Revision 77e9d967
Added by Leszek Koltunski almost 5 years ago
src/main/java/org/distorted/examples/meshjoin/MeshJoinRenderer.java | ||
---|---|---|
140 | 140 |
final int[] FACE_COLORS = new int[] { 0xffffff00, 0xff00ff00, 0xff0000ff, 0xffff0000 }; |
141 | 141 |
final int FACES=FACE_COLORS.length; |
142 | 142 |
int SIZE = 128; |
143 |
int STROKE = SIZE/20;
|
|
144 |
int OFF = STROKE/2 -1;
|
|
145 |
int OFF2 = (int)(0.577f*SIZE) + OFF;
|
|
146 |
int HEIGHT = SIZE - OFF;
|
|
147 |
int RADIUS = SIZE/12;
|
|
148 |
int ARC1_H = (int)(0.31f*SIZE);
|
|
143 |
float STROKE = 0.05f*SIZE;
|
|
144 |
float OFF = STROKE/2 -1;
|
|
145 |
float OFF2 = 0.577f*SIZE + OFF;
|
|
146 |
float HEIGHT = SIZE - OFF;
|
|
147 |
float RADIUS = SIZE/12;
|
|
148 |
float ARC1_H = 0.31f*SIZE;
|
|
149 | 149 |
float ARC1_W = SIZE*0.5f; |
150 |
float ARC2_W = 19.5f;
|
|
151 |
float ARC2_H = 116.5f;
|
|
152 |
float ARC3_W = 108.5f;
|
|
150 |
float ARC2_W = 0.152f*SIZE;
|
|
151 |
float ARC2_H = 0.91f*SIZE;
|
|
152 |
float ARC3_W = 0.847f*SIZE;
|
|
153 | 153 |
|
154 | 154 |
Bitmap result = Bitmap.createBitmap(FACES*SIZE,SIZE, Bitmap.Config.ARGB_8888); |
155 | 155 |
Canvas canvas = new Canvas(result); |
Also available in: Unified diff
Some progress with Pyraminx.