Page 1 of 1

compositor "render_custom"

Posted: Mon Feb 07, 2011 6:54 pm
by digitalgibs
So it's become pretty clear to me that this option is currently fairly useless.
  • No Begin/End capability
    No control over the TargetOperation before it is queued.
I just wanted to create a custom render pass that allowed me to render the entire scene using a single material. Since I have zero control over the drawing, this task is impossible or requires pages of hacks. Adding those two simple features would allow developers to register and unregister listeners or inject their own render calls without double-rendering the scene.

Re: compositor "render_custom"

Posted: Tue Feb 08, 2011 9:09 am
by so0os
You can use mViewport->setMaterialScheme("name"); to set scheme name for a viewport. And to avoid having to write it for each material, you can use MaterialManager::Listener and override handleSchemeNotFound. Example of this can be found here: http://www.ogre3d.org/tikiwiki/Glow&structure=Cookbook

Also, you can do this in compsoitor:

Code: Select all

target something
		{
			input none
			material_scheme myscheme
			pass clear
			{
			}
 
			pass render_scene
			{
			}
		}
It's all covered in the glow wiki thingie, go take a look!