Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Program Announcements / CSM Importer for DarkGDK

Author
Message
_Pauli_
AGK Developer
11
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 10th Jun 2011 18:29 Edited at: 31st Jul 2011 21:04



About:

CSMImport is a Cartography Shop Map Importer for DarkGDK. This allows you to import maps directly from the powerful and free Cartography Shop map creation tool. What you see is what you get!


Features:

Import CSM files directly (no export to X/3DS/DBO files required!)
All your map data packed into one handy file (geometry meshes, lightmaps, entities, groups, vis-groups, camera settings)
Support for CSM file versions 4 and 5
Build one single object from your whole map for easy handling and manipulation (position, scale, apply shaders,...)
Lightmaps are directly loaded from the map file into a separate texture stage (no duplicate geometry)
Easily access all your important entity data (positions, flags, properties,...)
Make use of the powerful grouping functions (e.g. hide complex vis-groups when they are no longer in view to save processing power)
All this is packed into one handy CSMFile class
Released as Open Source under the GNU GPL license


Usage Example:

This code snippet loads a CSM file and builds an object from it in a few lines of code:




Scene Comparison:



Attachments

Login to view attachments
Matty H
11
Years of Service
User Offline
Joined: 7th Oct 2008
Location: England
Posted: 10th Jun 2011 18:48
Quote: "Free to use for non-commercial purposes"


Will you be selling a license?
Or is the non-commercial restriction out of your control for whatever reason?

I think I have cartography shop so I may give this a try, I usually use 3DWS as there is a great importer for that on these forums.

Using your importer, does it mean all the objects are setup in GDK with ID numbers etc, and does this mean you get automatic culling?

_Pauli_
AGK Developer
11
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 10th Jun 2011 19:06 Edited at: 10th Jun 2011 19:09
Quote: "Will you be selling a license? Or is the non-commercial restriction out of your control for whatever reason?"


The full version will be available for a little money, but the free version won't have any restrictions except a little popup showing me as the author (as this was a tough piece of work).
As far as I know there are no restrictions on the CSM file format what so ever. I'm not sure if it's even possible to protect a file format, as files are just streams of data...

Quote: "I usually use 3DWS as there is a great importer for that on these forums."


3DWS is like an improved version of CShop. But CShop is free and still a great tool for creating maps! It does everything I need and this importer originally started as a plugin for my own games.

Quote: "Using your importer, does it mean all the objects are setup in GDK with ID numbers etc, and does this mean you get automatic culling?"


As it is right now, the whole map is built into one object for easy handling, with all the sub-meshes and faces as limbs (keeping the hierarchy of CShop). I don't think DarkGDK does culling on individual limbs. But you could easily make objects out of the limbs. Or write your own culling by hiding/showing certain vis-groups.

Matty H
11
Years of Service
User Offline
Joined: 7th Oct 2008
Location: England
Posted: 10th Jun 2011 19:36
Quote: "(as this was a tough piece of work)."


I can imagine, I have the source to the 3DWS importer and its quite involved, great work Pauli.

Quote: "I don't think DarkGDK does culling on individual limbs. But you could easily make objects out of the limbs. Or write your own culling by hiding/showing certain vis-groups."


Sounds good.


I will definitely look at this when I start a new project, I had a few problems with 3DWS last time I used it but I can't remember what they were, it may have been the terrain stuff.

I also had a few problems with mapscape, seems to crash quite often.

Having this would provide another option, which is always a good thing

_Pauli_
AGK Developer
11
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 10th Jun 2011 20:16
Thanks matty! I'd be glad if you find good use for it!
It was really quite complicated. I had to learn all that binary file stuff, building improved data structures, building the meshes, etc... The whole thing is more than 600 lines of code now.

_Pauli_
AGK Developer
11
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 22nd Jun 2011 14:19 Edited at: 22nd Jun 2011 14:20
UPDATE:

CSMImport has just been released as Open Source under the GNU GPL license!
The download package has been attached to the first post.

Rights:
- Any usage (including commercial) of this program is allowed.
- You receive a copy of the source code.
- You may study and examine the source code.
- You may modify the source code or include it in your own projects.
- You are allowed to make as many copies of the source code as you like.
- You may release the modified source code to the public.

Rules:
- Every copy you release has to include a copyright notice, a warranty notice and a copy of the GNU GPL license.
- If you publish a modified version, it has to be released under the same license as the source code.

vitinho444
9
Years of Service
User Offline
Joined: 12th Oct 2010
Location:
Posted: 22nd Jun 2011 16:15
Where is the include?

Learning C++
VB6 Advanced: 4/5
VB.NET Advanced: 4/5
_Pauli_
AGK Developer
11
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 22nd Jun 2011 16:31
The header and code files are in the folder "Source Code".

_Pauli_
AGK Developer
11
Years of Service
User Offline
Joined: 13th Aug 2009
Location: Germany
Posted: 31st Jul 2011 21:05
I wonder if anyone ever made good use of this...

WLGfx
12
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 3rd Aug 2011 04:23
I will be using this soon when I move my current project to it's next stage. Great work Pauli...

Warning! May contain Nuts!

Login to post a reply

Server time is: 2020-09-29 06:31:28
Your offset time is: 2020-09-29 06:31:28