Adding bump mapping to Mars fries Celestia?

General discussion about Celestia that doesn't fit into other forums.
Topic author
NeilF
Posts: 35
Joined: 20.03.2005
With us: 19 years 8 months

Adding bump mapping to Mars fries Celestia?

Post #1by NeilF » 22.03.2005, 09:28

I'm trying to add a bump map to Mars, but in doing so it seems to make Celestia die. It just sits there doing nothing but accessing Ram/Harddrive?
This is my current setup:-

Code: Select all

extras/
        mars/
                  mars.ssc (see below)
                  textures/
                        hires/
                        lowres/
                        medres/
                                MarsVT.ctx (see below)
                                16kMarsBump.png
                                MarsVT/
                                        level0/
                                                *png files*
                                        level1/
                                                *png files*
                                        level2/
                                                *png files*
                                        level3/
                                                *png files*
                                        level4/
                                                *png files*


My mars.ssc file:-

Code: Select all

AltSurface "MarsVT" "Sol/Mars"
{
   Texture "MarsVT.ctx"
   BumpMap "16kMarsBump.png"
}


My Mars.ctx file:-

Code: Select all

VirtualTexture
{
        ImageDirectory "Mars"
        BaseSplit 0
        TileSize 512
        TileType "png"
}


Without the bump mapping Mars is displayed fine...

I apologise for what are no doubt "noob" questions, but none of these downloads seem to come with the slightest bit of help text (ie: what to put where etc), and I can't seem to find the answers on the forum, or help sites :(

note: I've tried the bump mapping with the standard textture as well... This does not fry Celestia, but doesn't seem to make any difference to Mars?

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #2by selden » 22.03.2005, 11:57

What kind of graphics card do you have?
Some of them simply don't have the functionality to be able to draw bumpmaps.
Selden

TERRIER
Posts: 717
Joined: 29.04.2003
With us: 21 years 6 months
Location: West Yorkshire, England

Post #3by TERRIER » 22.03.2005, 12:26

I must admit that when I had 256MB of RAM, realistically I could only run a 4k "single piece" png bump/normal map on my system.

Using a 16k VT dds Normal map was fine, if a little jerky.
1.6.0:AMDAth1.2GHz 1GbDDR266:Ge6200 256mbDDR250:WinXP-SP3:1280x1024x32FS:v196.21@AA4x:AF16x:IS=HQ:T.Buff=ON Earth16Kdds@15KkmArctic2000AD:FOV1:SPEC L5dds:NORM L5dxt5:CLOUD L5dds:
NIGHT L5dds:MOON L4dds:GALXY ON:MAG 15.2-SAP:TIME 1000x:RP=OGL2:10.3FPS

Topic author
NeilF
Posts: 35
Joined: 20.03.2005
With us: 19 years 8 months

Post #4by NeilF » 22.03.2005, 14:55

selden wrote:What kind of graphics card do you have?
Some of them simply don't have the functionality to be able to draw bumpmaps.


Radeon 9800XT (2.8P4 with 1gb of ram)

I suspect the problem is me not knowing how to specify it in the script? ie: I cannot even use the bumpmap on the standard texture!? ie: It appears to make no difference.

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #5by selden » 22.03.2005, 15:34

You should be able to see bumpmaps with a 9800. (I'm assuming you've installed the very latest drivers from ATI.)

Make sure the RenderPath is set to "OpenGL vertex program", although this should be the default for your card. While running Celestia, type a ctrl-V several times to see what Render Paths are available and how they differ.

Don't forget that the effects of a bumpmap are most noticable near the terminator, when sunlight is at a low angle. Also, bumpmaps do not cause Celestia to cast shadows across the rest of the landscape. They only shade the sides of the protrusions.

When looking at Mars using an unmodified version of Celestia and the Basic Render Path, you should not see any bumps:
Image

With the OpenGL vertex program path, you should see something like this:
Image

Does this help?
Selden

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #6by selden » 22.03.2005, 15:43

Sorry: I went back and reread your original post.

I'm trying to add a bump map to Mars, but in doing so it seems to make Celestia die. It just sits there doing nothing but accessing Ram/Harddrive?


That is your system paging itself to death.
You are trying to use too many large textures at the same time. They simply don't fit into the amount of RAM you have on your system, so your computer is trying to use disk space as virtual memory. That makes the system absurdly slow. You need to buy more memory for your computer. In the meantime, you will have to limit the number of textures that you ask Celestia to use.

Open the "Task Manager" and look at what's shown by its "Performance" tab. When you run Celestia, make a note of how much memory it's trying to use. Your computer needs more memory than that.
(512 MB is a good place to start. 1GB should be enough.)
Selden

Topic author
NeilF
Posts: 35
Joined: 20.03.2005
With us: 19 years 8 months

Post #7by NeilF » 22.03.2005, 15:43

selden wrote:You should be able to see bumpmaps with a 9800. (I'm assuming you've installed the very latest drivers from ATI.)

Make sure the RenderPath is set to "OpenGL vertex program", although this should be the default for your card. While running Celestia, type a ctrl-V several times to see what Render Paths are available and how they differ.

Don't forget that the effects of a bumpmap are most noticable near the terminator, when sunlight is at a low angle. Also, bumpmaps do not cause Celestia to cast shadows across the rest of the landscape. They only shade the sides of the protrusions.

Does this help?


I already have some bumpmaps working - Eg: for titan. That all came as a single downloadable zip so no problem.

I'm almost certain the problem here is the fact I have "16kMarsBump.png" and simply have not put it in the right place, or changed tge SSC correctly to use it? (see my examples above)

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #8by selden » 22.03.2005, 15:49

Sorry: I've been answering the wrong question.

Remember that a 16K image is 16Kx8Kx4 bytes = 128MBx4=512MB. Before Celestia can load a PNG image into your graphics card, it has to expand it to its full size in RAM.

Your system needs to have more than 512MB of main memory in order to display a surface texture of that size in a reasonable amount of time.

"Virtual textures" help because you don't have to load one gigantic image at once, but you do have to load many of them, depending on how close the viewpoint is to the planet.
Selden

Avatar
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 22
With us: 22 years 7 months
Location: Hamburg, Germany

Post #9by t00fri » 22.03.2005, 16:42

Neil,

for 'Noobs' (and programmers alike ;-) ), it pays to do small back-of-the enveloppe memory estimates first, before plugging in 16k bump map files in addition to the main texture!

The problem is not so much your system memory, but rather the memory available on your graphics card (256MB?)! That's why you will be much better off, taking my virtualtex script that chops your 16k monster PNG file into many little PNG tiles. These you will be able to handle very smoothly with your graphics setup. Please use the forum's search engine to localize the latest version of my virtualtex.

Don't forget, that handling of such big textures in Celestia is best done after some familiarity with the program has been acquired already. In contrast, the default Celestia distribution is meant to work at the 'push button' level for newcomers.

Bye Fridger

TERRIER
Posts: 717
Joined: 29.04.2003
With us: 21 years 6 months
Location: West Yorkshire, England

Post #10by TERRIER » 22.03.2005, 17:20

Neil,

Looking at the AltSurface set-up in your original post, it would seem to be correct.
However, I'm not sure if you can run the 16k texture.
If you're still wanting to use a full size texture and not a VT, and although this might seem a bit of a pain, it might be worth trying a 4k, and then an 8k version to see if your system can handle them.
1.6.0:AMDAth1.2GHz 1GbDDR266:Ge6200 256mbDDR250:WinXP-SP3:1280x1024x32FS:v196.21@AA4x:AF16x:IS=HQ:T.Buff=ON Earth16Kdds@15KkmArctic2000AD:FOV1:SPEC L5dds:NORM L5dxt5:CLOUD L5dds:
NIGHT L5dds:MOON L4dds:GALXY ON:MAG 15.2-SAP:TIME 1000x:RP=OGL2:10.3FPS

Topic author
NeilF
Posts: 35
Joined: 20.03.2005
With us: 19 years 8 months

Post #11by NeilF » 22.03.2005, 17:52

TERRIER wrote:Neil,

Looking at the AltSurface set-up in your original post, it would seem to be correct.
However, I'm not sure if you can run the 16k texture.
If you're still wanting to use a full size texture and not a VT, and although this might seem a bit of a pain, it might be worth trying a 4k, and then an 8k version to see if your system can handle them.


I'm trying a 4K one, and am having some success now... Do I need to specify a "bumpheight" in the SCC as well?

eg:-

Code: Select all

Modify "Mars" "Sol" {
   BumpMap "4kMarsBump.png"
   BumpHeight 12.0
}

TERRIER
Posts: 717
Joined: 29.04.2003
With us: 21 years 6 months
Location: West Yorkshire, England

Post #12by TERRIER » 22.03.2005, 18:23

NeilF wrote:I'm trying a 4K one, and am having some success now... Do I need to specify a "bumpheight" in the SCC as well?


Ah yes, I'd forgotten about the bumpheight setting. I use a lot of Normal maps, which don't need a bump height setting.

regards,
TERRIER
1.6.0:AMDAth1.2GHz 1GbDDR266:Ge6200 256mbDDR250:WinXP-SP3:1280x1024x32FS:v196.21@AA4x:AF16x:IS=HQ:T.Buff=ON Earth16Kdds@15KkmArctic2000AD:FOV1:SPEC L5dds:NORM L5dxt5:CLOUD L5dds:
NIGHT L5dds:MOON L4dds:GALXY ON:MAG 15.2-SAP:TIME 1000x:RP=OGL2:10.3FPS

Sky Pilot
Posts: 99
Joined: 01.12.2004
With us: 19 years 11 months
Location: Moved recently from the Bihem System, now in Fort Worth, Texas, USA

Post #13by Sky Pilot » 22.03.2005, 20:00

Selden, the laptop I'm running right now is using a Radeon 7500 AGP with 32 MB RAM. Do you know whether this card will display bumpmaps? Thanks!
"In the beginning the Universe was created. This has made a lot of people very angry and been widely regarded as a bad move."

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #14by selden » 22.03.2005, 21:51

Sorry, I don't know for sure. Sometimes the graphics vendors add new functionality in their drivers.

The quickest way to find out if they should work is to run Celestia and type a ctrl-V several times. Each time you type it, you should see a message appear briefly in Celestia's window telling you which "Render Path" it is using.

The paths you might see listed are
Basic
Multitexture
OpenGL vertex program
OpenGL 2.0

Here's a summary of the features they support:

"Basic" shows colored planets.
"Multitexture" adds night lights and shadows of planets on rings.
"OpenGL vertex program" adds bumpmaps, specular reflections and shadows of rings on planets.
"OpenGL 2.0" adds multiple light sources and their shadows

Each of the later three "Render Paths" requires additional OpenGL features which may not be present in older cards.
Selden

Sky Pilot
Posts: 99
Joined: 01.12.2004
With us: 19 years 11 months
Location: Moved recently from the Bihem System, now in Fort Worth, Texas, USA

Post #15by Sky Pilot » 22.03.2005, 22:48

Thanks Selden. That answers my question. I only get Basic and Multitexture.
"In the beginning the Universe was created. This has made a lot of people very angry and been widely regarded as a bad move."


Return to “Celestia Users”