Re: [osg-users] multiple input with osgwidgets

2016-10-05 Thread Gianni Ambrosio

Meldryt wrote:
> 
> The reason why i use MouseHandler is because it will send events to the 
> WindowManager which knows all about its windows and widgets.
> 

I may be wrong since I don't know your code in detail but I think about class 
"responsiblities". From my point of view it's not bad to implement a 
MouseEventHandler which updates (in some way) the window manager. Maybe a 
WindowManagerUpdater that will be a collaborator of the MouseEventHandler so 
that your cose will be more testable. You will not have to send events to the 
window manager but just call the proper methods from the WindowManagerUpdater.

Cheers,
Gianni

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=68880#68880





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] multiple input with osgwidgets

2016-10-05 Thread Sebastian Schmidt

gambr wrote:
> Honestly I usually derive from osgGA::GUIEventHandler to handle mouse events.
> 
> Cheers,
> Gianni


I use the osgWidget::MouseHandler and osgGA::CameraManipulator which both 
derive from osgGA::GUIEventHandler.

The reason why i use MouseHandler is because it will send events to the 
WindowManager which knows all about its windows and widgets.

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=68855#68855





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] multiple input with osgwidgets

2016-10-04 Thread Gianni Ambrosio
Honestly I usually derive from osgGA::GUIEventHandler to handle mouse events.

Cheers,
Gianni

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=68849#68849





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] multiple input with osgwidgets

2016-10-04 Thread Sebastian Schmidt

gambr wrote:
> Hi Meldryt,
> I worked with osgWidget in the past. I move a widget with 
> left_mouse+mouse_move and resize it with central_mouse_button+mouse_move.
> I also tried to show a contextual menu clicking with right mouse button on it.
> Now I'm on OSG 3.4.0 but moved recentrly from OSG 3.0.1.
> 
> Could you please just write "one" of the cases not working in your 
> implemetation?
> 
> Cheers,
> Gianni


This all is one case. Its also not triggering for my parent window (canvas).

When i have two buttons pressed and release one of them, i get no event 
(release or drag) for the second button.

I don't know why this is happening with osgWidget::Input but not with my 
CameraManipulator.

I could try this with 3.4.0, maybe it was fixed in the past.

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=68843#68843





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] multiple input with osgwidgets

2016-09-30 Thread Gianni Ambrosio
Hi Meldryt,
I worked with osgWidget in the past. I move a widget with left_mouse+mouse_move 
and resize it with central_mouse_button+mouse_move.
I also tried to show a contextual menu clicking with right mouse button on it.
Now I'm on OSG 3.4.0 but moved recentrly from OSG 3.0.1.

Could you please just write "one" of the cases not working in your 
implemetation?

Cheers,
Gianni

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=68831#68831





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] multiple input with osgwidgets

2016-09-30 Thread Sebastian Schmidt
bump!
Does anyone else have this issue?

I have no problem when i try to track this event inside my handle function of 
the custom osgGA::StandardManipulator class.

But for my GUI widgets its easier to track this input events just by overriding 
mousePush, mouseDrag, ... events of osgWidget::Input.

So there is this situation when i dont receive mouseDrag event.
1. push left or right mouse button and hold down.
2. now push the other button and release it
3. drag the first button

I use version 3.0.1

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=68829#68829





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] multiple input with osgwidgets

2016-08-12 Thread Sebastian Schmidt
I have problems with receiving multi input events in my osgWidget::Label class.
f.e. 
1. click right mouse
2. click left mouse
3. release left mouse
4. no event when i drag the right mouse

i added 
Code:
setEventMask(osgWidget::EVENT_ALL);

 to receive all events but i seems like osg is killing//ignoring all other 
states when one of the mouse button is released.

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=68357#68357





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org