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
Stop making unstandard pure implementations of WebRTC and let's use the native library!
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 with a large number of segfaults and sigbuses. ✨
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.dev5-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9f13c22b42d06f6e5492cd385ec4e90ea7e97e4449a5a702d0ee60854f545cf0 |
|
MD5 | 0b293292aa1461d52e12378c3b38d3bd |
|
BLAKE2b-256 | 6b625c171b142db9a093d53dae3bca6db12ee5bea354af5396d6c12367d39396 |
Hashes for wrtc-0.0.0.dev5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 26c1149b4e58fd99116a332c7995a3134d8c57a3a575c80be2c1b469f01973e4 |
|
MD5 | 648dc393644ed711bbfd71f8c4c37f37 |
|
BLAKE2b-256 | cf8efa2e5dbb6ef38e2274b87960bc658e5722bd76185ae1f2c413fd74cec471 |
Hashes for wrtc-0.0.0.dev5-cp310-cp310-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f153e659c8ac7372a1476bf2993a30ecaf2aed500528692d2b62fa6a4fd9aff5 |
|
MD5 | 52c5bc5c48af4c30fec7332029c9bdcd |
|
BLAKE2b-256 | 01ddeb96e6f540bb64a32c17c047e3d3b6afc2b17ca3394d6ad5586ef930dde0 |
Hashes for wrtc-0.0.0.dev5-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | be100c86527f0a1d822c272c7f0aa3d9928dede36392646ef7113b67db497c90 |
|
MD5 | 23cc60599a9bf69278f391ab39b148e8 |
|
BLAKE2b-256 | 8bd0b0dcfd8acb453e88cfaac9af153a29ff7890100edb30b6574a61ce149947 |
Hashes for wrtc-0.0.0.dev5-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6f990c4ec2159421dd61b237990999216895c604461fbf43d4108c740a0392b0 |
|
MD5 | e77730b6fc7880ac3a647a77d16e9265 |
|
BLAKE2b-256 | 13d657e857fa2b26c39cb8d545f3570d8f30d1fca9b4c6c6fdff8e73baef097f |
Hashes for wrtc-0.0.0.dev5-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8153f1963c434ac690eaf6954de454d2dd9281d403e1b7488411819a92325413 |
|
MD5 | 788a32e0ddb4e02b4acdfc2caf27d323 |
|
BLAKE2b-256 | e29c7bf19ab2528d47b825b20a87c076d09ea54c71ee009f45433fe186e2ad03 |
Hashes for wrtc-0.0.0.dev5-cp39-cp39-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f5c53cb901203986ccfe930cf9980c7d4ab6d3257e20674bf47b5335e3688916 |
|
MD5 | 6729ca782d69e255f689bdf4e59be94d |
|
BLAKE2b-256 | 4df90724c8714a5e9c24b1a3f6ed632b7bd4f505ae89a32c6e1eebd309139d06 |
Hashes for wrtc-0.0.0.dev5-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 235e77f4379b3da0b6001de4ebd6ee0bd72b19b53887be04aecd4f8435404d72 |
|
MD5 | 7242ebf9ec5a50ddda84a7086f22bae3 |
|
BLAKE2b-256 | f368c89375275835d1c49089d03afbb0b859fd83cdf3976337eae4c9af216649 |
Hashes for wrtc-0.0.0.dev5-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 41e9491032e2f6b3f047a1074e902cf06e446bd29a7761b01437075447984db7 |
|
MD5 | 8e3f90755446d600dea31d767191db69 |
|
BLAKE2b-256 | 1464a71483c7df9734f111ab3c6577552bee05104dd4939ce86acae6d9ae1ada |
Hashes for wrtc-0.0.0.dev5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2c62627b142dcd27d3bf337aa864d008f2a79bcab626daf90f080e9ee3d514ed |
|
MD5 | f211324faff74eaf3aeff321d1ee3adc |
|
BLAKE2b-256 | 019cf2c59bf3ba00ceef8591aad4d86d98cf164e11753f927279877a8ef0a85b |
Hashes for wrtc-0.0.0.dev5-cp38-cp38-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c7b12a379968d6f4892aa626918d6ad61f7454c80f8323ee017b8d6f3c3bfa96 |
|
MD5 | 4b643383b777c6f7b60860080d1d9954 |
|
BLAKE2b-256 | cdd4e94eb0b3e75cefa28549f2f96433679ad8afcadbe2d8bd2da5a1f4db5e90 |
Hashes for wrtc-0.0.0.dev5-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9a5cbd9f86b0b1a71874158ee92ca586709816a91eceee1e6f7e49807638734b |
|
MD5 | 178c7b004c19736450eb238a391f0bc7 |
|
BLAKE2b-256 | daa27b6f37f5b623e9e7b7863600991a339680e2bbfdf9ce529e43d6497b5040 |
Hashes for wrtc-0.0.0.dev5-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4e99676d87d7e1a56bd366bc1e4315399ccaef84b7b8cc06e5da31b5bcba324a |
|
MD5 | aeb254910b7c2150fbaf285b2d9a3928 |
|
BLAKE2b-256 | 642f40502cf37941681f79e26cac5be786633b5168bba32d92b5c68e5f9e3625 |
Hashes for wrtc-0.0.0.dev5-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1b4210195695985b6166e7d71cae4aa893b94168d199fd63fae167aae7957c5f |
|
MD5 | 9786a8d46b8c4f357ae2488e87f790a5 |
|
BLAKE2b-256 | f3179c9739d0c031ea6db275e0bbd9ec67675111a3ea39bb88bb7baa88912e53 |
Hashes for wrtc-0.0.0.dev5-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 46a5f76fd2c2bc8a5191ba410394b8d2ac0148c831557b17722ac873d84ca7e2 |
|
MD5 | 8d9ca570c8799e10868df1dbbc9d4060 |
|
BLAKE2b-256 | 10da79da3ff9dc7cef84f9af4ac44dbe4a1f14aa2598bc06a03aeb94da6c6aca |