Marble Floor with simple reflections

Using reflections can lend credence to the realistic look you’re trying to achieve. This is especially true when you’re working with a reflective material or object, like a marble floor. Fortunately, Unity has made it easy to create more realistic reflections without the need for complex and complicated steps.

Reflection Probes

One way to achieve reflections is to use a Reflection Probe. This probe acts like a camera by looking at the data around it and captures it. The probe then generates a Cubemap that allows it to reflect what’s in the environment and can change according.

In order to edit the probe, you must first create it.

Start by adding it into the Hierarchy window by

Right Click -> Light -> Reflection Probe

This in turn will create a reflection probe in the shape of a wireframe cube in your scene

Next, move the cube to the object you want the reflections on.

In this case, because I want the reflections on the floor, I moved the cube towards the middle of the marble floor and had it intrude a bit underneath the floor. This is to ensure the reflection probe takes into account the floor as well.

Next, with the probe selected, click on the 3 connected dots connecting them in the Inspector Panel.

This in turn will allow you to resize the cube.

Resize it to your need and reclick on the 3 connected dots in the Inspector Panel to exit out of Edit mode.

The final size of the reflection probe

Even though there is a reflection, note that the size, location, and quality of the reflections are off.

Notice the reflection of the doors is right below the wall panels

One might wonder if reflection probes can’t create realistic reflections, why would anyone use it. The main reason is the lower processing power needed to generate realistic reflections. For instance, if you’re making a mobile game or an object that you want reflections on but is miniscule in the overall scene, using reflection probes is the best way to achieve realistic reflections without dedicating a lot of processing power to create said reflections.

Screen Space Reflections

On the other hand, if you have the processing power to support more realistic reflections, like a computer or console, you can instead use screen space reflections. Screen Space Reflections, or SSR, is great when you want to create reflections on wet, shiny, or mirrored surfaces. However, because it uses Unity’s Post-Processing package, you’ll need to implement it if you have not.

After downloading the Post Processing package, you can create a Post Processing Profile by

Right-click in the Project Window -> Create -> Post-processing Profile

Next, with the new profile selected, click on Add Effect in the Inspector Panel and add Screen-Space Reflections

Depending on the Unity version you’re currently using, you might have to add both the Post-Process Layer and Post-Process Volume onto your Main Camera in order for SSR to work. You can add both by clicking on Add Component in the Inspector panel when viewing the Main Camera’s properties

Due to how the Post Process method works in Unity, there might be a few more steps.

  1. Red Box: Add the Main Camera as the Trigger
  2. Green Box: Add a new Layer. In this case, I called my new layer “Post”. In addition, change the Layer to the layer you just created.
  3. Blue Box: Change the layer to the new layer you just created.

Fortunately, Post Process Volume is straightforward. Just add the Post Process Profile you created in Step 1 in the slot next to the Profile.

Now you can play around with the settings and watch it change before your eyes in the Scene view.

The reflections are much more realistic this time and the size stays consistent to the actual object.

Furthermore, if you move around the scene, not only does the reflection stays with the object, the size also stays the same!