skillfed

pygrabber

Module for grabbing live video images using DirectShow

pygrabber v0.2 77.0K downloads/30d#14,566 on PyPI70
Permissive license MIT DORMANT released

What it is and what it does

pygrabber is a Python wrapper around DirectShow that lets you work with video cameras on Windows. It provides a FilterGraph class that abstracts DirectShow's filter-based architecture, allowing you to enumerate connected cameras, capture individual frames or video streams, and apply camera settings—all from Python code.

The package is designed for straightforward camera integration tasks: listing available devices, grabbing frames on demand or in a loop, and saving output to files. It depends on comtypes (for COM interop with DirectShow) and numpy (likely for frame data handling). Because it wraps a Windows-specific multimedia API, it is not cross-platform.

Use it for:

  • List all USB or built-in cameras connected to a Windows PC and select one for capture.
  • Capture still frames from a camera at regular intervals and save them as image files.
  • Stream live video from a camera to a window on screen using DirectShow's rendering pipeline.
  • Build a simple GUI application that lets users preview, capture, or record from a camera.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Capture photos and video from Windows cameras using DirectShow, enumerate connected devices, and configure camera settings from Python.

Yes, if you are on Windows and need straightforward camera access without heavy dependencies. The low install friction and permissive license are advantages. However, the dormant maintenance status (last update 2023-10-20) means no active support; install only if you can tolerate unfixed bugs or are confident the package meets your needs as-is.

Install

pygrabber on PyPI

pip

pip install pygrabber

uv

uv add pygrabber

poetry

poetry add pygrabber

Installing pygrabber

Before you install

Low install friction with a pure-Python wheel. Maintenance is dormant—last release was 2023-10-20 and last commit 2024-08-30—so expect no active bug fixes or feature updates.

License in practice

MIT license is permissive; you can use, modify, and distribute this package with minimal restrictions, provided you retain the license notice.

Quickstart

pip install pygrabber

from pygrabber.dshow_graph import FilterGraph

graph = FilterGraph()
print(graph.get_input_devices())

Windows-only; requires DirectShow support and comtypes + numpy at runtime.

Verify before relying

  • Whether the package works reliably with modern Windows versions and camera drivers.
  • Python version compatibility (requires_python is unspecified in the fact sheet).
  • Whether dormant status means critical bugs are unfixed or if the package is simply stable.

Package facts

License MIT (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies 2 — comtypes, numpy
Maintenance dormant — 1,029 days since the last release
Last repo commit
First released
Downloads 76,984/month — #14,566 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: pygrabber-0.2-py3-none-any.whl

Tags

windows camera capture pythondirectshow video grabbingenumerate usb cameraspython webcam frame grabbingdirectshow filter graphlive video streaming python windowscamera device listing
windows-onlydirectshowcamera-capture

More Graphics packages