Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add WHIP Simulcast Support #209

Merged
merged 2 commits into from
Feb 1, 2024
Merged

Add WHIP Simulcast Support #209

merged 2 commits into from
Feb 1, 2024

Conversation

Sean-Der
Copy link
Contributor

No description provided.

})
}

func (sp *SDKMediaSink) SetWritePLI(quality livekit.VideoQuality, writePLI func()) *SDKMediaSinkTrack {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need the extra setter here? From looking when SetWritePLI is called, it looks like we may be able to pass the writePLI function as a parameter to AddTrack?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do unfortunately :(

We create the tracks at signaling time. This is so we can block until they are all resolved.

We don’t know the SSRC until the media is flowing though.

pkg/whip/sdk_media_sink.go Outdated Show resolved Hide resolved
pkg/whip/sdk_media_sink.go Outdated Show resolved Hide resolved
pkg/whip/whip_handler.go Show resolved Hide resolved
h.trackSDKMediaSinkLock.Lock()
defer h.trackSDKMediaSinkLock.Unlock()

if _, ok := h.trackSDKMediaSink[kind]; !ok {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just curious about why we need two add all expected simulcast tracks when we get the first one here, instead of adding each one when we get the corresponding source track callback?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We create the tracks at signaling time. This is so we can block until they are all resolved.

We don’t know the SSRC until the media is flowing though.

maybe a better way to do this. Don’t know yet

pkg/whip/whip_handler.go Outdated Show resolved Hide resolved
@Sean-Der Sean-Der force-pushed the sean-der/simulcast branch 4 times, most recently from 91055c9 to 0ac29ab Compare February 1, 2024 02:41
Copy link
Contributor

@biglittlebigben biglittlebigben left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We still need to make sure we use a different stats gatherer per input layer, but I can fix that in a subsequence PR.

@Sean-Der Sean-Der merged commit 218e0c7 into main Feb 1, 2024
3 checks passed
@Sean-Der Sean-Der deleted the sean-der/simulcast branch February 1, 2024 18:00
biglittlebigben added a commit that referenced this pull request Feb 3, 2024
 ## Changelog

 ### Added
- Add EndedAt field to Ingress State (#40)
- Log room name and participant ID (#191)
- Gather input stats for url pull sessions (#192)
- Add support for SRT in URL Pull ingress (#206)
- Compute input media jitter (#205)
- Gather pipeline output statistics (#207)
- Add WHIP Simulcast Support (#209)

 ### Fixed
- Use a secret token to authenticate relay connections (#186)
- Update go-sdk to fix pli missed (#188)
- Use new upstream go-gst repository (#189)
- Refactor stats gathering functionality (#201)
- Add nil check in media stats merging code (#204)
- Do not use sample providers in the go SDK (#212)
biglittlebigben added a commit that referenced this pull request Feb 3, 2024
## Changelog

### Added
- Add EndedAt field to Ingress State (#40)
- Log room name and participant ID (#191)
- Gather input stats for url pull sessions (#192)
- Add support for SRT in URL Pull ingress (#206)
- Compute input media jitter (#205)
- Gather pipeline output statistics (#207)
- Add WHIP Simulcast Support (#209)

### Fixed
- Use a secret token to authenticate relay connections (#186)
- Update go-sdk to fix pli missed (#188)
- Use new upstream go-gst repository (#189)
- Refactor stats gathering functionality (#201)
- Add nil check in media stats merging code (#204)
- Do not use sample providers in the go SDK (#212)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants