Add defaultKID opt
This commit is contained in:
2
index.js
2
index.js
@@ -378,7 +378,6 @@ const parseMPDStream = async (mpdUrl) => {
|
||||
targetProp: 'subtitles'
|
||||
}];
|
||||
|
||||
|
||||
toParse.forEach(({ rootProp, subProp, targetProp }) => {
|
||||
try {
|
||||
for (const [key, value] of Object.entries(parsedManifest?.mediaGroups?.[rootProp]?.[subProp])) {
|
||||
@@ -400,6 +399,7 @@ const parseMPDStream = async (mpdUrl) => {
|
||||
name: `${parsedManifest.playlists?.[i]?.attributes?.RESOLUTION?.width || 'N/C'}x${parsedManifest.playlists?.[i]?.attributes?.RESOLUTION?.height || 'N/C'}`,
|
||||
codec: parsedManifest.playlists?.[i]?.attributes?.CODECS,
|
||||
bandwidth: parsedManifest.playlists?.[i]?.attributes?.BANDWIDTH,
|
||||
defaultKID: parsedManifest.playlists?.[i]?.contentProtection?.mp4protection?.attributes['cenc:default_KID']?.replaceAll('-', '') || null,
|
||||
fps: parsedManifest.playlists?.[i]?.attributes?.['FRAME-RATE'],
|
||||
resolution: {
|
||||
width: parsedManifest.playlists?.[i]?.attributes?.RESOLUTION?.width,
|
||||
|
||||
Reference in New Issue
Block a user