@@ -243,10 +243,6 @@ function vtkOpenGLVolumeMapper(publicAPI, model) {
243
243
const shadowFactor = '' ;
244
244
245
245
switch ( model . lastLightComplexity ) {
246
- default :
247
- case 0 : // no lighting, tcolor is fine as is
248
- break ;
249
-
250
246
case 1 : // headlight
251
247
case 2 : // light kit
252
248
case 3 : {
@@ -287,7 +283,10 @@ function vtkOpenGLVolumeMapper(publicAPI, model) {
287
283
lightNum ++ ;
288
284
}
289
285
} ) ;
286
+ break ;
290
287
}
288
+ case 0 : // no lighting, tcolor is fine as is
289
+ default :
291
290
}
292
291
293
292
shaders . Fragment = FSSource ;
@@ -702,11 +701,6 @@ function vtkOpenGLVolumeMapper(publicAPI, model) {
702
701
const pos2 = new Float64Array ( 3 ) ;
703
702
for ( let i = 0 ; i < 6 ; ++ i ) {
704
703
switch ( i ) {
705
- default :
706
- case 0 :
707
- vec3 . set ( normal , 1.0 , 0.0 , 0.0 ) ;
708
- vec3 . set ( pos2 , ext [ 1 ] , ext [ 3 ] , ext [ 5 ] ) ;
709
- break ;
710
704
case 1 :
711
705
vec3 . set ( normal , - 1.0 , 0.0 , 0.0 ) ;
712
706
vec3 . set ( pos2 , ext [ 0 ] , ext [ 2 ] , ext [ 4 ] ) ;
@@ -727,6 +721,11 @@ function vtkOpenGLVolumeMapper(publicAPI, model) {
727
721
vec3 . set ( normal , 0.0 , 0.0 , - 1.0 ) ;
728
722
vec3 . set ( pos2 , ext [ 0 ] , ext [ 2 ] , ext [ 4 ] ) ;
729
723
break ;
724
+ case 0 :
725
+ default :
726
+ vec3 . set ( normal , 1.0 , 0.0 , 0.0 ) ;
727
+ vec3 . set ( pos2 , ext [ 1 ] , ext [ 3 ] , ext [ 5 ] ) ;
728
+ break ;
730
729
}
731
730
vec3 . transformMat3 ( normal , normal , model . idxNormalMatrix ) ;
732
731
vec3 . transformMat4 ( pos2 , pos2 , model . idxToView ) ;
@@ -759,10 +758,6 @@ function vtkOpenGLVolumeMapper(publicAPI, model) {
759
758
760
759
// handle lighting values
761
760
switch ( model . lastLightComplexity ) {
762
- default :
763
- case 0 : // no lighting, tcolor is fine as is
764
- break ;
765
-
766
761
case 1 : // headlight
767
762
case 2 : // light kit
768
763
case 3 : {
@@ -799,7 +794,11 @@ function vtkOpenGLVolumeMapper(publicAPI, model) {
799
794
}
800
795
} ) ;
801
796
// mat3.transpose(keyMats.normalMatrix, keyMats.normalMatrix);
797
+ break ;
802
798
}
799
+ case 0 : // no lighting, tcolor is fine as is
800
+ default :
801
+ break ;
803
802
}
804
803
} ;
805
804
0 commit comments