Fixed context and edge init in PShape3D

This commit is contained in:
codeanticode
2012-03-31 19:42:16 +00:00
parent d49a72aba7
commit ce64c2e5ff
4 changed files with 36 additions and 18 deletions

View File

@@ -6111,6 +6111,7 @@ public class PGraphicsOpenGL extends PGraphics {
public int[] emissive;
public float[] shininess;
// TODO: this should probably go in the TessGeometry class
public int[][] edges;
// For later, to be used by libraries...
@@ -6127,6 +6128,12 @@ public class PGraphicsOpenGL extends PGraphics {
edgeCount = firstEdge = lastEdge = 0;
}
public void clearEdges() {
edgeCount = firstEdge = lastEdge = 0;
}
public void allocate() {
codes = new int[PGL.DEFAULT_IN_VERTICES];
vertices = new float[3 * PGL.DEFAULT_IN_VERTICES];