Skip to main content
added 148 characters in body
Source Link

I'm rendering the camera output to an rendertexture on a plane. This works fine. But I want to put GameObjects on the rendertexture on positions of world objects that are visible on the camera.

camera.WorldToViewportPoint(obj.transform.position) shows the correct positions, but is not mapped to the rendertexture. How can I do this?

So it's GameObject in world > camera input > plane with RenderTexture > world or local position of gameobject on top of rendertexture plane.

I'm rendering the camera output to an rendertexture on a plane. This works fine. But I want to put GameObjects on the rendertexture on positions of world objects that are visible on the camera.

camera.WorldToViewportPoint(obj.transform.position) shows the correct positions, but is not mapped to the rendertexture. How can I do this?

I'm rendering the camera output to an rendertexture on a plane. This works fine. But I want to put GameObjects on the rendertexture on positions of world objects that are visible on the camera.

camera.WorldToViewportPoint(obj.transform.position) shows the correct positions, but is not mapped to the rendertexture. How can I do this?

So it's GameObject in world > camera input > plane with RenderTexture > world or local position of gameobject on top of rendertexture plane.

Source Link

get position of GameObject on rendertexture from camera

I'm rendering the camera output to an rendertexture on a plane. This works fine. But I want to put GameObjects on the rendertexture on positions of world objects that are visible on the camera.

camera.WorldToViewportPoint(obj.transform.position) shows the correct positions, but is not mapped to the rendertexture. How can I do this?