[FEATURE] Possible To Do Now? Remove EIA_608 text from file

(Bob) #1

I’ve been running MCEBuddy for a while now, works great. I have it process all of my Plex dvr recordings extract the closed captions and remux them into a resulting MKV file. This has worked beautifully for years. HOWEVER, The latest version of Plex now has support for EIA_608 subtitles, and they are showing up as ‘Unknown’ subtitle on all of my recordings, because I’m NOT reencoding the video, just remuxing. So now the EIA subs, A) looks like crap, but B) causes the srt file to not be auto-selected and played as previously was the case. Since I have hearing impaired people in my house, having them automatically on at all times is a requirement.
Not to mention the display of the EIA subtitles looks horrible compared to the nice clean srt subs.

After a bit of searching I found that ffmpeg CAN remove the EIA_608 text from the ts (or mkv) file… using this command:
ffmpeg -i input.mkv -codec copy -bsf:v “filter_units=remove_types=6” output.mkv

I’ve tested this and it works as expected. So here’s the feature request, OR an ask from you is there some way to do this now?

Give me the option to run that ffmpeg command AFTER you’ve extracted the subs to an srt file, THEN remux to mkv and add the subtitles back in.

Possible now?

Do-able soon?

Thanks in advance for your help.

0 Likes

(Bob) #2

Well I answered my own question. With a bit of tinkering, I ended up writing a bat file that does this in post process.
This simply takes the mkv file that MCEbuddy produces, and runs it though ffmpeg again to remove the EIA_608 subs before Plex sees them. Life is good again.

If anyone wants a copy of my script, let me know and I’ll send it along.

1 Like

(Goose) #3

Feel free to post the file here (you can use code brackets)

Have you considered including your parameter -bsf:v "filter_units=remove_types=6" in the profile? Wouldn’t that be simpler?

0 Likes

(Bob) #4

It seems like it would be, yes, however in my testing removing
the EIA subtitles from a TS file to mkv conversion didn’t work,
But from mkv to mkv it worked perfectly. Maybe there’s a way to
make it work during the initial conversion, but I knew how to do
this, and didn’t want to mess with that more.

0 Likes

(Bob) #5

Here’s the relevant code for anyone else that wants to get rid of those annoying EIA_608 subtitles, until Plex and CCextractor get their act togehter with them:
Add this to your profile.conf that you’re using to process files:

CustomCommandPath=C:\Windows\System32\cmd.exe
CustomCommandParameters="/c C:\ccextractor\RemoveSubs\RemoveSubs.bat "%convertedfile%" "%srtfile%" "
CustomCommandHangPeriod=100
CustomCommandCritical=true
CustomCommandUISession=false
CustomCommandShowWindow=false

and then here’s my script (adjust the paths to meet your requirements) I also remove the .srt file since that’s been merged into my mkv file (per my settings):

@echo off

For %%A in (%1) do (
    Set Folder=%%~dpA
    Set InputFileName=%%~nA
)

del /q %2

IF %ERRORLEVEL% EQU 0 (
 ECHO Delete Of SRT File %2 Successfull
)

C:\Progra~1\MCEBuddy2x\ffmpeg\ffmpeg.exe -i %1 -codec copy -bsf:v "filter_units=remove_types=6" G:\BuddyTemp\working0\NoSubsOutput.mkv

IF %ERRORLEVEL% EQU 0 (GOTO :SUCCESS) ELSE (GOTO :FAIL)

:SUCCESS
 ECHO Removal Of EIA_608 Subs From %1 Was Successfull

del /q %1
IF %ERRORLEVEL% EQU 0 (
 ECHO Delete Of Original MKV Successfull
)
ECHO %InputFileName%

ren "G:\BuddyTemp\working0\NoSubsOutput.mkv" "%InputFileName%.mkv"

IF %ERRORLEVEL% EQU 0 (
 ECHO Rename of New MKV without EIA subs was Successfull
)

EXIT
:FAIL
 ECHO Something Went Wrong With Removal Of EIA Subs. 
EXIT /B %ERRORLEVEL%
1 Like