Skip to content

Commit ad7b749

Browse files
author
mfiess
authored
updates for windows (pxscene#614)
1 parent b02c676 commit ad7b749

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

examples/pxScene2d/src/rasterizer/pxPath.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -739,7 +739,7 @@ void pxPath::pushOpcode(uint8_t op)
739739

740740
void pxPath::pushFloat(float f)
741741
{
742-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
742+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
743743
floatBytes_t fb = {.f = f};
744744
#else
745745
// support older toolchain
@@ -784,7 +784,7 @@ float pxPath::getFloatAt(int i)
784784
return 0;
785785
}
786786

787-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
787+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
788788
floatBytes_t fb = {.bytes =
789789
{
790790
opStream[i + 3], opStream[i + 2],
@@ -816,7 +816,7 @@ float pxPath::getFloatAt(const uint8_t *p)
816816
return 0;
817817
}
818818

819-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
819+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
820820
floatBytes_t fb = {.bytes =
821821
{
822822
p[3], p[2], p[1], p[0]
@@ -867,7 +867,7 @@ static point2d_t mapToEllipse(point2d_t xy, point2d_t rxy, a2cReal_t cosphi, a2c
867867
const a2cReal_t xp = cosphi * xy.x - sinphi * xy.y;
868868
const a2cReal_t yp = sinphi * xy.x + cosphi * xy.y;
869869

870-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
870+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
871871
return point2d_t( { .x = xp + centerx,.y = yp + centery } );
872872
#else
873873
// support older toolchain
@@ -903,7 +903,7 @@ static uarc_t approxUnitArc(a2cReal_t ang1, a2cReal_t ang2)
903903
const a2cReal_t x2 = cos(ang1 + ang2);
904904
const a2cReal_t y2 = sin(ang1 + ang2);
905905

906-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
906+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
907907
return uarc_t( {
908908
.pt1 = point2d_t( { .x = x1 - y1 * a , .y = y1 + x1 * a } ),
909909
.pt2 = point2d_t( { .x = x2 + y2 * a , .y = y2 - x2 * a } ),
@@ -999,7 +999,7 @@ static acenter_t getArcCenter( a2cReal_t px,
999999
if (sweepFlag == 0.0 && ang2 > 0.0) { ang2 -= TAU; }
10001000
if (sweepFlag == 1.0 && ang2 < 0.0) { ang2 += TAU; }
10011001

1002-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
1002+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
10031003
return acenter_t( { .c = point2d_t( { .x = centerx,
10041004
.y = centery } ),
10051005
.ang1 = ang1,
@@ -1085,7 +1085,7 @@ static bcurves_t arcToBezier(a2cReal_t px, a2cReal_t py,
10851085
ang1 += ang2;
10861086
}
10871087

1088-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
1088+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
10891089
const point2d_t rxy = { .x = rx, .y = ry };
10901090
#else
10911091
// support older toolchain
@@ -1104,7 +1104,7 @@ static bcurves_t arcToBezier(a2cReal_t px, a2cReal_t py,
11041104
point2d_t xy2 = mapToEllipse(curve.pt2, rxy, cosphi, sinphi, center.c.x, center.c.y);
11051105
point2d_t xy = mapToEllipse(curve.pt3, rxy, cosphi, sinphi, center.c.x, center.c.y);
11061106

1107-
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB)
1107+
#if !defined(PX_PLATFORM_DFB_NON_X11) && !defined(PX_PLATFORM_GENERIC_DFB) && !defined(PX_PLATFORM_WIN)
11081108
bcurves.push_back( bcurve_t( {
11091109
.xy1 = xy1,
11101110
.xy2 = xy2,

0 commit comments

Comments
 (0)