LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why the row and column reverses?

I have an image 736 pixels (row) and 554 pixels (column). In the IMAQ ColorImageToArray.VI, the VI has a 2D array with Y axis as the first dimension (Dim) of the array and X-axis as the second Dim. Why do we break away from the tradition of the first dimension of a 2D-array is the row and the second dimension is column? When I go to use the Index Array function, the index 0 is row and index 1 is column, as the little hint or tip trying to give me clue.
I am confused.
Download All
0 Kudos
Message 1 of 4
(3,003 Views)
I didn't write LabVIEW or IMAQ, so I can't answer your question.

However; if you want to be more comfortable with this, just transpose the array with the function of that name in the array palette.
0 Kudos
Message 2 of 4
(3,003 Views)
Don't know the answer but I can give an idea that just might make make sense.

It has to do with keeping the various indexes of multi-dimensional arrays straigt in my head.

Think of a 7-d array as a library. To find a letter on a page of a book you would first go the correct Floor.
Then the correct isle of shelves.

Then the correct shelf.

Then the book.

Then the page.

Then the line (i.e. row).

then the character on the line (column).

Using this model higher "d" arrays are just collections of the lower arrays.

The smallest "d" array is comprised of only columns.

This model is a lot easier for me to handle, than trying to visualize a 3-d array inside 4-space.

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 3 of 4
(3,003 Views)
Hi trout00;

Well, actually, IMAQ is doing its job and it didn't depart from the traditional way of representing the size of a matrix: (rows, columns)

The height of an image is the number of rows and the width of the image is the number of columns.

Your image is 554 pixels in height, which is the number of rows and 736 pixels in width, which is the number of columns. That's why the resulting array indicating the size of your image says [554, 736].

Regards;
Enrique
www.vartortech.com
0 Kudos
Message 4 of 4
(3,003 Views)