a Python extension that provides bindings to WebRTC M92
Project description
A Python extension that provides bindings to WebRTC M92
Examples
•
Documentation
•
PyPI
Python WebRTC
Let's use the native WebRTC with strict compatibility and fully implemented stuff!
This project follows the W3C specification with some modifications and additions to make it work better with Python applications, with useful APIs like programmatic audio and video.
DISCLAIMER
This project is still under development and isn't ready for any serious use. In the current stage, it's possible to establish connection and work with audio, but many interfaces and methods not implemented yet.
Snippet
import asyncio
import webrtc
async def main():
pc = webrtc.RTCPeerConnection()
stream = webrtc.get_user_media()
for track in stream.get_tracks():
pc.add_track(track, stream)
audio_source = webrtc.RTCAudioSource()
track = audio_source.create_track()
pc.add_track(track)
local_sdp = await pc.create_offer()
print(local_sdp.sdp)
if __name__ == '__main__':
asyncio.run(main())
Requirements
Pre-built wheels:
- Python 3.7 or higher
- pip 21 or higher
- And compatible platform:
Linux | macOS | Windows | |||||
---|---|---|---|---|---|---|---|
armv7l | arm64 | x86_64 | Intel | Apple Silicon | 64bit | ||
Python | 3.7 | N/A | N/A | ✅ | ✅ | N/A | ✅ |
3.8 | N/A | N/A | ✅ | ✅ | ✅ | ✅ | |
3.9 | N/A | N/A | ✅ | ✅ | ✅ | ✅ | |
3.10 | N/A | N/A | ✅ | ✅ | ✅ | ✅ |
Building from sources (sdist):
- ~15 GB of free disk space
- CMake 3.14 or higher
- GCC 7.5 or higher
- glibc 2.18 or higher
- ARM toolchain (ARM only)
Full building instruction will be present later
Installing
Pre-built wheel:
pip3 install --pre wrtc
Build from sources:
pip3 install --pre wrtc --no-binary wrtc
Documentation
The documentation is live at readthedocs.io.
Getting help
You can get help in several ways:
- Report bugs, request new features by creating an issue.
- Ask question by starting a discussion.
Contributing
Contributions of any sizes are welcome.
Special thanks to
- Authors of node-webrtc.
License
The python-webrtc
is published under the BSD 3-Clause License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for wrtc-0.0.0.dev7-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 05f81e4ec22636976d56e43182ba2c51719984db015c4957b8fd5e97e558ebde |
|
MD5 | fb35a4fceb746a1c51e87cf18dcc1c93 |
|
BLAKE2b-256 | c4dd6c0467a0057be4ad9506bddeefca8bc8aeb97577ef58b99efa288cb0c92a |
Hashes for wrtc-0.0.0.dev7-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0183727c837132f7962dc8ab0330d0070ba34ec31204a518ed214c82d8193b83 |
|
MD5 | 139a94dba0e77a636d06585f1e23db7f |
|
BLAKE2b-256 | b3331035ece3899b170215f8035f6600024e3ba265be4cac8f73b1feb5931777 |
Hashes for wrtc-0.0.0.dev7-cp310-cp310-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b65b286e51d708140ea3aa9f425584c523a1e08dd848aa87c63a64c0b79f2b82 |
|
MD5 | a3230ee6c7adb031bc7fbf99493d7216 |
|
BLAKE2b-256 | 3e17a31db2827e1e05a8f4547ca6fb92fd002df2d3c7e69e0bee822e163919a0 |
Hashes for wrtc-0.0.0.dev7-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6035ce1e4ac123b6277489eafeabcd16ecc0729e1827ef53d1f90b03a32cec4a |
|
MD5 | eb63bc1c6f74a855c7b6b6ab9b3aa8c1 |
|
BLAKE2b-256 | 04bc4e6e02e832daa6083ccccb8c558021fdada69ac2fba82292126700b19d5e |
Hashes for wrtc-0.0.0.dev7-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | aa1476dadc7478ca66d12045567a40068edb0344e27d098755f0df644b520fad |
|
MD5 | 1539d36435390dad4d443af7a505d958 |
|
BLAKE2b-256 | 2ebc414da91309384843aae7d60679a4a852097747f9ce64a88ae1be9a8f666a |
Hashes for wrtc-0.0.0.dev7-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d49c1669e5fb3695064c872ddddf03ca34c06bf6682632c3ea056492f61118ad |
|
MD5 | 72b19b3d77f5d5a0c9b9f78fc6a7f70b |
|
BLAKE2b-256 | 4c7143e961d2793b1e14a15934a7bcec5fc21df17e3a7fe686eaa30550c5f4c8 |
Hashes for wrtc-0.0.0.dev7-cp39-cp39-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1ef5ec5190a45357336a99d9c99e0a20e0e16eabd31bc7684e2228a64fc50a3e |
|
MD5 | eeb17e409160ae528bd617b84129ae4b |
|
BLAKE2b-256 | a4307b63b581efc1ca5d4f0cf4a872f5f27c58c1d369eca1becec3c3532e9c78 |
Hashes for wrtc-0.0.0.dev7-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 17c5e67e3348617b758b4d24e18dc802d0281b61730cbe389975eb4785f033c1 |
|
MD5 | 1deea61087f5f8685505fd9b2d646f62 |
|
BLAKE2b-256 | 5c2ef0bca7670173c781469d7344a0cc4d7bf0515fd487071701b7b7ac89b37d |
Hashes for wrtc-0.0.0.dev7-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6879314a06a845039e17f6f668e0ade2f3321666d3444bae730ff011612a6c79 |
|
MD5 | 292a548b6ef65b0dda7342ae20dad9b1 |
|
BLAKE2b-256 | 3deb2a9b9b0bdd6b05eed52d90c1b1e2983a21f52a1e79a86e3e9e706b7ff256 |
Hashes for wrtc-0.0.0.dev7-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 732fa975bbe564bce98e4e28929495ec0c0ffe150d666b37aaa24fd6cc4d3e8c |
|
MD5 | 5ecd8ad1a81fa2960c85488be672a7ea |
|
BLAKE2b-256 | d7a7424b7a4a15a6aad0b402995734eb90c86e4e03c9f74d5ee2fb80ac23eddf |
Hashes for wrtc-0.0.0.dev7-cp38-cp38-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c8ef9200c805723b67499c30e5d1ed62963b34319e324b465f10b5ddae6d8f75 |
|
MD5 | 9276984c41de28a770e15bb027549f56 |
|
BLAKE2b-256 | 26af0630f62cdb793d090fcbb2fd4aa58c91d2b4d13255b640746fa6428a5e50 |
Hashes for wrtc-0.0.0.dev7-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 81ae324e8629e31b6ff954d6b213db783108500707aaab184ebaf95bae4346e1 |
|
MD5 | b878b2144369352574d0e2700a0e893d |
|
BLAKE2b-256 | a65e52b812186d2ec1f61fb23d337dd7954167e2b32a2f63cc51c612449133a1 |
Hashes for wrtc-0.0.0.dev7-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68c699b379b4c786f154addf6e1dd741719481c9e083d981f4e70700d95a5525 |
|
MD5 | 62aa4f580ef3dce9e1a5ca8a868da74f |
|
BLAKE2b-256 | 2487fcbddda1a47007ee0c3e636aaa6444e9bdcb48bbdecbdfeb1c4354d8d732 |
Hashes for wrtc-0.0.0.dev7-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9f9749326baf209842ae2dc79593c7226588bba5d03556332b635624785d0fef |
|
MD5 | 32f9936479996b61da380cba14095996 |
|
BLAKE2b-256 | 63b857c8bbc15cba7d4cb86cf0b67ae52ced6cad9305adf26276c88a19832063 |
Hashes for wrtc-0.0.0.dev7-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0d589f84ceb56683ef23b0e882391b212cfc475fd4855064ba78c1701743837b |
|
MD5 | 1df7db486c252e1497ce5d5a50834997 |
|
BLAKE2b-256 | 961657cc89e0d9ca188edf3f39cd2d672530a779f461d8a5696a755ba8c03326 |