You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am getting a System.ComponentModel.Win32Exception (0x80004005): The specified executable is not a valid application for this OS platform exception doing a FFmpeg.Conversions.FromSnippet.Split only when the FFmpeg.SetExecutablesPath is set to a different path then where I extracted the FFmpeg files from the .zip file.
I added ffmpeg.exe and ffprobe.exe to my project folder, added the files to my project and have them set to Copy always. I am trying to use them from the assembly location (the files are in the assembly location).
This is the entire exception:
System.ComponentModel.Win32Exception (0x80004005): The specified executable is not a valid application for this OS platform.
at System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startInfo)
at System.Diagnostics.Process.Start()
at Xabe.FFmpeg.FFmpeg.RunProcess(String args, String processPath, Nullable1 priority, Boolean standardInput, Boolean standardOutput, Boolean standardError) at Xabe.FFmpeg.FFmpegWrapper.<>c__DisplayClass14_0.<RunProcess>b__0() at System.Threading.Tasks.Task1.InnerInvoke()
at System.Threading.Tasks.Task.Execute()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Xabe.FFmpeg.Conversion.d__35.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
This is how I am setting the executable path when the exception happens:
FFmpeg.SetExecutablesPath(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location));
I added a line in my log to get FFmpeg's executable path _logger.DebugFormat("FFmpeg exe path {0}", FFmpeg.ExecutablesPath);
And that displays what appears to be a valid path
FFmpeg exe path C:\Development<solution name>\bin\x86\Debug
Should I be using more FFmpeg files in my project?
My project is a WinForms app using .NET Framework 4.8 and Xabe.FFmpeg 5.2.6.
Thanks
The text was updated successfully, but these errors were encountered:
I am getting a System.ComponentModel.Win32Exception (0x80004005): The specified executable is not a valid application for this OS platform exception doing a FFmpeg.Conversions.FromSnippet.Split only when the FFmpeg.SetExecutablesPath is set to a different path then where I extracted the FFmpeg files from the .zip file.
I added ffmpeg.exe and ffprobe.exe to my project folder, added the files to my project and have them set to Copy always. I am trying to use them from the assembly location (the files are in the assembly location).
This is the entire exception:
System.ComponentModel.Win32Exception (0x80004005): The specified executable is not a valid application for this OS platform.
at System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startInfo)
at System.Diagnostics.Process.Start()
at Xabe.FFmpeg.FFmpeg.RunProcess(String args, String processPath, Nullable
1 priority, Boolean standardInput, Boolean standardOutput, Boolean standardError) at Xabe.FFmpeg.FFmpegWrapper.<>c__DisplayClass14_0.<RunProcess>b__0() at System.Threading.Tasks.Task
1.InnerInvoke()at System.Threading.Tasks.Task.Execute()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Xabe.FFmpeg.Conversion.d__35.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
This is how I am setting the executable path when the exception happens:
FFmpeg.SetExecutablesPath(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location));
I added a line in my log to get FFmpeg's executable path _logger.DebugFormat("FFmpeg exe path {0}", FFmpeg.ExecutablesPath);
And that displays what appears to be a valid path
FFmpeg exe path C:\Development<solution name>\bin\x86\Debug
Should I be using more FFmpeg files in my project?
My project is a WinForms app using .NET Framework 4.8 and Xabe.FFmpeg 5.2.6.
Thanks
The text was updated successfully, but these errors were encountered: