> Starting to dig a little bit deeper than the passive use of mjpegtools, I'd
> like to know what kind of  image is a YUV image once piped ?
> Does it fit into scalar, color or vector type of images (or none of them).

The "yuv4mpeg" format is a binary stream that starts with a text formated 
header describing the content (image size, aspect ratio, frame rate and 
interlacing information).

The header is followed by frames, which all begin by "FRAME\n" followed by the 
frame data.

The frame data are raw pixels in YUV planar format. Each pixel is described by 
3 independant values: Y (luminance), U (blue chrominance) and V (red 
chrominance). Those values are split in 3 independant planes (you can think 
of a plane as an image carrying only part of the pixel - one plane for Y, one 
plane for U and one plane for V). The U and V planes are downsized by a 
factor 2 in each direction, and the 3 planes are output one after the other 
in the byte stream. For a 320x240 image, you get

Y(0,0) Y(0,1) ... Y(0,319) Y(1,0) ... Y(239,319) U(0,0) U(0,2) ... U(0,318) 
U(2,0) ... U(238,318) V(0,0) V(0,2) ... V(238,318)

This is called YUV4:2:0 planar format. For more information about the 
different YUV formats, have a look at http://www.fourcc.org.

Laurent Pinchart



-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users

Reply via email to