Results 1 to 3 of 3

Thread: Bitmap image in 2D array

  1. #1
    Addicted Member
    Join Date
    Mar 10
    Posts
    231

    Bitmap image in 2D array

    Hello, guys I am trying to turn a bitmap image into 2D array .
    This is my bitmap image:

    I want to represent each white pixel inside the array with 1 and each black pixel with 0,but I need only pure white and pure black
    And then redraw it , any ideas ?

  2. #2
    Addicted Member
    Join Date
    Mar 10
    Posts
    231

    Re: Bitmap image in 2D array

    Anyone ?

  3. #3
    Hyperactive Member
    Join Date
    Apr 11
    Posts
    268

    Re: Bitmap image in 2D array

    Quote Originally Posted by mitko29 View Post
    Anyone ?
    do you only need a bool indicator? like
    pos1 isblack = false //means its white
    pos2 isblack = true //means its black
    ?
    if thats what you need then i think the easiest solution is to create a List<List<bool>> imagearraycheck
    so you will have an example like this:

    imagearraycheck[0][3] = true;

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •