Hi Glen,
I'm using the Osg.Net libraries (Osg.Net, Osg.DB ... Osg.Viewer)
I'm using OSG version 2.0.0 v7 2007-06-19.
I had tried the most recent version of OSG, but after a while discovered it
didn't work with the C# wrappers I was using.
The error message is "Osg.GraphicsContext.Traits does not contain a definition
for inheritedWindowData"
I'm using VS2005 Professional Edition.
regards
Ernest
Date: Wed, 7 May 2008 23:04:46 -0400
From: [EMAIL PROTECTED]
To: [email protected]
Subject: Re: [osg-users] How to get the Handle for C# displays
Ernest,
Are you using osgDotNet wrappers? what version of OSG? what's the error you get
when trying to compile traits.inheritedWindowData = ... ? thanks -gw
On Wed, May 7, 2008 at 9:52 PM, Ernest Abbott <[EMAIL PROTECTED]> wrote:
Hi Glen,
Thanks for the link. I'd looked at the code before. But there doesn't seem to
be an equivalent in C# for the following (left hand side).
traits->inheritedWindowData = new osgViewer::GraphicsWindowWin32::WindowData(
hwnd );
Yes, I can get the handle. But traits does not have "inheritedWindowData" or
anything that
looks like it.
All traits has is
addObserver
displayName
Dispose
Equals
GetHashCode
GetType
removeObserver
ToString
I am able to render my image to its own window, but not within a panel I've set
up.
regards
Ernest
Date: Wed, 7 May 2008 08:02:39 -0400
From: [EMAIL PROTECTED]
To: [email protected]
Subject: Re: [osg-users] How to get the Handle for C# displays
Ernest,
Here's a code snippet. This is C++/CLI but you will get the idea. Grab the
Handle property from your .NET control and pass it to the Traits of your new
graphics context:
http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/2007-November/004540.html
HTH -gw
On Tue, May 6, 2008 at 9:52 PM, Ernest Abbott <[EMAIL PROTECTED]> wrote:
I'm very very new to OSG. I'm writing in C# and have a limited understanding of
C++. I am, as vehicle of learning OSG, converting a sample OSG C++ program to
C#. I want to be able to display my rendered image in an area within my windows
Form. I realise that I need to get the handle for the render object, which is
easily done. But I can't see where/how I can let OSG know what this handle is.
ie How can I pass the handle to OSG so that it renders within my window
control?
A bit of sample code would be of a great help.
regards
Ernest Abbott
Messenger's gone Mobile! Get it now!
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
--
Glenn Waldron : Pelican Mapping : http://pelicanmapping.com : 703-652-4791
Miss your Messenger buddies when on-the-go? Get Messenger on your Mobile!
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
--
Glenn Waldron : Pelican Mapping : http://pelicanmapping.com : 703-652-4791
_________________________________________________________________
Be a Hero and Win with Iron Man
http://clk.atdmt.com/UKM/go/msnnkmgl0010000009ukm/direct/01/
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org