mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-11-22 16:46:10 -08:00
feat(subtitles): generate Japanese subtitles during Jellyfin playback (#294)
* feat(subtitles): generate Japanese subtitles during Jellyfin playback - Read the item's original file via toJellyfinOriginalStreamUrl and write output to a temp dir - Transcoded playback uses Jellyfin's audio index and only external references - Show Jellyfin media by title and redact URL tokens in subprocess errors - Update overlay copy, docs, and changelog fragment * fix(subtitles): redact full stream tokens and reuse one Jellyfin output folder * test(subtitles): make Jellyfin output path assertions platform-neutral - Compare dirname/basename via node:path instead of POSIX-only regexes - Assert the full sub-add command uses the generated output path
This commit is contained in:
1 parent
7909fcd2cf
commit
bf4e5bb609
14 files changed
+295
-25
No files matched your search
+12
@@ -310,6 +310,7 @@ import {
|
||||
replayCurrentSubtitleRuntime,
|
||||
resolveSanitizedSubtitleSeekCommand,
|
||||
resolveJellyfinPlaybackPlanRuntime,
|
||||
toJellyfinOriginalStreamUrl,
|
||||
runStartupBootstrapRuntime,
|
||||
saveSubtitlePosition as saveSubtitlePositionCore,
|
||||
clearYomitanParserCachesForWindow,
|
||||
@@ -6723,6 +6724,17 @@ const subtitleGenerationRuntime = createSubtitleGenerationRuntime({
|
||||
}),
|
||||
resolveYoutubeSourceUrl: (mediaPath) =>
|
||||
youtubePlaybackRuntime.getYoutubeSourceUrlForStream(mediaPath),
|
||||
resolveJellyfinMedia: (mediaPath) => {
|
||||
const playback = activeJellyfinRemotePlayback;
|
||||
const sourceUrl = playback && toJellyfinOriginalStreamUrl(mediaPath, playback.itemId);
|
||||
return sourceUrl
|
||||
? {
|
||||
sourceUrl,
|
||||
transcoded: playback.playMethod === 'Transcode',
|
||||
audioStreamIndex: playback.audioStreamIndex ?? null,
|
||||
}
|
||||
: null;
|
||||
},
|
||||
getMpvClient: () => appState.mpvClient,
|
||||
onProgress: (progress) => {
|
||||
for (const window of [overlayManager.getMainWindow(), overlayManager.getModalWindow()]) {
|
||||
|
||||
Reference in new issue
Block a user