Jump to content

  • Log In with Google      Sign In   
  • Create Account

#Actualmightypigeon

Posted 02 March 2013 - 01:08 AM

@mightypigeon: Did you build that using .NET with C# or VB? When I was working in C++ and DirectX, I'd build mine using the winapi C classes, which is gross Win32 stuff from the 90's... Designing .NET applications are a breeze, but getting my C++ engine built on top of OpenGL to interact with .NET hasn't ever worked out for me yet.

 

EDIT: Woah, I asked before I looked up wxWidgets. You sir, answered by question before I even knew haha

Back in the day I used C# for the interface with a small helper DLL written in C++ which was used to communicate with the engine using .NET interop.  It was a pain.

 

Lately I've been doing it the other way around, I was playing around with WPF and enjoyed it so now I have written a couple of dialogs for the editor using it and C#.  They export to a COM library.  After a lot of mucking around, the end result I can load up those WPF windows in native C++ using COM - no managed C++ or C++/CLI stuff at all, wanted to keep that away from the engine.  I ended up pulling an all-nighter to get it going, and I'm having nightmares just thinking about it again, but it's one of those things that once you do it the first time, it's there forever.  Definitely a learning experience!

 

 

 


Looks like I've started on the right track already, as I already have my engine code compiled into a DLL and the game project uses it. Where I do not know how to add editor features right now is for instance, rendering things like labels on objects or the rotate/scale/move gizmo, and rendering other debug shapes. I suppose they just need to be treated as special cases in the rendering engine, so they do not become affected by the lighting, for example. Sounds like the most popular option is to have the game and editor code as totally separate projects. Guess as a start, I'll keep both in one project but keep the editor code and game code in separate folders.

 

Rendering ad-hoc lines and labels and things like that is definitely worth implementing, even if you aren't writing an editor.  It can be a life saver down the track as you can quickly implement debug drawing in your game code (draw an AI's navigation path for example)

 

And speaking of gizmos, here is something I found that I found a while back: https://github.com/CedricGuillemet/LibGizmo

Works great.


#1mightypigeon

Posted 02 March 2013 - 01:05 AM

@mightypigeon: Did you build that using .NET with C# or VB? When I was working in C++ and DirectX, I'd build mine using the winapi C classes, which is gross Win32 stuff from the 90's... Designing .NET applications are a breeze, but getting my C++ engine built on top of OpenGL to interact with .NET hasn't ever worked out for me yet.

 

EDIT: Woah, I asked before I looked up wxWidgets. You sir, answered by question before I even knew haha

Back in the day I used C# for the interface with a small helper DLL written in C++ which was used to communicate with the engine using .NET interop.  It was a pain.

 

Lately I've been doing it the other way around, I was playing around with WPF and enjoyed it so now I have written a couple of dialogs for the editor using it and C#.  They export to a COM library.  After a lot of mucking around, the end result I can load up those WPF windows in native C++ using COM - no managed C++ or C++/CLI stuff at all, wanted to keep that away from the engine.  I ended up pulling an all-nighter to get it going, and I'm having nightmares just thinking about it again, but it's one of those things that once you do it the first time, it's there forever.  Definitely a learning experience!

 

 

 

And speaking of gizmos, here is something I found that I found a while back: https://github.com/CedricGuillemet/LibGizmo

Works great.


PARTNERS