VideoHelp Forum
+ Reply to Thread
Page 12 of 16
FirstFirst ... 2 10 11 12 13 14 ... LastLast
Results 331 to 360 of 457
Thread
  1. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    For AviGain, do the dropdown numbers map to sample rates like 3=128k or if not, how does that work?
    I tried looking for documentation in different versions, but I didn't see any.

    Thanks.
    Quote Quote  
  2. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    This is what is currently in the works.

    Click image for larger version

Name:	y9km.png
Views:	795
Size:	30.7 KB
ID:	20478

    Preserving the FourCC of the video codec...will be done behind the scenes...no reason to expose that.

    The audio stream can be preserved...but then no gain will be applied at this time...I might get around to adding meta tag support. However using LAME to encode to MP3 will be available.

    I may look into wave compression later down the road...got a lot I'm trying to stuff into this release already.

    HardSub's will be in this release, if possible...I don't care for them but my cousin has been bugging the shit out of me for a year now about it...so I'm giving in.

    From what I understand it's possible to hardsub sub/idx files...this probably won't make it in this release by probably soon afterwards if things don't blow up all over the place.

    The only thing planned for that I have questions about is my down mixing of audio streams. As it's the only thing that I dont' have working sample code already written for.

    As for custom volume levels...that just seems like I'd be adding to the problem rather than trying to resolve it. I'll give it some thought...but expect it to be like what my cousin went through to finally get me to do hardsubs.

    Maybe I could add it as an INI option...for those wanting to tweak stuff...course editing the source isn't any harder....if you know where to look that is. Which you do now.

    Yeah I need to figure out how to get that sexy little lady over here.

    However that will likely never happen...as there was a miss understanding a few years back. I woke up to some guy ramming his car into their garage door...I got my gun and tried to stop him...but he fled and I wasn't going to open fire when no one was hurt...in a neighborhood filled with kids. Anyways somehow her older brothers girlfriend got it into her head that the guy who was smashing up their house was one of my friends.

    You know that saying....no good deed goes unpunished.
    Quote Quote  
  3. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    In AVI Gain this is what the MP3 values mean.
    [Linky]
    Quote Quote  
  4. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    What Gain options will be included? I really like the way "level.exe" works. Can you incorporate this or something very similar? I'd like to keep the screaming car chases and the quiet spoken voices the same or nearly the same volume so I don't have to keep turning my amp volume up and down. That really p*sses me off.
    Quote Quote  
  5. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Originally just baseline Replay Gain & R128 re-encodes...but it's looking like adding Tag versions of those won't be hard to drop in at present.

    I'm not a fan of how level.exe does things...but I could add it as well...but I do hope it's use will be limited to ones own personal library...and not show up on YouTube and the like for public consumption.

    It's still going to be a while however...the code is nearly doubled in size...and I still have to finish plugging some stuff in...HardSubs, and detecting the language of embeded subs...mainly.

    Right now I'm mainly cleaning up the code to make it easier to add more stuff in the future.

    However I'm getting rather carried away from what the original goals of the app...which was to simply be a GUI for Soopafresh's method of getting acceptable volume out of videos.
    Quote Quote  
  6. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Okay right now I'm toying around with mimicking a feature done in Belini's fork...that is an Alternate Path for the final encode.

    Right now I have code that tries to grab two folder path depth to the original video...to append to the alternate path...to help keep things semi organized.

    The question is...should I do it this way...or just trim the drive value off...and append everything else...which could make things rather deep.

    Examples:
    C:\Users\Foo\Downloads\YouTube\Funny Video's\Fight for kisses.mp4
    C:\TV Shows\House (2004)\Season 01\01x01 - Pilot.mp4
    C:\House (2004)\Season 01\01x01 - Pilot.mp4
    C:\Movies\5 Days of War (2011).mp4
    C:\5 Days of War (2011).mp4

    <Destination>\YouTube\Funny Video's\
    <Destination>\House (2004)\Season 01\
    <Destination>\House (2004)\Season 01\
    <Destination>\Movies\
    <Destination>\

    Or

    <Destination>\Users\Foo\Downloads\YouTube\Funny Video's\
    <Destination>\TV Shows\House (2004)\Season 01\
    <Destination>\House (2004)\Season 01\
    <Destination>\Movies\
    <Destination>\
    Quote Quote  
  7. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Originally Posted by Nologic View Post
    Originally just baseline Replay Gain & R128 re-encodes...but it's looking like adding Tag versions of those won't be hard to drop in at present.

    I'm not a fan of how level.exe does things...but I could add it as well...but I do hope it's use will be limited to ones own personal library...and not show up on YouTube and the like for public consumption.

    It's still going to be a while however...the code is nearly doubled in size...and I still have to finish plugging some stuff in...HardSubs, and detecting the language of embeded subs...mainly.

    Right now I'm mainly cleaning up the code to make it easier to add more stuff in the future.

    However I'm getting rather carried away from what the original goals of the app...which was to simply be a GUI for Soopafresh's method of getting acceptable volume out of videos.
    I only use level.exe for my own personal use.

    I'm not highly edumacated in how these different programs modify the audio and what their directives are. It seems like everyone has a different definition of "normalizing" audio. It gets very confusing.
    Maybe you could tell me why you don't like level.exe and what it does or doesn't do compared to other methods?

    I just want something to keep the extreme volume changes between car chases and people talking in an office to a minimum so I don't have to play with my amp volume all the time, and will also raise total volume of audio if necessary so I don't have to turn my amp up so high to hear the audio that I hear hissing from the speakers.

    If there is something other than level.exe that does that just as well then I'd consider using that.

    I don't think adding level.exe would be hard at all. Heck, probably just another 2 lines of code.

    Thanks for being cool about all this stuff.
    Quote Quote  
  8. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    I basically don't like it because it does like what you stated...I personally think there should be a difference between two folks whispering sweet nothings...and a howitzer firing off a round.

    However I also get it when the loud parts are over done and try to shatter your windows. This generally is because of a bad downmix to stereo from AC3...that said I've also seen where the audio engineer simply got out of hand when mixing originally.

    Now at some point I intend to add support for Stereo Tool which would allow some fairly advanced audio scripting to be done.

    Course I might also add support for Sox which would give some options as well....anyways we'll see what ends up happening...I got a fair amount on my plate right now.
    Quote Quote  
  9. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    @ Fonzo -


    Okay level.exe is the old command line console version of Levelator ...so I guess company name changed at some point...or someone else provided the level.exe.

    However the DLL can be updated which is found here ....it will need to be renamed...but seems to function just fine.

    Right now I have yet to figure out how to pipe from FFMpeg to Levelator correctly...let alone pipe from Levelator to something else. This is bad news...as it means a lot of hard drive space will be utilized during conversions. Plus likely take longer...but speed isn't my main concern...working correctly is.

    Anyways if you find any information on this PLEASE forward it to me. As it makes adding this far more likely in the near term.
    Last edited by Nologic; 25th Oct 2013 at 18:38.
    Quote Quote  
  10. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Originally Posted by Nologic View Post
    Okay right now I'm toying around with mimicking a feature done in Belini's fork...that is an Alternate Path for the final encode.

    Right now I have code that tries to grab two folder path depth to the original video...to append to the alternate path...to help keep things semi organized.

    The question is...should I do it this way...or just trim the drive value off...and append everything else...which could make things rather deep.

    Examples:
    C:\Users\Foo\Downloads\YouTube\Funny Video's\Fight for kisses.mp4
    C:\TV Shows\House (2004)\Season 01\01x01 - Pilot.mp4
    C:\House (2004)\Season 01\01x01 - Pilot.mp4
    C:\Movies\5 Days of War (2011).mp4
    C:\5 Days of War (2011).mp4

    <Destination>\YouTube\Funny Video's\
    <Destination>\House (2004)\Season 01\
    <Destination>\House (2004)\Season 01\
    <Destination>\Movies\
    <Destination>\

    Or

    <Destination>\Users\Foo\Downloads\YouTube\Funny Video's\
    <Destination>\TV Shows\House (2004)\Season 01\
    <Destination>\House (2004)\Season 01\
    <Destination>\Movies\
    <Destination>\
    My vote would be to default to the same chosen source directory, or send it to the exactly chosen/specified destination directory(if that option is available). I personally wouldn't want to choose a dest dir and end up having to drill down added directories to get to the outputted file. I'd end up having to move the outputted files back up the structure to where I wanted them in the first place.
    Or, when choosing a dest dir, open a window which would also allow the creation of folders and then you could create subfolders if you wanted as your chosen dest.
    Just my 2 cents.
    Quote Quote  
  11. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Originally Posted by Nologic View Post
    I honestly don't recall...my best guess is that normalize.exe does sound compression thus changing the wave form...making nearly all things equally load...then level.exe applies gain to it....thus upping the volume.

    It's been a few years since I toyed with the original batch scripts...and like you I went looking for software updates...one thing lead to another...
    I tried eliminating the "normalize.exe" step in the batch file and only use level.exe and it seemed to both level and increase overall volume. Although I may not have been lickin right.

    With no documentation, it's hard to tell exactly what it does for sure. Maybe I need to test it with highly variable sound level samples to make sure.

    UPDATE: I did some testing and it seems to do both leveling and increasing volume if my ears are working right.
    Last edited by fonzo; 26th Oct 2013 at 16:41. Reason: Updated for testing results
    Quote Quote  
  12. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Originally Posted by Nologic View Post
    @ Fonzo -


    Okay level.exe is the old command line console version of Levelator ...so I guess company name changed at some point...or someone else provided the level.exe.

    However the DLL can be updated which is found here ....it will need to be renamed...but seems to function just fine.

    Right now I have yet to figure out how to pipe from FFMpeg to Levelator correctly...let alone pipe from Levelator to something else. This is bad news...as it means a lot of hard drive space will be utilized during conversions. Plus likely take longer...but speed isn't my main concern...working correctly is.

    Anyways if you find any information on this PLEASE forward it to me. As it makes adding this far more likely in the near term.
    Ok, I'll use the updated dll file, although I'm not sure how much that will really "update" the way or how level.exe works. I tried updating all the programs Soopafresh's scripts use including the, I believe, newest version of ffmpeg(which needed quite a few more files for it to run). Everything except ffmpeg worked fine. ffmpeg kept giving me errors about the mp3 file and would cause the gain to bomb and not complete. I went back to using Soopafresh's version and it worked fine. Strange...

    Regarding incorporating level.exe as a gain, can't you using ffmpeg to write the audio track as a wave file, level.exe it, and then use ffmpeg to reencode to mp3 and then merge?
    I follows the same ideas as the soopafresh scripts.
    Since you only process 1 video file at a time, this shouldn't take up that much extra space and would definitely work correctly.
    Doesn't piping it from one program to another still require some hard drive space somewhere by the OS or can it do all of it in memory?

    BTW, it would be nice as well to use the source dir and create a temp dir inside of it to do the work similar to the scripts. Then people could make sure their source dir partition had lots of space and was a fast drive [rotation speed + cache] (if they have more than 1.) This would give the option of choosing a different partition than C or a different drive entirely for all of the work/processing, or using drive C if you so choose or only have 1 drive 1 partition.

    I like to keep my OS partition separate from my apps and data partitions and don't like using it for temp space as I try to keep it from getting boated.
    It would also give people a chance to watch what is actually happening while the program is running if they so choose, like Soopafresh scripts, without having to hunt down the temp dir that is being used, like I did.

    Also, my buddy has a huge arse tv and we compared watching the same avi file from flash drive plugged directly in the the tv, played from laptop to tv, and run through his upconvert dvd player. The results were interesting. Running it through the dvd player gave a MUCH better picture quality than via the other methods.

    I don't know if there are any home media centers, game consoles, or anything else that will do that. If there are, will you or anyone else please let me know.

    Thanks.
    Quote Quote  
  13. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    At present the destination folder is completely elective...you still have direct replace option, and also the default complete sub folder.

    So the destination folder at present just tries to mimic the folder structure you have in the source location.

    Far as Levelator you can use the new version...sending it to the Levelator.exe...but it'll output a new file with .output appended to the original name. It'll also show a GUI no matter what...but the GUI will close after the file is done processing.

    Right now I'm using the new version in VideoGain...and I haven't figured out how to hide the GUI...well I can hide it right now but it still flashes for a second before it gets hidden.

    Now the newer version does seem to produce a better audio file compared to the older version...not leaps and bounds better...but noticeable. So for the time being I'll use the newer build...but if the GUI bugs enough people I'll roll back to the older one.

    You are correct when using level.exe there is no need to use Normalize.exe

    Right now I'm still doing ReplayGain\R128 post Levelator...but I may add a option to do just Levelator and forgo further tweaking.

    As for FFMpeg and Soopa's scripts...the newer builds have a largely different command line as well as codec's...so things can still be done the same as Soopa's...but the command lines will need to be adjusted to work correctly.

    As for Piping...it's normally handled all in system memory...and only when there is a lot of pressure is it pushed out to virtual memory (hard drive)...since system memory wears out at a much slower rate...and is also much faster than a hard drive...it's best to Pipe stuff when possible.

    Concerning the Temp folder...at some later point I may add the option to define where it's located...but the video source folder is not always the best location...as it could be a networked drive...which would mean like 4 trips across the network or more rather than two. That said I could certainly see someone with an SSD wanting to make damn good use of it...if its not their OS drive.

    Now keep in mind I'm using the Temp folder defined by the OS...which is typically in your User Account....so if you setup your User Account on a different drive...that should be now where the Temp folder will be.

    So one could in theory make use of a SSD or faster drive...which is not the OS drive...however it's not at all straight forward at present.

    On the subject of Up Converted videos...most modern video players can do Post Processing...which will enhance the look of video playback. So your buddies laptop should have done just as good of a job as that DVD player...keep in mind the laptop needs to have a good enough CPU (not hard these days) and a fairly quick hard drive...as it needs to serve the CPU that data fairly fast...slow transfers can impact video quality. So if that flash drive was USB 2.0 it may not have been quick enough...if it was USB 3...then it certainly was quick enough (or should be)...and the problem is else where.

    Anyways those Android devices I linked to prior should do the trick with playback being done in VLC...and I think XBMC now has post processing as well.

    Click image for larger version

Name:	VideoGain.png
Views:	804
Size:	40.2 KB
ID:	20830
    Quote Quote  
  14. Member Belini's Avatar
    Join Date
    Aug 2011
    Location
    Brazil
    Search Comp PM
    The advantage of having three paths is able to stop and then continue where you left off.

    Source Directory: Where are the files that have not yet been standardized.
    Destination of standard files: Where the files are saved with standardized volume.
    Destination of the original files: Where the original files will be moved after creating the files normalized.
    It would be nice When choosing the dest dir, open a window Also Which would allow the creation of folders, subfolders will be created by the program equal to the source directory and I use this way why have many files to normalize.
    Quote Quote  
  15. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Originally Posted by Belini View Post
    The advantage of having three paths is able to stop and then continue where you left off.

    Source Directory: Where are the files that have not yet been standardized.
    Destination of standard files: Where the files are saved with standardized volume.
    Destination of the original files: Where the original files will be moved after creating the files normalized.
    It would be nice When choosing the dest dir, open a window Also Which would allow the creation of folders, subfolders will be created by the program equal to the source directory and I use this way why have many files to normalize.
    I can see why you might want to use 3 dirs if you are processing many files or have to stop in the middle as long as if you make the source and dest original dirs the same in the program it just bypasses the copy/move step if you'd rather not do it that way. Then you have a choice of using either option.

    However, I DON'T like the idea of the program generating a bunch of directory structures I don't and wouldn't want.
    Maybe if you like it and I don't, it could be a check box option like "copy directory structure" which would allow for both options.
    The code is already there for selecting source directory. You could use that code to choose dest standard and dest original if there are to be 3 directories used and then check "copy directory structure" if you want that done.
    It would give users both options.

    I'm sorry if I misunderstood what you were trying to say, but when you replied to my message and put your message intertwined with mine it got confusing.
    Quote Quote  
  16. Member Belini's Avatar
    Join Date
    Aug 2011
    Location
    Brazil
    Search Comp PM
    If the file is moved from the source directory and stop when further normalization files that have already been normalized will not be listed again.

    Being removed each file from the source directory after creating the normalized copy at the end of the process we will have only 2 directories being an original and one with normalized volume, the source directory will be empty when complete normalization of all files.

    I use this way:
    [spoiler][/spoiler]
    Quote Quote  
  17. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Ok, I see what you are doing, I think...(I don't speak/read Portuguese). In theory it looks good. The only thing I'd worry about is the extra I/O overhead of copying/moving the original files, especially if there are a lot of large ones.
    I would think that would slow down the entire process quite a bit, especially depending upon the speed of the hard drive(s).
    What happens in your program if you make the source dir and "moved source files dir" the same dir?
    Last edited by fonzo; 28th Oct 2013 at 12:11.
    Quote Quote  
  18. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Originally Posted by Nologic View Post

    Far as Levelator you can use the new version...sending it to the Levelator.exe...but it'll output a new file with .output appended to the original name. It'll also show a GUI no matter what...but the GUI will close after the file is done processing.

    Right now I'm using the new version in VideoGain...and I haven't figured out how to hide the GUI...well I can hide it right now but it still flashes for a second before it gets hidden.
    Now the newer version does seem to produce a better audio file compared to the older version...not leaps and bounds better...but noticeable. So for the time being I'll use the newer build...but if the GUI bugs enough people I'll roll back to the older one.

    Right now I'm still doing ReplayGain\R128 post Levelator...but I may add a option to do just Levelator and forgo further tweaking.

    Now keep in mind I'm using the Temp folder defined by the OS...which is typically in your User Account....so if you setup your User Account on a different drive...that should be now where the Temp folder will be.

    On the subject of Up Converted videos...most modern video players can do Post Processing...which will enhance the look of video playback. So your buddies laptop should have done just as good of a job as that DVD player...keep in mind the laptop needs to have a good enough CPU (not hard these days) and a fairly quick hard drive...as it needs to serve the CPU that data fairly fast...slow transfers can impact video quality. So if that flash drive was USB 2.0 it may not have been quick enough...if it was USB 3...then it certainly was quick enough (or should be)...and the problem is else where.
    So if you install Levelator in dir A and your source files are in dir B, how do you make the call to levelator correctly inside a batch file to "levelate" the files in dir A?
    dir A\levelator dir B\filename.wav?

    What is the purpose of doing replaygain after levelator? Doesn't that defeat the purpose of using levelator?

    I could change the temp folder in windoze to point to a different drive, but if that drive goes offline, I wonder what windoze, or your program, would do then?

    That usb drive was probably 2.0, but remember, that same drive was plugged into all the devices, so they all got to read at the same rate.
    The laptop used VLC. I don't know what the tv and dvd player do/use.
    Maybe one day we'll try the laptop with file on HD just to see if there is any difference.

    One thing they should change in VLC is the way you adjust the volume. It's a pain. (sorry, off topic)
    Quote Quote  
  19. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Okay I'm NOT a batch script guru at all. Hehe but I think this will work.

    Levelator from what I could tell seems to be portable...meaning you can just copy the files for the app and have it anywhere...and don't actually have to install it on other systems.

    So this is how I'd do it...I'm certain there are better ways...but I'm writing an AutoIt script to get away from Batch scripts.

    Create a folder call Bin and in it, make two more folders FFMpeg & Levelator...in those sub folders put the files for each of those apps.

    Now create a batch script on the same level as Bin with the following contents:
    Code:
    @Echo Off
    
    If Not Exist .\Temp\ MKDir .\Temp\
    If Not Exist .\Complete\ MKDir .\Complete\
    
    For %%i in (*.avi) Do (
    Del /F /S /Q .\Temp\*.*
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\%%~ni.avi -an -sn -c:v Copy -f AVI .\Temp\%%~ni.avi
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\%%~ni.avi -vn -sn -c:a pcm_s16le -f WAV .\Temp\%%~ni.wav
    Start /Wait ..\Bin\Levelator\Levelator.exe .\Temp\%%~ni.wav
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\%%~ni.output.wav -c:a libmp3lame -q:a 2 -f MP3 .\Temp\%%~ni.mp3
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\Temp\%%~ni.avi -i .\Temp\%%~ni.mp3 -c:v Copy -c:a Copy -f AVI .\Complete\%%~ni.avi
    Del /F /S /Q .\Temp\*.*
    )
    
    RMDir /S /Q .\Temp\
    So you should have something that looks like so:
    .\BatchScript.bat
    .\Bin\FFMpeg\ffmpeg.exe
    .\Bin\FFMpeg\...
    .\Bin\Levelator\Levelator.exe
    .\Bin\Levelator\...

    Now when you want to process a folder full of videos...copy the batch script and the Bin folder inside the folder you wish to process...double click the batch script and go drink some coffee.

    I thought the purpose of Levelator was to make all sounds nearly the same. I personally at this time do not know if Levelator's final volume is the same from audio track to audio track...I'd assume so...but I don't actually know. As I said I'll likely have an entry just for doing this with Levelator.

    My main concession here is that I know some folks have bad down mixes...that is how Levelator got brought in at all...as an attempt to make a bad situation...well less bad...not good...but better.

    So I want to keep everything working off of ether R128 or ReplayGain volume levels...to keep to any sort of standard...and actually R128 is the only real standard being widely adopted. Hence why even using Levelator I rope the volume back in with those two standards.

    Keep in mind this is a bit of hobby code for me...so anything you get far as requests, take as a blessing...there is no obligation on my part to make your wishes come true.

    As for Temp on a different drive going down...I would imagine ether the app would break right away...or worse yet...continue on...even though nothing is really getting done. Honestly it very well could try continuing on...I don't have any code in place to make sure Temp exists...I just assume it does and write to where ever it's located as directed by Windows. Hehe granted writing such code isnt' much more than a line or two...so I guess I should toss it in there...on the off chance Temp goes away for whatever reason.

    ** Update **

    Actually you "may" not need the Start /Wait bit...and you could define where app's are.

    Not sure if it works...but "should".
    Code:
    @Echo Off
    
    set FFMpeg=D:\My Projects\Video Gain\BIN\FFMpeg\ffmpeg.exe
    set Levelator=D:\My Projects\Video Gain\BIN\Levelator\Levelator.exe
    
    If Not Exist .\Temp\ MKDir .\Temp\
    If Not Exist .\Complete\ MKDir .\Complete\
    
    For %%i in (*.avi) Do (
    Del /F /S /Q .\Temp\*.*
    "%FFMpeg%" -i .\%%~ni.avi -an -sn -c:v Copy -f AVI .\Temp\%%~ni.avi
    "%FFMpeg%" -i .\%%~ni.avi -vn -sn -c:a pcm_s16le -f WAV .\Temp\%%~ni.wav
    "%Levelator%" .\Temp\%%~ni.wav
    "%FFMpeg%" -i .\%%~ni.output.wav -c:a libmp3lame -q:a 2 -f MP3 .\Temp\%%~ni.mp3
    "%FFMpeg%" -i .\Temp\%%~ni.avi -i .\Temp\%%~ni.mp3 -c:v Copy -c:a Copy -f AVI .\Complete\%%~ni.avi
    Del /F /S /Q .\Temp\*.*
    )
    
    RMDir /S /Q .\Temp\
    If that code works as expected...all you would then need to do is copy the batch script to where your videos are.
    Last edited by Nologic; 28th Oct 2013 at 15:56.
    Quote Quote  
  20. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Well isn't this just a pisser.

    Yesterday I went to put in my Language Detection code for subtitles...and came to realize it was useless. The code itself is fine and works great...if all the stars are lined up. Basically if the subtitle is UniCode things are fine...the problem is when it's not...which typically means its ASCII and I need to somehow magically figure out what Code Page is suppose to be applied...which largely depends on knowing what language it is before hand...and even then it's typically a 1 in 4 chance of using the right code page.

    So my cool new feature is sunk before it even got out the gate.

    This also spills over into hardsub's for those wanting to apply non latin based languages.

    This blows given that Unicode has been around since 1991...twenty+ years and still not universally used.

    <sarcasm>God forbid a text document going from 90kb to 190kb...oh the horror.</sarcasm>

    I have noticed that MS Word 2007 does a fair job of guessing what code page needs to be applied...and one can then copy that out and paste it into a UniCode document and all is good...however that is a lot of hands on effort...and will not always be correct unless you are fluent in the langage being converted to UniCode. Just a frigging mess it is.

    Oh Firefox also doesn't do to bad...slightly worse than Word from what little I've done...but generally in the ball park.

    Anyways looks like I'll do some testing and then see about releasing a new build....minus the new subtitle bits.
    Quote Quote  
  21. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Pardon my ignorance here, but I believe you are talking about 2 different "versions" of sub/idx subtitles and not an .srt file. Is that correct?
    I've seen different subs in .mkv containers. At one point I was trying to find a way to get subs out of mkv and into an srt file, but that was a long time ago. I reached the point of having to do some type of character recognition and gave up.
    Quote Quote  
  22. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Hi fonzo,

    No I'm actually talking about SRT's (SubRip)...I was looking to take the content of the SRT and have it ran against Google Translate, to decipher what language the content is (english, spanish, french, arabic, russian,...) so that I could ensure proper meta tags in MKV, MP4 and maybe other containers down the road. Also maybe add support to make sure external subtitles are properly tagged.

    I have code that does this wonderfully right now...if the SRT is UniCode encoded...else if in ASCII what it returns is greatly subject to error and hence worthless.

    The whole subtitle thing is a pile of steaming crap...mostly when dealing with non latin based languages...if those were all done in Unicode...things would be fine...but instead folks are doing ASCII so users have to apply code pages to them to get them to render out correct...this is fine...most of the time...if your system is already set to said code page...but if not...happy hunting. I can only guess that ASCII is being used to somehow allow Win95/98 users to still enjoy subtitles....SO for the few jackasses that won't upgrade to Win2k or above...the vast majority get the shaft...even tho things are not that pretty for Win95/98 users ether.

    It's just out and out crap...that's screwed a couple of what I felt would be cool features as it also effects HardSubs as well...I'm just mad that something so foolish has been allowed to continue and effect other things going forward.
    Quote Quote  
  23. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Is it even possible in autoscript to somehow use sub+idx files and hardcode them into a video file?
    Quote Quote  
  24. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    I haven't tried sub+idx files as of yet...so far just SRT, ASS, SAS.

    Basically if you can find a way to get it to play with FFPlay I can get it to HardSub...or should barring anything unforeseen.
    Quote Quote  
  25. Member
    Join Date
    Apr 2011
    Location
    Eastern US
    Search PM
    Originally Posted by Nologic View Post
    Okay I'm NOT a batch script guru at all. Hehe but I think this will work.

    Levelator from what I could tell seems to be portable...meaning you can just copy the files for the app and have it anywhere...and don't actually have to install it on other systems.

    So this is how I'd do it...I'm certain there are better ways...but I'm writing an AutoIt script to get away from Batch scripts.

    Create a folder call Bin and in it, make two more folders FFMpeg & Levelator...in those sub folders put the files for each of those apps.

    Now create a batch script on the same level as Bin with the following contents:
    Code:
    @Echo Off
    
    If Not Exist .\Temp\ MKDir .\Temp\
    If Not Exist .\Complete\ MKDir .\Complete\
    
    For %%i in (*.avi) Do (
    Del /F /S /Q .\Temp\*.*
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\%%~ni.avi -an -sn -c:v Copy -f AVI .\Temp\%%~ni.avi
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\%%~ni.avi -vn -sn -c:a pcm_s16le -f WAV .\Temp\%%~ni.wav
    Start /Wait ..\Bin\Levelator\Levelator.exe .\Temp\%%~ni.wav
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\%%~ni.output.wav -c:a libmp3lame -q:a 2 -f MP3 .\Temp\%%~ni.mp3
    Start /Wait ..\Bin\FFMpeg\ffmpeg.exe -i .\Temp\%%~ni.avi -i .\Temp\%%~ni.mp3 -c:v Copy -c:a Copy -f AVI .\Complete\%%~ni.avi
    Del /F /S /Q .\Temp\*.*
    )
    
    RMDir /S /Q .\Temp\
    So you should have something that looks like so:
    .\BatchScript.bat
    .\Bin\FFMpeg\ffmpeg.exe
    .\Bin\FFMpeg\...
    .\Bin\Levelator\Levelator.exe
    .\Bin\Levelator\...

    Now when you want to process a folder full of videos...copy the batch script and the Bin folder inside the folder you wish to process...double click the batch script and go drink some coffee.
    .
    I tried using references to Levelator's directory, but it always complained about missing files it was looking for inside it's subdirectory(images). I couldn't do .\levelator\levelator.exe x.wav but you could do cd levelator, levelator.exe ..\x.wav, and you'd have x.wav and x.output.wav in the main avi_gain folder, but would then have to cd .. and then continue processing. And, yes, I had the levelator dir in my path, but not levelator\images.

    I was just modding the original batch files to try it out.

    Maybe you can give me a clue as to why this didn't work.
    Quote Quote  
  26. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Batch Scripts are not my thing...no interest in them...really should talk to SoopaFresh if you have questions about them.

    That said I did a bit of work...if there are issues...you are on your own...but in my testing it worked fine.

    Code:
    @Echo Off
    
    set FFMpeg=D:\My Projects\Video Gain\BIN\FFMpeg\ffmpeg.exe
    set Levelator=D:\My Projects\Video Gain\BIN\Levelator\Levelator.exe
    
    If Not Exist .\Temp\ MKDir .\Temp\
    If Not Exist .\Complete\ MKDir .\Complete\
    
    For %%i in (*.avi,*.divx) Do (
    Del /F /S /Q "%%~dpiTemp\*.*"
    "%FFMpeg%" -i "%%~fi" -an -sn -c:v Copy -f AVI "%%~dpiTemp\%%~ni.avi"
    "%FFMpeg%" -i "%%~fi" -vn -sn -c:a pcm_s16le -f WAV "%%~dpiTemp\%%~ni.wav"
    "%Levelator%" "%%~dpiTemp\%%~ni.wav"
    "%FFMpeg%" -i "%%~dpiTemp\%%~ni.output.wav" -c:a libmp3lame -q:a 2 -f MP3 "%%~dpiTemp\%%~ni.mp3"
    "%FFMpeg%" -i "%%~dpiTemp\%%~ni.avi" -i "%%~dpiTemp\%%~ni.mp3" -c:v Copy -c:a Copy -f AVI "%%~dpiComplete\%%~ni.avi"
    Del /F /S /Q "%%~dpiTemp\*.*"
    )
    
    RMDir /S /Q .\Temp\
    Now if you want to get into trying to recurse folders then you could give this a try (untested)

    Code:
    @Echo Off
    
    set FFMpeg=D:\My Projects\Video Gain\BIN\FFMpeg\ffmpeg.exe
    set Levelator=D:\My Projects\Video Gain\BIN\Levelator\Levelator.exe
    
    For /R .\ %%i in (*.avi,*.divx) Do (
    If Not Exist "%%~dpiTemp\" MKDir "%%~dpiTemp\"
    If Not Exist "%%~dpiComplete\" MKDir "%%~dpiComplete\"
    "%FFMpeg%" -i "%%~fi" -an -sn -c:v Copy -f AVI "%%~dpiTemp\%%~ni.avi"
    "%FFMpeg%" -i "%%~fi" -vn -sn -c:a pcm_s16le -f WAV "%%~dpiTemp\%%~ni.wav"
    "%Levelator%" "%%~dpiTemp\%%~ni.wav"
    "%FFMpeg%" -i "%%~dpiTemp\%%~ni.output.wav" -c:a libmp3lame -q:a 2 -f MP3 "%%~dpiTemp\%%~ni.mp3"
    "%FFMpeg%" -i "%%~dpiTemp\%%~ni.avi" -i "%%~dpiTemp\%%~ni.mp3" -c:v Copy -c:a Copy -f AVI "%%~dpiComplete\%%~ni.avi"
    RMDir /S /Q "%%~dpiTemp\"
    )
    If you have problems see this page and this page.

    Okay more untested code...that should work...and should be able to be dumped in your SendTo folder so that you can process files & folders...I'm sure it's lacking lots of checks and what not...don't care...just trying to show what could be done to some extent.

    Code:
    @Echo Off
    
    set FFMpeg=D:\My Projects\Video Gain\BIN\FFMpeg\ffmpeg.exe
    set Levelator=D:\My Projects\Video Gain\BIN\Levelator\Levelator.exe
    Set Extensions=*.avi,*.divx
    
    If [%1]==[] (
        REM Executed With No Command Lines Options
        For %%a In (%Extensions%) Do (
            Call:EncodeFile "%%~fa" "%%~dpa" "%%~na"
        )
        For /F "Delims=" %%b In ('Dir /AD /B /S /ON ^|Findstr /I /V /C:"Complete"') Do (
            PushD "%%~b\"
            For %%c in (%Extensions%) Do (
                Call:EncodeFile "%%~fc" "%%~dpc" "%%~nc"
            )
            PopD
        )
    ) Else (
        REM Executed With Command Lines Options
        For %%a In (%*) DO (
            Dir /AD /B "%%~a" 1>Nul 2>Nul && (
                REM It's a Folder
                PushD "%%~a\"
                For %%b in (%Extensions%) Do (
                    Call:EncodeFile "%%~fb" "%%~dpb" "%%~nb"
                )
                For /F "Delims=" %%c In ('Dir /AD /B /S /ON ^|Findstr /I /V /C:"Complete"') Do (
                    CD /D "%%~c"
                    For %%d in (%Extensions%) Do (
                        Call:EncodeFile "%%~fd" "%%~dpd" "%%~nd"
                    )
                )
                PopD
            ) || (
                REM It's a File
                Call:EncodeFile "%%~fa" "%%~dpa" "%%~na"
            )
        )
    )
    GoTo:EOF
    
    :EncodeFile
    If Not Exist "%~2Temp\" MKDir "%~2Temp\"
    If Not Exist "%~2Complete\" MKDir "%~2Complete\"
    "%FFMpeg%" -i "%~1" -an -sn -c:v Copy -f AVI "%~2Temp\%~3.avi"
    "%FFMpeg%" -i "%~1" -vn -sn -c:a pcm_s16le -f WAV "%~2Temp\%~3.wav"
    "%Levelator%" "%~2Temp\%~3.wav"
    "%FFMpeg%" -i "%~2Temp\%~3.output.wav" -c:a libmp3lame -q:a 2 -f MP3 "%~2Temp\%~3.mp3"
    "%FFMpeg%" -i "%~2Temp\%~3.avi" -i "%~2Temp\%~3.mp3" -c:v Copy -c:a Copy -f AVI "%~2Complete\%~3.avi"
    RMDir /S /Q "%~2Temp\"
    GoTo:EOF
    For aid in functions in DOS/Batch scripts see this page.

    Something that might be a hint at avoiding the Complete folder can be found here.
    Last edited by Nologic; 12th Nov 2013 at 16:13.
    Quote Quote  
  27. Skipped through and found a few links to older versions for this program, but, not seeing a link for the current one and not finding a website for it either.

    Is there a link in the software section of this site? a homepage?
    Quote Quote  
  28. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Well here are my current public builds.
    Quote Quote  
  29. Cool thanks. I found 1.41.7 and used it, seemed to work but wasn't sure how to set the volume.

    I use a program called MP3Gain for well, mp3's... and you type in a number like 95db.


    How do you set the vol with this program? also for quality of audio, default is 90, is higher or lower better?


    I'm assuming if I don't click re-encode under H264 it leaves the video alone?


    Just got a few small folders of videos (music, tutorials, humour) that I just finished converting over to MP4 and cropping (some were old formats like swf, mov, mpeg) but finding some are very quiet and some super loud. I ran the program on my music video folder and everything seems the same volume now, but I have to turn my TV down about 10 clicks from what I normally have it set for when watching movies and tv shows.
    Quote Quote  
  30. Member
    Join Date
    Nov 2009
    Location
    United States
    Search Comp PM
    Yeah I've heard of MP3Gain...SoopaFresh's original batch scripts used it...then I moved to AACGain which does both MP3 & AAC files...via meta tags...however the current build actually re-encodes the audio...the next build you'll be able to select meta tags when available (mp3 & aac source streams)...else it'll re-encode.

    Anyways through the GUI there is no way to set the desired DB...for that you have to wonder into the source code to change it.

    Right now it's set to -18 LUFS which is about 89.9-90.0db....so to get 95db you would change it to something like -13LUFS. Right now it's set to mimic Replay Gain's default values...in other words the same default for MP3Gain.

    For Audio Quality...yeah for that build higher values are better quality.

    However for Video Quality...lower values are better quality...ah the joy of confusing settings.

    Yeah if re-encode is unchecked it won't encode anything...however even if it is checked...it won't encode video that is already H264 encoded.

    The next version should be more clear about things...I hope.

    Hehe well then it sounds like it did its job.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!