Hi Tim,

Thanks for the clarification on version number, this helps me get a
idea of what changes are affect things.  In this instance a bug fix
for a Camera in the scene graph has broken the inheritance of the
slave Camera.

I think the best solution is to override
osg::CullSettings::inheritCullSettings() from within osg::Camera and
put the extra clear colour inheritance in there.  This way View.cpp
can simply call inheritCullSettings() without needs its own check set
of the clear colour.  Since inheritCullSettings will bypass the
setClearColor() call it'll also miss the overriding of the
inheritance.

I'm await a clean build to see if it works fine, if it does I'll check it in.

Robert.

On Mon, Jun 16, 2008 at 5:41 PM, Tim Moore <[EMAIL PROTECTED]> wrote:
> On Mon, 16 Jun 2008 16:01:48 +0100
> "Robert Osfield" <[EMAIL PROTECTED]> wrote:
>
>> Hi Tim,
>>
>> Which version of the OSG are you using?  What is Camera setup?
>>
>> Robert.
> OSG is SVN 8425
>
> The camera setup isn't too exotic: using an osg::Viewer, there's one
> slave with the 3D scene (possibly more) which should inherit the
> master's clear color and a 2D GUI / HUD camera that should not. The
> master's clear color is set every frame.
>
> Tim
>
>>
>> On Mon, Jun 16, 2008 at 3:22 PM, Tim Moore <[EMAIL PROTECTED]> wrote:
>> > Hello,
>> > I'm sorry that this isn't an osg-submission, but I'm not sure what
>> > the best fix. Since the applyMaskAction change was made for
>> > Camera::setCameraClearColor, slave cameras no longer inherit the
>> > master camera's clear color when CLEAR_COLOR is part of the
>> > inheritance mask. More accurately, they get the proper clear color
>> > the first time osg::View::updateSlave is called, but not after. The
>> > problem is that the setClearColor() call in that method causes the
>> > CLEAR_COLOR bit in the inheritance mask to be cleared
>> > when DISABLE_ASSOCIATED_INHERITANCE_MASK_BIT is set (the default).
>> >
>> > A workaround would be to set the inheritance mask action of the
>> > camera to DO_NOT_MODIFY_INHERITANCE_MASK, but that doesn't seem
>> > right; the code that is implementing the inheritance shouldn't be
>> > disabling it. I suspect that the best fix would be to implement a
>> > setClearColorOverride() method that doesn't perform the
>> > applyMaskAction() call; other camera properties might need the same
>> > treatment.
>> >
>> > Thanks,
>> > Tim
>> > _______________________________________________
>> > osg-users mailing list
>> > [email protected]
>> > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>> >
>> _______________________________________________
>> osg-users mailing list
>> [email protected]
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to