I need to use Matlab reshape() to achieve the following:
Say I have an image (M lines x N cols x 3). So essentially an M by N image with 3 channels for each pixel as red, green, blue.
I would like to reshape this image to become.
3 x total number of pixels
where, column 1 is RGB for image(1,1), column 2 is RGB for image(2,1), column 3 is RGB for image(3,1), . . . is RGB for image(m,1), is RGB for image(1,2) and so on ...