Hi,
How can I run irrlicht in visual c++ using any version of .Net framework? Is it even possible? should I include Irrlicht as a dinamic dll?
I want to create a Windows Form Project, on which the irrlicht world would be only on a seccion of a window, and add WF controls to edit properties of the elements of the world, could that be done?
Sorry about my english
thank's
running irrlicht in visual c++
-
- Posts: 3
- Joined: Tue Oct 27, 2009 4:12 pm
thank´s a lot Psan, but do you know how can I comunicate the events between the windows form component that host the irrlicht world and the irrlicht world in fact, for example, if I set the world on a picture box and I want select one of the scene nodes and watch its properties. How can I do that by clicking on a simple picture box.
Thank´s a lot again....
Thank´s a lot again....
You will have to use PeekMessage and GetMessage to intercept the keyboard or mouse events going to the picture child window in the main drawing loop and route them to EventReceiver or handle yourself.
It's a little hacky and caused problems for me, so good luck with that. The link below has a demo project that's much better. I hope it will help you.
http://irrlicht.sourceforge.net/phpBB2/ ... p?p=133188
It's a little hacky and caused problems for me, so good luck with that. The link below has a demo project that's much better. I hope it will help you.
http://irrlicht.sourceforge.net/phpBB2/ ... p?p=133188
-
- Posts: 3
- Joined: Tue Oct 27, 2009 4:12 pm
-
- Posts: 3
- Joined: Wed Nov 04, 2009 11:28 pm
Hello.
I try using Irrlicht with Visual Studio 2008. And i had two porblems.
1. When I simply uncomment the string #include <irrlicht.h> in my main header file or in my main .cpp file I receive following errors:
IReferenceCounted.h(116) : error C3862: 'irr::IReferenceCounted::drop': cannot compile an unmanaged function with /clr:pure or /clr:safe
Inline native assembly not supported in managed code
IReferenceCounted.h(124) : error C3821: 'irr::IReferenceCounted::~IReferenceCounted': managed type or function cannot be used in an unmanaged function
Inline native assembly not supported in managed code
IReferenceCounted.h(124) : error C3642: 'void *irr::IReferenceCounted::__delDtor(unsigned int)' : cannot call a function with __clrcall calling convention from native code
IReferenceCounted.h(116) : error C3645: 'irr::IReferenceCounted::drop' : __clrcall cannot be used on functions compiled to native code
2. I really don't understand where I should place the code from the example to get its working with my existing Windows Form Project.
I try using Irrlicht with Visual Studio 2008. And i had two porblems.
1. When I simply uncomment the string #include <irrlicht.h> in my main header file or in my main .cpp file I receive following errors:
IReferenceCounted.h(116) : error C3862: 'irr::IReferenceCounted::drop': cannot compile an unmanaged function with /clr:pure or /clr:safe
Inline native assembly not supported in managed code
IReferenceCounted.h(124) : error C3821: 'irr::IReferenceCounted::~IReferenceCounted': managed type or function cannot be used in an unmanaged function
Inline native assembly not supported in managed code
IReferenceCounted.h(124) : error C3642: 'void *irr::IReferenceCounted::__delDtor(unsigned int)' : cannot call a function with __clrcall calling convention from native code
IReferenceCounted.h(116) : error C3645: 'irr::IReferenceCounted::drop' : __clrcall cannot be used on functions compiled to native code
2. I really don't understand where I should place the code from the example to get its working with my existing Windows Form Project.
-
- Posts: 3
- Joined: Wed Nov 04, 2009 11:28 pm
Yes, I'm really noob in Windows programming - I don't use C# (I really have never use it willingly). So, do you mean that it's standart of Visual Studio? And I could write some of working code thinking that this is C++, but that was C#?Sylence wrote:Irrlicht is a C++ library. Not a C#.
There are some .NET wrappers for Irrlicht but afaik there aren't actively developed any more.
So, I have checked. I even haven't open category of C# files in VS Wizards.
Update: I assume that the problem is somewhere in that I try to include Irrlicht into a header file. I retry to add #include <irrlicht.h> to main.cpp and receive
warning C4627: '#include <irrlicht.h>': skipped when looking for precompiled header use
Add directive to 'stdafx.h' or rebuild precompiled header