Skip to content

Commit

Permalink
rearrange to fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
cewert committed Sep 28, 2023
1 parent 9ea0466 commit 0902d6f
Showing 1 changed file with 26 additions and 24 deletions.
50 changes: 26 additions & 24 deletions source/utils/deviceCapabilities.brs
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,8 @@ function getDeviceProfile() as object
"IsRequired": true
}
'
' add mp3 to TranscodingProfile for music
' add mp3 directly to transcoding profile.
' for music i think?
deviceProfile.TranscodingProfiles.push({
"Container": "mp3",
"Type": "Audio",
Expand All @@ -397,6 +398,30 @@ function getDeviceProfile() as object
"MaxAudioChannels": maxAudioChannels
})

' setup container arrays
tsArray = {
"Container": "ts",
"Context": "Streaming",
"Protocol": "hls",
"Type": "Video",
"AudioCodec": tsAudioCodecs,
"VideoCodec": tsVideoCodecs,
"MaxAudioChannels": maxAudioChannels,
"MinSegments": 1,
"BreakOnNonKeyFrames": false
}
mp4Array = {
"Container": "mp4",
"Context": "Streaming",
"Protocol": "hls",
"Type": "Video",
"AudioCodec": mp4AudioCodecs,
"VideoCodec": mp4VideoCodecs,
"MaxAudioChannels": maxAudioChannels,
"MinSegments": 1,
"BreakOnNonKeyFrames": false
}

' set preferred audio codec for transcoding
if isValid(surroundSoundCodec)
' use preferred surround sound codec
Expand Down Expand Up @@ -450,29 +475,6 @@ function getDeviceProfile() as object
})
end if

tsArray = {
"Container": "ts",
"Context": "Streaming",
"Protocol": "hls",
"Type": "Video",
"AudioCodec": tsAudioCodecs,
"VideoCodec": tsVideoCodecs,
"MaxAudioChannels": maxAudioChannels,
"MinSegments": 1,
"BreakOnNonKeyFrames": false
}
mp4Array = {
"Container": "mp4",
"Context": "Streaming",
"Protocol": "hls",
"Type": "Video",
"AudioCodec": mp4AudioCodecs,
"VideoCodec": mp4VideoCodecs,
"MaxAudioChannels": maxAudioChannels,
"MinSegments": 1,
"BreakOnNonKeyFrames": false
}

' apply max res to transcoding profile
if maxResSetting <> "off"
tsArray.Conditions = [maxVideoHeightArray, maxVideoWidthArray]
Expand Down

0 comments on commit 0902d6f

Please sign in to comment.