[osg-users] osgDotNet

27 views
Skip to first unread message

Michael W. Hall

unread,
Jul 10, 2009, 6:05:30 PM7/10/09
to OpenSceneGraph Users
Can someone help me out with building this? I have been following the
directions, but no luck yet. I created the environment variable as the
instructions said, but I get errors saying that it cannot open the osg
files.

These files are on my system and in the location specified. Any help is
appreciated.

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

Michael W. Hall

unread,
Jul 10, 2009, 6:10:56 PM7/10/09
to OpenSceneGraph Users
Additional information. The error is looking for files in
osgIntrospection. I do not see this in my osg install directory.
However, I had no errors on the build of OSG or the install and none on
VPB.

Michael

Michael W. Hall

unread,
Jul 10, 2009, 6:59:30 PM7/10/09
to OpenSceneGraph Users
I did find an osgIntrospection include file in the directory where I got
OSG from SVN. Copied that to the installed location of OSG. The
osgDotNet built, but gave a link error about OsgIntrospection.lib. I
downloaded the precompiled libs and copied that to the OSG install
directory.

The project seemed to build. I then tried to run the generate function
as stated in the readme. Now I am getting an error saying that the
application failed to start because osg55-osgIntrospectiond.dll was not
found.

Should this have been installed when I build OSG? Again, if anyone is
using osgDotNet I would appreciate any help.

Michael

Jason Daly

unread,
Jul 10, 2009, 8:21:10 PM7/10/09
to OpenSceneGraph Users
Michael W. Hall wrote:
> I did find an osgIntrospection include file in the directory where I got
> OSG from SVN. Copied that to the installed location of OSG. The
> osgDotNet built, but gave a link error about OsgIntrospection.lib. I
> downloaded the precompiled libs and copied that to the OSG install
> directory.
>
> The project seemed to build. I then tried to run the generate function
> as stated in the readme. Now I am getting an error saying that the
> application failed to start because osg55-osgIntrospectiond.dll was not
> found.
>
> Should this have been installed when I build OSG? Again, if anyone is
> using osgDotNet I would appreciate any help.
>

I'm not using it, but I know one thing you'll have to do is to enable
the building of the wrappers when you run CMake (set the
BUILD_OSG_WRAPPERS variable to ON).

Hope this helps...

--"J"

Andrew Burnett-Thompson

unread,
Jul 11, 2009, 7:35:14 AM7/11/09
to osg-...@lists.openscenegraph.org
Hi there,

Not sure if I've done this right, this is intended to be a response to the message "osgDotNet" here :
http://groups.google.com/group/osg-users/browse_thread/thread/c8c8422c8f74b865?hl=en

Anyways - assuming it is right ...

I am currently writing an application using OpenSceneGraph integrated to C# .NET. Rather than use osgDotNet (which I couldn't get to compile for the latest version 2.8.0) I opted to use C++/CLI - which is Microsoft's second version of managed C++.

C++/CLI is amazing, they really got it right. You can compile managed C++ classes with native member variables and functions. You can compile native classes with managed member variables and functions. You can allocate memory on the native or managed heap, you can really do what you like.

A simple example of integrating osg to a .NET user control via C++/CLI can be found here:

http://www.april1985.com/2008/02/19/osgnetdemo/

Once you've done that you do all your OSG work in a C++ dll with managed extensions enabled and expose the bits you want to C# via your managed C++/CLI classes.

We've not opted to wrap openscenegraph, that would be far too much effort. Instead the functionality we required to expose to C# (which is minimal) is wrapped.

hope this helps

Vaibhav Bansal

unread,
Jul 12, 2009, 10:41:19 AM7/12/09
to OpenSceneGraph Users

Hello

 

I was trying to place some osgText in my scene, the text seems to become distorted however.

A picture of the distorted text is attached, please comment if any one has faced such problem before.

I am using osg2.6.1.

 

Thanks and Regards

Vaibahv Bansal

 

imageProb.jpg

Robert Osfield

unread,
Jul 12, 2009, 12:21:03 PM7/12/09
to OpenSceneGraph Users
Hi Vaibahv,

I've never seen a problem like this before. Exactly how are you
setting your text? Do you see the problem across platforms and
different hardware/drivers? What happens you run the osgtext example.

Robert.

Vaibhav Bansal

unread,
Jul 13, 2009, 3:01:28 AM7/13/09
to OpenSceneGraph Users
Hello Robert,

The osgText example runs fine.
I tested on two machines with different cards/drivers, the problem remains.

I am using these modes :

text->setCharacterSizeMode(osgText::Text::OBJECT_COORDS);
text->setAxisAlignment(osgText::Text::SCREEN);

I am using position values of the order of 1438137.375, and font size of
1.6.
Could this be related to precision.


Thanks and Regards
Vaibhav Bansal

Robert Osfield

unread,
Jul 13, 2009, 3:11:24 AM7/13/09
to OpenSceneGraph Users
HI Vailbhav,

Try moving your text nearer to a local origin to see if the problem is
a precision issue. A good technique to use when dealing with large
model coordinates is to place a MatrixTransform above the local
geometries to place them in world coords, and to enable the local
geometries to have a local origin to maximize precision.

Robert.

Vaibhav Bansal

unread,
Jul 13, 2009, 7:47:51 AM7/13/09
to OpenSceneGraph Users
Hello Robert,

Thanks for the advice for placing geometries in local cords, it worked
wonderfully.

Reply all
Reply to author
Forward
0 new messages