Skip to content

Change the group A/V API from Tox to ToxAV #1364

Open
@sudden6

Description

@sudden6

Currently groups with AV enabled are decoding the audio in the Tox main thread. This is done here. This also means that the callbacks for groupAV are emitted from the main thread, potentially causing confusion for the client developers.

Ideally we would do the decoding in the dedicated ToxAV thread to keep the protocol and other events running smoothly even under heavy decoding load/many parallel calls. This will also fix the inconsistency of emitting AV callbacks from the main and the ToxAV thread.

Unfortunately this requires an API break since all functions below this line take a Tox struct as parameter and we don't have access to the ToxAV struct. Access to the ToxAV struct is needed, because we need a lock when queuing packets for decoding and a queue which toxav_iterate(...) can access.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low priorityapi breakChange breaks API or ABI

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions