- Mikael Gyth
- Posts: 33
- Joined:
Unity3D ImageEffects
Hello.
There might be a simple solutions to this, but I haven't discovered it yet.
Is there a way to have Unitys ImageEffects not effect NoesisGui?
There might be a simple solutions to this, but I haven't discovered it yet.
Is there a way to have Unitys ImageEffects not effect NoesisGui?
-
sfernandez
Site Admin
- Posts: 3183
- Joined:
Re: Unity3D ImageEffects
Hi,
We are currently doing our render on the MonoBehavior.PostRender() function, that gets called after Unity's Render.TransparentGeometry layer, but before Camera.ImageEffects.
I've been investigating and I think we can move our Render to the end of frame by using a corutine that waits until then. We will probably change it for 1.2 version, but if you want to try it now, you will have to modify a pair of scripts:
- In Assets/Plugins/NoesisGUI/Scripts/NoesisGUIPanel.cs, change the PostRender() function to:
- In Assets/Plugins/NoesisGUI/Scripts/Core/NoesisUIRenderer.cs, in the function UpdateSettings(), comment the line that flips render vertically for deferred lighting:
We are currently doing our render on the MonoBehavior.PostRender() function, that gets called after Unity's Render.TransparentGeometry layer, but before Camera.ImageEffects.
I've been investigating and I think we can move our Render to the end of frame by using a corutine that waits until then. We will probably change it for 1.2 version, but if you want to try it now, you will have to modify a pair of scripts:
- In Assets/Plugins/NoesisGUI/Scripts/NoesisGUIPanel.cs, change the PostRender() function to:
Code: Select all
void OnPostRender()
{
if (_uiRenderer != null)
{
StartCoroutine(EndOfFrameRender());
}
}
IEnumerator EndOfFrameRender()
{
yield return new WaitForEndOfFrame();
_uiRenderer.PostRender();
}
Code: Select all
private void UpdateSettings(Noesis.AntialiasingMode aaMode,
Noesis.TessellationMode tessMode, Noesis.TessellationQuality tessQuality,
Noesis.RendererFlags flags)
{
// update renderer size
if (_texture == null)
{
// ...
if (_isGraphicsDeviceDirectX)
{
// ...
if (camera != null &&
camera.actualRenderingPath == UnityEngine.RenderingPath.DeferredLighting)
{
// vvv H E R E vvv
//flags |= RendererFlags.FlipY;
}
}
}
else // Render to Texture
{
// ...
}
// ...
}
- Mikael Gyth
- Posts: 33
- Joined:
Re: Unity3D ImageEffects
I will give it a try.
Your customer service never seizes to astonish me. Thank you very much.
Your customer service never seizes to astonish me. Thank you very much.
- Mikael Gyth
- Posts: 33
- Joined:
Re: Unity3D ImageEffects
Just popped in to say that the fix seems to work as expected.
I did notice that Unitys Bloom affect still affected NoesisGUI after the changes tough (But thats not a problem for us right now).
Thanks again for the quick reply
I did notice that Unitys Bloom affect still affected NoesisGUI after the changes tough (But thats not a problem for us right now).
Thanks again for the quick reply
Re: Unity3D ImageEffects
If you change this for the 1.2 version, could this be made optional somehow? I'm currently using the Unity3D Image effects to create some cool transitions between the NoesisGUI pages ...
Geert
Geert
-
sfernandez
Site Admin
- Posts: 3183
- Joined:
Re: Unity3D ImageEffects
Yes, Bloom is affecting all the textures (brush gradients, text glyphs, images...) that we use to render the GUI. We will investigate how to avoid this issues when rendering the GUI without image effects.Just popped in to say that the fix seems to work as expected.
I did notice that Unitys Bloom affect still affected NoesisGUI after the changes tough (But thats not a problem for us right now).
Thanks again for the quick reply
It sounds right to me, we can provide a check box in the NoesisGUI Panel component to decide if Image Effects should affect the GUI or not. Thanks for the suggestion.If you change this for the 1.2 version, could this be made optional somehow? I'm currently using the Unity3D Image effects to create some cool transitions between the NoesisGUI pages ...
Geert
Who is online
Users browsing this forum: Ahrefs [Bot] and 2 guests