Webcam raw format

3

I have a crappy usb webcam (Logitech C250) and want to discover what raw format the device sends.

I'm using VLC to stream the video across my network, but there are lots of formats to choose from, and I want to choose the one that requires no (or easiest) transcoding.

So, how can I find out what the device actually pumps out natively?

Edit: Also, the device supports audio apparently, but I can never find the path to use in VLC, it might only be supported by windows drivers - any ideas?

mercutio

Posted 2010-09-09T17:29:06.873

Reputation: 135

Answers

2

Seeing this thread is tagged linux, I'm guessing heavyd's answer does not suit you, albeit being complete.

I'm not a VLC user myself but I'm guessing once VLC is displaying the video, there should be a menu with a "Video properties" item or something similar.

On the other hand, you could try to use the camera using mplayer and see what it outputs. Open up a console, and type the following :

mplayer tv:///

By now, a new window should have opened along with plenty of text being printed inside the console. It should start by saying which version it is, followed a few lines after by "Playing tv:///"

The line you're looking for is

Current format: [format here]

Or even

Selected video codec: [blah] vfm: raw (RAW *interesting_info_here*)

MPlayer can be compiled with various options and the output will differ, which is the reason why I explicited two possible locations where you can find the information you're seeking.

After a bit of googling, this link suggests your camera can output YUYV or MJPEG.

tamtakos

Posted 2010-09-09T17:29:06.873

Reputation: 156

Thanks, that's absolutely perfect. It is RAW YUY2, so now I can play with getting the optimum streaming capacity out of this slow machine :) – mercutio – 2010-09-13T11:03:45.307

0

VLC uses the Microsoft DirectShow framework to get video from Webcams and other video capture devices. In the Windows Platform SDK there is a nice tool to help debug DirectShow "filters" called Graph Edit. You can download the whole SDK to get the MS tool or there is an open source version called GraphStudio.

Get GraphEdit or GraphStudio and once you have the application open, insert a filter(from the Graph menu). Select the "Video Capture Sources" category and insert your camera onto the graph. You should should now be able to right click on the exposed pins of the filter and select "Properties" to view the formats the camera supports. Many cameras will support multiple formats but common ones include YUY2, YV12, MJPEG and many more.

heavyd

Posted 2010-09-09T17:29:06.873

Reputation: 54 755