hi, i'm now doing a program to calculate the pixels for the comparison between two images. both image should have the same size, 16 x 16 pixels, and in a matrices representation. any suggestion that could help me? does 2-dimensional array is reasonable? because if i do the 2-dimensional array, i need to declare 256 variables, and if suddenly i need to change the size into 24 x 24 pixels, it's gonna be more declaration.... could anyone can give a suggestion? thank you
what is the best practise to read and calculate matrices representation 16 x 16 pixel
Collapse
X
-
Why? (Hint: a 16x16 array *is* 256 variables that you can directly address)because if i do the 2-dimensional array, i need to declare 256 variables
I guess that depends on how you are going to use it. An image could be represented by nothing more than as a long string of bytes: That's one dimension. So a List<byte> could be an image. Two List<byte> variables could be your two images. I guess an n by 2 array could be two images.does 2-dimensional array is reasonable?
Comment