- Home /
Feeding a GBuffer to a camera
As the title says, is there any way to feed an entire GBuffer to a camera and let it do the rest?
I am trying to construct a camera's GBuffer from 2 cameras with smaller viewports. I got GBuffer0-3 from the small cameras in a RenderTexture. I also got the transparents of the small cameras into a RenderTexture, but those are not the issue yet. I tried to feed the data back into the main camera (using CommandBuffers) and no matter where I do that step (ofc, later than GBufferPass at leas) the main camera renders nothing. I did set it up to clear nothing and render nothing. I did test all the render textures and they are 100% correct and in the right format.
I could do the blending myself since I got all the data and all I need is to apply the deferred ComputeLight, blend in the transparents and then all posteffects, but I'd like the camera to go on with its natural course because I want this camera to be compatible with any ImageEffect that is currently out there without rewriting the ImageEffect myself to use the gbuffer instead of getting stuff from the camera.