MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / hb_mixdown_get_default

Function hb_mixdown_get_default

libhb/common.c:2913–2949  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2911}
2912
2913int hb_mixdown_get_default(uint32_t codec, hb_channel_layout_t *ch_layout)
2914{
2915 int mixdown;
2916 switch (codec)
2917 {
2918 // the FLAC encoder defaults to the best mixdown up to 7.1
2919 case HB_ACODEC_FFALAC:
2920 case HB_ACODEC_FFALAC24:
2921 case HB_ACODEC_FFFLAC:
2922 case HB_ACODEC_FFFLAC24:
2923 case HB_ACODEC_OPUS:
2924 case HB_ACODEC_CA_AAC:
2925 case HB_ACODEC_CA_HAAC:
2926 case HB_ACODEC_FFAAC:
2927 case HB_ACODEC_FDK_AAC:
2928 case HB_ACODEC_FDK_HAAC:
2929 case HB_ACODEC_FFPCM16:
2930 case HB_ACODEC_FFPCM24:
2931 mixdown = HB_AMIXDOWN_7POINT1;
2932 break;
2933
2934 // the (E-)AC-3 and TrueHD encoder defaults to the best mixdown up to 5.1
2935 case HB_ACODEC_AC3:
2936 case HB_ACODEC_FFEAC3:
2937 case HB_ACODEC_FFTRUEHD:
2938 mixdown = HB_AMIXDOWN_5POINT1;
2939 break;
2940
2941 // other encoders default to the best mixdown up to DPLII
2942 default:
2943 mixdown = HB_AMIXDOWN_DOLBYPLII;
2944 break;
2945 }
2946
2947 // return the best available mixdown up to the selected default
2948 return hb_mixdown_get_best(codec, ch_layout, mixdown);
2949}
2950
2951int hb_mixdown_get_default_s(uint32_t codec, const char *layout)
2952{

Callers 3

sanitize_audioFunction · 0.85
hb_mixdown_get_default_sFunction · 0.85

Calls 1

hb_mixdown_get_bestFunction · 0.85

Tested by

no test coverage detected