Fix info for mp4

This commit is contained in:
niksedk 2021-09-03 12:56:58 +02:00
parent 3f9b5641cb
commit c9f69c8fcd
2 changed files with 3 additions and 1 deletions

View File

@ -525,6 +525,8 @@ namespace Nikse.SubtitleEdit.Core.Common
info.Width = mp4Parser.VideoResolution.X;
info.Height = mp4Parser.VideoResolution.Y;
info.TotalMilliseconds = mp4Parser.Duration.TotalSeconds * 1000;
info.TotalSeconds = info.TotalMilliseconds / 1000.0;
info.TotalFrames = mp4Parser.FrameRate * info.TotalSeconds;
info.VideoCodec = "MP4";
info.FramesPerSecond = mp4Parser.FrameRate;
info.Success = true;

View File

@ -91,7 +91,7 @@ namespace Nikse.SubtitleEdit.Logic
StartInfo =
{
FileName = ffmpegLocation,
Arguments = $"-i \"{inputVideoFileName}\" -vf \"ass={Path.GetFileName(assaSubtitleFileName)}\",yadif,format=yuv420p -bf 2 -strict -2 -s {width}x{height} \"{outputVideoFileName}\" -c:v {videoEnding} -preset {preset} -crf {crf} {audioSettings}",
Arguments = $"-i \"{inputVideoFileName}\" -vf \"ass={Path.GetFileName(assaSubtitleFileName)}\",yadif,format=yuv420p -g 30 -bf 2 -strict -2 -s {width}x{height} \"{outputVideoFileName}\" -c:v {videoEnding} -preset {preset} -crf {crf} {audioSettings} -use_editlist 0 -movflags +faststart",
UseShellExecute = false,
CreateNoWindow = true,
WorkingDirectory = Path.GetDirectoryName(assaSubtitleFileName),