Dear Mike,

    Thanks for you help. There are so many warnings and errors. Following
are some statements:

 

1>------ Build started: Project: VGEForPRDAirPollution, Configuration: Debug
Win32 ------

1>Compiling...

1>VGEForPRDAirPollution.cpp

1>C:\OpenSceneGraph2.0\OpenSceneGraph\include\OpenThreads/Mutex(40) :
warning C4272: 'OpenThreads::Mutex::Mutex' : is marked
__declspec(dllimport); must specify native calling convention when importing
a function.

OpenThreads::Mutex::`vftable'' : per-appdomain symbol should not be marked
with __declspec(dllimport)

1>C:\OpenSceneGraph2.0\OpenSceneGraph\include\osg/Referenced(64) : warning
C4272: 'osg::Referenced::ref' : is marked 

......

 

1>VGEForPRDAirPollution.obj : error LNK2028: unresolved token (0A00000C)
"public: void __clrcall osg::Referenced::ref(void)const "
([EMAIL PROTECTED]@osg@@$$FQBMXXZ) referenced in function "public: __clrcall
osg::ref_ptr<class osg::Referenced>::ref_ptr<class osg::Referenced>(class
osg::ref_ptr<class osg::Referenced> const &)"
([EMAIL PROTECTED]@osg@@@osg@@[EMAIL PROTECTED]@@Z)

1>VGEForPRDAirPollution.obj : error LNK2028: unresolved token (0A00000D)
"public: void __clrcall osg::Referenced::unref(void)const "
([EMAIL PROTECTED]@osg@@$$FQBMXXZ) referenced in function "public: __clrcall
osg::ref_ptr<class osg::Referenced>::~ref_ptr<class osg::Referenced>(void)"
([EMAIL PROTECTED]@osg@@@osg@@[EMAIL PROTECTED])

1>VGEForPRDAirPollution.obj : error LNK2028: unresolved token (0A000011)
"public: __clrcall osg::CopyOp::CopyOp(unsigned int)"
([EMAIL PROTECTED]@@[EMAIL PROTECTED]@Z) referenced in function "public: 
__clrcall
osg::RefMatrixd::RefMatrixd(class osg::RefMatrixd const &)"
([EMAIL PROTECTED]@@[EMAIL PROTECTED]@@Z)

1>VGEForPRDAirPollution.obj : error LNK2028: unresolved token (0A000012)
"public: virtual __clrcall osg::CopyOp::~CopyOp(void)"
([EMAIL PROTECTED]@@[EMAIL PROTECTED]) referenced in function "public: __clrcall
osg::RefMatrixd::RefMatrixd(class osg::RefMatrixd const &)"
([EMAIL PROTECTED]@@[EMAIL PROTECTED]@@Z)

1>VGEForPRDAirPollution.obj : error LNK2028: unresolved token (0A000013)
"public: __clrcall osg::Object::Object(void)" ([EMAIL PROTECTED]@@[EMAIL 
PROTECTED])
referenced in function "public: __clrcall
osg::StateAttribute::Callback::Callback(void)"
([EMAIL PROTECTED]@osg@@[EMAIL PROTECTED])

1>VGEForPRDAirPollution.obj : error LNK2028: unresolved token (0A000014)
"public: __clrcall osg::Object::Object(bool)" ([EMAIL PROTECTED]@@[EMAIL 
PROTECTED]@Z)
referenced in function "public: __clrcall osg::RefMatrixd::RefMatrixd(void)"
([EMAIL PROTECTED]@@[EMAIL PROTECTED])

......

1>Build log was saved at
"file://d:\VGEForPRDAirPollution\TestNet\VGEForPRDAirPollution\VGEForPRDAirP
ollution\Debug\BuildLog.htm"

1>VGEForPRDAirPollution - 1227 error(s), 4507 warning(s)

========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

 

Thanks and regards

Bingli

The Institute of Space and Earth Information Science,

The Chinese university of Hong Kong, Shatin, N.T., Hong Kong, P.R.China

 

 

 

 

 

 

-----邮件原件-----
发件人: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 代表 Mike Wittman
发送时间: 2007年8月2日 22:23
收件人: osg-users@lists.openscenegraph.org
主题: Re: [osg-users] A simple question from an learner.

 

OSG can definitely be used with WinForms.  It sounds like you're running

into some project configuration issue though.  If you can post your

error messages we might be able to provide better help.

 

-Mike

 

> -----Original Message-----

> From: [EMAIL PROTECTED] [mailto:osg-users-

> [EMAIL PROTECTED] On Behalf Of ijustfu

> Sent: Thursday, August 02, 2007 4:25 AM

> To: osg-users@lists.openscenegraph.org

> Subject: [osg-users] A simple question from an learner.

> 

> Dear Robert.

>     I build a simple OSG program with visual studio2005.net. I use c++

> language , and select "window forms application", then get the

following

> codes:

> 

> #include "stdafx.h"

> #include "Form1.h"

> 

> #include <osgViewer/Viewer>

> #include <osgDB/ReadFile>

> 

> using namespace VGEForPRDAirPollution;

> 

> [STAThreadAttribute]

> int main(array<System::String ^> ^args)

> {

>     // Enabling Windows XP visual effects before any controls are

> created

>     Application::EnableVisualStyles();

>     Application::SetCompatibleTextRenderingDefault(false);

>     // Create the main window and run it

>     Application::Run(gcnew Form1());

> 

>     osgViewer::Viewer viewer;

>     viewer.setSceneData(osgDB::readNodeFile("cow.osg"));

>     return viewer.run();

> }

> 

> After adding osgViewerd.lib and osgDBd.lib into project, compile it

but

> fund

> so many warnings and errors.

> 

> Above codes can be run under 'win32 console application'(c++).

> 

> Does above means OSG can not be used under "window forms application"?

If

> yes, is there any setting of solution environment?

> 

> Thanks.

> Bingli

> 

> 

> 

> _______________________________________________

> osg-users mailing list

> osg-users@lists.openscenegraph.org

> 

http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or

g

_______________________________________________

osg-users mailing list

osg-users@lists.openscenegraph.org

http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

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

Reply via email to