553 |
553 |
{
|
554 |
554 |
int COLORS = FACE_COLORS.length;
|
555 |
555 |
FactorySticker factory = FactorySticker.getInstance();
|
556 |
|
float S1 = 0.050f;
|
557 |
|
float S2 = 0.051f;
|
558 |
|
float R1 = 0.07f;
|
559 |
|
float R2 = 0.02f;
|
560 |
|
float R3 = 0.06f;
|
561 |
|
float R4 = 0.04f;
|
562 |
556 |
|
563 |
557 |
if( face<COLORS )
|
564 |
558 |
{
|
565 |
|
factory.drawRexCornerSticker(canvas, paint, left, top, FACE_COLORS[face%COLORS], S1, R2, R3);
|
|
559 |
float S = 0.05f;
|
|
560 |
float R = 0.02f;
|
|
561 |
float ANGLE = (float)(Math.PI/15);
|
|
562 |
float F = REX_D*SQ2;
|
|
563 |
float G = (1-REX_D)*SQ2/2;
|
|
564 |
float[] vertices = new float[] { F/2, -G/3, -F/2, -G/3, 0, 2*G/3 };
|
|
565 |
float[] angles = new float[] { -ANGLE/2, ANGLE, ANGLE };
|
|
566 |
|
|
567 |
factory.drawRoundedPolygon(canvas, paint, left, top, vertices, angles, S, FACE_COLORS[face%COLORS], R);
|
566 |
568 |
}
|
567 |
569 |
else if( face<2*COLORS )
|
568 |
570 |
{
|
|
571 |
float S = 0.035f;
|
|
572 |
float R = 0.040f;
|
569 |
573 |
float[] vertices = { -REX_D,0.0f, 0.0f, -REX_D, +REX_D, 0.0f, 0.0f, +REX_D};
|
570 |
|
factory.drawRoundedPolygon(canvas, paint, left, top, vertices, null, S1, FACE_COLORS[face%COLORS], R4);
|
|
574 |
factory.drawRoundedPolygon(canvas, paint, left, top, vertices, null, S, FACE_COLORS[face%COLORS], R);
|
571 |
575 |
}
|
572 |
576 |
else
|
573 |
577 |
{
|
574 |
|
factory.drawRexEdgeSticker(canvas, paint, left, top, FACE_COLORS[face%COLORS], S2, R1);
|
|
578 |
float S = 0.051f;
|
|
579 |
float R = 0.070f;
|
|
580 |
factory.drawRexEdgeSticker(canvas, paint, left, top, FACE_COLORS[face%COLORS], S, R);
|
575 |
581 |
}
|
576 |
582 |
}
|
577 |
583 |
|
Convert the Rex corner sticker to the new mechanism.