Merge pull request #6291 from Arcus92/pgs-fix-position
Some checks are pending
Push & Release 🌍 / Automation 🎛️ (push) Waiting to run
Push & Release 🌍 / Unstable release 🚀⚠️ (push) Waiting to run
Push & Release 🌍 / Quality checks 👌🧪 (push) Waiting to run
Push & Release 🌍 / GitHub CodeQL 🔬 (push) Waiting to run
Push & Release 🌍 / Deploy 🚀 (push) Blocked by required conditions

Update dependency libpgs to v0.8.0
This commit is contained in:
Bill Thornton 2024-11-04 12:24:10 -05:00 committed by GitHub
commit 22ae941a9a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 18 additions and 9 deletions

14
package-lock.json generated
View File

@ -45,7 +45,7 @@
"jquery": "3.7.1",
"jstree": "3.3.17",
"libarchive.js": "2.0.2",
"libpgs": "0.6.0",
"libpgs": "0.8.0",
"lodash-es": "4.17.21",
"markdown-it": "14.1.0",
"material-design-icons-iconfont": "6.7.0",
@ -15080,9 +15080,9 @@
}
},
"node_modules/libpgs": {
"version": "0.6.0",
"resolved": "https://registry.npmjs.org/libpgs/-/libpgs-0.6.0.tgz",
"integrity": "sha512-k8ic6VTJTCun8Ump8iAe+tZi3pa1ZhDlq1v4hmZOmYQzSQ44QpZoClMXuSfJ1B91eRWOO6q50rXhyCPuB9dXbg==",
"version": "0.8.0",
"resolved": "https://registry.npmjs.org/libpgs/-/libpgs-0.8.0.tgz",
"integrity": "sha512-YpmcQYP177j08Vd0zEORgtdHsdPLGF8FCL152DgTQg2txLx1ndjgNOJ1n0217ap5rFV8riTugzjM9sqPrT1e5Q==",
"license": "MIT"
},
"node_modules/lie": {
@ -36347,9 +36347,9 @@
}
},
"libpgs": {
"version": "0.6.0",
"resolved": "https://registry.npmjs.org/libpgs/-/libpgs-0.6.0.tgz",
"integrity": "sha512-k8ic6VTJTCun8Ump8iAe+tZi3pa1ZhDlq1v4hmZOmYQzSQ44QpZoClMXuSfJ1B91eRWOO6q50rXhyCPuB9dXbg=="
"version": "0.8.0",
"resolved": "https://registry.npmjs.org/libpgs/-/libpgs-0.8.0.tgz",
"integrity": "sha512-YpmcQYP177j08Vd0zEORgtdHsdPLGF8FCL152DgTQg2txLx1ndjgNOJ1n0217ap5rFV8riTugzjM9sqPrT1e5Q=="
},
"lie": {
"version": "3.1.1",

View File

@ -106,7 +106,7 @@
"jquery": "3.7.1",
"jstree": "3.3.17",
"libarchive.js": "2.0.2",
"libpgs": "0.6.0",
"libpgs": "0.8.0",
"lodash-es": "4.17.21",
"markdown-it": "14.1.0",
"material-design-icons-iconfont": "6.7.0",

View File

@ -1339,7 +1339,8 @@ export class HtmlVideoPlayer {
video: videoElement,
subUrl: getTextTrackUrl(track, item),
workerUrl: `${appRouter.baseUrl()}/libraries/libpgs.worker.js`,
timeOffset: (this._currentPlayOptions.transcodingOffsetTicks || 0) / 10000000
timeOffset: (this._currentPlayOptions.transcodingOffsetTicks || 0) / 10000000,
aspectRatio: this._currentAspectRatio === 'auto' ? 'contain' : this._currentAspectRatio
};
this.#currentPgsRenderer = new libpgs.PgsRenderer(options);
});
@ -2089,6 +2090,14 @@ export class HtmlVideoPlayer {
mediaElement.style['object-fit'] = val;
}
}
const pgsRenderer = this.#currentPgsRenderer;
if (pgsRenderer) {
if (val === 'auto') {
pgsRenderer.aspectRatio = 'contain';
} else {
pgsRenderer.aspectRatio = val;
}
}
this._currentAspectRatio = val;
}