pytgcalls / ntgcalls

A Native Implementation of Telegram Calls in a seamless way.
https://pytgcalls.github.io
GNU Lesser General Public License v3.0
58 stars 11 forks source link
audio calls cpp ffmpeg group-chat lib library nadymov py-tgcalls pytgcalls python stream telegram tgcalls video video-calls video-chat voice-chat voip webrtc
pytgcalls logo

A Native Implementation of Telegram Calls in a seamless way.
Examples Documentation PyPi Releases Channel Chat

NativeTgCalls PyPI - Version Downloads

Welcome to NativeTgCalls, an innovative open-source project. NativeTgCalls represents the next evolution in Telegram calling, building on the foundation laid by PyTgCalls.

Powerful Simple Light
Fast Logo
Built from scratch in C++ using Boost and libwebrtc
Simple Logo
Simple Python, GO and C Bindings
Light logo
We removed anything that could burden the library, including NodeJS

...and more, without even rewriting your code that uses PyTgCalls!

Overview

NativeTgCalls, often referred to as NTgCalls, is an exciting open-source venture. This project redefines the Telegram calling experience and introduces innovative features while preserving the legacy of PyTgCalls.

Build Status

Architecture Windows Linux MacOS
x86_64 BUILD BUILD BUILD
ARM64 BUILD BUILD BUILD

Key Features

Experimentation and Customization

NativeTgCalls is a playground for experimentation. We understand the importance of customization for developers, empowering you to tailor your Telegram calling solutions to your precise requirements.

Advancing with PyTgCalls

Building upon the success of PyTgCalls, NativeTgCalls provides a natural progression for developers familiar with its predecessor. This evolution streamlines the development process and extends the capabilities of Telegram calling.

Importantly, PyTgCalls will seamlessly integrate the new core (NTgCalls) to ensure backward compatibility.

Compiling

Python Bindings

NativeTgCalls offers Py Bindings, enabling seamless integration with Python. Follow these steps to compile NativeTgCalls with Python Bindings:

  1. Ensure you are in the root directory of the NativeTgCalls project.
  2. Run the following command to install the Py Bindings:

    python3 setup.py install

    Go Bindings

    NativeTgCalls offers Go Bindings, enabling seamless integration with Go. Follow these steps to compile NativeTgCalls with Go Bindings:

  3. There is an example project for Go in ./examples/go/ directory, ensure you are in that directory
  4. Prerequisites for building are the same as for building library itself and can be found here
  5. Download shared release of the library from https://github.com/pytgcalls/ntgcalls/releases
    1. Static won't work
  6. Copy ntgcalls.h file into ./examples/go/ntgcalls/ directory
  7. The rest of the files should be copied to ./examples/go/ directory
    1. ntgcalls.dll and ntgcalls.lib files in case of Windows amd64 shared release
  8. Then in ./examples/go/ directory run go build or go run . with CGO_ENABLED=1 env variable set
    1. $env:CGO_ENABLED=1; go run . for Windows PowerShell
    2. CGO_ENABLED=1 go run . for UNIX

C Bindings

For developers looking to use NativeTgCalls with C and C++, we provide C Bindings. Follow these steps to compile NativeTgCalls with C Bindings:

  1. Ensure you are in the root directory of the NativeTgCalls project.
  2. Run the following command to generate the shared libs:
    python3 setup.py build_shared
  3. Upon successful execution, a shared library will be generated in the "shared-output" directory. You can now use this library to develop applications with NativeTgCalls.
  4. To include the necessary headers in your C/C++ projects, you will find the "include" folder in the root of the project. Utilize this folder for including the required header files.

Key Contributors

Junior Developers

Special Thanks

We would like to extend a special thanks to @null-nick and @branchscope for their valuable contributions to the testing phase of the library. Their dedication to testing and optimizing the library has been instrumental in its success.

Additionally, we extend our gratitude to all contributors for their exceptional work in making this project a reality.