use glUsage variable

This commit is contained in:
codeanticode
2015-11-15 16:21:30 -05:00
parent f2c32f5143
commit 03953fd26a
2 changed files with 3 additions and 3 deletions
@@ -9764,7 +9764,7 @@ public class PGraphicsOpenGL extends PGraphics {
trimPolySpecular();
trimPolyEmissive();
trimPolyShininess();
trimAttributes();
trimPolyAttributes();
}
if (0 < polyIndexCount && polyIndexCount < polyIndices.length) {
@@ -9848,7 +9848,7 @@ public class PGraphicsOpenGL extends PGraphics {
polyShininessBuffer = PGL.allocateFloatBuffer(polyShininess);
}
void trimAttributes() {
void trimPolyAttributes() {
for (String name: polyAttribs.keySet()) {
VertexAttribute attrib = polyAttribs.get(name);
if (attrib.type == PGL.FLOAT) {
+1 -1
View File
@@ -3879,7 +3879,7 @@ public class PShapeOpenGL extends PShape {
if (!attrib.bufferCreated()) attrib.createBuffer(pgl);
pgl.bindBuffer(PGL.ARRAY_BUFFER, attrib.buf.glId);
pgl.bufferData(PGL.ARRAY_BUFFER, attrib.sizeInBytes(size),
tessGeo.polyAttribBuffers.get(name), PGL.STATIC_DRAW);
tessGeo.polyAttribBuffers.get(name), glUsage);
}
pgl.bindBuffer(PGL.ARRAY_BUFFER, 0);