RenderTarget viewports are never removed by CompositorManager in Ogre 2.1

Discussion area about developing with Ogre-Next (2.1, 2.2 and beyond)


Post Reply
Shimayama
Halfling
Posts: 74
Joined: Sat Apr 25, 2009 2:20 pm
Location: Norway
x 1

RenderTarget viewports are never removed by CompositorManager in Ogre 2.1

Post by Shimayama »

It seems that when removing workspaces on a RenderTarget, and then adding them again, we grow the number of actual viewports on the render target each time (RenderTarget::getNumViewports()).

For example if something like this is done multiple times, with the a bit varying viewport size each time:

Code: Select all

compositorManager->removeAllWorkspaces();
compositorManager->removeAllWorkspaceDefinitions();
compositorManager->removeAllNodeDefinitions();
compositorManager->removeAllShadowNodeDefinitions();

def = _CreateWorkspaceDef(...);
compositorManager->addWorkspace(..., defName, ...);
and mRenderTarget->getNumViewports() is printed after each time, the return value will grow.

I searched for removeAllViewports and removeViewport calls in Ogre but it seems they are never used.
Post Reply