Skip to content

1nfrag/mute-profanity

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

68 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

I've created a plugin that is designed to mute profanity in your movie library. It works by comparing the movie's subtitle file against your filter file. When a match is found, XBMC will mute the audio for the duration of the word.

How to use it:
Navigate to a movie or TV show you'd like to edit. The add-on will try to find the subtitle file for that movie, extracting embedded subtitles if possible. If you don't have one, it will ask if you'd like to download one. Downloads come from www.opensubtitles.org. After a very brief processing time, you then play the movie normally. You will notice that the blocked words are muted!

Key Features:
* Edit the strictness in the settings menu
* Category-specific strictness ratings
* Mute profanity in either movies or TV shows
* Extract subtitles automatically from MKV or MP4 files
* Download missing subtitles from the internet

Configuration Details:
Since the subtitle file and not the audio itself is analyzed, you will notice that the mute times are not always exact. The script is only guessing when the blocked word is spoken, and it can be wrong sometimes. This add-on includes a setting which specifies the amount of time in milliseconds before and after the time of the blocked word that XBMC should start and end the mute. By default, this is 300ms, but can be adjusted for more or less time, depending on preferences.

It's important to have an accurate subtitles file, with correct timings. If you notice that your subtitles show up too early or too late, the script will mute too early or too late as well. Even with max timing settings, the plugin will not mute before or after the subtitle is no longer displayed.

After you download and install the application, the list of blocked words is found in the script directory under "resources"->"filter.txt". Each word should be on it's own line and you can use the '*' character to match any number of characters. Change this file as you see fit.

How it works:
XBMC has built-in the ability to read a EDL file (Edit Decision List) and process it accordingly. The script will create this file, which contains the timestamps of when mutes should occur. Again, this calculation is found from processing the subtitles file of the movie being 'edited'. If no SRT file could be found, the add-on will attempt to download one based on the name of the file from www.opensubtitles.org. If one could not be found, the script will fail. If you need to mute a movie and the download feature is not working, I suggest you download the SRT file separately, ensure that it's timing is correct, then re-run my script to mute the profanity.

Enjoy!

About

XBMC add-on used to mute profanity

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%