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

Improve Direct Play support for AV1 codec #2001

Merged
merged 1 commit into from
Oct 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 5 additions & 15 deletions source/utils/deviceCapabilities.bs
Original file line number Diff line number Diff line change
Expand Up @@ -301,21 +301,11 @@ function getTranscodingProfiles() as object
end if

' AV1
for each container in transcodingContainers
if di.CanDecodeVideo({ Codec: "av1", Container: container }).Result
if container = "mp4"
' check for codec string before adding it
if mp4VideoCodecs.Instr(0, ",av1") = -1
mp4VideoCodecs = mp4VideoCodecs + ",av1"
end if
else if container = "ts"
' check for codec string before adding it
if tsVideoCodecs.Instr(0, ",av1") = -1
tsVideoCodecs = tsVideoCodecs + ",av1"
end if
end if
end if
end for
' CanDecodeVideo() returns false for AV1 when the container is provided
' Manually add AV1 to the mp4VideoCodecs list if support is detected
if di.CanDecodeVideo({ Codec: "av1" }).Result
mp4VideoCodecs = mp4VideoCodecs + ",av1"
end if

' AUDIO CODECS
for each container in transcodingContainers
Expand Down
Loading