1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Minor tidying.

This commit is contained in:
jules 2013-10-28 13:59:09 +00:00
parent 63587c007b
commit 569fe21e7f

View file

@ -69,48 +69,45 @@ bool PathFlatteningIterator::next()
float y3 = 0;
float x4 = 0;
float y4 = 0;
float type;
for (;;)
{
float type;
if (stackPos == stackBase)
{
if (index >= path.numElements)
{
return false;
}
else
type = points [index++];
if (type != Path::closeSubPathMarker)
{
type = points [index++];
x2 = points [index++];
y2 = points [index++];
if (type != Path::closeSubPathMarker)
if (type == Path::quadMarker)
{
x2 = points [index++];
y2 = points [index++];
x3 = points [index++];
y3 = points [index++];
if (type == Path::quadMarker)
{
x3 = points [index++];
y3 = points [index++];
if (! isIdentityTransform)
transform.transformPoints (x2, y2, x3, y3);
}
else if (type == Path::cubicMarker)
{
x3 = points [index++];
y3 = points [index++];
x4 = points [index++];
y4 = points [index++];
if (! isIdentityTransform)
transform.transformPoints (x2, y2, x3, y3);
}
else if (type == Path::cubicMarker)
{
x3 = points [index++];
y3 = points [index++];
x4 = points [index++];
y4 = points [index++];
if (! isIdentityTransform)
transform.transformPoints (x2, y2, x3, y3, x4, y4);
}
else
{
if (! isIdentityTransform)
transform.transformPoint (x2, y2);
}
if (! isIdentityTransform)
transform.transformPoints (x2, y2, x3, y3, x4, y4);
}
else
{
if (! isIdentityTransform)
transform.transformPoint (x2, y2);
}
}
}
@ -150,7 +147,8 @@ bool PathFlatteningIterator::next()
return true;
}
else if (type == Path::quadMarker)
if (type == Path::quadMarker)
{
const size_t offset = (size_t) (stackPos - stackBase);