Search Unity

How can I have a second camera (3D minimap) that does not render background

Discussion in 'General Graphics' started by uo7_unity, Apr 7, 2021.

  1. uo7_unity

    uo7_unity

    Joined:
    Jan 30, 2021
    Posts:
    1
    I have a ship flying in space and enemies represented by red cubes, and I have second camera that renders like a minimap, as seen in this tutorial:

    And in game shown as such, intended to act like a 3D radar with the player in the middle of the circle and enemies around it:

    This camera also uses a culling mask, so it only renders certain GameObjects (namely the red enemies and the player in the middle), but I can't keep it from also rendering a background -it either renders skybox or a solid color
    Is there a way to render a "transparent" skybox, one when overlapped with the main camera, only renders the objects but not the background/skybox?

    Thank for any help/advice in advance
     
  2. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,343
    Camera component -> Clear Flags = Depth