This release includes 1 breaking change for platform teams planning a safe upgrade.
✓ No known CVEs patched in this version
Topics
+13 more
Affected surfaces
ReleasePort's take
Light signalThe vidgear release 0.3.5 deprecates the enablePiCamera boolean flag, requiring code changes to use Backend.PIGEAR enumeration.
Why it matters: Update any configuration or code that sets enablePiCamera before upgrading; failure will cause runtime errors after the migration deadline.
Summary
AI summaryDeprecated enablePiCamera boolean flag in favor of explicit Backend.PIGEAR enumeration.
Changes in this release
| Type | Severity | Summary | CVE |
|---|---|---|---|
| Breaking | Medium |
Deprecated enablePiCamera boolean flag; replaced with explicit api=Backend.PIGEAR enumeration syntax. Deprecated enablePiCamera boolean flag; replaced with explicit api=Backend.PIGEAR enumeration syntax. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Feature | Medium |
Introduced high-performance multi-threaded FFGear video decoding API with hardware acceleration and metadata extraction. Introduced high-performance multi-threaded FFGear video decoding API with hardware acceleration and metadata extraction. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Feature | Medium |
Added unified Backend Enum for explicit backend selection across VideoGear, WebGear, WebGear_RTC, NetGear_Async. Added unified Backend Enum for explicit backend selection across VideoGear, WebGear, WebGear_RTC, NetGear_Async. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Feature | Medium |
Refactored Stabilizer into plugin-style architecture with new StabilizerMode enum and factory function. Refactored Stabilizer into plugin-style architecture with new StabilizerMode enum and factory function. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Feature | Medium |
WriteGear now allows omitting video codec via None in output_params for auto-selection (e.g., GIF output). WriteGear now allows omitting video codec via None in output_params for auto-selection (e.g., GIF output). Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Feature | Medium |
Updated Asyncio CLI with proper store_true flags and new -a/--api backend selection flag. Updated Asyncio CLI with proper store_true flags and new -a/--api backend selection flag. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Feature | Medium |
Added official Poetry installation guide and ecosystem support for Poetry-managed environments. Added official Poetry installation guide and ecosystem support for Poetry-managed environments. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Feature | Medium |
Added py.typed marker for PEP 561 compliance, enabling external type checkers. Added py.typed marker for PEP 561 compliance, enabling external type checkers. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Performance | Medium |
Replaced flake8 and black with ruff for unified, high-speed linting and formatting across codebase. Replaced flake8 and black with ruff for unified, high-speed linting and formatting across codebase. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Bugfix | Medium |
Fixed severe memory leak in Stabilizer where self.__transforms grew unbounded, preventing OOM hazards. Fixed severe memory leak in Stabilizer where self.__transforms grew unbounded, preventing OOM hazards. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Bugfix | Medium |
Corrected FFGear metadata tuple handling when extract_metadata mode is enabled. Corrected FFGear metadata tuple handling when extract_metadata mode is enabled. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Bugfix | Medium |
Fixed validate_video to check file path existence before processing. Fixed validate_video to check file path existence before processing. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Bugfix | Medium |
Resolved missing demuxer header handling in get_supported_demuxers. Resolved missing demuxer header handling in get_supported_demuxers. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Bugfix | Medium |
Improved StopIteration handling in default video codec selection logic. Improved StopIteration handling in default video codec selection logic. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Bugfix | Medium |
Fixed IndexError in validate_audio bit-depth parsing for planar sample formats. Fixed IndexError in validate_audio bit-depth parsing for planar sample formats. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Bugfix | Medium |
Expanded get_supported_demuxers to handle comma-separated demuxer aliases correctly. Expanded get_supported_demuxers to handle comma-separated demuxer aliases correctly. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: low |
— |
| Refactor | Medium |
Migrated packaging infrastructure from setup.py/setup.cfg to modern pyproject.toml standards. Migrated packaging infrastructure from setup.py/setup.cfg to modern pyproject.toml standards. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Refactor | Medium |
Updated type hints to leverage Python 3.10+ structures including PEP 604 union types and generics. Updated type hints to leverage Python 3.10+ structures including PEP 604 union types and generics. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
| Refactor | Medium |
Extracted YT_backend into dedicated module for cleaner separation of concerns. Extracted YT_backend into dedicated module for cleaner separation of concerns. Source: granite4.1:8b-q6_K@2026-05-21 Confidence: high |
— |
Full changelog
What's Changed (Highlights)
📓 Release Notes can be found here ↗️
New Features ✨
- ✨ FFGear API:
- Introduced a brand-new high-performance, multi-threaded video decoding Gear built on top of DeFFcode's
FFdecoderAPI. - Supports real-time FFmpeg subprocess pipelines, low-overhead hardware-accelerated decoding (e.g., CUDA/NVDEC), flexible pixel format conversions, and asynchronous per-frame metadata extraction.
- Includes dedicated parameters:
source_demuxer,frame_format,custom_ffmpeg, andextract_metadata.
- Introduced a brand-new high-performance, multi-threaded video decoding Gear built on top of DeFFcode's
- ⚡️ Unified Backend Selection (
BackendEnum):- Introduced a unified
apiparameter accepting a newBackendenum (Backend.CAMGEAR,Backend.PIGEAR,Backend.FFGEAR) acrossVideoGear,WebGear,WebGear_RTC, andNetGear_Async. - Replaces the legacy
enablePiCameraboolean flag with a clean, explicit enumeration-based backend selection.
- Introduced a unified
- ⚡️ Plugin-Ready Stabilizer Architecture:
- Refactored the monolithic
Stabilizerclass into a plugin-stylestabilizer/sub-package with a shared_StabilizerBase, anASWStabilizerimplementation, and a factoryStabilizer()function. - Added a new
StabilizerModeenum for selecting stabilization backends viaVideoGear'sSTABILIZER_MODEoption, with clean provisions for upcoming real-time backends (e.g., Kalman tracking).
- Refactored the monolithic
- 🚩 WriteGear: Discard
-vcodecviaNone:- Setting
-vcodecor-c:vtoNoneinoutput_paramsnow cleanly omits the video codec parameter, letting FFmpeg auto-select the encoder (useful for GIF output and similar workflows).
- Setting
- 📦️ Poetry Package Management:
- Added an official Poetry installation guide and ecosystem support for Poetry-managed environments.
Updates/Improvements ⚡️
- Packaging Infrastructure Modernization:
- Migrated build and metadata configurations from legacy
setup.py/setup.cfgto modernpyproject.tomlconfiguration standards. - Switched to automatic package discovery via setuptools, excluding tests and docs from distribution builds.
- Migrated build and metadata configurations from legacy
- Toolchain Overhaul (Ruff Migration):
- Completely replaced
flake8andblackwithrufffor unified, high-speed linting and formatting across the entire codebase.
- Completely replaced
- Type Hint Modernization:
- Systematically updated type hints to leverage native Python 3.10+ structures, including PEP 604 union types (
X | Y) and built-in collection generics.
- Systematically updated type hints to leverage native Python 3.10+ structures, including PEP 604 union types (
- PEP 561 Compliance:
- Added a
py.typedmarker file so external type checkers (e.g.,pyright,mypy) properly recognize VidGear as an inline-typed package.
- Added a
- CamGear YouTube Backend Refactor:
- Extracted
YT_backendinto a dedicatedyt_backendmodule for cleaner separation of concerns and improved maintainability.
- Extracted
- Asyncio CLI Updates:
- Replaced boolean string arguments with proper
store_trueflags for-S,-yt,-l, and-ep. - Added
-a/--apiflag for backend selection (camgear/pigear/ffgear) and FFGear-specific arguments (-sd,-ff,-cf). - Marked
--enablePiCameraas a deprecated CLI flag with a runtime warning.
- Replaced boolean string arguments with proper
Breaking Updates/Changes 💥
-
💣 Deprecated
enablePiCamera:- The
enablePiCameraboolean flag has been officially deprecated across all core capture APIs (VideoGear,WebGear,WebGear_RTC,NetGear_Async) in favor of the explicitapi=Backend.PIGEARenumeration syntax. - Using the old flag will emit a
DeprecationWarningat runtime. It will be removed in a future release.
- The
Bug-fixes 🐛
- Stabilizer Memory Leak:
- Fixed a severe memory bottleneck where
self.__transformstracking records grew unbounded over the entire runtime duration (O(total_frames) → O(smoothing_radius)), eliminating an out-of-memory hazard for long-running sessions.
- Fixed a severe memory bottleneck where
- FFGear Metadata Tuple Handling:
- Fixed
read()to correctly enqueue and return(frame, metadata)tuples whenextract_metadatamode is enabled.
- Fixed
- Helper Utilities:
- Fixed
validate_videoto verify file path existence before processing. - Fixed missing demuxer header handling in
get_supported_demuxers. - Corrected
StopIterationhandling in default video codec selection logic. - Fixed
IndexErrorinvalidate_audiobit-depth parsing by replacing barere.findallindexing with guardedre.searchand adding a fallback parser for planar sample formats (fltp,s16p,u8p, etc.). - Fixed
get_supported_demuxersto expand all comma-separated demuxer aliases (e.g."matroska,webm"now yields both entries instead of only the last).
- Fixed
VidGear is free and open source and will always remain so. ❤️
It is something I am doing with my own free time. But so much more needs to be done, and I need your help to do this. For just the price of a cup of coffee 🍵, you can make a difference 🤝
Detailed Changelog: https://github.com/abhiTronix/vidgear/compare/vidgear-0.3.4...vidgear-0.3.5
Breaking Changes
- Deprecated `enablePiCamera` boolean flag across VideoGear, WebGear, WebGear_RTC, NetGear_Async; will be removed in a future release.
Weekly OSS security release digest.
The CVE patches and breaking changes that affected production tools this week. One email, every Sunday.
No spam, unsubscribe anytime.
Share this release
Track A Pure-Python Computer Vision Library That's Fast and Minimal
Get notified when new releases ship.
Sign up freeAbout A Pure-Python Computer Vision Library That's Fast and Minimal
All releases →Related context
Related tools
Beta — feedback welcome: [email protected]