onPlayerVideoSizeChanged property

(void Function(String streamID, int width, int height)?) onPlayerVideoSizeChanged
read / write

The callback triggered when the stream playback resolution changes.

Available since: 1.1.0 Description: After the startPlayingStream function is called successfully, the play resolution will change when the first frame of video data is received, or when the publisher changes the encoding resolution by calling setVideoConfig, or when the network traffic control strategies work. Use cases: Developers can update or switch the UI components that actually play the stream based on the final resolution of the stream. Trigger: After the startPlayingStream function is called successfully, this callback is triggered when the video resolution changes while playing the stream. Caution: If the stream is only audio data, the callback will not be triggered. Note: This function is only available in ZegoExpressVideo SDK!

  • streamID Stream ID.
  • width Video decoding resolution width.
  • height Video decoding resolution height.

Implementation

static void Function(String streamID, int width, int height)?
    onPlayerVideoSizeChanged;