Coder Social home page Coder Social logo

antipixel's Introduction

antiPixel Build Status Actions Status

๐Ÿ‘พ Convert BMPs and text files to proper x8086 assembly arrays.

About

Converts pictures and text files into MASM code arrays. Basic image reading and manipulation in C++, in Visual Studio 2019. Author: Saad Bazaz.

Use cactus_example.txt, 16color-palette or cactus_example.bmp as examples

How to make pixel games in MASM?

Follow this guy's awesome tutorial (https://www.youtube.com/watch?v=dyANHsj2UOw&list=PLvpbDCl_H7mfgmEJPl1bTHlH5g-f0kWDM)!

Instructions

HOW TO USE METHOD 1:

  1. Create a pixel drawing in mspaint on 25x25 canvas
  2. Save As => BMP Picture => (24-bit Bitmap)
  3. Go to https://www.text-image.com/convert/ascii.html, convert the BMP to text
  4. Save the text in a txt file, place it in the program's solution folder
  5. Compile the program and feed it the text file

HOW TO USE METHOD 2 (my current method):

  1. Create a pixel drawing in mspaint on 25x25 canvas
  2. Save As => BMP Picture => (16 color Bitmap) !!!!! IMPORTANT !!!!!
  3. Now, Save As => BMP Picture => (24-bit Bitmap) !!!!! These steps were necessary to convert all extra colors into 16 color !!!!!
  4. NOW you can place the image in the program's solution folder
  5. Compile the program and feed it the bmp file

HOW TO USE METHOD 3:

  1. Create a pixel drawing in mspaint on 25x25 canvas
  2. Save As => BMP Picture => (24-bit Bitmap)
  3. Place the image in the program's solution folder
  4. Compile the program and feed it the bmp file

You can change the color number assignments according to your desire. Just head over to Color.h and change the preprocessor definitions. ๐Ÿ‘‡

Colors

Troubleshooting

  • if you can't find the User_Results folder, make it yourself or download the latest build a) STRUCTURE User_Results =>

  • BMPColorASM
    
  • BMPMonoASM
    
  • TextToASM
    
  • Sometimes the arrays may be terminated by an extra comma so remove that before running the arrays.

  • avoid using pictures bigger than 500x500 pixels. It won't crash in any situation, but it would be slow to render and you'd probably get worried.

  • The program has not been tested with images generated from different programs, like GIMP or Photoshop. In those cases, you would have to look up the HEADER SIZE and change it in the Advanced Configurations

Support

Make pull requests, create Issues, and do everything you want to get information out of me. You can personally email me at [email protected] I'd love to entertain any questions and suggestions!

antipixel's People

Contributors

saadbazaz avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.