Sign in to follow this  

Terrain editor - Common approaches?

This topic is 4665 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi I will soon be at the stage in development where I need an editor for my terrain engine. The engine was written in C++ with SDL/OpenGL as a DLL and obviously I'd like to use it in the editor as well... The question is how. I don't think I'd like to go the MFC route, but here are some other options I've been mulling over: 1. Create a CORBA interface to an easy to develop visual basic GUI - I work with CORBA a lot at my day job so I think I could achieve this, though it seems a little overkill 2. Load in my C++ DLL into a VB program - Don't know if this is even possible 3. Load in my C++ DLL into a C# program - Don't know C# but it looks pretty cool, and I've heard of people having success here 4. Write my own GUI within SDL - A little too much work I think At the moment I think I'm going to look into what's possible in C#... If anyone can suggest a better option, or has an opinion on any of this I'd be very appreciative

Share this post


Link to post
Share on other sites
Their is a tutorial on setting up MFC to do this, however you might find it easier (if you have the tools.. i.e. VS.NET or the compiler package and a free ide) to use C# to render your terrain while you edit it. I think C# retains the power of C at the expense of being as easy to work with controls as in VB. That said, you can do this in any language but C# is probably the fastest route.

You could possibly plug into the editor your main engine DLL. Depending on how its structured (i.e. an engine object or just a library of functions) you can link in as many as you need to save coding time.

One possibility you may want to look into which falls somewhere in the middle of a 'tool' and the game is to program the editor directly into the game ala Tribes 1 and 2 or Earth 2150 (there are a few more but I cant remember off the top of my head..)

That second approach would allow you to use your engine in place.. The only requirements are a full GUI engine (also their is one on GameDev someplace (a link to one)). Its nice and if you integrate it properly you shouldent take that much of a performance hit while dealing with the GUI and rendering your terrain.

I like both approaches, and in my case I probably would go both routes. I like having external tools to rapidly develop <insert game data here>. Internal tools tend to be more clunky as you cannot simply add in a windows control as easily as you could in a C# Form. The GUI library on Gamedev has support for virtually everything you will need and if you want something else I believe it has an extension mechanism.

G/l (cool project btw ;) I've never gotten to the point of needed a special terrain tool for a game project.)


-LINKS-
http://www.ogre3d.org/ << The GUI Engine mentioned on GameDev not too long ago

[edit]
On a side note: I searched the GDNet forums for more options and their are a few other GUI libraries you may want to look into.

http://glgooey.sourceforge.net/ << Zlib License Compatable
http://gigi.sourceforge.net/ << I didnt see screenshots of this on SF

Share this post


Link to post
Share on other sites
I think I will go for both approaches like you suggested. I just finished adding a text system and a console window to the game so I could easily add some clunky controls to tweak any problems with the levels... and I'll need an external tool (C#, now that it appears possible) for most of the editting

Quote:
Original post by Undergamer
Their is a tutorial on setting up MFC to do this, however you might find it easier (if you have the tools.. i.e. VS.NET or the compiler package and a free ide) to use C# to render your terrain while you edit it. I think C# retains the power of C at the expense of being as easy to work with controls as in VB. That said, you can do this in any language but C# is probably the fastest route.


I'm using VS.NET 2003, so I have easy access to C#. I'll start looking at ways to take advantage of my DLL, but if you have any links already, I'd be happy to hear them :)

Thanks for the help

Share this post


Link to post
Share on other sites
Why not just try one of the existing terrain editors already out there.

http://www.freeworld3d.org =======> best in my opinion
http://www.dyvision.co.uk/ale.htm
http://www.nebsoftware.com/Terrain.html

Share this post


Link to post
Share on other sites
Very nice links, thanks

I tried all of them, and they are all quite nice, but I think I'll still implement my own. I have time, and don't consider what I'm getting done here as important as what I'm learning. Plus, I hate the controls in all of them

Share this post


Link to post
Share on other sites
If you try:

www.codeproject.com
www.csharpcorner.com

You can get a jump start on everything there is to know about C# from a practical example based standpoint. The first link would be my choice, and it has examples working with DLL's and importing functions.

The syntax of C# is very similar to C and you shouldent have a problem with it. In fact you could even use Managed C++ as a replacement for C# if you dont want to worry about different security concerns in an unfamiliar language.

Share this post


Link to post
Share on other sites

This topic is 4665 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this