1.1 --- a/lib/display.c Tue Nov 13 18:39:07 2018 +0100
1.2 +++ b/lib/display.c Tue Nov 13 22:33:09 2018 +0100
1.3 @@ -164,11 +164,11 @@
1.4 /* Copying from/to the display to/from a backing store. */
1.5
1.6 void display_copy(display_config_t *cfg, uint8_t *store,
1.7 - int width, int height, int ystep,
1.8 + int width, int height,
1.9 int x, int y, int key, int to_display)
1.10 {
1.11 display_copy_section(cfg, store, width, height,
1.12 - 0, 0, width, height, ystep,
1.13 + 0, 0, width, height,
1.14 x, y, key, to_display);
1.15 }
1.16
1.17 @@ -176,7 +176,7 @@
1.18
1.19 void display_copy_section(display_config_t *cfg, uint8_t *store,
1.20 int width, int height,
1.21 - int xstart, int ystart, int xsize, int ysize, int ystep,
1.22 + int xstart, int ystart, int xsize, int ysize,
1.23 int x, int y, int key, int to_display)
1.24 {
1.25 int sx, sy, dx, dy;
1.26 @@ -196,7 +196,7 @@
1.27
1.28 /* Perform the copying between the store and display. */
1.29
1.30 - for (sy = ystart, dy = y; (sy < ylimit) && (dy < cfg->line_count); sy += ystep, dy++)
1.31 + for (sy = ystart, dy = y; (sy < ylimit) && (dy < cfg->line_count); sy += 1, dy++)
1.32 {
1.33 for (sx = xstart, dx = x; (sx < xlimit) && (dx < cfg->line_length); sx++, dx++)
1.34 {
1.35 @@ -210,7 +210,7 @@
1.36 storeline[sx] = displayline[display_get_position(cfg, dx)];
1.37 }
1.38
1.39 - storeline += width * ystep;
1.40 + storeline += width;
1.41 displayline = display_wrap_pointer(cfg, displayline + cfg->line_length);
1.42 }
1.43 }