so here is my script to loop through specific video extensions » add a manual profile » generate necessary *.bat & finally a final 'loader' batch file to execute previous *.bat files sequentially & necessary logging (this gives quiet a deal of freedom if you so want)
Now the above code which is fairly easy to understand (bcz its written by a noob) run perfectly & create necessary files. For instance one of the file1.bat looks like this:Code:::== :: gets lines into vars c1 v2 v... @echo off :: user input required cd /d "d:\Trainers\out\" setLocal EnableDelayedExpansion dir /B /O:N | findstr ".wmv$ " >filename.txt echo. >log.txt :: user input required for /f "tokens=* delims= " %%a in ('type filename.txt ^|findstr ".wmv$"') do ( set /a n+=1 echo. >file!n!.bat set in=%in%%%a :: user input required set out=!in:.wmv=.mp4! :: user input required set v=x264 --crf 23 --level 3.1 --tune film -o "d:\Trainers\out\!in!" "d:\Trainers\out\!out!" echo. !v!>file!n!.bat ) dir /B /O:N | findstr ".bat$ " >x264_home.txt for /f "tokens=* delims= " %%a in (x264_home.txt) do ( set /a n+=1 :: mtee is an external library Google it set "z=call %%a | mtee /d/c/t/+ log.txt" echo. !z! >> x264_home.bat ) echo. @echo off > newFile.bat type x264_home.bat >> newFile.bat type newFile.bat > x264_home.bat del newFile.bat,x264_home.txt,filename.txt echo. pause >> x264_home.bat echo. @echo All Operation done... >> x264_home.bat :: user input required move "d:\Trainers\out\*.bat" "d:\Program Files\x264_auto\test\" :: user input required move "d:\Trainers\out\log.txt" "d:\Program Files\x264_auto\test\" ::==
...& the loader .bat file looks likeCode:x264 --crf 23 --level 3.1 --tune film --preset veryslow --deblock -2:-1 --zones 24233,25324,q=20 --acodec aac --abitrate 80 -o "d:\Trainers\out\1.wmv" "d:\Trainers\out\1.mp4"
You see this is a quiet flexible approach in that you can change filestr » set another loop » set another profileCode:@echo off call file1.bat | mtee /d/c/t/+ log.txt call file2.bat | mtee /d/c/t/+ log.txt call file3.bat | mtee /d/c/t/+ log.txt @echo All Operation done...
I am successful because there is no error in any output ...but its the x264.exe (provider/compiler x264GUI) throws error which it otherwise don't?
its the x264 thats the culprit perhaps a senior guide is required hereCode:d:\Program Files\x264_auto\test>x264 --crf 23 --level 3.1 --tune film --preset veryslow --deblock -2:-1 --zones 24233,25324,q=20 --acodec aac --abitrate 80 -o "d:\Trainers\out\1.wmv" "d:\Trainers\out\1.mp4" ffms [error]: could not create index lavf [error]: could not open input file raw [error]: raw input requires a resolution. x264 [error]: could not open input file `d:\Trainers\out\1.mp4' via any method!
+ Reply to Thread
Results 1 to 3 of 3
-
-
--abitrate --acodec --o WMV
I may not have the latest build but the version that I have doesn't like any of those option.Last edited by jagabo; 23rd Oct 2012 at 06:45.
-
Ok the problem has been resolved & am successful at getting automation sequence. More details here:
http://khanzmusing.blogspot.com/2012/10/automating-sequencing-logging-beauty-of.html
Similar Threads
-
[C++] How to read progress from CMD prompts like FFMPEG's
By squadjot in forum ProgrammingReplies: 5Last Post: 12th Feb 2021, 06:49 -
questions about MCTemporalDenoise (nOObs encouraged to read)
By unclescoob in forum RestorationReplies: 24Last Post: 2nd Mar 2012, 12:28 -
Using ffmped cmd line to create WinFF preset
By Yaro in forum Video ConversionReplies: 0Last Post: 18th Jul 2011, 15:33 -
how to run as admin in CMD in Windows XP?
By jyeh74 in forum Newbie / General discussionsReplies: 7Last Post: 29th Jan 2010, 18:26 -
wildcards in cmd
By cL0N31 in forum ComputerReplies: 6Last Post: 3rd Apr 2009, 20:58