Jump to content
  • Advertisement
Sign in to follow this  
Juergen

Loading raw texture

This topic is 4136 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, I have a volume texture in the raw format. I want to load and edit it, but have no idea how? What is to do, that I get a normal texture (with header) out of it. _______________ Thanks, Jürgen.

Share this post


Link to post
Share on other sites
Advertisement
Wrong forum, you probably want Game Programming (Ask a mod to move the topic rather than re-posting though).

What format is the raw texture in? What do you mean by a "normal texture"? And what do you mean by "with header"? Textures don't have headers, they're just chunks of raw data.

And what graphics API are you using? Direct3D? OpenGL? Something else?

Share this post


Link to post
Share on other sites
Oh, I'm sorry. I don't know, which format it is. I have only the raw file, with the informations, that it is 256 x 256 x 32 pixel and is in rgb colormode.

I mean with "normal texture" and "with header", that I want, to convert the raw file into an usually image format. I need this, because I want to convert these image in a next step into the dds format from microsoft. For this, I use the DevIL, but DevIL can't load raw files directly.

Thanks, Jürgen.

Share this post


Link to post
Share on other sites
If the file size is 256x256x3 bytes, then there is no header in the image file. In this case, just open it and copy the pixel data into your application.

If the file size is larger than 256x256x3 then, skip the difference and load data. (The header is located at the front of the file in general.)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!