Hello Peter,

> 1. Can the visual studio 2008 use the
> compiled  win32 binaries and libs in the osg 2.2 release or not ?

Which compiler was your 2.2 compiled with?

VS2008 is still pretty new, but from what I have seen, it is  
binary-compatible with 2005 (please don't kill me if this ends up not  
being true... :-) ). So if your OSG 2.2 binaries and 3rdParty packages  
were compiled with 2005 (8.0), you should be able to use them with  
2008 (9.0). At least, I use the 3rdParty binaries for 8.0 with 9.0 and  
it seems to work (until now! *crosses fingers*).

> If the naswer is no, then what do i need to do to get compatiable libs or
> binaries to use with visual studio 2008 ?

If the answer turns out to be no, you can compile OSG from source  
using VS2008. You need CMake 2.5 (which is in the "nightly CVS  
snapshots" section on cmake.org - http://www.cmake.org/files/vCVS/ )  
or 2.6 when it comes out. See the compilation instructions on  
openscenegraph.org, and pay heed to the platform specific info for  
VS2005, which still applies to 2008.

> 2. My c++ is a bit
> rusty, but when you link the libs into your project, and build a
> final result does it not embed the libs into you application exe and
> eleiminate the need for the run time osg DLL's. I thought that was
> the reason to link in the libs ? If this is not the case why not ?

In a nutshell, when linking with a dynamic library, you still need a  
.lib (which is then called an "import library" instead of just a  
"library"). That way, the executable links without undefined symbols.  
But then at runtime, the symbols that were defined in the import  
library will try to use those in the DLL. So your application needs to  
be able to find this DLL, which is the reason we usually either

A) place the DLLs needed for an app in the same directory as the app,  
which is a bit less "clean" but is useful to create a package that can  
just be downloaded and run regardless of the DLLs a user has on their  
machine, or
B) change the PATH environment variable to include the directory where  
the DLLs are contained.

The other option is to statically link OSG to your app, but I don't  
know how well that is supported at the moment (and particularly on  
Windows). It would likely make a huge executable however...

> and   then what exasctly is needed to run a final application on a
> XP/vista machine that has a clean install of the os ?   EG osg
> runtime dll + c++ runtime or what ?

Exactly. You need any DLLs that your app requires and which are not  
part of the standard Windows XP/Vista install. In most cases, this  
will mean OSG's DLLs and the Visual C++ runtime for the version you  
compiled with (8.0, 8.0SP1, or 9.0 for example). You can use  
dependency walker (http://www.dependencywalker.com/) to see which DLLs  
your app depends on, and whether it's able to find them.

Other people can help you a bit more on this, but I believe the  
3rdParty binaries on  
https://osgtoy.svn.sourceforge.netsvnroot/osgtoy/3rdParty/branches/  
(for the compiler you have) contain all that is needed (and if I'm not  
mistaken, the binaries installer includes those as well). So you could  
conceivably make a directory in which you put the DLLs from that  
package and your executable, and that should work. Correct me if I'm  
wrong though.

Good luck,

J-S
-- 
______________________________________________________
Jean-Sebastien Guay     [EMAIL PROTECTED]
                         http://whitestar02.webhop.org/

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.


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

Reply via email to