File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -182,10 +182,10 @@ sub new {
182182 my ($type ,$points ,$faceidx ,$colors ) = @_ ;
183183 my $this = $type -> SUPER::new($points ,$colors ,$options );
184184 $faceidx = $this -> {Faceidx } = $faceidx -> ulong; # (3,nfaces) indices
185- $options = $this -> {Options };
186- my ($idxflat , $idx0 , @idxdims ) = ($faceidx -> flat, $faceidx -> dims);
187185 PDL::barf " Triangles error: broadcast dimensions forbidden for '$_ ' [@{[$this ->{$_ }->dims]}]" for grep $this -> {$_ }-> ndims != 2, qw( Points Colors Faceidx) ;
188186 PDL::barf " Triangles error: dimension mismatch between Points [@{[$this ->{Points}->dims]}] and Colors [@{[$this ->{Colors}->dims]}]" if $this -> {Points }-> ndims != $this -> {Colors }-> ndims or $this -> {Points }-> dim(1) != $this -> {Colors }-> dim(1);
187+ $options = $this -> {Options };
188+ my ($idxflat , $idx0 , @idxdims ) = ($faceidx -> flat, $faceidx -> dims);
189189 if ($options -> {Shading } or $options -> {ShowNormals }) {
190190 my ($fn , $vn ) = triangle_normals($this -> {Points }, $faceidx );
191191 if ($options -> {ShowNormals }) {
You can’t perform that action at this time.
0 commit comments