You can have a second camera render to a texture and use that texture in the UI. It’s expensive because you are rendering everything twice (once for the main view and another for the minimap) although you can reduce this by on rendering certain objects using cull masks (as shown here: https://developer.playcanvas.com/en/tutorials/camera-model-masking/)
There are a number of other ways to implement a minimap including:
- Pre-rendering to texture at the start of the level and add the dynamic elements on top
- Have the world represented in data (eg for RTS Command and Conquer where everything is grid based, it might be represented in a 2D grid) and populate the minimap using that data