troymccabe / isolate-mkv-langs Goto Github PK
View Code? Open in Web Editor NEWUse MKVMerge to strip all but specified languages from your .mkvs. [USE AT YOUR OWN RISK]
License: MIT License
Use MKVMerge to strip all but specified languages from your .mkvs. [USE AT YOUR OWN RISK]
License: MIT License
I have MKV's with the following mkvmerge json output
{
"attachments": [],
"chapters": [],
"container": {
"properties": {
"container_type": 17,
"duration": 2784416000000,
"is_providing_timestamps": true,
"muxing_application": "libebml v1.3.5 + libmatroska v1.4.8",
"segment_uid": "b988904d51b8b7e6aa66579b40518080",
"writing_application": "mkvmerge v20.0.0 ('I Am The Sun') 64-bit"
},
"recognized": true,
"supported": true,
"type": "Matroska"
},
"errors": [],
"file_name": "c:\\TEMP\\Orange\\A Series of Unfortunate Events - S02E01 - The Austere Academy Part One (1080p.WEB-DL.METCON).mkv",
"global_tags": [],
"identification_format_version": 11,
"track_tags": [],
"tracks": [
{
"codec": "MPEG-4p10/AVC/h.264",
"id": 0,
"properties": {
"codec_id": "V_MPEG4/ISO/AVC",
"codec_private_data": "014d4028ffe10026674d4028e8803c0113f2e02200000300020000030061c0c00059b88001de85251803c60c448001000468ebecb2",
"codec_private_length": 53,
"default_duration": 41666666,
"default_track": true,
"display_dimensions": "1920x1080",
"display_unit": 0,
"enabled_track": true,
"forced_track": false,
"language": "und",
"minimum_timestamp": 0,
"number": 1,
"packetizer": "mpeg4_p10_video",
"pixel_dimensions": "1920x1080",
"uid": 1838355504502411037
},
"type": "video"
},
{
"codec": "AC-3",
"id": 1,
"properties": {
"audio_channels": 6,
"audio_sampling_frequency": 48000,
"codec_id": "A_AC3",
"codec_private_length": 0,
"default_duration": 32000000,
"default_track": true,
"enabled_track": true,
"forced_track": false,
"language": "und",
"minimum_timestamp": 0,
"number": 2,
"uid": 1
},
"type": "audio"
},
{
"codec": "SubRip/SRT",
"id": 2,
"properties": {
"codec_id": "S_TEXT/UTF8",
"codec_private_length": 0,
"default_track": false,
"enabled_track": true,
"encoding": "UTF-8",
"forced_track": false,
"language": "eng",
"minimum_timestamp": 6125000000,
"number": 3,
"text_subtitles": true,
"track_name": "English",
"uid": 18090303752434403640
},
"type": "subtitles"
},
{
"codec": "SubRip/SRT",
"id": 3,
"properties": {
"codec_id": "S_TEXT/UTF8",
"codec_private_length": 0,
"default_track": false,
"enabled_track": true,
"encoding": "UTF-8",
"forced_track": false,
"language": "swe",
"minimum_timestamp": 6166000000,
"number": 4,
"text_subtitles": true,
"track_name": "Swedish",
"uid": 13343674609987706554
},
"type": "subtitles"
},
{
"codec": "SubRip/SRT",
"id": 4,
"properties": {
"codec_id": "S_TEXT/UTF8",
"codec_private_length": 0,
"default_track": false,
"enabled_track": true,
"encoding": "UTF-8",
"forced_track": false,
"language": "nor",
"minimum_timestamp": 6166000000,
"number": 5,
"text_subtitles": true,
"track_name": "Norwegian",
"uid": 14190375328162152868
},
"type": "subtitles"
},
{
"codec": "SubRip/SRT",
"id": 5,
"properties": {
"codec_id": "S_TEXT/UTF8",
"codec_private_length": 0,
"default_track": false,
"enabled_track": true,
"encoding": "UTF-8",
"forced_track": false,
"language": "ger",
"minimum_timestamp": 6166000000,
"number": 6,
"text_subtitles": true,
"track_name": "German",
"uid": 6522050753938359961
},
"type": "subtitles"
},
{
"codec": "SubRip/SRT",
"id": 6,
"properties": {
"codec_id": "S_TEXT/UTF8",
"codec_private_length": 0,
"default_track": false,
"enabled_track": true,
"encoding": "UTF-8",
"forced_track": false,
"language": "fin",
"minimum_timestamp": 6166000000,
"number": 7,
"text_subtitles": true,
"track_name": "Finnish",
"uid": 17098188466736604796
},
"type": "subtitles"
}
],
"warnings": []
}
In this case the command isolate_mkv_langs.py -d c:\TEMP\Orange -l eng -m "c:\Program Files\MKVToolNix\mkvmerge.exe"
will leave me with a video with only the English subtitles but no audio.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.