Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#2.0 C#3.0 C# C#4.0
Hello codeproject,
 
I want a component to display the image in matrix, I have not found,
how transforms (listbox, listview, textbox and dataview) to a matrix to desplay the image values...
 
Thank you friends
Posted 16-Dec-11 0:03am
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You need to keep a DataList control with repeat column="n" and rows="n" & bind only (n*n)images dataItem , where dim of matrix is n.
 
I hope its help you.
  Permalink  
Comments
pablo ramos1 at 16-Dec-11 9:01am
   
give me an exemple plz i'm begainner
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Have a look at similar question with solution
How to convert image to pixel matrix in C#?[^]
Convert Bmp image to matrix[^]
 
from Reference link :-
public Color[][] GetBitMapColorMatrix(string bitmapFilePath)
      {
          bitmapFilePath = @"YourImage";
            Bitmap b1 = new Bitmap(bitmapFilePath);
           int hight = b1.Height;
           int width = b1.Width;
            Color[][] colorMatrix = new Color[width][];
 
            for (int i = 0; i < width; i++)
 
            {
               colorMatrix[i] = new Color[hight];
 
                for (int j = 0; j < hight; j++)
 
                {
                    colorMatrix[i][j] = new Color();
                   colorMatrix[i][j] = b1.GetPixel(i, j);
 
                }
            }
            return colorMatrix;
 
        }
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 8,284
1 Sergey Alexandrovich Kryukov 7,407
2 DamithSL 5,614
3 Maciej Los 4,989
4 Manas Bhardwaj 4,986


Advertise | Privacy | Mobile
Web01 | 2.8.1411023.1 | Last Updated 16 Dec 2011
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100