[ogg-dev] OggYUV

Arc arc at Xiph.org
Tue Nov 8 17:12:03 PST 2005


On Wed, Nov 09, 2005 at 07:38:09AM +0800, illiminable wrote:
> 
> Well i guess it depends what it's being used for. My understanding is the 
> usefullness of such a raw format is to firstly get raw data from some 
> hardware device, be it a video camera/webcam etc... which correct me if i'm 
> wrong, all output raw data in a fourcc format or one of the common rgb 
> formats.

Yes and no.  DV input is always DV format, which is in YUV 4:1:1.  Most webcams 
that I've seen export as some form of JPEG or MJPEG format, being based on a 
digital camera chipset and compressing the frame for USB bandwidth reasons.  
Older webcams, such as the quickcam series, dumped (as I recall) every other 
line of green, and every fourth line of red and blue, so it'd go "green - red - 
green - blue".. probobally via a striped color filter and b&w CCD.

The oddball JPEG formats often include special headers, I can't imagine anyone 
creating a FourCC entry for each one since they're designed for a specific 
application, and even the MJPEG formats I've seen don't seem to follow any real 
standard completely.

What you've probobally seen is the camera /driver/ outputting something via some 
Windows-specific API, which would attribute a fourcc to whatever codec it 
outputs, but again, the fourcc identifier is for the codec only.

My work with various webcams has led me to saying a single OggJPEG format, sort 
of like our own intraframe MJPEG, where the stream header gives the framerate, 
frame size, etc and each packet contains a complete and legal JPEG file, will do 
the job since all of these formats can have their headers removed (which provide 
frame size, frame#, and sometimes audio data) and sent to libjpeg.

It'll be the job of the application, or prehaps an application-side plugin for 
that camera, to turn whatever raw data that's received from Video4Linux into 
OggJPEG packets (if JPEG-based) before sending to OggStream for processing.
 

-- 

The recognition of individual possibility,
 to allow each to be what she and he can be,
  rests inherently upon the availability of knowledge;
 The perpetuation of ignorance is the beginning of slavery.

from "Die Gedanken Sind Frei": Free Software and the Struggle for Free Thought
 by Eben Moglen, General council of the Free Software Foundation


More information about the ogg-dev mailing list