File tree Expand file tree Collapse file tree 2 files changed +8
-12
lines changed
soba/performances/src/instances Expand file tree Collapse file tree 2 files changed +8
-12
lines changed Original file line number Diff line number Diff line change 53
53
"parallel" : true
54
54
}
55
55
},
56
+ "publish" : {
57
+ "command" : " npm publish" ,
58
+ "cwd" : " dist/libs/core"
59
+ },
56
60
"test" : {
57
61
"executor" : " @nx/jest:jest" ,
58
62
"outputs" : [" {workspaceRoot}/coverage/{projectRoot}" ],
Original file line number Diff line number Diff line change @@ -103,27 +103,19 @@ export class NgtsInstance {
103
103
standalone : true ,
104
104
template : `
105
105
<ngt-instanced-mesh
106
+ *args="[undefined, undefined, 0]"
106
107
[userData]="{ instances: meshes() }"
107
108
[ref]="instancesRef"
108
109
[matrixAutoUpdate]="false"
109
110
[raycast]="nullRaycast"
110
- *args="[undefined, undefined, 0]"
111
111
ngtCompound
112
112
>
113
113
<ngt-instanced-buffer-attribute
114
+ *args="[matrices(), 16]"
114
115
attach="instanceMatrix"
115
- [count]="matrices().length / 16"
116
- [array]="matrices()"
117
- [itemSize]="16"
118
- [usage]="DynamicDrawUsage"
119
- />
120
- <ngt-instanced-buffer-attribute
121
- attach="instanceColor"
122
- [count]="colors().length / 3"
123
- [array]="colors()"
124
- [itemSize]="3"
125
116
[usage]="DynamicDrawUsage"
126
117
/>
118
+ <ngt-instanced-buffer-attribute *args="[colors(), 3]" attach="instanceColor" [usage]="DynamicDrawUsage" />
127
119
<ng-container *ngTemplateOutlet="content" />
128
120
</ngt-instanced-mesh>
129
121
` ,
@@ -205,7 +197,7 @@ export class NgtsInstances {
205
197
this . matrices ( ) ,
206
198
this . colors ( ) ,
207
199
] ;
208
- if ( frames === Infinity || count < frames ) {
200
+ if ( ( frames === Infinity || count < frames ) && instancedMesh ) {
209
201
instancedMesh . updateMatrix ( ) ;
210
202
instancedMesh . updateMatrixWorld ( ) ;
211
203
parentMatrix . copy ( instancedMesh . matrixWorld ) . invert ( ) ;
You can’t perform that action at this time.
0 commit comments