-
- for (unsigned local_yb = 0; local_yb < image->vsample[cn]; ++local_yb) {
- for (unsigned local_xb = 0; local_xb < image->hsample[cn]; ++local_xb) {
+
+ uint8_t* pixel_write_pointer_y = image->pixel_write_pointer[cn];
+ for (unsigned local_yb = 0; local_yb < image->vsample[cn]; ++local_yb, pixel_write_pointer_y += image->stride[cn] * DCTSIZE) {
+ uint8_t* pixel_write_pointer = pixel_write_pointer_y;
+ for (unsigned local_xb = 0; local_xb < image->hsample[cn]; ++local_xb, pixel_write_pointer += DCTSIZE) {