Skip to content

Latest commit

 

History

History
75 lines (44 loc) · 1.73 KB

File metadata and controls

75 lines (44 loc) · 1.73 KB

Examples

Simple

Source: simple.py

Description: Shows basics of setting up a virtual camera and sending frames.

python ./examples/simple.py

Video

Source: video.py

Description: Reads video frames from a file and sends them to the virtual camera.

# Download example mp4 from:
# https://file-examples.com/index.php/sample-video-files/sample-mp4-files/
python ./examples/video.py file_example_MP4_1280_10MG.mp4

Latency

Source: latency.py

Description: Allows to evaluate latency visually by comparing color changes with corresponding output on the terminal.

python ./examples/latency.py

Webcam Filter

Source: webcam_filter.py

Description: Reads frames from a webcam, applies a filter, and sends them to the virtual camera.

screencast tbd

RGBA GIF

Source: rgba_gif.py

Description: Reads RGBA frames from a GIF animation and sends them to a virtual camera while preserving transparency. Useful for post-processing in other software like OBS Studio.

screencast tbd

Multi Device

Source: multi_device.py

Description: Sends the same frames to multiple Linux v4l2loopback devices from Python.

python ./examples/multi_device.py

Native Rust

Source: ../crates/pyvirtualcam-core/examples/simple.rs

Description: Demonstrates the initial native Rust API for the Linux v4l2loopback backend.

cargo run -p pyvirtualcam-core --example simple