-
Notifications
You must be signed in to change notification settings - Fork 2
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
Added Content-Resolution to prepare & transcode #31
Conversation
for _, track := range tctx.InputAsset.AssetSpec.VideoSpec.Tracks { | ||
if track.Type == "video" { | ||
contentResolution = fmt.Sprintf("%dx%d", track.Width, track.Height) | ||
break | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: We should probably create a litle helper/utility to grab the video track from an asset spec (or maybe receiving a trackType string
and returning the first track with that). We have this exact same loop repeated in a couple of places now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gonna do this in another pr
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
83f253a
to
b02bd95
Compare
@@ -4,7 +4,7 @@ go 1.16 | |||
|
|||
require ( | |||
github.com/golang/glog v1.0.0 | |||
github.com/livepeer/go-api-client v0.1.2 | |||
github.com/livepeer/go-api-client v0.1.3-0.20220513154150-a37f7c0b5586 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
v0.1.3
https://github.com/livepeer/go-api-client/releases/tag/v0.1.3
go get github.com/livepeer/go-api-client@v0.1.3
go mod tidy
Fixes #25
Depends on livepeer/go-api-client#6
What does it do?
Retrieve the source asset resolution and provide it to PushSegment, to be used as a Content-Resolution header and display the source resolution correctly.