USB Video Device Class Solutions and Examples

Author

Reads 11K

Top view composition of mobile phone placed near USB flash drive and mini gimbal camera on wooden table with green foliage
Credit: pexels.com, Top view composition of mobile phone placed near USB flash drive and mini gimbal camera on wooden table with green foliage

The USB Video Device Class is a powerful solution for streaming video over USB. It allows for high-quality video transmission with low latency.

There are several examples of USB Video Device Class solutions, including the Logitech C920 webcam, which is a popular choice for streaming video. This webcam is capable of streaming at 1080p resolution.

The USB Video Device Class provides a standardized way for devices to communicate with each other, making it easier to implement video streaming solutions. This standardization has led to the development of a wide range of devices that can work together seamlessly.

The Logitech C920 webcam is just one example of a device that can take advantage of the USB Video Device Class. Other devices, such as the Elgato HD60, can also use this class to stream high-quality video.

If this caught your attention, see: Does Dropbox Reduce Video Quality

What is UVC?

UVC cameras are USB-powered devices that incorporate standard video streaming functionality and connect seamlessly with host machines. They use standard and class-specific descriptors to describe their capability.

Credit: youtube.com, MISUMI UVC USB 2.0 Video Dongle Capture Device UCD-210M

The latest version of the USB video class specification is UVC 1.5, which fully describes the video function to the host. This ensures that UVC devices can work together seamlessly with host machines.

UVC is a standard protocol for video transmission over USB, meaning it defines how video data should be formatted and transferred. This standardization allows different devices and software to work together without issues.

UVC-compliant devices can be easily connected to a host system and used immediately without the need for installing special drivers. The host system's operating system recognizes the UVC device and uses generic drivers to enable its functionality.

UVC devices are compatible with a wide range of operating systems, including Windows, macOS, Linux, and Android. This broad compatibility ensures that users can use their video devices across different platforms without issues.

Here are the key factors that contribute to the widespread usage of UVC:

  1. Standardization: UVC defines how video data should be formatted and transferred.
  2. Plug and play: UVC devices can be easily connected and used without special drivers.
  3. Compatibility: UVC-compliant devices work with various operating systems.
  4. Applications: UVC streaming is used in webcams, digital camcorders, and other video capture and streaming applications.
  5. Quality and performance: UVC supports various video resolutions and frame rates.
  6. Ease of use: UVC devices are recognized and configured by the system automatically.

Terminology and Grouping

Terminology is key when working with USB video devices. The UVC (USB Video Class) driver is a crucial component that supports both color and non-color cameras.

Credit: youtube.com, USB video device class

A color camera outputs color streams, such as RGB or YUV, while a non-color sensor camera outputs non-color streams like IR or Depth. The UVC driver supports both types of cameras, and it's recommended to specify a value in the camera firmware to determine how the driver registers the camera.

Here's a quick rundown of some important terminology:

Grouping cameras can make applications like Windows Hello work more efficiently. By specifying a UVC-FSSensorGroupID in the camera's BOS descriptor, related cameras can be exposed to the OS as a group. This can include an IR camera and a Color camera on the same physical device.

The UVC driver will use this information to expose the camera functions as related, making it easier for applications to use them in their scenarios. If updating the device firmware is not possible, a custom INF file can be used to specify a sensor group ID and name.

Additional reading: Video Coding Experts Group

Device Support and Examples

Credit: youtube.com, USB 3 0 and Universal Video Class Universal Video Class (UVC)

The USB video device class is supported on a variety of devices, including webcams, digital camcorders, and DVD players.

Many USB video devices are plug-and-play, meaning they can be easily connected to a computer and start working right away.

Some examples of devices that use the USB video class include the Logitech C920 webcam and the Sony HDR-XR260 camcorder.

These devices can be used for a range of applications, from video conferencing to recording home movies.

Example Device

Let's take a look at an example device that showcases the capabilities of USB cameras. This example composite device has two camera functions: a UVC color camera and a UVC IR camera.

The device is registered under two categories: KSCATEGORY_VIDEO_CAMERA for the color camera and KSCATEGORY_SENSOR_CAMERA for the IR camera. This allows the device to be recognized and used by the operating system and applications.

Here are the key features of the example composite device:

Credit: youtube.com, What is a Device Driver | How Does Device Driver Works Explained | Computer Drivers

Device Capabilities:

  • Color camera function under KSCATEGORY_VIDEO_CAMERA
  • IR camera function under KSCATEGORY_SENSOR_CAMERA
  • Color camera function enables still image capture
  • Color and IR camera functions are associated as a group

The device's BOS descriptor includes a platform-specific device capability that specifies the MS OS 2.0 descriptor platform capability GUID, a vendor control code (bMS_VendorCode), and the applicable OS version (Windows 10 and later).

The MS OS 2.0 descriptor is retrieved by sending a vendor-specific control request to the device, which returns a descriptor set blob containing the MS OS 2.0 descriptor values.

Some of the key values in the MS OS 2.0 descriptor include:

  • Set Header
  • Configuration Subset Header
  • Color Camera Function Subset Header
  • Registry Value Feature Descriptor for sensor group ID
  • Registry Value Feature Descriptor for sensor group name
  • Registry Value Feature Descriptor for enabling still image capture
  • IR Camera Function Subset Header
  • Registry Value Feature Descriptor for sensor group ID
  • Registry Value Feature Descriptor for sensor group name
  • Registry Value Feature Descriptor for registering the camera as a sensor camera

RidgeRun's Gadget Library Solution

You can customize your UVC driver by supplying an Extension Unit plug-in, providing a private control channel between device and vendor-supplied application.

The Extension Unit plug-in allows for private control, enabling a more tailored experience for users.

To make the OS take advantage of the device's Method 2/3 still image capture support, through UVC driver, the device firmware could specify a value in the BOS descriptor.

If you can't update the device firmware, you can use a custom INF to specify that your camera supports Method 2 or Method 3 still capture method.

Discover more: Private Video Calls

Vibrant close-up of green SDI cables connected to yellow device with visible USB port.
Credit: pexels.com, Vibrant close-up of green SDI cables connected to yellow device with visible USB port.

Specify the value to enable Method 2/3 still image capture using the BOS descriptor or a custom INF file.

The custom INF file must include the AddReg entry: EnableDependentStillPinCapture: REG_DWORD: 0x0 (Disabled) to 0x1 (Enabled).

Configuring UVC devices through custom INF is still supported and takes precedence over BOS descriptor based mechanism.

You don't need to add the prefix "UVC-" when specifying device properties through INF, it's only needed for device properties that are specified through BOS descriptor and are per interface instance specific.

UVC Features and Formats

The USB video device class (UVC) supports a wide range of streaming video data profiles, making it a versatile and useful technology.

One of the key benefits of UVC is its ability to handle multiple video formats, including MJPEG, MPEG-1 SS, and H.264, to name a few.

Here are some of the specific formats supported by UVC 1.5:

  • MJPEG
  • MPEG-1 SS
  • MPEG-2 PS
  • MPEG-2 TS
  • MPEG-4 SL
  • H.264
  • VP8
  • SMPTE VC1
  • uncompressed YUV formats: YUY2, NV12
  • DV formats: SD-DV, SDL-DV, and HD-DV

Method 2 or 3 Support

Method 2 or Method 3 still capture support is available for UVC devices.

Automatic dry food feeders with webcam domestic cats
Credit: pexels.com, Automatic dry food feeders with webcam domestic cats

The UVC specification provides a mechanism to specify if the video streaming interface supports Method 1/2/3 type still image capture.

To enable Method 2/3 still image capture, the device firmware could specify a value in the BOS descriptor using the UVC-EnableDependentStillPinCapture DWORD.

You can also use a custom INF file to specify that your camera supports Method 2 or Method 3 still capture method.

The custom INF file must include the AddReg entry: EnableDependentStillPinCapture: REG_DWORD: 0x0 (Disabled) to 0x1 (Enabled).

Setting this entry to Enabled (0x1) allows the capture pipeline to leverage Method 2/3 for still image capture.

Configuring UVC devices through custom INF takes precedence over BOS descriptor based mechanism.

You don't need to add the prefix "UVC-" when specifying device properties through INF.

Consider reading: Usb 2 O vs 3.0

Supported Formats

The Supported Formats of UVC 1.5 are quite impressive. UVC 1.5 supports a wide range of streaming video data profiles.

MJPEG is one of the formats supported by UVC 1.5. This format is widely used for its simplicity and ease of implementation.

Credit: youtube.com, What is a Codec? | Intro to Codecs, Formats & Bitrate

MPEG-1 SS, MPEG-2 PS, and MPEG-2 TS are also supported formats. These formats are commonly used for broadcasting and streaming high-quality video.

MPEG-4 SL, H.264, VP8, and SMPTE VC1 are additional formats supported by UVC 1.5. These formats offer advanced compression and encoding capabilities.

Uncompressed YUV formats, specifically YUY2 and NV12, are also supported. These formats are ideal for applications that require high-quality, uncompressed video.

DV formats like SD-DV, SDL-DV, and HD-DV are also supported by UVC 1.5. These formats are commonly used for digital video recording and playback.

Here is a list of the supported formats:

  • MJPEG
  • MPEG-1 SS
  • MPEG-2 PS
  • MPEG-2 TS
  • MPEG-4 SL
  • H.264
  • VP8
  • SMPTE VC1
  • YUY2
  • NV12
  • SD-DV
  • SDL-DV
  • HD-DV

UVC Use Cases and Solutions

UVC is a standard protocol for video transmission over USB, allowing different devices and software to work together seamlessly.

The widespread usage of UVC in video capture and streaming can be attributed to its standardization, plug and play functionality, compatibility with various operating systems, and ease of use.

UVC-compliant devices are commonly used in webcams, digital camcorders, video conferencing systems, medical imaging devices, and frame grabbers.

Expand your knowledge: Wireless Security Systems Cameras

Credit: youtube.com, 1080P UVC USB grabber + WiFi router + nikon camera. HD video to USB UVC.

Users can connect a UVC-compatible camera to a USB port, and the system will automatically recognize and configure the device, making it ready for immediate use with video conferencing software, recording applications, or streaming platforms.

UVC supports various video resolutions and frame rates, from standard definition (SD) to full high definition (FHD) and even higher resolutions like 4K, depending on the device's capabilities and the USB version used.

Here are some of the key applications that use UVC streaming:

  • Webcams
  • Digital camcorders
  • Video conferencing systems
  • Medical imaging devices
  • Frame grabbers

The primary advantage of UVC streaming is its ease of use, making it a popular choice for applications where video capture and streaming are required.

Supported Operating Systems

The USB video device class is supported on a variety of operating systems, which is great news for users looking to connect their devices.

Windows users are in luck, as the class is supported on Windows XP SP2 and later, with UVC 1.0 support. For Windows 7 and later, UVC 1.1 is supported, while Windows 8 and later support UVC 1.5.

Credit: youtube.com, Are USB Adapters Compatible With All Operating Systems? - The Hardware Hub

Linux users can also enjoy support, with kernel versions 2.6.26 and later supporting UVC 1.1. If you're using a more modern Linux system, you'll want to know that kernel versions 4.5 and later support UVC 1.5, although with some limitations.

Mac OS X Tiger users won't be left out, as the class is supported from version 10.4.3. If you're using FreeBSD, you're in luck, as support starts from version 9.0.

Here's a quick rundown of the supported operating systems:

Desiree Feest

Senior Assigning Editor

Desiree Feest is an accomplished Assigning Editor with a passion for uncovering the latest trends and innovations in technology. With a keen eye for detail and a knack for identifying emerging stories, Desiree has successfully curated content across various article categories. Her expertise spans the realm of Azure, where she has covered topics such as Azure Data Studio and Azure Tools and Software.

Love What You Read? Stay Updated!

Join our community for insights, tips, and more.