File tree Expand file tree Collapse file tree 1 file changed +12
-10
lines changed
Expand file tree Collapse file tree 1 file changed +12
-10
lines changed Original file line number Diff line number Diff line change @@ -271,19 +271,21 @@ public static void ErrorCheckEncodingProfile(VCProfile profile)
271271 }
272272 }
273273
274- if ( profile . AudioEncodings ! = null )
274+ if ( profile . AudioEncodings = = null )
275275 {
276- foreach ( var audioEncoding in profile . AudioEncodings )
276+ profile . AudioEncodings = new List < AudioEncoding > ( ) ;
277+ }
278+
279+ foreach ( var audioEncoding in profile . AudioEncodings )
280+ {
281+ if ( audioEncoding . Encoder == "fdk_aac" )
277282 {
278- if ( audioEncoding . Encoder == "fdk_aac" )
283+ // Make sure this version of VidCoder recognizes the encoder
284+ HBAudioEncoder encoder = HandBrakeEncoderHelpers . GetAudioEncoder ( audioEncoding . Encoder ) ;
285+ if ( encoder == null )
279286 {
280- // Make sure this version of VidCoder recognizes the encoder
281- HBAudioEncoder encoder = HandBrakeEncoderHelpers . GetAudioEncoder ( audioEncoding . Encoder ) ;
282- if ( encoder == null )
283- {
284- audioEncoding . Encoder = "av_aac" ;
285- StaticResolver . Resolve < IAppLogger > ( ) . Log ( "Preset specified fdk_aac but it is not supported in this build of VidCoder. Fell back to av_aac." ) ;
286- }
287+ audioEncoding . Encoder = "av_aac" ;
288+ StaticResolver . Resolve < IAppLogger > ( ) . Log ( "Preset specified fdk_aac but it is not supported in this build of VidCoder. Fell back to av_aac." ) ;
287289 }
288290 }
289291 }
You can’t perform that action at this time.
0 commit comments