Slow JPG decompression

The place to discuss creating, porting and modifying Celestia's source code.
Topic author
Redfish
Posts: 185
Joined: 22.05.2002
With us: 22 years 6 months
Location: Lat: 50.850 Long: 5.683 | Maastricht Netherlands
Contact:

Slow JPG decompression

Post #1by Redfish » 28.08.2002, 14:07

At the moment i'm using large jpg files for the moons of jupiter, but this considerable slows down celestia, even more than loading the earth16k.dds and the satellites surrounding it.
Is there any way to improve the performance?

Darkmiss
Posts: 1059
Joined: 20.08.2002
With us: 22 years 3 months
Location: London, England

Post #2by Darkmiss » 28.08.2002, 17:01

I noticed this too
So im trying to get as many dds files as i can

I had an 8k jpg of mars, and it took about 20 seconds to show on the screen, after traveling time.
CPU- Intel Pentium Core 2 Quad ,2.40GHz
RAM- 2Gb 1066MHz DDR2
Motherboard- Gigabyte P35 DQ6
Video Card- Nvidia GeForce 8800 GTS + 640Mb
Hard Drives- 2 SATA Raptor 10000rpm 150GB
OS- Windows Vista Home Premium 32

abiogenesis
Posts: 104
Joined: 07.06.2002
With us: 22 years 5 months
Location: Redmond, WA

Post #3by abiogenesis » 28.08.2002, 17:46

You can convert your jpegs to dxt compressed files using utilities created by nVidia. From their website you can download a stand-alone conversion program and a PhotoShop plug-in. The plug-in is, by far, the easier of the two. You just have to open your jpeg in PhotoShop and Save As dds.

The stand-alone program only works on tif files, I believe, so you'll need to be able to do the jpeg/tiff conversion at least. That can be done with The Gimp if you don't have PhotoShop.

- a b i o g e n e s i s -

Rassilon
Posts: 1887
Joined: 29.01.2002
With us: 22 years 9 months
Location: Altair

Post #4by Rassilon » 28.08.2002, 20:07

Yeah but has anyone got the dds plugin to work in photoshop?
I'm trying to teach the cavemen how to play scrabble, its uphill work. The only word they know is Uhh and they dont know how to spell it!

abiogenesis
Posts: 104
Joined: 07.06.2002
With us: 22 years 5 months
Location: Redmond, WA

Post #5by abiogenesis » 28.08.2002, 20:38

I don't know what you mean. I've used it to save files as .dds and that seemed to work fine. I haven't used it extensively and I can't really mess with it now (my GeForce 3 is in the shop :( ) but I didn't have any obvious problems.

- a b i o g e n e s i s -

Topic author
Redfish
Posts: 185
Joined: 22.05.2002
With us: 22 years 6 months
Location: Lat: 50.850 Long: 5.683 | Maastricht Netherlands
Contact:

Post #6by Redfish » 28.08.2002, 20:40

Yeah the plugin actually works for me. And making dds files from jpg's did improve speed for me. I couldn't dxt the europa8k texture, cuz it crashed my photoshop.

ANDREA
Posts: 1543
Joined: 01.06.2002
With us: 22 years 5 months
Location: Rome, ITALY

Post #7by ANDREA » 28.08.2002, 22:05

abiogenesis wrote:I don't know what you mean. I've used it to save files as .dds and that seemed to work fine. I haven't used it extensively and I can't really mess with it now (my GeForce 3 is in the shop :( ) but I didn't have any obvious problems.

- a b i o g e n e s i s -


I have gone to nVidia home page, but I didn't find anywhere the PhotoShop plug-in able to convert .jpg in .dds
Will you please be so kind to give me the web page where I can download it?
Thanks a lot!
Andrea
"Something is always better than nothing!"
HP Omen 15-DC1040nl- Intel® Core i7 9750H, 2.6/4.5 GHz- 1TB PCIe NVMe M.2 SSD+ 1TB SATA 6 SSD- 32GB SDRAM DDR4 2666 MHz- Nvidia GeForce GTX 1660 Ti 6 GB-WIN 11 PRO

Ortolan
Posts: 120
Joined: 31.03.2002
With us: 22 years 7 months
Location: Melbourne, Australia

Post #8by Ortolan » 29.08.2002, 01:23


Miserableman
Posts: 65
Joined: 03.04.2002
With us: 22 years 7 months
Location: Brighton, England
Contact:

Post #9by Miserableman » 29.08.2002, 11:38

JPGs are slow because they have to be decompressed by the processor before they can be displayed. DDS files also have to be decompressed, but they are decompressed by your graphics hardware, which is a lot quicker and supports some new features.

(at least I think that's right)

Don't use the photoshop plugin (unless you can get it to behave). Photoshop has some bugs involving transparancies which can royally screw your work up. Instead download the standalone tool-suite here. Use the program nvdxt.exe from the command line to convert TIFF files to DDS format. Warning: even though the documentation says it can, nvdxt cannot convert from any other file format than TIFF.

I had to resort to GIMP in Linux to actually make specular reflections in my textures though :O/

Rassilon
Posts: 1887
Joined: 29.01.2002
With us: 22 years 9 months
Location: Altair

Post #10by Rassilon » 29.08.2002, 15:06

Miserableman wrote:JPGs are slow because they have to be decompressed by the processor before they can be displayed. DDS files also have to be decompressed, but they are decompressed by your graphics hardware, which is a lot quicker and supports some new features.

(at least I think that's right)

Don't use the photoshop plugin (unless you can get it to behave). Photoshop has some bugs involving transparancies which can royally screw your work up. Instead download the standalone tool-suite here. Use the program nvdxt.exe from the command line to convert TIFF files to DDS format. Warning: even though the documentation says it can, nvdxt cannot convert from any other file format than TIFF.

I had to resort to GIMP in Linux to actually make specular reflections in my textures though :O/


Thank you thats what I was looking for....
I'm trying to teach the cavemen how to play scrabble, its uphill work. The only word they know is Uhh and they dont know how to spell it!

Boots

DXT Formats

Post #11by Boots » 29.08.2002, 22:40

Can any one explain (or point me to) what the differences in the texture formats are DXT1 DXT3 DXT5... and which is best for what type of texture, eg planet, clouds, specular, bump (the latter 2 apear to be greyscale (8bit).

Miserableman
Posts: 65
Joined: 03.04.2002
With us: 22 years 7 months
Location: Brighton, England
Contact:

Post #12by Miserableman » 29.08.2002, 23:07

A standard picture is made up of three channels - Red, Green and Blue, which makes up the full colour image. Additionally, an image may have one (or sometimes even more than one) alpha channels - a fourth channel that can be used to map the transparancy (think dark = transparent, light = opaque) or specular highlights or somesuch.

dxt1 compression is only for RGB images - no alpha channel

dxt1a compression does have an alpha channel, but it is only one bit, which means there can only be two "colours". A texture such as this might be used to map the reflectiveness of the Earths surface - water reflects, land doesn't.

dxt3 compression supports a full 32bit alpha channel

dxt5 - same as dxt3, there is a difference and I think I once knew what it was, but I've forgotten now :O( I always used dxt3 for my Earth textures, so I wouldn't worry about dxt5.


dxt1 is 8:1 compression, and dxt3/dxt5 4:1 compression. I don't recommend using the photoshop plugin, as photoshop (and seemingly every other Windows program) can't handle transparencies - I had to create my alpha channels in GIMP for Linux (a superb program), then switch back to Windows to sow the dds file together :O/


Return to “Development”