Forum Index >  > Artists' Studio New Topic Post Reply
 A bit of help on the Cal3d xml character file and materials
mr d
 04/07/2010 06:10PM (Read 1516 times)  
Full Member

Status: offline

Registered: 12/07/2005
Posts: 160

Thought I'd add this tidbit for those having problems making a Cal3d XML file for a character in regards to materials and textures.
In between your character quotes you'll have skeleton- animation- mesh and finally material which you enter yourself. Now what you need to do is when making this file open each of your .XMF files and look at the second line where you see 'material=' followed by a number. These numbers are how you have to order your Material Section at the end of the character XML(Mesh and Material order does not need to be the same).
Now the fun part:
On export you may find if a charater is composed of more than one object, that Cal3d may give two objects the same Material number. Example if I made a head with seperate eyes but eyes linked to the head. Cal3d
sometimes will number it Head-Material=0, Eyes-Material=1. Going through the heirarchy.
But on occasion you may find it doing a Head-Material=0, Eyes-Material=0. Treating each as a seperate object with one Material. If it does this each object in this model would recieve the same first material listed in your XML Material section.
To correct you simply open up one of the XMF files and change the material number to 1.
Also if you have a character with more than one part(say a marine with gun and hat) that share the same texture, you can use just one material in your section to cover both. Just make sure the Material number in the .XMF for both objects matches the list order of the appropriate XRF material file.

Side note: the mesh XMF does not specify a particular material file name, just a number. So in the above example on export Cal would create Gun.XRF and Hat.XMF. But you can remove one and rename the other GunHat.XMF. Just make sure Material numbers match list order.

Mr. D

Profile Email
 04/16/2010 01:18PM  
Full Member

Status: offline

Registered: 01/30/2008
Posts: 322
Mr. D, thanks for that hints!

I just had some annoying issue with invisible/black tga-maps, so here's another one:
- When exporting a material with texture-maps be sure to set its diffuse color to opac white [255,255,255,255]. (This can also be set in the XRF.)
It seems the diffuse-color is multiplied with the texture-colors and darkens the texture if not white...

Profile Email
Content generated in: 0.37 seconds
New Topic Post Reply

Normal Topic Normal Topic
Sticky Topic Sticky Topic
Locked Topic Locked Topic
New Post New Post
Sticky Topic W/ New Post Sticky Topic W/ New Post
Locked Topic W/ New Post Locked Topic W/ New Post
View Anonymous Posts 
Anonymous users can post 
Filtered HTML Allowed 
Censored Content 

About delta3d

delta3d is a game and simulation engine appropriate for a wide variety of simulation and entertainment applications. delta3d uses best-of-breed open source technologies to create a fully integrated game engine and with content creation tools.MORE

Sponsor delta3d

For the past few years Caper Holdings LLC has been solely driving development of delta3d. To continue to provide upgrades and releases we are allowing the community to purchase sponsorships


User Functions

Don't have an account yet? Sign up as a New User

Lost your password?