Jump to content

View more

Image of the Day

Inventory ! Va falloir trouver une autre couleur pour le cadre D: #AzTroScreenshot #screenshotsaturday https://t.co/PvxhGL7cOH
IOTD | Top Screenshots

The latest, straight to your Inbox.

Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.


Sign up now

Loading textures to the GPU

4: Adsense

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.


  • You cannot reply to this topic
4 replies to this topic

#1 DarkRonin   Members   

1173
Like
1Likes
Like

Posted 07 July 2014 - 11:52 PM

Hi guys!

 

Not really a problem, just a quick question. smile.png

 

When you load a texture (for example a JPG) on to the d3dDevice via CreateTextureFromFile() or similar, is the texture decompressed by the API and then sent to the video card, or is the image decompressed on the video card itself?

 

Thanks in advance biggrin.png


Win32 Developer
One Of Them - Martial arts game that is mid development.

#2 Promit   Senior Moderators   

13098
Like
4Likes
Like

Posted 07 July 2014 - 11:58 PM

The texture is completely decompressed by the API, unless the file is a special compression format that can be decompressed by the GPU. Those formats are the various DXT or BC formats that are stored inside DDS files. Common compression formats (PNG, JPEG, TGA, etc) are API-decompressed.


SlimDX | Shark Eaters for iOS | Ventspace Blog | Twitter | Proud supporter of diversity and inclusiveness in game development

#3 DarkRonin   Members   

1173
Like
0Likes
Like

Posted 08 July 2014 - 12:03 AM

Ah ok, got ya :)

 

Are any of the GPU formats reasonable quality or even lossless?


Win32 Developer
One Of Them - Martial arts game that is mid development.

#4 phil_t   Members   

8002
Like
4Likes
Like

Posted 08 July 2014 - 12:36 AM

They're all lossy. They are commonly used and of reasonable quality depending on your scenario. They offer not just a win in terms of memory usage, but also potentially performance (it's less data for the GPU to read into the texture cache).

 

http://en.wikipedia.org/wiki/S3_Texture_Compression

http://www.reedbeta.com/blog/2012/02/12/understanding-bcn-texture-compression-formats/


Edited by phil_t, 08 July 2014 - 12:38 AM.


#5 DarkRonin   Members   

1173
Like
0Likes
Like

Posted 08 July 2014 - 12:40 AM

Awesome. Thanks for the info guys smile.png


Win32 Developer
One Of Them - Martial arts game that is mid development.




Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.