@@ -96,10 +96,12 @@ static void _get_screen_area(vectorio_vector_shape_t *self, displayio_area_t *ou
96
96
x = self -> absolute_transform -> x + self -> absolute_transform -> dx * self -> y ;
97
97
y = self -> absolute_transform -> y + self -> absolute_transform -> dy * self -> x ;
98
98
if (self -> absolute_transform -> dx < 1 ) {
99
+ x -= 1 ;
99
100
out_area -> y1 = out_area -> y1 * -1 + 1 ;
100
101
out_area -> y2 = out_area -> y2 * -1 + 1 ;
101
102
}
102
103
if (self -> absolute_transform -> dy < 1 ) {
104
+ y -= 1 ;
103
105
out_area -> x1 = out_area -> x1 * -1 + 1 ;
104
106
out_area -> x2 = out_area -> x2 * -1 + 1 ;
105
107
}
@@ -109,10 +111,12 @@ static void _get_screen_area(vectorio_vector_shape_t *self, displayio_area_t *ou
109
111
y = self -> absolute_transform -> y + self -> absolute_transform -> dy * self -> y ;
110
112
111
113
if (self -> absolute_transform -> dx < 1 ) {
114
+ x -= 1 ;
112
115
out_area -> x1 = out_area -> x1 * -1 + 1 ;
113
116
out_area -> x2 = out_area -> x2 * -1 + 1 ;
114
117
}
115
118
if (self -> absolute_transform -> dy < 1 ) {
119
+ y -= 1 ;
116
120
out_area -> y1 = out_area -> y1 * -1 + 1 ;
117
121
out_area -> y2 = out_area -> y2 * -1 + 1 ;
118
122
}
@@ -132,9 +136,11 @@ static void screen_to_shape_coordinates(vectorio_vector_shape_t *self, uint16_t
132
136
VECTORIO_SHAPE_PIXEL_DEBUG (" a(%3d, %3d)" , * out_shape_x , * out_shape_y );
133
137
if (self -> absolute_transform -> dx < 1 ) {
134
138
* out_shape_y *= -1 ;
139
+ * out_shape_y -= 1 ;
135
140
}
136
141
if (self -> absolute_transform -> dy < 1 ) {
137
142
* out_shape_x *= -1 ;
143
+ * out_shape_x -= 1 ;
138
144
}
139
145
VECTORIO_SHAPE_PIXEL_DEBUG (" b(%3d, %3d)" , * out_shape_x , * out_shape_y );
140
146
} else {
@@ -144,9 +150,11 @@ static void screen_to_shape_coordinates(vectorio_vector_shape_t *self, uint16_t
144
150
VECTORIO_SHAPE_PIXEL_DEBUG (" a(%3d, %3d)" , * out_shape_x , * out_shape_y );
145
151
if (self -> absolute_transform -> dx < 1 ) {
146
152
* out_shape_x *= -1 ;
153
+ * out_shape_x -= 1 ;
147
154
}
148
155
if (self -> absolute_transform -> dy < 1 ) {
149
156
* out_shape_y *= -1 ;
157
+ * out_shape_y -= 1 ;
150
158
}
151
159
VECTORIO_SHAPE_PIXEL_DEBUG (" b(%3d, %3d)" , * out_shape_x , * out_shape_y );
152
160
0 commit comments