No one experienced that OSG consumes 3DConnexion messages until you move
the window with the mouse, then auddenly messages related to the
3DConnexion Space Navigator starts coming in...?
On Friday, 13 November 2015, Anders Backman wrote:
> It seems to me that OSG eats the
Hello,
On Wed, Nov 18, 2015 at 12:41 PM, Anders Backman wrote:
> No one experienced that OSG consumes 3DConnexion messages until you move the
> window with the mouse, then auddenly messages related to the 3DConnexion
> Space Navigator starts coming in...?
If you don't want to
It seems to me that OSG eats the 3DConnexion messages, until you move the
window explicitly with the mouse.
The code below show that a console window works just fine, all messages are
intercepted by the "message window".
However, when a osgViewer run loop is being used, the messages seem to be
Ah thats great. A good step forward.
However, two minor questions:
1. Do you need the instance to the main osg window?
2. If not, how do you manage to get events from the device when you apply
force on it?
I get it to read data (in my message callback) but only if a move/modify
the osg window
Hi Anders,
You can create a separate "message-only" window to receive windows messages
from the SpaceMouse. See the following MSDN page:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms632599(v=vs.85).aspx#message_only
I've integrated the 3DConnexion SpaceNavigator into our
That is quite explicit. I was thinking about some method for intercepting
events.
I tried fiddling with creating a custom GraphicsWindowWin32 class, but it
turns out that this is explicitly created internally in:
osg::GraphicsContext* Win32WindowingSystem::createGraphicsContext(
I notice that there is a major difference between osgViewer::Viewer and
osgViewer::CompositeViewer:
The following code:
osgViewer::CompositeViewer viewer;
osg::ref_ptr traits = new
osg::GraphicsContext::Traits;
traits->x = 100;
traits->y = 100;
traits->width = 1000;
Did you tried something like:
osgViewer::Viewer viewer;
viewer.getCamera()->setGraphicContext(gc);
?
On Thu, Nov 12, 2015 at 2:52 PM, Anders Backman wrote:
> I notice that there is a major difference between osgViewer::Viewer and
> osgViewer::CompositeViewer:
>
> The
That is certainly an important call yes.
I guess my problem is that these two calls are not interchangeable:
#if 1
osg::ref_ptr gc =
osg::GraphicsContext::createGraphicsContext(traits.get());
#else
osg::ref_ptr window = new
osgViewer::GraphicsWindowWin32(traits);
gc = window.get();
So there seem to be only a very few alternatives for integrating such a
windows oriented toolkit as the 3DConnexion SpaceMouse...
My idea of being able to create a custom implementation of a
GraphicsWindowWin32 would really open up for a better integration, albeit
not a portable one...
Right
Hi.
Trying the 3DConnexion SpaceNavigator with OSG. However I would like to
stay away from VRPN and such dependencies...
I was wondering how to best intercept Windows messages from the
GraphicsWindowWin32 class.
This class has a virtual method handleNativeWindowingEvent which I would
like to
Hi Anders,
here is what I do for this on Windows
while (!viewer->done())
{
#if defined(_WIN32)
MSG msg;
if (::PeekMessage(,NULL,0,0,PM_NOREMOVE))
{
::GetMessage(, NULL, 0, 0);
if (wins.size())
{
12 matches
Mail list logo