I have a Player Camera and I want to show the Camera over a RawImage RenderTexture.
I created a RenderTexture and assigned t to the rawimage Texture.
The RawImage is a child of a new Camera set to the Solid Color black and culling mask set to nothing.
The Player Camera is set to skybox and everything.
Screenshots :
Player Camera :
The Camera under Main Menu :
The Raw Image :
I also have a script that I use the escape key to get to the main menu and display the player camera live in the raw image :
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Switch : MonoBehaviour
{
public GameObject[] cameras;
public RenderTexture guiCameraRenderTexture;
// Start is called before the first frame update
void Start()
{
}
// Update is called once per frame
void Update()
{
if(Input.GetKeyDown(KeyCode.Escape))
{
var cam0 = cameras[0].GetComponent<Camera>();
cam0.targetTexture = guiCameraRenderTexture;
cameras[1].SetActive(true);
}
}
}
While the game is running and pressing the escape key :
The Raw Image size is set to 300 on 300 and it looks more or less fine but still not sharp as if I switch to the player camera. On the raw image it looks like some blurry. And if I change the raw image size to 400 on 400 or even 600 on 600 it looks very bad the player camera.
The idea the main goal is to show the player camera live on the raw image when pressing on escape.
The problem is that the player camera looks with low quality on the raw image. It looks great when it’s not on the raw image.
This is the RenderTexture settings :
What I want to do is to display live the player camera on the raw image. But the player camera quality on the raw image is too bad. I can’t figure out how to directly show thew player camera with it’s original quality. Or what to change/add in the raw image or render texture to make it looks in highest quality.




