Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/visualization/interaction/Highlighter.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,15 +86,15 @@ ROS3D.Highlighter.prototype.renderHighlights = function(scene, renderer, camera)

/**
* Traverses the given object and makes every object that's a Mesh,
* Line or Sprite invisible. Also saves the previous visibility state
* Line, Sprite or points invisible. Also saves the previous visibility state
* so we can restore it later.
*
* @param scene - the object to traverse
*/
ROS3D.Highlighter.prototype.makeEverythingInvisible = function (scene) {
scene.traverse(function(currentObject) {
if ( currentObject instanceof THREE.Mesh || currentObject instanceof THREE.Line
|| currentObject instanceof THREE.Sprite ) {
|| currentObject instanceof THREE.Sprite || currentObject instanceof THREE.Points ) {
currentObject.previousVisibility = currentObject.visible;
currentObject.visible = false;
}
Expand All @@ -111,7 +111,7 @@ ROS3D.Highlighter.prototype.makeEverythingInvisible = function (scene) {
ROS3D.Highlighter.prototype.makeHighlightedVisible = function (scene) {
var makeVisible = function(currentObject) {
if ( currentObject instanceof THREE.Mesh || currentObject instanceof THREE.Line
|| currentObject instanceof THREE.Sprite ) {
|| currentObject instanceof THREE.Sprite || currentObject instanceof THREE.Points ) {
currentObject.visible = true;
}
};
Expand Down