Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

RandomAxess

Creating a .raw file

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

hey all, i wanted to create a .raw file, one that can be opened in Photoshop and observed. It has to be black and white...basically i''m looking into inputing a 2x2 array into the file, where each location is either black or white dot. Anyone know how to do this?

Share this post


Link to post
Share on other sites
Advertisement
Just write array to binary file. Write 0 where you want black color and 255 (0xFF) where you want white color. And write just pure data. No LF/CR characters. Then if size of file is x^2 PhotoShop sould figure out the size itself.

You should never let your fears become the boundaries of your dreams.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

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

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!