Hello and Happy new Year everyone.![]()
I was optimize my post processing when i see that i can won memory band-witch.
For having a antialiased rendering, I render my scene in an multisample texture. But at the end of the post processing, it have to be on the frame buffer 0 witch is not multi sampled. So between depth of field blur stage and the bloom stage, i make a glBlitFramebuffer from my multisample texture to a non multisample texture.
Actually :
multisample texture -(Depth of field blur stage) -> multisample texture
multisample texture -(Downsampling by glBlitFramebuffer function)-> classical texture
classical texture -(Bloom stage)-> ...
What i want to do :
multisample texture -(Depth of field blur stage) -> classical texture
classical texture -(Bloom stage)-> ...
As you can see, i may won memory band-witch.Accessing each samples of a texel in the multisample texture from a shader isn't a problem. My problem is : i have to do a linear combination of every texel samples to determine my output texel. But how compute each samples' weight ? How does the blit function perform in this case ? I expect they shouldn't have the same ... Or maybe i'm doing a mistake ?
![]()
Thank you for reading and answers.
(excuse my english, i'm also working on it)



Accessing each samples of a texel in the multisample texture from a shader isn't a problem. My problem is : i have to do a linear combination of every texel samples to determine my output texel. But how compute each samples' weight ? How does the blit function perform in this case ? I expect they shouldn't have the same ... Or maybe i'm doing a mistake ?
)
