don't use alias

This commit is contained in:
Konstantin Käfer
2014-01-29 12:55:59 +01:00
parent 9fc749eade
commit 80ec5742b5

View File

@@ -20,12 +20,9 @@ void LineBuffer::add(int16_t x, int16_t y, float ex, float ey, int8_t tx, int8_t
array.push_back((y * 2) | ty);
array.push_back(linesofar);
int16_t extrude = 0;
int8_t *extrude_x = ((int8_t *)&extrude) + 0;
int8_t *extrude_y = ((int8_t *)&extrude) + 1;
*extrude_x = round(extrudeScale * ex);
*extrude_y = round(extrudeScale * ey);
*(((int8_t *)&extrude) + 0) = round(extrudeScale * ex);
*(((int8_t *)&extrude) + 1) = round(extrudeScale * ey);
array.push_back(extrude);
if (!dirty) dirty = true;