abhiTronix/vidgear: VidGear Stable v0.3.3
Creators
- 1. Autodidact β’ Researcher β’ Open-sourcerer
- 2. Christian Clauss
- 3. @ngrok
- 4. Institute of Neuroscience, Chinese Academy of Sciences
- 5. Hyland|Nuxeo
Description
This update significantly enhances Vidgear's capabilities, ensuring better performance, broader compatibility, and improved user experience. The introduction of the Picamera2 API support, enhanced error handling, and detailed documentation updates are pivotal in making Vidgear more robust and user-friendly.
π Complete Release Notes can be found here βοΈ
<div align="center"> <img src="https://abhitronix.github.io/vidgear/latest/assets/images/help_us.png" alt="PiGear" width="40%" /> <p><i>VidGear is free and open source and will always remain so. β€οΈ</i></p>
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 π
<a href='https://ko-fi.com/W7W8WTYO' target='_blank'><img height='36' style='border:0px;height:36px;' src='https://cdn.ko-fi.com/cdn/kofi1.png?v=3' border='0' alt='Buy Me a Coffee at ko-fi.com' /></a>
</div>
What's Changed
New Features β¨
- PiGear:
- Official Support for Picamera2 API backend:
- This massive update brings official support for the new Picamera2 API, unlocking powerful features for Raspberry Pi Camera Modules and limited USB camera support.
- Seamless Python wrapper: A robust wrapper around Picamera2 API library simplifies integration with minimal code changes for existing PiGear users.
- Enhanced camera control: Leverages libcamera API under the hood for Raspberry Pi Camera Modules.
- Existing compatibility: Maintains compatibility with PiGear's existing super-charged multi-threaded and colorspace manipulation framework.
- Proper Resource management: Ensures proper resource release during PiGear termination.
- USB camera support (limited): Provides basic functionality for USB webcams. PiGear could accurately differentiates between USB and Raspberry Pi cameras using metadata.
- Backward compatibility: Seamlessly switches to the legacy Picamera library backend if Picamera2 is unavailable.
- Standalone functionalities: Standalone functionalities for both legacy
picamera
and newerpicamera2
backends for clarity. - Advanced optional parameters handling: Handles camera configurational parameters and user-defined settings for various camera types.
- Official Support for Picamera2 API backend:
- StreamGear:
- Introduced new
-enable_force_termination
attribute for immediate FFmpeg process termination.
- Introduced new
- Helper:
- Added support for SRTP/RTSPS in
is_valid_url
function:- SRTP/RTSPS extends RTSP/RTP to encrypt video and audio data using the same ciphers as HTTPS, typically AES with a 128-bit key length.
- Added a custom deprecated decorator to mark deprecated functions and parameters.
- Added support for SRTP/RTSPS in
Updates/Improvements β‘οΈ
- Core:
- Improved exception handling for module imports.
- Improved colorspace handling in videocapture gears.
- Asyncio:
- Replaced deprecated Starlette's
on_shutdown
parameter with an async context managerlifespan
in WebGear and WebGear_RTC APIs.
- Replaced deprecated Starlette's
- NetGear_Async API:
- Changed launch method to use
self.loop.create_task()
instead ofasyncio.ensure_future()
- Moved the event loop initialization code to an earlier point before setting event loop policy to ensure it is set up correctly before selecting
WindowsSelectorEventLoop
policy.
- Changed launch method to use
- StreamGear:
- Updated
close()
methods for handling gracefully signal interruptions based on different operating systems with device audio streams. - Enhanced stream copy support in Single Source mode.
- Updated
- NetGear:
- Handled socket session expiration more gracefully in
recv_handler
. - Ensured proper termination of the ZMQ context and socket when closing the NetGear instance.
- Handled socket session expiration more gracefully in
- WebGear:
- Enhanced error messages for WebGear auto-generation workflow.
- WriteGear:
- Improved error handling in
execute_ffmpeg_cmd
method.
- Improved error handling in
- Setup.py:
- Dropped legacy
picamera
dependency insetup.py
. - Updated
pyzmq
version to address installation issues.
- Dropped legacy
- Helper:
- Updated
extract_time
helper function regex to handle milliseconds.
- Updated
Breaking Updates/Changes π₯
- StreamGear:
- π£ Deprecated
terminate()
method and introduceclose()
method.- The
terminate()
method in StreamGear is now deprecated and will be removed in a future release. Developers should use the newclose()
method instead, which provides a more descriptive name like in WriteGear API for terminating StreamGear processes safely.
- The
- π£ Deprecated
rgb_mode
parameter instream()
method.- This parameter will be removed in a future version, and only BGR format frames will be supported.
- π£ Restricted
-livestream
parameter to Real-time Frames Mode only.- Live streaming is intended for low-latency streaming of real-time frames, where chunks contain only the most recent frames. It doesn't make sense when streaming from a video file, as the entire file can be streamed normally without the need for live streaming.
- π£ Deprecated
Bug-fixes π
- PiGear:
- Modify PiGear class behavior when
enforce_legacy_picamera=True
on unsupported system.
- Modify PiGear class behavior when
- StreamGear:
- Removed non-essential aspect ratio parameter to prevent unwanted distortions.
- NetGear:
- Fixed Secure Mode failing to work on conflicting ZMQ Contexts.
- Fixed
msg_json
undefined when terminating context in therecv_handler
method.
- CamGear:
- Fixed logging condition for yt-dlp.
Files
abhiTronix/vidgear-vidgear-0.2.1.zip
Files
(50.0 MB)
Name | Size | Download all |
---|---|---|
md5:249a7160a1e9a633def9cf1e131f8061
|
26.4 MB | Preview Download |
md5:b060270302965ad52980b82754820237
|
23.5 MB | Preview Download |
Additional details
Related works
- Is supplement to
- Software: https://github.com/abhiTronix/vidgear/tree/vidgear-0.3.3 (URL)