feature request discussion CSM files

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
Post Reply
Guest

feature request discussion CSM files

Post by Guest »

I was taking a look at the Cartography Shop Source file and I was wondering if in the next release you can add the simple following change. Allow the caller to provide a callback function to deal with the 'attribute' string (I think thats what its called) if the string is non-null. This way when loading a CSM file one can parse attributes on the fly with out much extra effort. It will be much easier for development teams to add volumetric entities to there levels such as anti-portals/occluders, sectors for portals or pvs, and so much more.
Guest

Post by Guest »

Ok let me elaborate on my first post for clarity.

At one point I bought UT2k3 just to get my hands on MAYA and the Unrealeditor. I wanted to see how modding the game was accomplished, and the tools involved. Long story short, it all about the dev tools and engine integration and workflow. I see that CartographyShop can make this happen rather painlessly without a special file format.

I was looking at the cartography shop file format and noticed that each 'thing' has both associated flags and strings. I'm assuming that there are other file formats with per 'thing' data associated. Anyhow it dawned on me just how useful such a format could be. Take a simple cube mesh add a flag or key-value pair (which thanks to cartography shop can be added easily to a menu using a text file) and voila instant sectors, or voila instant anti-portals, tag any geometry as static... you get the idea.

So here I find myself looking at the Irrlicht source for the CSM reader, and I notice I would have to use createmesh member function of the Imeshloader interface. So I am thinking of the possible ways to implement the functionality I want and I realize that I'm gonna have to recompile the Irrlicht dll. (please correct me if I'm wrong on that point) So basically I thought that if the createmesh member function also allowed you to pass a callback function to it that each specific mesh loader could implement if it wanted to. Basically the callback would be called if there was any associated data with the currently processed 'thing'. The user could then implement the callback to tell the loader not to process the current 'thing' (for example if it was a volume for pure collision purposes, like to set a pvs) or to process it and the callback does some other additional processing.

Is there a simpler/different way of accomplishing this? I thought it seemed like a nice idea and would even be helpful for gamespecific formats?
niko
Site Admin
Posts: 1759
Joined: Fri Aug 22, 2003 4:44 am
Location: Vienna, Austria
Contact:

Post by niko »

Anonymous wrote:Is there a simpler/different way of accomplishing this? I thought it seemed like a nice idea and would even be helpful for gamespecific formats?
You could simply reimplement the csm loader with your modifications, and without needing to recompile/modify Irrlicht you can use it as a new loader via ISceneManager::addExternalMeshLoader(). (http://irrlicht.sourceforge.net/docu/cl ... er.html#a7)
Your new loader will then be preferred by Irrlicht when using .csm files.
Post Reply