Jump to content
  • Advertisement
Sign in to follow this  
seamal

Textures

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

Im learning DirectX10 Ive run through a few ways of loading a texture, like a background image or a sprite sheet but they all seem very different, which is fairly irritating, all are using D3DX10CreateShaderResourceViewFromFile which i get some are using ID3D10ShaderResourceView* ID3DX10Sprite* but tbh im not really getting the process from all these mixed and over complicated ways, im having to plow through 20 odd files just to find the bit that loads the thing, does anyone know of a simple straight forward tutorial on how to load a image or texture with not hassle or fuss regards Seamal

Share this post


Link to post
Share on other sites
Advertisement
What do you find complicated about D3DX10CreateShaderResourceViewFromFile? And Tutorial 7 in the SDK should be quite a simple example.

Share this post


Link to post
Share on other sites
its not so much the D3DX10CreateShaderResourceViewFromFile, its more that in DX9 it was so sime to load a texture straight in, now its got all these effect files, and resourceviews that no one seems to explain properly.

and as far as tutorial 7 goes, i must admit i didnt see that one, but ontop of that its confused the issue with mapping onto an image plain, exactly what i was talking about when i said its mixed it up with extra stuff. I was looking for a straight forward load an image, without the whole rotating cubes and fancy effects

Share this post


Link to post
Share on other sites
Views are new to D3D10. In D3D9 you could create a texture and you then used it or its surface as a texture / render target. In D3D10 you can't set a texture to anything. You need to create a shader resource view to access it in a shader, and you need a render target view to render into it.

Regarding effect files, you don't have to use them (you can create shaders in code), but they're convenient. I'd suggest that you look in the docs at Direct3D 9 \ Programming Guide \ Effects. Try to use them in D3D9 first, since you're familiar with it, then you'd be able to adapt to their use in 10 more easily (they are a little different, but not much).

Share this post


Link to post
Share on other sites
thnx for the update, since they rebuilt the whole thing from the ground up im not sure whether they have made it easier lol, seems to me that they have made it 20 times more complicated

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!