shapes: set static usage on all VBs

This commit is contained in:
Kirill Vainer 2015-09-14 23:01:46 -04:00
parent 1aaf806c65
commit 6970c8db8a
5 changed files with 6 additions and 1 deletions

View File

@ -99,6 +99,7 @@ public class Grid extends Mesh {
updateBound();
updateCounts();
setStatic();
}
}

View File

@ -35,6 +35,7 @@ import com.jme3.math.Vector3f;
import com.jme3.scene.Mesh;
import com.jme3.scene.VertexBuffer;
import com.jme3.scene.VertexBuffer.Type;
import com.jme3.scene.VertexBuffer.Usage;
import com.jme3.util.BufferUtils;
import java.nio.FloatBuffer;
@ -62,6 +63,7 @@ public class WireFrustum extends Mesh {
3, 7,
}
);
getBuffer(Type.Index).setUsage(Usage.Static);
setMode(Mode.Lines);
}

View File

@ -389,6 +389,7 @@ public class Cylinder extends Mesh {
}
updateBound();
setStatic();
}
@Override

View File

@ -124,6 +124,7 @@ public class Quad extends Mesh {
}
updateBound();
setStatic();
}

View File

@ -299,7 +299,6 @@ public class Sphere extends Mesh {
}
updateBound();
setStatic();
}
/**
@ -400,6 +399,7 @@ public class Sphere extends Mesh {
this.interior = interior;
setGeometryData();
setIndexData();
setStatic();
}
public void read(JmeImporter e) throws IOException {