mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-06 07:14:55 +08:00
[threejs] Don't mark buffer objects for an update if they are zero length. Fixes #1345.
This commit is contained in:
parent
23982e8206
commit
2dc619a76c
@ -9865,11 +9865,11 @@ var spine;
|
||||
this.indicesLength += indicesLength;
|
||||
};
|
||||
MeshBatcher.prototype.end = function () {
|
||||
this.vertexBuffer.needsUpdate = true;
|
||||
this.vertexBuffer.needsUpdate = this.verticesLength > 0;
|
||||
this.vertexBuffer.updateRange.offset = 0;
|
||||
this.vertexBuffer.updateRange.count = this.verticesLength;
|
||||
var geo = this.geometry;
|
||||
geo.getIndex().needsUpdate = true;
|
||||
geo.getIndex().needsUpdate = this.indicesLength > 0;
|
||||
geo.getIndex().updateRange.offset = 0;
|
||||
geo.getIndex().updateRange.count = this.indicesLength;
|
||||
geo.drawRange.start = 0;
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -6995,11 +6995,11 @@ var spine;
|
||||
this.indicesLength += indicesLength;
|
||||
};
|
||||
MeshBatcher.prototype.end = function () {
|
||||
this.vertexBuffer.needsUpdate = true;
|
||||
this.vertexBuffer.needsUpdate = this.verticesLength > 0;
|
||||
this.vertexBuffer.updateRange.offset = 0;
|
||||
this.vertexBuffer.updateRange.count = this.verticesLength;
|
||||
var geo = this.geometry;
|
||||
geo.getIndex().needsUpdate = true;
|
||||
geo.getIndex().needsUpdate = this.indicesLength > 0;
|
||||
geo.getIndex().updateRange.offset = 0;
|
||||
geo.getIndex().updateRange.count = this.indicesLength;
|
||||
geo.drawRange.start = 0;
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -98,11 +98,11 @@ module spine.threejs {
|
||||
}
|
||||
|
||||
end () {
|
||||
this.vertexBuffer.needsUpdate = true;
|
||||
this.vertexBuffer.needsUpdate = this.verticesLength > 0;
|
||||
this.vertexBuffer.updateRange.offset = 0;
|
||||
this.vertexBuffer.updateRange.count = this.verticesLength;
|
||||
let geo = (<THREE.BufferGeometry>this.geometry);
|
||||
geo.getIndex().needsUpdate = true;
|
||||
geo.getIndex().needsUpdate = this.indicesLength > 0;
|
||||
geo.getIndex().updateRange.offset = 0;
|
||||
geo.getIndex().updateRange.count = this.indicesLength;
|
||||
geo.drawRange.start = 0;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user