Advertisement Jump to content
Sign in to follow this  

Display a texture from memory in Sharp/Slim DX

This topic is 1112 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
Sign in to follow this  

  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. 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!