25#include "livekit/data_track_error.h"
26#include "livekit/data_track_frame.h"
27#include "livekit/data_track_info.h"
28#include "livekit/ffi_handle.h"
29#include "livekit/result.h"
30#include "livekit/visibility.h"
35class OwnedLocalDataTrack;
79 std::optional<std::uint64_t> user_timestamp = std::nullopt);
94 uintptr_t ffiHandleId() const noexcept {
return handle_.get(); }
RAII wrapper for an FFI handle (uintptr_t) coming from Rust.
Definition ffi_handle.h:29
Represents a locally published data track.
Definition local_data_track.h:58
bool isPublished() const
Whether the track is still published in the room.
const DataTrackInfo & info() const noexcept
Metadata about this data track.
Definition local_data_track.h:66
Result< void, LocalDataTrackTryPushError > tryPush(std::vector< std::uint8_t > &&payload, std::optional< std::uint64_t > user_timestamp=std::nullopt)
Try to push a frame to all subscribers of this track.
void unpublishDataTrack()
Unpublish this data track from the room.
Result< void, LocalDataTrackTryPushError > tryPush(const DataTrackFrame &frame)
Try to push a frame to all subscribers of this track.
Represents the local participant in a room.
Definition local_participant.h:55
Lightweight success-or-error return type for non-exceptional API failures.
Definition result.h:40
Public API for the LiveKit C++ Client SDK.
Definition audio_frame.h:25
A single frame of data published or received on a data track.
Definition data_track_frame.h:36
Metadata about a published data track.
Definition data_track_info.h:27