Page 1 of 1

Help! Ida shape model is mirror-reversed

Posted: 14.01.2003, 02:29
by granthutchison
After a lot of messing around trying to lay a texture on to the asteroid Ida in Celestia, I've realised that the 3ds model is mirror-reversed. (You can confirm this by comparing the Celestia Ida with the Ida images and animations at http://www.solarviews.com/eng/ida.htm.)
The error probably arose in the first place because Ida is a retrograde rotator, so the original public-domain shape model has longitude increasing to the east, rather than the west. So if Celestia's 3ds mesh was built in the usual way, it would come out reversed east for west.

Now, I already have a nice, correctly orientated Ida model in POV-ray, but unfortunately there doesn't seem to be any way to export that to 3ds. So I took Tayfun Oner's VRML model from the site above, and ran that through the Crossroads file converter, and I now have a lovely, correct 3ds Ida model in Celestia - but I don't seem to be able to lay a texture on to it. (Aaaargh!)

Can anyone out there edit the original Celestia model? Failing that, can anyone advise if there's anything I might be able to do to the VRML so that it turns out a 3ds file that is fully Celestia-compatible?

Grant

Posted: 14.01.2003, 22:29
by granthutchison
Still fiddling with this.
I've converted the Celestia 3ds file to VRML 1.0, reversed the z coordinates and z components of the normal vectors, and reversed the numbering of the vertices for the faces. This produces a nicely reversed VRML object, but it is a little badly behaved when I export it to 3ds and look at it in Celestia - the brightness varies in visible increments depending on the angle of view, and it won't accept an applied surface texture.
Suggestions, anyone?

Grant

Posted: 14.01.2003, 22:38
by chris
granthutchison wrote:Still fiddling with this.
I've converted the Celestia 3ds file to VRML 1.0, reversed the z coordinates and z components of the normal vectors, and reversed the numbering of the vertices for the faces. This produces a nicely reversed VRML object, but it is a little badly behaved when I export it to 3ds and look at it in Celestia - the brightness varies in visible increments depending on the angle of view, and it won't accept an applied surface texture.
Suggestions, anyone?

Grant

I'm not sure what the problem with the texture is . . . could it be that the texture file name is getting munged? E.g. set to an absolute pathname like c:\foo\bar.jpg?

The problem with brightness sounds like your conversion tool is adding specularity to the surface material. Take a look at the Material node in the VRML file and make sure that the SpecularColor is set to black.

--Chris

Posted: 15.01.2003, 00:06
by granthutchison
chris wrote:I'm not sure what the problem with the texture is . . . could it be that the texture file name is getting munged? E.g. set to an absolute pathname like c:\foo\bar.jpg?
Just taking one of the prexisting 3ds objects, converting it to VRML and then back again to 3ds unchanged seems to stop it accepting a texture applied within Celestia - this happens with both Crossroads and 3Dwin. Maybe something the conversion utility is putting in?

chris wrote:The problem with brightness sounds like your conversion tool is adding specularity to the surface material. Take a look at the Material node in the VRML file and make sure that the SpecularColor is set to black.
Yes, you're right, 3Dwin was doing that. But even when I removed it in the VRML definition, it just put it back in again during the conversion to 3ds! Sigh.
Crossroads seems not to add specularity, but the odd brightness shifts persist, and they do seem to occur only after I've messed with the vertex coordinates (that is, I'm not seeing such shifts in models I just shift into VRML and then back again, unchanged). I wonder if I'm doing something that interferes with setting up appropriate normals for the vertices ... (He says, speculating on the basis of only slight knowledge.)

Grant

Posted: 15.01.2003, 18:56
by Guest
Hy Grant

I have mirrored the Ida model in 3dsmax (ver1.1). My problem is that the surface is also mirrored that means textur is sticked on inside of the model. I don't know what i can do.

I have also tried this with ACAD. But with this file texure dosn't work. Now i can't realy help.

But maybe it help try for export/import of 3d-files "3D Exploration v1.81" (30 day shareware) . The downloadlink can you find in the forum (Borg col... made this post).

By Jens

Posted: 16.01.2003, 15:39
by granthutchison
chris wrote:I'm not sure what the problem with the texture is . . . could it be that the texture file name is getting munged? E.g. set to an absolute pathname like c:\foo\bar.jpg?
Yes, I'm guessing, after nosing around the forum and looking at other postings re asteroid textures, that by importing into VRML I'm losing the connection to the texture (no sign of such a thing in the VRML text), so it's then obviously still going to be absent when I convert back to 3ds. :cry:
I guess I might be able to fix this by inserting the relevant information into the VRML definition before reconversion, but only if I understood what kind of information was required :oops:.
Seems like it can't be a named texture file, otherwise we wouldn't be able to switch textures. Is it a relative pathname to the textures directory? If you can give me an idea of what's needed I can see if I can find an analogue in VRML, and play around some more.

Grant

Eros model mirror-reversed?

Posted: 19.01.2003, 22:58
by HankR
I have a texture map for Eros based on NEAR spacecraft photography. It doesn't seem to correlate correctly with the Celestia shape model for Eros; it looks to me as if perhaps the Eros model is mirror-reversed also. Is it possible that all the 3ds models are being reversed when loaded in Celestia?

- Hank

Posted: 20.01.2003, 00:11
by Rassilon
The textures on models do get flipped somehow...from the way they appear in studio MAX yes...Im not sure if this is a bug or just how the 3ds is loaded in Celestia...

Eros model mirror-reversed?

Posted: 20.01.2003, 20:45
by granthutchison
HankR wrote:I have a texture map for Eros based on NEAR spacecraft photography. It doesn't seem to correlate correctly with the Celestia shape model for Eros; it looks to me as if perhaps the Eros model is mirror-reversed also. Is it possible that all the 3ds models are being reversed when loaded in Celestia?
Yes, Eros is reversed too. But most of the shape models are OK, in fact. Perhaps the Eros data, like the Ida data, were in a slightly different format, and this wasn't picked up when creating the 3ds meshes.
I've now abandoned my effort to fix the original 3ds from Celestia, and have just generated a brand new shape model for Ida. This is well-behaved in VRML (which is what I've designed it in), but it isn't exporting to a Celestia-3ds file well - I can either have it with a texture map, or I can have it smoothed, but I can't have both at the same time :( . But I'm hoping one of you folk may just be able to import it into 3D Studio and turn on automatic normals, which I'm assuming is all it needs ...

(If that's the case, we may also be able to improve on some of the other Celestia shape models, which have an unsightly seam down the prime meridian - this isn't being smoothed because (I think) a different set of vertices has been used for longitude 0 and longitude 360, instead of closing the shape model back on itself. I've certainly been able to generate models without this seam. :) )

Grant