VideoHelp Forum

Try DVDFab and download streaming video, copy, convert or make Blu-rays,DVDs! Download free trial !
+ Reply to Thread
Results 1 to 8 of 8
Thread
  1. Everything I say is false koberulz's Avatar
    Join Date
    Oct 2006
    Location
    Australia
    Search Comp PM
    Is there a way I can do this? I'm backing up The Sopranos onto my media server and most episodes just have normal English subs. Some, however, also have a Forced track for foreign dialogue, but MakeMKV doesn't bother to correctly mark it I've just noticed.

    So I need to find all the files with more than one sub track.

    Is there an automated way to do this? Open them, count the tracks, write file names to a text file or something?
    Quote Quote  
  2. Try a batch file that loops over all files with MediaInfo CLI, e.g. something like:
    Code:
    for %%a in (*.mkv) do (
    echo|set /p= "%%a " >> c:\textfile.txt
    MediaInfo.exe "%%~a" --Inform="General;%%TextCount%%" >> c:\textfile.txt
    )
    Quote Quote  
  3. Everything I say is false koberulz's Avatar
    Join Date
    Oct 2006
    Location
    Australia
    Search Comp PM
    Will that search subfolders? ie if I put that batch file in my "Sopranos" folder will it search my Season 1, Season 2 etc folders or will I need to rerun it for each season within that season's folder?

    And for that matter what exactly is it doing at each step?
    Quote Quote  
  4. Everything I say is false koberulz's Avatar
    Join Date
    Oct 2006
    Location
    Australia
    Search Comp PM
    Okay so that's a no on the subfolders now that I'm able to try it, although I managed to find a solution for that via Google.

    It also works by popping up a MediaInfo window for each episode, and won't move on to the next episode until I manually close the MediaInfo window, which rather defeats the purpose of automating.

    And it seems to just be writing the name of each episode into the text file, without regard for the number of subtitle tracks.

    Needs a line break between file names as well.
    Quote Quote  
  5. Member
    Join Date
    Jul 2007
    Location
    United States
    Search Comp PM
    Try the batch file by jagabo in this thread: https://forum.videohelp.com/threads/383550-Mediainfo-CLI-to-creat-NFO
    For %%F IN (*.mkv) do ("C:\Program Files\MediaInfoCLI\MediaInfo.exe" "%%F" >"%%~dpnF.NFO"). Replace NFO with txt for text files. A Mediainfo text file will be created for each file.

    Then use Notepad++ to search the .txt files for "Language" https://www.ghacks.net/2016/09/16/use-notepad-to-find-text-in-all-files-of-a-folder/. It will show the name of the file and all the sub languages.
    Quote Quote  
  6. Everything I say is false koberulz's Avatar
    Join Date
    Oct 2006
    Location
    Australia
    Search Comp PM
    Never mind, I got the sneaker batch to work. Didn't realise MediaInfo CLI and MediaInfo were different things.
    Quote Quote  
  7. Originally Posted by koberulz View Post
    Okay so that's a no on the subfolders now that I'm able to try it, although I managed to find a solution for that via Google.
    To help others in the future, why don't you post the solution?
    Quote Quote  
  8. Everything I say is false koberulz's Avatar
    Join Date
    Oct 2006
    Location
    Australia
    Search Comp PM
    It just needs to be made recursive with /R, although I don't recall whether that comes before or after %%a and have since deleted the batch file.
    Quote Quote  



Similar Threads