Conversion profile for anyone interested.

Discussion of advanced MakeMKV functionality, expert mode, conversion profiles
marcusj0015
Posts: 58
Joined: Thu Nov 29, 2012 5:52 pm

Conversion profile for anyone interested.

Post by marcusj0015 » Fri Nov 30, 2012 5:34 pm

Okay, so this "PERFECT" conversion profile supports all audio, subtitle, and video formats.

Video: video tracks are copied lossless from the original source.

Audio: audio is, depending on it's source, either compressed losslessly or copied over, lossy ones are copied, lossless formats are compressed with FLAC with the highest compression setting.

Subtitles: subtitles are losslessly compressed with ZLIB using it's highest compression setting.

FLAC compression options:
-compression_level can be between 1 and 12, 12 being the highest compression.

-lpc_coeff_precision can be between 1 and 15, 15 being the highest compression.

-lpc_passes can be between 1 and about 4 billion, after 8 it starts having worse compression. (tested from 1 to 33 passes, on a 24 bit 48khz sample file, I haven't tested any other bit/sample rate, but if there's demand I will.)

-lpc_type sets the algorithm to use, 3 has the highest compression.

-threads sets how many cpus to use for encoding, change 2 to how many cores your computer has.

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<profile> 
    <!-- profile name - Perfect -->
    <name lang="eng">PERFECT</name>
    
    <!-- Common MKV flags -->
    <mkvSettings 
        ignoreForcedSubtitlesFlag="false"
        useISO639Type2T="false"
    />
    
    <!-- Settings overridable in preferences -->
    <profileSettings
        app_DefaultSelectionString="-sel:all,-sel:(core|special|lossy),-sel:(rus|spa),+sel:(eng|und|nolang),+sel:mvcvideo,+sel:attachment,=100:all,-10:favlang"
    />
    
    <!-- Output formats currently supported by MakeMKV -->
    <outputSettings name="copy" outputFormat="directCopy">
        <description lang="eng">Copy track 1:1</description>
    </outputSettings>
    <outputSettings name="FLAC" outputFormat="FLAC">
        <description lang="eng">Compress Audio with FLAC</description>
        <extraArgs>-threads 2 -compression_level 12 -lpc_coeff_precision 15 -lpc_passes 8 -lpc_type 3</extraArgs>
    </outputSettings>
    <outputSettings name="zlib" outputFormat="directCopy">
        <description lang="eng">Compress subtitles with ZLIB</description>
        <extraArgs>compression="zlib" compressionLevel="9"</extraArgs>
    </outputSettings>
    
    <!-- Default rule - copy as is -->
    <trackSettings input="default">
        <output outputSettingsName="copy" 
                defaultSelection="$app_DefaultSelectionString,+sel:true"></output>
    </trackSettings>
    <trackSettings input="Mpeg1">
        <output outputSettingsName="copy" 
                defaultSelection="$app_DefaultSelectionString,+sel:true"></output>
    </trackSettings>
    <trackSettings input="Mpeg2">
        <output outputSettingsName="copy" 
                defaultSelection="$app_DefaultSelectionString,+sel:true"></output>
    </trackSettings>
    <trackSettings input="Mpeg4">
        <output outputSettingsName="copy" 
                defaultSelection="$app_DefaultSelectionString,+sel:true"></output>
    </trackSettings>
    <trackSettings input="VC1">
        <output outputSettingsName="copy" 
                defaultSelection="$app_DefaultSelectionString,+sel:true"></output>
    </trackSettings>
    
    <!-- Lossless Audio -->
    <trackSettings input="TRUEHD-stereo">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="TRUEHD-multi">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="MLP-stereo">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="MLP-multi">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTSHDMA-stereo">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTSHDMA-multi">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="FLAC-stereo">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="FLAC-multi">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="LPCM-stereo">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="LPCM-multi">
        <output outputSettingsName="FLAC"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    
    <!-- Lossy Audio --> 
    <trackSettings input="MP2">
    <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="MP3">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTS-stereo">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTS-multi">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTSHD-core-multi">
        <output outputSettingsName="copy" 
                defaultSelection="$app_DefaultSelectionString">
        </output>
    </trackSettings>
    <trackSettings input="DTSHD-core-stereo">
        <output outputSettingsName="copy" 
                defaultSelection="$app_DefaultSelectionString">
        </output>
    </trackSettings>
    <trackSettings input="DTSHD-stereo">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTSHD-multi">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTSHDLBR-stereo">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="DTSHDLBR-multi">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="AC3-stereo">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="AC3-multi">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="EAC3-stereo">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="EAC3-multi">
        <output outputSettingsName="copy"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    
    <!-- Compress subtitles with ZLIB -->
    <trackSettings input="PGS">
        <output outputSettingsName="zlib"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="PGS-forced">
        <output outputSettingsName="zlib"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="VOBSUB">
        <output outputSettingsName="zlib"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="VOBSUB-forced">
        <output outputSettingsName="zlib"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="VOBSUBHD">
        <output outputSettingsName="zlib"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
    <trackSettings input="VOBSUBHD-forced">
        <output outputSettingsName="zlib"
            defaultSelection="$app_DefaultSelectionString"></output>
    </trackSettings>
</profile>

Code: Select all

Changes 1:
Optimized flac compression, moved dtshd and dts express to the lossy section, because they're not lossless, dtshd core is now deselected by default, MVC (3D view of a 3D Blu-ray) is now selected by default

Code: Select all

Changes 2:
removed selection settings from track settings so the selection rules will work correctly.
Last edited by marcusj0015 on Wed Feb 03, 2016 12:02 pm, edited 19 times in total.

marcusj0015
Posts: 58
Joined: Thu Nov 29, 2012 5:52 pm

Re: Conversion profile for anyone interested.

Post by marcusj0015 » Sun Jan 13, 2013 2:49 pm

I don't mean to offend anyone, and I'd be glad to hear vetoes, but I believe my conversion profile to be optimal for lossless compression, so is there any chance it can be stickied?

Romansh
Posts: 872
Joined: Sat Jan 22, 2011 7:09 pm

Re: Conversion profile for anyone interested.

Post by Romansh » Sun Jan 13, 2013 7:47 pm

Maximum compression will only give you maybe 5% better compression than the default on most tracks. How is that optimal? I'm terribly offended :P

crowfax
Posts: 972
Joined: Thu Feb 18, 2010 5:55 am

Re: Conversion profile for anyone interested.

Post by crowfax » Sun Jan 13, 2013 10:22 pm

This is awesome. Thanks for your work.
Home Theater PC: Assassin HTPC, XBMCbuntu 12.0 (Frodo), Intel i5 3570k 3.4 GHz Ivy Bridge w/ HD 4000, LG BD-ROM
Playback Devices: Mede8er MED600X3D, MyGica EnjoyTV 120, Xtreamer SideWinder 3, Crystal Acoustics MediaMatchBox

jbates58
Posts: 2
Joined: Sat Aug 24, 2013 5:31 am

Re: Conversion profile for anyone interested.

Post by jbates58 » Sat Aug 24, 2013 9:03 am

i get an error when running this profile, and the the conversion stops. and clues?

cheers

Jason

Donny Bahama
Posts: 9
Joined: Sun Feb 23, 2014 2:02 am

Re: Conversion profile for anyone interested.

Post by Donny Bahama » Sat Mar 01, 2014 4:43 am

OMG, Halleleujah! I've been banging my head against the wall for 3 days now, trying to get profiles to work! FINALLY - this one WORKS (AND I was able to modify it to suit my needs)! Thank you! Thank you! THANK YOU!!!

etrask
Posts: 17
Joined: Thu Oct 31, 2013 12:32 am

Re: Conversion profile for anyone interested.

Post by etrask » Wed Aug 20, 2014 5:32 am

I like it a lot.

Can't really argue with it being perfect for lossless rips.

Good job!

mancolh
Posts: 10
Joined: Tue Aug 19, 2014 7:10 pm

Re: Conversion profile for anyone interested.

Post by mancolh » Fri Aug 22, 2014 1:59 am

Is there any way to add a section that also copies the DTS-HD MA and TrueHD tracks so a person could choose between FLAC /PCM and original depending on the player used?

marcusj0015
Posts: 58
Joined: Thu Nov 29, 2012 5:52 pm

Re: Conversion profile for anyone interested.

Post by marcusj0015 » Sat Aug 23, 2014 2:54 am

mancolh wrote:Is there any way to add a section that also copies the DTS-HD MA and TrueHD tracks so a person could choose between FLAC /PCM and original depending on the player used?

Yup, just find the truehd/dtsma section and change <output outputSettingsName="FLAC" to <output outputSettingsName="copy"


mancolh
Posts: 10
Joined: Tue Aug 19, 2014 7:10 pm

Re: Conversion profile for anyone interested.

Post by mancolh » Sat Aug 23, 2014 4:47 pm

Thanks for the hints. Finally got an xml editor and edited the FLAC profile to add the copy output. Doing my first rip now.

kenneth
Posts: 64
Joined: Tue Aug 26, 2014 9:53 pm

Re: Conversion profile for anyone interested.

Post by kenneth » Thu Aug 28, 2014 10:09 pm

I'm building a tool using makemkvcon where I am generating conversion profiles on the fly, and I'm curious why this part (excerpt from the full profile) is necessary when the default rule is copy as-is?
<trackSettings input="DTSHD-stereo">
<output outputSettingsName="copy"
defaultSelection="$app_DefaultSelectionString,-sel:true"></output>
</trackSettings>
What does this entry do? As far as I can see, no where is DTSHD-stereo (or any of the other lossy formats) explicitly set to use anything other than copy as-is?

Can anyone explain the way this works?
BatchMKV - free Windows-based batch processing software for MakeMKV

ndjamena
Posts: 830
Joined: Mon Jan 07, 2013 12:23 am

Re: Conversion profile for anyone interested.

Post by ndjamena » Fri Aug 29, 2014 12:11 am

<trackSettings input="DTSHD-stereo">
<output outputSettingsName="copy"
defaultSelection="$app_DefaultSelectionString,-sel:true"></output>
</trackSettings>
The first line indicates this xml node is intended for tracks consisting of Stereo DTS-HRA. The second line tells it to simply copy the stream without re-encoding it. The third line deselects the output track and the final line closes the node.

Apparently the Author of the profile doesn't consider HRA worth keeping. He must have never encountered HRA on a disc because usually it's used on the main track instead of DTS-MA. I generally convert HRA to FLAC but the final file does tend to come out larger than the original, however, since more programs/devices are compatible with DTS-MA than HRA I think copying HRA is a bad idea. The best options with HRA are either encoding to FLAC or just keeping the core since the stream itself is pretty much useless at the moment and will kill any device that fails to extract the core properly (it seems the latest WDTV firmware fixed HRA bit-streaming).

marcusj0015
Posts: 58
Joined: Thu Nov 29, 2012 5:52 pm

Re: Conversion profile for anyone interested.

Post by marcusj0015 » Fri Aug 29, 2014 5:57 am

Yeah, I prefer to keep lossless audio, but if there is no lossless track, I'll manually select the best lossy track available.

kenneth
Posts: 64
Joined: Tue Aug 26, 2014 9:53 pm

Re: Conversion profile for anyone interested.

Post by kenneth » Fri Aug 29, 2014 7:18 am

marcusj0015 wrote:Yeah, I prefer to keep lossless audio, but if there is no lossless track, I'll manually select the best lossy track available.
Ahh, I understand.

But why is ,-sel:true included in the trackSettings for lossy tracks and what does it mean (the true part, I realize -sel deselects track(s))? Why is it necessary, if lossy tracks are deselected in the profileSettings app_DefaultSelectionString?
BatchMKV - free Windows-based batch processing software for MakeMKV

Post Reply