Cham wrote:ElChristou wrote:Today I can load the page; indeed it's a much better model! Have you send an email as those guys asked? (else I'll send it)
I'll publish a 3ds version only (no CMOD version), since there's some problems with smoothing with the CMODTool utility (we need to solve this, by the way !).
Is this the smoothing problem your referring to?
All my models go through the cmodfix tool. I noticed that when I export models with only quads that these ugly squares do not appear. This model was created by converting a height map to a dem and then converting the dem to a waveobject. This conversion to waveobject creates triangles. When I export this to cmod I get the ugly squares even after running through cmodfix.
I'm not sure why the squares disappear when I export quad models to cmod. The exporter I wrote creates the triangles during export with this code.
Code: Select all
for face in mesh.faces:
out.write( '%f %f %f %f %f %f' % (face.v[2].co.x, face.v[2].co.y, face.v[2].co.z, face.v[2].no.x, face.v[2].no.z, face.v[2].no.y,))
out.write( ' %f %f\n' % face.uv[2])
out.write( '%f %f %f %f %f %f' % (face.v[3].co.x, face.v[3].co.y, face.v[3].co.z, face.v[3].no.x, face.v[3].no.z, face.v[3].no.y,))
out.write( ' %f %f\n' % face.uv[3])
out.write( '%f %f %f %f %f %f' % (face.v[0].co.x, face.v[0].co.y, face.v[0].co.z, face.v[0].no.x, face.v[0].no.z, face.v[0].no.y,))
out.write( ' %f %f\n' % face.uv[0])
out.write( '%f %f %f %f %f %f' % (face.v[0].co.x, face.v[0].co.y, face.v[0].co.z, face.v[0].no.x, face.v[0].no.z, face.v[0].no.y,))
out.write( ' %f %f\n' % face.uv[0])
out.write( '%f %f %f %f %f %f' % (face.v[1].co.x, face.v[1].co.y, face.v[1].co.z, face.v[1].no.x, face.v[1].no.z, face.v[1].no.y,))
out.write( ' %f %f\n' % face.uv[1])
out.write( '%f %f %f %f %f %f' % (face.v[2].co.x, face.v[2].co.y, face.v[2].co.z, face.v[2].no.x, face.v[2].no.z, face.v[2].no.y,))
out.write( ' %f %f\n' % face.uv[2])
Models that have triangles already are exported with this code.
Code: Select all
for face in mesh.faces:
d = 0
for vert in face.v:
out.write( '%f %f %f %f %f %f' % (face.v[d].co.x, face.v[d].co.y, face.v[d].co.z, face.v[d].no.x, face.v[d].no.z, face.v[0].no.y,))
out.write( ' %f %f\n' % face.uv[d])
When I view the models with wiremode in Celestia, they all have similar looking triangles but when exported with the second code block they have ugly squares that I can't get rid of..Models exported to cmod with the first code block look smooth with no ugly squares.
Cham, if you see this, maybe you could post what these smoothing problems your having look like?
cartrite