Page 1 of 1

jpg problem

Posted: 15.02.2004, 22:08
by jrr
Hi there,
Could somebody tell me why some jpg textures will load and others don't.
I downloaded some textures of mars and earth and some don't show up on the planet. I checked the ssc file and the name of the file under altsurface was correct. Please help...

Thanks

Posted: 15.02.2004, 22:12
by granthutchison
Do your jpg's all have sides that are a power-of-two pixels long? If not, Celestia won't show them. So you'll need to rescale to 512x256, or 1024x512, or 2048x1024, etc.

Grant

Posted: 15.02.2004, 22:21
by jrr
Just had a look. They are ok: 1024x512, so that's not the prob.

Posted: 15.02.2004, 22:25
by granthutchison
Is the name of your defined alternate surface appearing in the Alternate Surface menu when you right-click on the object of interest? If not, I think you might have a syntax error in the AltSurface definition. If the alternate surface name is there but you're coming up with a white sphere when you select it, then Celestia is having trouble finding the correct texture, for some reason.

Grant

Posted: 15.02.2004, 22:38
by jrr
The name appears in the Alternate Surface menu and yes i'm getting a white sphere. I did convert the jpg to a dss just to check, and it showed up as a texture map. But the jpg....

Posted: 15.02.2004, 22:45
by granthutchison
OK, where have you made the AltSurface statement, and where have you put the texture?
If you've edited solarsys.ssc with the AltSurface statement, then your texture needs to be in the main Celestia textures/medres directory. If you've created the AltSurface in a little add-on ssc, then the usual thing would be to place the associated texture in the same directory tree, so you'd have something that looked like:

Code: Select all

extras\
  myaddon\
     myaltsurface.ssc
     textures\
        medres\
            mynewtexture.jpg


Grant

Posted: 15.02.2004, 22:53
by jrr
Great, thank's a lot that's solved!!!

Buuuuuut what is the problem when I see a black sphere after I put a high resolution map in the hires folder and switch to high resolution?

Posted: 16.02.2004, 04:20
by Mikeydude750
What graphics card do you have?

It's possible that you might not have enough video memory, and the texture can't be displayed...

Posted: 16.02.2004, 07:51
by jrr
I have an old Nvidia GForce2 MX 32Mb.
But then again, why can I display the converted dss file and not the jpg?
Something to do with compression and memory ?

Posted: 16.02.2004, 11:32
by selden
jrr,

The most common problem is trying to use a surface texture image that's the wrong size. It has to be a power of two on a side (e.g. 1024x512).

Also, you haven't mentioned how big the image is. A JPEG or PNG has to fit in the memory of your graphic card after it has been fully expanded along with all of the other images you've previously looked at. A 1024x512 JPEG, for example, requires 1024x512x4 bytes = 2MB of grahics memory. In contrast, a DDS texture only needs as much room in graphics memory as it occupies on disk.

Posted: 16.02.2004, 12:24
by jrr
The file size is 4096x2048 pixels and the uncompressed file size= 24 Mb
With all the other textures loaded of Celestia I guess it's a limitation of my card ?

Thank's for your help

J?rgen

Posted: 16.02.2004, 12:32
by selden
An uncompressed 4Kx2K image simply can't fit into the memory of your card. Don't forget that the memory is used for other functions, too, like the Z buffer. You can either convert the image to DDS format, or you can upgrade to a card with more memory. (A 128MB FX 5200 is about US$ 85.)

Posted: 16.02.2004, 14:27
by jrr
Ok, thanks for the information.
We can close this thread now I think.