Advertisement Jump to content
Sign in to follow this  
Uberapan3

OpenGL Loading a texture from RGBA in memory?

This topic is 4883 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

I'm trying to teach myself DirectX, coming from OpenGL. My model loader that I used for OpenGl simply loads texture data into an array of RGBA values. Using this with OpenGl was very simple. However, I cannot seem to do this in DirectX. All the D3DX functions (for example: D3DXCreateTextureFromFileInMemory) assume I have the data loaded in a specific format including the file headers, for example JPG. However, I just want to specify where the data is, its width, height and format, and then let DX do the mipmap generation and other such tasks. How can I best do this? Did I miss some simple function? Thanks in advance for any help.

Share this post


Link to post
Share on other sites
Advertisement
Huh, I don't know how I could have missed that. I used the search function for all it was worth before posting. Thanks for the link!

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!