I have searched a few sites and haven't found a solution. I hope this question not to come off as a duplicate.
I have the following files in the same folder:
FFMPEG.exe (32-bit version)
Asia17.avi (Video codec hffyuv, audio codec PCM)
Test.bat
Test.avs (Avisynth script file)
------------------------------------------------
The text within the Test.bat file is:
ffmpeg -i "TEST.AVS" -acodec flac -vcodec ffv1 -level 3 -threads 8 -coder 1 -context 1 -g 1 -slices 24 -slicecrc 1 -color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m output.mkv
When I run the Test.bat file, I don't get any error message, but the FFMPEG does not proceed further. Please see the attached pictures.
I'd like to just get the 28gb uncompressed AVI file to be compressed using lossless codecs. I don't have any specific desire to convert the uncompressed files into ".mkv", ".avi" or ".mp4". I'm pleased with any extension as long as the content is not lost during compression and the file size is smaller.
I'm looking forwards to receiving helpful tips or any advice from "pioneers".
Thank you for your time reading.
[Attachment 53424 - Click to enlarge]
+ Reply to Thread
Results 1 to 30 of 44
-
-
Are you trying to learn FFmpeg/batch processing or are you trying to compress your file?
If it's to compress the file, use Virtualdub2. Open the source, video/compression set the output codec.
Audio/full processing/compression set output codec.
to troubleshoot the batch file, first make sure the command works outside of the batch file
by copy and pasting it into the command window -
Why are you using avisynth ? Post the .avs script . Verify that the .avs script is valid (preview it in vdub2 or mpchc)
If you're not doing any additional processing with avisynth, why not compress the file directly ? (skip avisynth entirely)
If Asia17.avi already uses huffyuv, that's already using lossless compression. ie. it's not uncompressed
-g 1 -
1) check your test.avs with virtualdub2. If it's open fine without issues and show your video then test.avs is ok.
2) If test.avs is ok you should try to encode video only with your commandline (without audio):
ffmpeg -i "TEST.AVS" -vcodec ffv1 -level 3 -threads 8 -coder 1 -context 1 -g 1 -slices 24 -slicecrc 1 -color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m output.mkv
Audio can be elaborated later. -
-
I did some post-processing in the Avisynth such as resizing, cropping, deinterlacing with QTGMC...etc.
Here is my Avisynth script:
SetFilterMTMode("QTGMC",2)
FFmpegSource2("asia17A.avi", atrack=1)
ConvertToYV12(interlaced=true)
AssumeTFF()
QTGMC(Preset="medium",Edithreads=2)
BilinearResize(720,540)
Crop(0,0,0,-6)
Spline16Resize(720,540)
Prefetch(10)
Yes, the Hffyuv is a lossless compression. However, I need to apply post-processing filters to make it better. I try to open the script with Virtualdub 1.9.1.1 but it fails. -
-
[Attachment 53431 - Click to enlarge] I placed everything in the program file (x86) folder. And here is the error message. -
Virtualdub does not recognize the "test.avs" file I created. I clicked on "run script" in Virtualdub, then I searched for the "test.avs" file, but then I don't see the "test.avs" file anywhere through VirtualDub. I had to, in the dropdown list, click on "All Files (*.*) to be able to see the "test.avs" but then it fails to load the script file. The error message I attached in here too.
-
-
[Attachment 53432 - Click to enlarge] I have verified that FFMPEG has been successfully installed in the system. I don't know why I got this error message. -
-
[Attachment 53433 - Click to enlarge] Here is the picture showing components inside my Avisynth+ folder. I have the ffms2.dll you just mentioned. -
-
Thank you, guys!! I literally had to uninstall everything (AVIsynth, Virtualdub) and reinstalled them to make it work. I finally got it to work.
May I ask if you guys have ever compressed uncompressed 10-bit MOV files to lossless AVI HUFFYUV using FFMPEG batch files? -
-
I did not know that. Thank you for telling me. Right now I have uncompressed 10-bit MOV files that are huge in size. If I want to compress them using lossless codecs with the FFMPEG command line, can you take a look at this command line and correct it if it's written wrong? I'd appreciate your help.
for %%a in ("*.mov") do ffmpeg -i "%%a" -vcodec ffv1 -c:v libx264 -preset slow -crf 0 -c:a flac -b:a 256k "output.mkv" -
You have 2 codecs specified (ffv1 and libx264), and for flac audio you do not need to specify a bitrate
You need to change the output name, otherwise the batch will overwrite "output.mkv" each time
For ffmpeg libx264 you need to specify the pixel format used for the encoding, what kind of MOV is it ? 10bit RGB, 10bit422 YUV ?
Otherwise you can use ffv1 instead, and it will automatically pick the source pixel format
Code:for %%a in ("*.mov") do ffmpeg -i "%%a" -pix_fmt xxxxx -c:v libx264 -preset slow -crf 0 -c:a flac "%%~na.mkv"
Code:for %%a in ("*.mov") do ffmpeg -i "%%a"-c:v ffv1 -c:a flac "%%~na.mkv"
-
-
Then you would use -pix_fmt yuv422p10le
You can confirm with ffmpeg -i input.mov for one of the input files and read the console. It should say "v210" and yuv422p10le
(old versions of ffmpeg would default to 8bit 4:2:0 encoding for libx264 if you did not include -pix_fmt; but it looks like you do not need to include -pix_fmt yuv422p10le for newer versions; but it doesn't hurt to include it ) -
Thank you so much. I successfully converted one MOV files into MKV files. By the way, I'm also trying to convert these 10-bit 422YUV files into MPEG-2 DVDs. Could you suggest a command line for such a task? All my captured MOV files have a resolution of 720x486. I'm trying to convert them to DVDs with specifications as followed:
9800kb/s for video bitrates.
AC-3 PCM
About the 8/10 bit, I'm not sure if a DVD can take 10-bit 422 as most DVDs that I inspected are 8-bit YUV 420 Planar. I'm looking forwards to being taught/guided on this, because this may be my final format that I am going to stick to. I appreciate your time a lot. -
MPEG2 for DVD is 8bit 4:2:0 only
NTSC DVD cannot take 486 height, you'd have to crop or resize to 720x480
Are these interlaced contents ? Such as home video ? Or something else like a film/movie or TV series ?
If it was progressive content , such as film, ffmpeg 's mpeg2 encoder cannot add soft pulldown
And FFmpeg's mpeg2 encoder is not very good , I'd avoid this scenario for DVD -
That probably won't work. 9800 max? Or average? Or are you planning on a Constant BitRate? Unless the videos are short (less than an hour, maybe), CBR's not a good idea. AC-3 PCM? You'd better have a look at What Is DVD.
Total bitrate including video, audio and subs can be max 10.08 Mbit/s (10080 Kbit/s) -
My tapes are retail tapes. They are movies/Television series. I don't have homemade videos.
The reason I'm asking for this is that i purchased professionally produced DVDs (retail DVDs) and I compared their picture quality with my raw uncompressed MOV files. I notice my uncompressed MOv files quality = their retail DVDs. Then I assume they muat have w way to convert these files to dvds. I also notice their video bitrates are super high: 9500/9800 kbs. Even the best DVD RECORDER LIKE JVC and TOSHIBA XS34...can't obtain this high bitrate. I can upload a portion of their retail DVD so you can see their quality vs my uncompressed Mov files. Other tha Ffmpeg, would you recommend any other programs that could create high quality DVDs? Please advise me. Thank you. -
AC-3 is the compliant audio format for DVDs If I'm correct. I meant AC-3 not the AC3 PCM, my bad. Please see the attached picture. For DVDs. VBR is recommended, I believe. Not constant bitrate.
[Attachment 53620 - Click to enlarge]
Similar Threads
-
AviSynth scripts always output GREEN SCREEN
By rilopes64 in forum Newbie / General discussionsReplies: 0Last Post: 11th Dec 2019, 06:39 -
Does Video Fred's AviSynth scripts work on Windows 10?
By Meloware in forum Video ConversionReplies: 9Last Post: 16th Dec 2018, 21:38 -
how to tell to Avisynth ---> AUDIO NONE = - an of FFMPEG?
By marcorocchini in forum Newbie / General discussionsReplies: 3Last Post: 9th Aug 2017, 10:02 -
AVISynth scripts not opening in Virtual Dub
By bvdd in forum Video ConversionReplies: 46Last Post: 10th Jan 2016, 23:19 -
Need advice for Avisynth scripts to use for Video
By roseofpain in forum Newbie / General discussionsReplies: 6Last Post: 22nd Jul 2015, 02:15