Reading Simple Data From a Caligari TrueSpace File

User avatar
BNG
Chief Warrant Officer
Posts: 684
Joined: 16 Oct 2009, 03:26
Type the number ten into the box: 0
Location: Texas

Reading Simple Data From a Caligari TrueSpace File

Post by BNG »

Just thought this post might be useful for someone trying to mess with the Caligari model formats. I've always had some interest in writing export and possibly import scripts, but so far the task is not for the timid at heart. I mostly work with the older COB and SCN format using older modeling tools like 3D Exploration 1X, Blender, doesn't really support either Caligari format anymore, so getting model into Blender nowadays involves converting models to some common format like 3DS. I know that Design Devil did some conversion work with a compiler called Free Basic 2, but I was wondering if it can be used to compile import and or export TSX based plugins for the modelside 6.6 of 7.6 or 7.61?

Also, does anyone know if Python has any applications for TS in terms of importing and or exporting model data to and from TS? Thanks, Leroy.
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

It is possible to write any type of TS6 plugin with my FreeBasic version. The reason for the SDK translation to FreeBasic was 1. I hate C++ and 2. FreeBasic is - what the name says - free for everyone.

The point is not which language you use to write the plugin, the point is the knowledge of the trueSpace internals about the model format and the translation between them i.e. importing or exporting 3DS or OBJ.

Years ago i had the idea to write such a exporter for LUXrender but it was to difficult for me to translate the different model types from truespace to the destination format including textures, light, animation stuff etc. But maybe with the open source plugin dribble and a few other informations around you could do this. Dribble include a lot of the needed information except nurbs and metaballs and such stuff.

The most difficult part is (in my eyes) to find enough code examples to handle the truespace side because the SDK help is ... sorry to say that ... sh*t

But, if you need something (C++ SDK, file format informations, example codes or other stuff) feel free to ask me, i have a lot of material here.
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
nigec
Master Chief Petty Officer
Posts: 561
Joined: 21 May 2009, 18:46

Re: Reading Simple Data From a Caligari TrueSpace File

Post by nigec »

I'll have a look, will FreeBasic work with 7.6 modelside?. I have a horrible feeling I just wiped the hard drive TS6.6 was on :oops:
I'm looking at doing an exporter to xml, I loath C++
If you interested this is what I'm doing these days :)
http://nigecdesigns.co.uk/Batchcreator/"

nevermind, it does work :)
Nice work :worship:
User avatar
BNG
Chief Warrant Officer
Posts: 684
Joined: 16 Oct 2009, 03:26
Type the number ten into the box: 0
Location: Texas

Re: Reading Simple Data From a Caligari TrueSpace File

Post by BNG »

It does appear that information is a bit limited, and I've done way too many web searches only to find virtually nothing about writing TSX or even RSX based plugin code written in plain text format. Trying to view binary versions is way too hard. I have a simple PE application called BDASM to view information from TSX files, but I don't know what to do with the resulting output. DD, your work with FBC are amazingly some of the best examples I've seen in all my searching. Clinton, has some pretty amazing code examples as well.
User avatar
nigec
Master Chief Petty Officer
Posts: 561
Joined: 21 May 2009, 18:46

Re: Reading Simple Data From a Caligari TrueSpace File

Post by nigec »

clintonman's fbx exporter is probably the one to take a look at
However DD's examples are very nicely commented and probably the best way to go, after an hour of trying freebasic it was "oh I see how it works!", whether I can do an exporter and server/client is a different matter.
I'm going to try exporting a triangle, then a square, a cube
then a diffuse colour on a cube
then the fun starts with textures and uv's :?
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

Maybe Fenerit is also a good source for informations. He wrote (and writes) a lot of TSX.

btw... Phyton in tS6.6 (7.6 Modelside) is no solution for that. I also would start years ago with phyton but in tS you can not do many things with it. The implementation of Phyton in tS is just a joke.

This was also a reason for me to learn how i can write TSX.

I have so many cool ideas for useful plugins for tS but for the most of them i have not enough experience with all this 3D stuff from a geometrical or mathematical point of view and the most importend point - i have no time :(
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
nigec
Master Chief Petty Officer
Posts: 561
Joined: 21 May 2009, 18:46

Re: Reading Simple Data From a Caligari TrueSpace File

Post by nigec »

Yeah I considered Python, it would of helped me no end because there is already a Blender plugin that has everything I need, but reading up on TS's Python API it wasn't going to be much use.
User avatar
Fenerit
Senior Chief Petty Officer
Posts: 173
Joined: 21 Nov 2011, 19:19
Type the number ten into the box: 9

Re: Reading Simple Data From a Caligari TrueSpace File

Post by Fenerit »

DesignDevil wrote:Maybe Fenerit is also a good source for informations. He wrote (and writes) a lot of TSX.
I can share my codes via PM if one wish to learn from or to enhance them (time to add more comments), but in the part concerning the tSxapi mostly I learn from YOUR guys sources and from the tSxapi SDK examples (far less from the doc manual); there is nothing of advanced manipulations ON tSxapi in my codes, just operations OF tSxapi. For 95% they concerns with MFC/C++ controls' declarations and for the remaining 5% with the tSxapi; thus they could look more like dialogbox "templates" than truly effective plugins which does adds new tools. Since I know VB best more than C++, and LUA and Perl than Python, also myself is looking for sources of tSxapi for Freebasic which is very similar to VB in its constructors, otherwise I can't escape from the "database/textediting" realm that is the programming's subclass of the forementioned languages which I know a little a bit but that for a 3D modeler is somewhat marginal.
DesignDevil wrote: The point is not which language you use to write the plugin, the point is the knowledge of the trueSpace internals about the model format and the translation between them i.e. importing or exporting 3DS or OBJ.
This is completely true. BTW, I can also add that in making plugins one is involved just upon those program's parts with which he deal best; i.e., because my use of tS is mainly ranged by static meshes, I overlook of learning the tSxapi for animations in favour of other unless required by the advancement of the plugin's development, if any.

BTW, what about to start some MFC/C++/Freebasic tutorials within the Developer subforum?
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

BTW, what about to start some MFC/C++/Freebasic tutorials within the Developer subforum?
Well we had a own forum for this but it was not enough used (not enough programers out there) so that it was closed ... but hey, why not - give it a try

Alternative: we could reopen a new site for this - i could host that on my website if there is enough interest. It could be done in a few hours. That would give us the possibility to have a place where people could download a lot of stuff and maybe all sourcecodes which we can find and we self publish as open source, tutorials etc. etc.

If we do so ... is a forum the best way? - or a wiki - or something else?

Let me know your opinion ...
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
nigec
Master Chief Petty Officer
Posts: 561
Joined: 21 May 2009, 18:46

Re: Reading Simple Data From a Caligari TrueSpace File

Post by nigec »

I'd be interested, I would say a wiki or both
I'm in a strange place as I know more about the renderer I want to "plugin", Truespace I only ever modelled with it so I guess that's going to be the fun part.

Luckily I don't need the Thea SDK, I do have it but I'm using a client to communicate, this way I skilfully avoid any licensing issues, I just have to create a pipeline, exporter and material system and a render view, I know all the commands TS needs to send I have a working client but C# or Python..
MFC/C++ interests me, I have bailed on C++ on every version of my Batch rendering tool and regret it every time!

Maybe I'm out of my depth but it seems promising there is people willing to help
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

Hello,

I ask myself what is better. A forum, wiki or a combination of both. Then i do a search and my solution is that a combination is not so easy to handle and also not simple enough to use. (i.e. find articles etc.). Just a wiki is also no good solution in the aspect of discussions code related stuff.

So i decided to setup a phpbb3 forum on my webspace. i call it T.E.C.C. (Truespace Extension Coder Corner).

The link is http://tecc.designdevil.de

It is my first forum so let me know what you think, what you miss or if you have any problems with it. Try a little bit around.

The idea for the start is to keep it small, simple, easy to use and not overloaded with different things. I just implemented a little mod to fold/unfold source code.

ok, now...let's give it a try.
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
BNG
Chief Warrant Officer
Posts: 684
Joined: 16 Oct 2009, 03:26
Type the number ten into the box: 0
Location: Texas

Re: Reading Simple Data From a Caligari TrueSpace File

Post by BNG »

Looks like an excellent idea I added it to my favs. Thank, Leroy.
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

THX,

i had the idea years ago but there was nobody who wrotes TSX except me ;)

But let's see what happens. At the moment i fill the forum with a lot of my finished and unfininished projects.
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
Emmanuel
Chief Warrant Officer
Posts: 670
Joined: 14 Jun 2009, 06:47

Re: Reading Simple Data From a Caligari TrueSpace File

Post by Emmanuel »

Many people (like me) want to develop plugins but the lack of ressources is a serious brake. Also, we are all growing up and having children and new responsabilities only leave little time to explore by ourselves.

Your forum is very well done, I like the design and colors very much. I wish it will become a great ressource place.
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

THX Emmanuel,
Also, we are all growing up and having children and new responsabilities only leave little time to explore by ourselves.
i absolutly agree ;)
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
Fenerit
Senior Chief Petty Officer
Posts: 173
Joined: 21 Nov 2011, 19:19
Type the number ten into the box: 9

Re: Reading Simple Data From a Caligari TrueSpace File

Post by Fenerit »

I've take a look at the forum; very elegant indeed. 8-) One quaestion: shaders, are they also included?
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

Not yet but it is a very interesting point. I had never the intention to understand shaders but they are very importend especialy for exporters etc.

Any ideas about that? Which type of Forum would be useful for that?

Shader Source Codes, Shader Development, Routines and Formulas?

Let me know
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
Fenerit
Senior Chief Petty Officer
Posts: 173
Joined: 21 Nov 2011, 19:19
Type the number ten into the box: 9

Re: Reading Simple Data From a Caligari TrueSpace File

Post by Fenerit »

Shaders development. And then subtitle like "place to discuss, develop and share, shaders and shaders sources" or similar; so that all tS APIs are covered.
User avatar
DesignDevil
Master Chief Petty Officer
Posts: 500
Joined: 22 May 2009, 08:52
Type the number ten into the box: 0
Location: Neuruppin, Germany, Earth.

Re: Reading Simple Data From a Caligari TrueSpace File

Post by DesignDevil »

Done.
I still use TrueSpace 6.6
Link: My Youtube Channel
Link: www.DesignDevil.de - Plugins, Tutorials and more about TrueSpace 6.6
User avatar
Fenerit
Senior Chief Petty Officer
Posts: 173
Joined: 21 Nov 2011, 19:19
Type the number ten into the box: 9

Re: Reading Simple Data From a Caligari TrueSpace File

Post by Fenerit »

So matching? :shock: This is a risk: I'm not of English mother-tongue... :D
User avatar
BNG
Chief Warrant Officer
Posts: 684
Joined: 16 Oct 2009, 03:26
Type the number ten into the box: 0
Location: Texas

Re: Reading Simple Data From a Caligari TrueSpace File

Post by BNG »

Fenerit wrote:So matching? :shock: This is a risk: I'm not of English mother-tongue... :D
No problem just write them in your languages and we can just translate them as needed; it works pretty good. Leroy

Return to “General Discussion”