3ds writer problem

I know, this is little bit off-topic, but many of you know how to read/write 3ds. I wrote a 3ds writer, but the round edges are not smooth. Which chunks do I have to set, to get smooth edges with goroud-shading?

I got two cylinder with identical number of faces, one written with my writer, one with 3ds-max. The max file is round, mine not:



Hey, hey. I’m currently earning my money with a 3ds writer…

You need to specify the smoothing chunk, which is in the faces chunk I believe (so its size applies to this). For every face, you need to specify a bit for a certain smoothing group (leaving 32 smoothing groups and any combination of them). Then, when two adjacent polys belong to the same smoothing group the get smoothed agains each other (interpolating their connecting vertice’s normals).
If you don’t have info about that chunk, contact me. I also had that problem, and I realized that I wasn’t adding the smoothing chunk’s size into the Face chunk but as a chunk out of it. It has to be encapsulated by the faces chunk.

Hey, thanks! That will solve my problem. But isn’t the format limitated to 32 groups of rounded faces? I think, I would have big problems with that (as I have very big models…). Is there a solution for that? Maybe more face-lists?


Basically yes, but you won’t probably have a model that need 32 smoothing groups, and if so, you can split it up in more objects (head and feet etc.)

I have lot’s of objects with more than 32 smoothing groups. Even a simple plate with 32 round holes would have 32 smoothing groups… and that’s a single part in my system. So I would have to split it up and a Max-User would see e.g. plate_1, plate_2 etc. as single parts?

It’s a mad file format :-/

Have you got good documentation? I’ve only found the chunk-ID number of the smoothing group, but no futher description. So I try to find the rest with a hex-edit :frowning:


[This message has been edited by Kilam Malik (edited 02-08-2001).]

As long as the faces of two smoothing groups haven’t got a sharp edge, you can put them in the same smoothing group. So you can reuse many smoothing groups. Gonna email you my 3ds doc.

Oh, what’s your email?

Please send it to f.epple@cadenas.de