From 28370276a7330304f67953bb8940164ad537df5c Mon Sep 17 00:00:00 2001 From: k-m_schindler Date: Sun, 15 Dec 2013 17:16:46 +0000 Subject: minor code optimization git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@3027 b956fd51-792f-4845-bead-9b4dfca2ff2c --- src/media/UMediaCore_FFmpeg.pas | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'src/media') diff --git a/src/media/UMediaCore_FFmpeg.pas b/src/media/UMediaCore_FFmpeg.pas index d2fe9185..1478cc2a 100644 --- a/src/media/UMediaCore_FFmpeg.pas +++ b/src/media/UMediaCore_FFmpeg.pas @@ -351,18 +351,15 @@ end; function TMediaCore_FFmpeg.ConvertFFmpegToAudioFormat(FFmpegFormat: TAVSampleFormat; out Format: TAudioSampleFormat): boolean; begin + Result := true; case FFmpegFormat of AV_SAMPLE_FMT_U8: Format := asfU8; AV_SAMPLE_FMT_S16: Format := asfS16; AV_SAMPLE_FMT_S32: Format := asfS32; AV_SAMPLE_FMT_FLT: Format := asfFloat; AV_SAMPLE_FMT_DBL: Format := asfDouble; - else begin - Result := false; - Exit; - end; + else Result := false; end; - Result := true; end; -- cgit v1.2.3