//-----------------------------------------------------------------------
void CompositorManager::setCompositorEnabled(Viewport *vp, const String &compositor, bool value)
{
    CompositorChain *chain = getCompositorChain(vp);
    for(size_t pos=0; pos < chain->getNumCompositors(); ++pos)
    {
        CompositorInstance *instance = chain->getCompositor(pos);
        if(instance->getCompositor()->getName() == compositor)
        {
            chain->setCompositorEnabled(pos, value);
            break;
        }
    }
}
Exemple #2
0
void DeferredShadingSystem::logCurrentMode(void)
{
  if(mActive == false)
  {
    LogManager::getSingleton().logMessage("No Compositor Enabled!");
    return;
  }

  CompositorInstance* ci = mInstance[mCurrentMode];
  assert(ci->getEnabled() == true);
  LogManager::getSingleton().logMessage("Current Mode: ");
  LogManager::getSingleton().logMessage(ci->getCompositor()->getName());
}
//-----------------------------------------------------------------------
void CompositorManager::removeCompositor(Viewport *vp, const String &compositor)
{
    CompositorChain *chain = getCompositorChain(vp);
    for(size_t pos=0; pos < chain->getNumCompositors(); ++pos)
    {
        CompositorInstance *instance = chain->getCompositor(pos);
        if(instance->getCompositor()->getName() == compositor)
        {
            chain->removeCompositor(pos);
            break;
        }
    }
}
void DeferredShadingSystem::logCurrentMode(void)
{
	if (mActive==false)
	{
		LogManager::getSingleton().logMessage("No Compositor Enabled!");
		return;
	}

	CompositorInstance* ci = mInstance[mCurrentMode];
	assert(ci->getEnabled()==true);

	LogManager::getSingleton().logMessage("Current Mode: ");
	LogManager::getSingleton().logMessage(ci->getCompositor()->getName());
		
	if (mCurrentMode==DSM_SHOWLIT)
	{			
		LogManager::getSingleton().logMessage("Current mrt outputs are:");
		LogManager::getSingleton().logMessage(ci->getTextureInstanceName("mrt_output", 0));
		LogManager::getSingleton().logMessage(ci->getTextureInstanceName("mrt_output", 1));
	}
}