[SOLVED] Ogre 1.11.2 compositors render overlays

Problems building or running the engine, queries about how to use features etc.
Post Reply
rpgplayerrobin
Gnoll
Posts: 619
Joined: Wed Mar 18, 2009 3:03 am
x 355

[SOLVED] Ogre 1.11.2 compositors render overlays

Post by rpgplayerrobin »

Ogre Version: 1.11.2
Operating System: Windows 10
Render System: Direct3D9

I am having some problems with compositors when upgrading from Ogre 1.9 to 1.11.2.
It seems that the "input previous" texture in a compositor includes overlays for some reason (I am using Gorilla for UI).

When I tried the exact same thing in Ogre 1.9, the "input previous" texture never includes overlays.

This makes it a bit hard to make compositors like Bloom and Distortion correctly.

Is there any way to make that texture not include overlays by default, and behave like it did in Ogre 1.9?

Here is an example compositor that clearly shows that the UI is getting rendered before using the bloom material/shader with it:

Code: Select all

compositor Bloom
{
    technique
    {
        texture rt_output target_width target_height PF_R8G8B8
        texture rt0 target_width_scaled 0.25 target_height_scaled 0.25 PF_R8G8B8
        texture rt1 target_width_scaled 0.25 target_height_scaled 0.25 PF_R8G8B8

        target rt_output
        {
            input previous
        }

        target rt0
        {
            input none

            pass render_quad
            {
                material Bloom_BrightPass
                input 0 rt_output
            }
        }

        target rt1
        {
            input none

            pass render_quad
            {
                material Bloom_BlurV
                input 0 rt0
            }
        }

        target rt0
        {
            input none

            pass render_quad
            {
                material Bloom_BlurH
                input 0 rt1
            }
        }

        target_output
        {
            input none

            pass render_quad
            {
                material Bloom_BloomBlend
                input 0 rt_output
                input 1 rt0
            }
        }
    }
}
Last edited by rpgplayerrobin on Thu Jul 12, 2018 1:56 am, edited 1 time in total.
paroj
OGRE Team Member
OGRE Team Member
Posts: 1995
Joined: Sun Mar 30, 2014 2:51 pm
x 1075
Contact:

Re: Ogre 1.11.2 compositors render overlays

Post by paroj »

does Gorilla correctly check the Viewport::getOverlaysEnabled flag? To narrow down the problem please also check the Compositor Sample.
rpgplayerrobin
Gnoll
Posts: 619
Joined: Wed Mar 18, 2009 3:03 am
x 355

Re: Ogre 1.11.2 compositors render overlays

Post by rpgplayerrobin »

Thank you so much!

I feel a bit stupid now for not thinking of that. :D
Post Reply