Server Gateway SDK v3.8.202.20 for Linux C++
Public Member Functions | Protected Member Functions | List of all members
agora::rtc::ILocalVideoTrack Class Referenceabstract

#include <NGIAgoraVideoTrack.h>

Public Member Functions

virtual void setEnabled (bool enable)=0
 
virtual int setVideoEncoderConfiguration (const VideoEncoderConfiguration &config)=0
 
virtual int enableSimulcastStream (bool enabled, const SimulcastStreamConfig &config)=0
 
virtual int updateSimulcastStreamConfig (const SimulcastStreamConfig &config)=0
 
virtual LOCAL_VIDEO_STREAM_STATE getState ()=0
 
virtual bool getStatistics (LocalVideoTrackStats &stats)=0
 
- Public Member Functions inherited from agora::rtc::IVideoTrack
virtual bool addRenderer (agora_refptr< IVideoSinkBase > videoRenderer, media::base::VIDEO_MODULE_POSITION position=media::base::POSITION_POST_FILTERS)=0
 
virtual bool removeRenderer (agora_refptr< IVideoSinkBase > videoRenderer, media::base::VIDEO_MODULE_POSITION position=media::base::POSITION_POST_FILTERS)=0
 
virtual VideoTrackType getType ()=0
 

Protected Member Functions

 ~ILocalVideoTrack ()
 
- Protected Member Functions inherited from agora::rtc::IVideoTrack
 ~IVideoTrack ()
 

Detailed Description

ILocalVideoTrack is the base class for local video tracks, providing the main methods of local video tracks.

After creating local video tracks, you can publish one or more local video tracks by calling publishVideo.

Constructor & Destructor Documentation

◆ ~ILocalVideoTrack()

agora::rtc::ILocalVideoTrack::~ILocalVideoTrack ( )
inlineprotected

Member Function Documentation

◆ enableSimulcastStream()

virtual int agora::rtc::ILocalVideoTrack::enableSimulcastStream ( bool  enabled,
const SimulcastStreamConfig config 
)
pure virtual

Enables or disables the simulcast stream mode.

Parameters
enabledDetermines whether to enable or disable the simulcast stream mode.
  • true: Enable the simulcast stream mode.
  • false: Disable the simulcast stream mode.
configThe reference to the configurations for the simulcast stream mode. See SimulcastStreamConfig.
Returns
  • 0: Success.
  • < 0: Failure.

◆ getState()

virtual LOCAL_VIDEO_STREAM_STATE agora::rtc::ILocalVideoTrack::getState ( )
pure virtual

Gets the state of the local video stream.

Returns
The current state of the local video stream.

◆ getStatistics()

virtual bool agora::rtc::ILocalVideoTrack::getStatistics ( LocalVideoTrackStats stats)
pure virtual

Gets the statistics of the local video track.

Parameters
[out]statsThe reference to the statistics of the local video track.
Returns
  • true: Success.
  • false: Failure.

◆ setEnabled()

virtual void agora::rtc::ILocalVideoTrack::setEnabled ( bool  enable)
pure virtual

Enables or disables the local video track.

Once the local video track is enabled, the SDK allows for local video capturing, processing, and encoding.

Parameters
enableDetermines whether to enable the local video track.
  • true: Enable the local video track.
  • false: Disable the local video track.

◆ setVideoEncoderConfiguration()

virtual int agora::rtc::ILocalVideoTrack::setVideoEncoderConfiguration ( const VideoEncoderConfiguration config)
pure virtual

Sets the video encoder configuration.

Each video encoder configuration corresponds to a set of video parameters, including the resolution, frame rate, bitrate, and video orientation.

The configurations specified in this method are the maximum values under ideal network conditions. If the video engine cannot render the video using the specified parameters due to poor network conditions, the configurations further down the list are considered until a successful configuration is found.

Parameters
configThe reference to the video encoder configuration. See VideoEncoderConfiguration.
Returns
  • 0: Success.
  • < 0: Failure.

◆ updateSimulcastStreamConfig()

virtual int agora::rtc::ILocalVideoTrack::updateSimulcastStreamConfig ( const SimulcastStreamConfig config)
pure virtual

Update simulcast stream config.

Parameters
configThe reference to the configurations for the simulcast stream mode. See SimulcastStreamConfig.
Returns
  • 0: Success.
  • < 0: Failure.

The documentation for this class was generated from the following file: