Browse Source

fix compose between 2-d and 3-d mats

David Rose 19 years ago
parent
commit
6f21efb679
1 changed files with 1 additions and 1 deletions
  1. 1 1
      panda/src/pgraph/transformState.cxx

+ 1 - 1
panda/src/pgraph/transformState.cxx

@@ -1370,7 +1370,7 @@ do_compose(const TransformState *other) const {
   }
 
   // Do the operation with matrices.
-  if (is_2d()) {
+  if (is_2d() && other->is_2d()) {
     LMatrix3f new_mat = other->get_mat3() * get_mat3();
     return make_mat3(new_mat);
   } else {