olstenj Joined: 04 Mar 2008 Total posts: 1 Gender: Unknown |
Posted: Thu Aug 28, 2008 3:34 pm Post subject: Syncing Video and Subtitle file names Post Rating: 0 |
|
|
For subtitles to appear the video file and the subtitle file need to be the same. For quite a while I was doing this manually, it was somewhat of a pain so I wrote a batch file to do this for me. It works 99% of the time and so there is no guarantee that it will work every time. Just put the file in the same directory as your video (.avi) & subtitle (.srt) files and run it. First it will ask you the title that you want and then it will ask you how many episodes you have. Then it does its thing. The only limit that this program has is that the format of the original files must have E then the episode number in it (for example: yisanE01.avi). The attached file needs to be changed to a .bat instead of the .txt for it to work. The content of the file are below if you want to copy it and then save it as a .bat file. If this is too confusing, I can post step by step instructions.
@echo off
mkdir temp
SET /P name=Enter series name please (no numbers please):
SET /P EP=How many episodes are there (10 or more)?
set /a EP1=EP
:AVI
move *E%EP%*.avi temp\%name%E%EP%.avi
set /a EP=EP-1
if %EP% == 9 goto AVI2
goto AVI
:AVI2
move *E0%EP%*.avi temp\%name%E0%EP%.avi
set /a EP=EP-1
if %EP% == 0 goto SRT
goto AVI2
:SRT
move *E%EP1%*.srt temp\%name%E%EP1%.srt
set /a EP1=EP1-1
if %EP1% == 9 goto SRT2
goto SRT
:SRT2
move *E0%EP1%*.srt temp\%name%E0%EP1%.srt
set /a EP1=EP1-1
if %EP1% == 0 goto END
goto SRT2
:END
cd temp
move *.* ..
cd ..
rmdir temp
Written by Jamison Olsten paypal: ebay_ubay@yahoo.com
pause
| Description: |
|
 Download |
| Filename: |
subs-final.txt |
| Filesize: |
690 Bytes |
| Downloaded: |
16 Time(s) |
|
|
| Back to top |
|