Hide and Show Objects — Scene Visibility in Unity

Use Unity’s Scene Visibility (SceneVis) controls to quickly hide and show objects in the Scene View, without changing the object’s in-game visibility. Read this section to learn how to use SceneVis tools, including keyboard shortcuts, visibility toggle methods, and Isolation.

The first appearance of Scene Visibility controls is noticed in Unity 2019.1.

Hide and Show Object in Unity 2019 — New Scene Visibility

Goals for SceneVis:

  • Quick access to hide and show object via keyboard shortcuts, or hierarchy buttons;
  • 100% granular visual control, i.e. can hide/show individual items, parents don’t override;
  • A clear indication of hiding/showing state in the Hierarchy, without getting cluttered;
  • Ability to enable/disable the effects of SceneVis, without losing hide/show states;
  • Save vis state info, but never “dirty” the scene, play nice with source control.

Scene Visibility Overview

As a scene becomes more detailed, it often helps to temporarily hide and show specific objects, allowing you to view, select, and edit without obstructions. Scene Visibility enables this functionality via hierarchy tools and keyboard shortcuts, plus a toolbar toggle to quickly enable or disable the effects (similar to the Scene Lighting toggle).

A special “Isolate” action will immediately show only the selected objects, then revert to the previous SceneVis settings when Isolation is exited.

Hide and Show Object in Unity 2019 — New Scene Visibility

Because SceneVis only affects the editor Scene View, in-game visuals do not change. This means your scenes won’t have accidentally missing items, and hiding an object will not trigger bakes for lighting, occlusion, or other systems.

Additionally, SceneVis modifications are always saved, but only locally- hiding and showing objects with SceneVis will not create source control conflicts.

UI and Keyboard Shortcuts

SceneVis Hierarchy Column

This column displays visibility status for each item in the hierarchy:

  1. This item and its children are visible;
  2. This item and its children are hidden;
  3. This item is visible but has some hidden children;
  4. This item is hidden but has some visible children.

Hide and Show Object in Unity 2019 — New Scene Visibility

If an item and all its children are visible, they will only show a status icon on hover.

SceneVis Toolbar Toggle

Click to enable or disable the effects of SceneVis (image on, image off).

SceneVis Toolbar Toggle - Unity 2019

Keyboard Shortcuts

SceneVis does not include default keyboard shortcuts (currently). However, you can set your own easily:

  • From the top menu, choose next to open the Shortcuts panel:
    • “Edit > Shortcuts” on Windows,
    • “Unity > Shortcuts” on Mac OS X;
  • In the “Category” column, choose “Scene Visibility”;
  • Set your shortcuts as desired.

Scene Visibility - Shortcuts

Hide and Show Objects

Hide and Show Individual Object:

  1. Hover your mouse over a visible item, and you should see the “Visible” icon show.
  2. Move your mouse over the icon (it will highlight), and click to toggle it’s status to Hidden.
  3. The item becomes Hidden, and will now show the “Hidden” icon.
  4. Click again to toggle back to Visible.

Scene Visibility - Unity 2019 - Hide and Show Object in Hierarchy

Hide and Show Object + Children:

  1. Hover your mouse over an item with several children;
  2. Move your mouse over the icon (it will highlight);
  3. Hold ALT and click;
  4. The item and all its children will become Hidden, and will now show the “Hidden” icon;
  5. Hold ALT and click again to toggle back to Visible.

Isolate Selection: Isolate Objects in Hierarchy

Isolate Selection - SceneVis Overview - Unity 2019

Isolate Selection is a special function that allows you to immediately narrow your view to a selection of objects, then pop back to the “normal” scene view. Any visibility changes you make while in Isolation are temporary.

Currently, you will need to set up the “Isolate Selection” shortcut by yourself: Cmd + Shift + I.

Using Isolate:

  1. Hide several random objects in your scene, just for example’s sake;
  2. Select one hidden item and one visible item;
  3. Press the keyboard shortcut for “Isolate Selection”;
  4. Note that all non-selected items are now hidden, and the two items you selected are visible including the previously hidden item;
  5. Look in the bottom-right of your Scene View, click the “Exit” button under “Isolation”;
  6. Note that all items are back to the pre-isolation visibility status.

Editor Extensions for Hiding and Showing Game Objects

If you are exciting about the topic and want to level up with Game Objects Isolating and Hierarchy View in whole, you need to consider next Editor Extensions from Unity Asset Store:

We hope this article helped you use Scene Visibility with Unity. You may also want to see our other step by step Unity Tutorials.

Hide and Show Objects — Scene Visibility in Unity
Hide and Show Objects — Scene Visibility in Unity 1

Use Unity's Scene Visibility (SceneVis) controls to quickly hide and show objects in the Scene View, without changing the object's in-game visibility.

Editor's Rating:
5
Support for Unity Assets
I am Andrew Sirota, Founder at Makaka Games and full-time Publisher on Unity Asset Store. First of all, read the latest docs online. If it didn’t help, get the support.
Related Articles
Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button

Spelling error report

The following text will be sent to our editors: