Closed kumarkrish85 closed 11 months ago
What happens when you execute the above ffmpeg command from command line?
I can successfully execute the ffmpeg command from command line and see the mp4 file with audio. The ffmpeg exes are saved inside C: folders.
cc: @kokorin
Configure Jaffree (FFmpeg#setLogLevel
) and log framework you use to print debug logs and post logs here.
P.S. One should start with checking debug logs before creating issues
Thanks @kokorin
Below are the exception after enabling logger.
15:29:37.603 [StdErr] ERROR com.github.kokorin.jaffree.process.BaseStdReader - [out#0/mp4 @ 0000023e51e49ec0] [fatal] Error opening output C:\twatme.mp4: Permission denied 15:29:37.620 [StdErr] ERROR com.github.kokorin.jaffree.process.BaseStdReader - [error] Error opening output file C:\twatme.mp4. 15:29:37.620 [StdErr] ERROR com.github.kokorin.jaffree.process.BaseStdReader - [fatal] Error opening output files: Permission denied Exception in thread "main" com.github.kokorin.jaffree.process.JaffreeAbnormalExitException: Process execution has ended with non-zero status: -13. Check logs for detailed error message. at com.github.kokorin.jaffree.process.ProcessHandler.interactWithProcess(ProcessHandler.java:220) at com.github.kokorin.jaffree.process.ProcessHandler.execute(ProcessHandler.java:162) at com.github.kokorin.jaffree.ffmpeg.FFmpeg.execute(FFmpeg.java:421) at org.example.Main.main(Main.java:40)
And logs clearly show that the user which runs JVM has no permissions to create C:\twatme.mp4
Thanks @kokorin i tried inside the folder where I have complete permission, it worked. Thanks for your help.
Describe the issue I am trying to perform screen recording along with audio and save the file as .mp4, i have installed ffmpeg and added in the system path, i can execute the ffmpeg command from any windows path. But while executing it from the example code i am getting an error.
To Reproduce Steps to reproduce the behavior:
Sample file If applicable, attach a file with which the issue can be reproduced
Expected behavior A clear and concise description of what you expected to happen.
Logs
ffmpeg -hide_banner -loglevel error -f dshow -i audio="@device_cm_{33D9A762-90C8-11D0-BD43-00A0C911CE86}\wave_{C96EF9E4-FF73-4008-97E1-01F0015E368B}" -f gdigrab -framerate 30 -i desktop -c:v libx264 %video_file_name%".mp4"
exception from the java console:
Exception in thread "main" com.github.kokorin.jaffree.process.JaffreeAbnormalExitException: Process execution has ended with non-zero status: -13. Check logs for detailed error message. at com.github.kokorin.jaffree.process.ProcessHandler.interactWithProcess(ProcessHandler.java:220) at com.github.kokorin.jaffree.process.ProcessHandler.execute(ProcessHandler.java:162) at com.github.kokorin.jaffree.ffmpeg.FFmpeg.execute(FFmpeg.java:421)
please help @kokorin
Additional context Windows using gdigrab