Skip to content

Commit

Permalink
fix: typo func ClaerTempFile
Browse files Browse the repository at this point in the history
  • Loading branch information
Tohrusky committed Jan 4, 2025
1 parent 695938b commit 41d77bb
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions module/ffmpeg/merge.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ func MergeVideo(originPath string, inputFiles []string, outputPath string) error
func ReMuxWithSourceVideo(originPath string, outputPath string, concatOutputPath string) error {
// Define the different codec combinations to try
codecCombinations := [][]string{
// Try copying both audio and subtitles
{
"-map", "1:v:0",
"-map", "0:a",
Expand All @@ -85,7 +86,8 @@ func ReMuxWithSourceVideo(originPath string, outputPath string, concatOutputPath
"-c:a", "copy",
"-c:s", "copy",
"-max_interleave_delta", "0",
}, // Try copying both audio and subtitles
},
// Try FLAC for audio and copy subtitles
{
"-map", "1:v:0",
"-map", "0:a",
Expand All @@ -95,23 +97,25 @@ func ReMuxWithSourceVideo(originPath string, outputPath string, concatOutputPath
"-c:a", "flac",
"-c:s", "copy",
"-max_interleave_delta", "0",
}, // Try FLAC for audio and copy subtitles
},
// Try copying only audio
{
"-map", "1:v:0",
"-map", "0:a",
"-disposition:v:0", "default",
"-c:v", "copy",
"-c:a", "copy",
"-max_interleave_delta", "0",
}, // Try copying only audio
},
// Try FLAC for audio only
{
"-map", "1:v:0",
"-map", "0:a",
"-disposition:v:0", "default",
"-c:v", "copy",
"-c:a", "flac",
"-max_interleave_delta", "0",
}, // Try FLAC for audio only
},
}

// Iterate over each codec combination
Expand Down

0 comments on commit 41d77bb

Please sign in to comment.