LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

What is the format of the flattened pixmap?

There appears to be no definition of the flattened pixmap in the LabVIEW literature. I need this information to resize an image. I am starting with a jpeg. I read the jpeg and flatten the data. I then put the flattened data into a picture. If the original picture is too big to fit on my control panel, I need to resize it. I don't want to spend 700 dollars or more to buy a generic image processing utility to do this. I want to resize it using the standard LabVIEW FullDevSys functions. In my initial approach, I want to operate on flattened image data. In order to do this, I need to know the details of the flattened image data. It comes out of the "Read JPEG File.vi" function as a 1D array of U8s. Is this simply R,G,B,R
,G,B,R,G,B,..., or is there more to it? Is the colormap affected by decimation of the image data?
jc
Mac 10.4
LV7.1
CLD
0 Kudos
Message 1 of 6
(3,893 Views)
I have no any printed document about this format also, but you can just give a look inside standart "Unflatten pixmap" function diagram.
Also, it seems to me that there is a ImageProcessing project on OpenG which deals with image resampling/resizing.
0 Kudos
Message 2 of 6
(3,893 Views)
> There appears to be no definition of the flattened pixmap in the
> LabVIEW literature. I need this information to resize an image. I am
> starting with a jpeg. I read the jpeg and flatten the data. I then
> put the flattened data into a picture. If the original picture is too
> big to fit on my control panel, I need to resize it. I don't want to
> spend 700 dollars or more to buy a generic image processing utility to
> do this. I want to resize it using the standard LabVIEW FullDevSys
> functions. In my initial approach, I want to operate on flattened
> image data. In order to do this, I need to know the details of the
> flattened image data. It comes out of the "Read JPEG File.vi"
> function as a 1D array of U8s. Is this simply R,G,B,R,G,B,R,G,B,.
..,
> or is there more to it? Is the colormap affected by decimation of the
> image data?

The pixmap data is probably some header followed by pixel information.
I believe there is a VI that takes a 2D and builds a flattened pixmap,
and it will likely give you the size of the header. Other tricky points
-- the data is likely R, G, B, R, G, B, ... except that at the end of
the row there is often some padding, so that the next row starts on a
nice boundary. This means that the header usually has a field called
row bytes, and it doesn't necessarily equal pixel on a row times size of
pixel. The encoding will also be different for different pixmap depths,
with true color being one of the simpler ones to deal with.

Greg McKaskle
0 Kudos
Message 3 of 6
(3,893 Views)
Have you seen G Toolbox at:

http://gtoolbox.yeah.net



jcrooke wrote:
> There appears to be no definition of the flattened pixmap in the
> LabVIEW literature. I need this information to resize an image. I am
> starting with a jpeg. I read the jpeg and flatten the data. I then
> put the flattened data into a picture. If the original picture is too
> big to fit on my control panel, I need to resize it. I don't want to
> spend 700 dollars or more to buy a generic image processing utility to
> do this. I want to resize it using the standard LabVIEW FullDevSys
> functions. In my initial approach, I want to operate on flattened
> image data. In order to do this, I need to know the details of the
> flattened image data. It comes out of the "Read JPEG File.vi"
> functi
on as a 1D array of U8s. Is this simply R,G,B,R,G,B,R,G,B,...,
> or is there more to it? Is the colormap affected by decimation of the
> image data?
0 Kudos
Message 4 of 6
(3,893 Views)
Thanks for the feedback, the toolbox looks great, but I didn't see a function in the gtoolbox that looked appropriate. Perhaps you could be more specific.
jc
Mac 10.4
LV7.1
CLD
0 Kudos
Message 5 of 6
(3,893 Views)
jcrooke wrote:
> Thanks for the feedback, the toolbox looks great, but I didn't see a
> function in the gtoolbox that looked appropriate. Perhaps you could
> be more specific.


On this page:
http://www.geocities.com/gzou999/resize.htm
0 Kudos
Message 6 of 6
(3,893 Views)