Browse Source

renderOrder = Infinity

Atrahasis 7 years ago
parent
commit
0f934852e1
1 changed files with 3 additions and 0 deletions
  1. 3 0
      examples/js/controls/TransformControls.js

+ 3 - 0
examples/js/controls/TransformControls.js

@@ -136,6 +136,9 @@
 
 						object.name = name;
 
+						//always render on top of the scene (avoid being hidden by transparent objects)
+						object.renderOrder = Infinity;
+
 						if ( position ) object.position.set( position[ 0 ], position[ 1 ], position[ 2 ] );
 						if ( rotation ) object.rotation.set( rotation[ 0 ], rotation[ 1 ], rotation[ 2 ] );