Sebastian Sack | 25 Jun 2012 18:14
Picon
Picon

Need some help - Adding a CameraManipulator to a second camera.

Hi community,

i have a little problem:

i created a second camera, showing my scene from another viewing point, like in this tutorial (with render
to texture as an overlay)

now i want to add a CameraManipulator to this camera.

my normal camera has a manipulator, too. you can move with the arrow keys in the scene.
(viewer.setCameraManipulator(new MyManipulator))

now i want to turn the second camera around with some other keys ('a' and 'd')

can you help me out?

thanks a lot.

osgdogg

ps: i know - my english isn't that good

... 

Thank you!

Cheers,
Sebastian

------------------
(Continue reading)

Robert Osfield | 26 Jun 2012 10:38
Picon

Re: Need some help - Adding a CameraManipulator to a second camera.

HI Sebastien,

If you want to manage multiple interactive cameras then the
appropriate approach is to use multiple View's, one per view that you
want, and manage these within a CompositeViewer.  Each View has it's
own CameraManipualtor and the events will be passed from the
GraphicsWindow to the appropriate View's CameraManipulator so you
don't need to play games to special key combinations.  See the
osgcompositeviewer example.

Robert.

On 25 June 2012 17:14, Sebastian Sack <sebastian-sack@...> wrote:
> Hi community,
>
> i have a little problem:
>
> i created a second camera, showing my scene from another viewing point, like in this tutorial (with render
to texture as an overlay)
>
>
> now i want to add a CameraManipulator to this camera.
>
> my normal camera has a manipulator, too. you can move with the arrow keys in the scene.
(viewer.setCameraManipulator(new MyManipulator))
>
> now i want to turn the second camera around with some other keys ('a' and 'd')
>
> can you help me out?
>
(Continue reading)


Gmane