Set is_screencast on NativeVideoSource creation - #552
Conversation
|
it seems like you haven't added any nanpa changeset files to this PR. if this pull request includes changes to code, make sure to add a changeset, by writing a file to refer to the manpage for more information. |
eef7d59 to
d276130
Compare
There was a problem hiding this comment.
It looks like we already have a screenshare flag:
#[derive(Clone, Debug)]
pub struct TrackPublishOptions {
// If the encodings aren't set, LiveKit will compute the most appropriate ones
pub video_encoding: Option<VideoEncoding>,
pub audio_encoding: Option<AudioEncoding>,
pub video_codec: VideoCodec,
pub dtx: bool,
pub red: bool,
pub simulcast: bool,
// pub name: String,
pub source: TrackSource,
pub stream: String,
}#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum TrackSource {
Unknown,
Camera,
Microphone,
Screenshare,
ScreenshareAudio,
}Would it be sufficient to reuse this flag?
cc: @theomonnom
I didn't think of this TBH. It could be done by exposing a setter in Side note: The only "problem" I see with this, is that |
7ea5f04 to
6d49d4c
Compare
|
Something that I had forgotten to mention when I created this, is that when |
Makes InternalSource's is_screencast configurable. Setting it improves the latency when sharing screen content.
6d49d4c to
b04977c
Compare
|
I tested it with m137 and the |
|
Closing as it was implemented it in a different PR. |
Makes InternalSource's is_screencast configurable when creating a NativeVideoSource. This improves the stream's latency when vp9 is used for sharing screen content.