Jump to content
  • Advertisement
Sign in to follow this  
myvraccount

Display a texture from memory in Sharp/Slim DX

This topic is 992 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 using SharpDX (very similar to SlimDX, and probably the same code will work).

 

I'm trying to display a texture that's in memory as either a byte array or a Bitmap object, rather than loading it from a file.  Ultimately I guess it needs to be made into a Texture2D object so I can input it into the shaders.

 

I tried using some function called Resource.FromMemory, but I got unknown exceptions/errors.

 

I thought maybe the load information or description or something was set up wrong, so I loaded a texture from a file and compared the data, then adjusted my input to the FromMemory function to match, but that didn't fix it.

 

I'm really stumped, but I really need this to work!  Please if you have any ideas, post them.  Thank you.

 

(And no I don't have source code with me, sorry).

Share this post


Link to post
Share on other sites
Advertisement
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!