mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-22 07:20:45 +00:00
sol: simplify sol_codec_id()
Bug-Id: CID 1238993
This commit is contained in:
parent
b99ca86350
commit
30b8eb0f87
@ -50,18 +50,15 @@ static int sol_probe(AVProbeData *p)
|
||||
|
||||
static enum AVCodecID sol_codec_id(int magic, int type)
|
||||
{
|
||||
if (magic == 0x0B8D)
|
||||
{
|
||||
if (type & SOL_DPCM) return AV_CODEC_ID_SOL_DPCM;
|
||||
else return AV_CODEC_ID_PCM_U8;
|
||||
}
|
||||
if (type & SOL_DPCM)
|
||||
{
|
||||
if (type & SOL_16BIT) return AV_CODEC_ID_SOL_DPCM;
|
||||
else if (magic == 0x0C8D) return AV_CODEC_ID_SOL_DPCM;
|
||||
else return AV_CODEC_ID_SOL_DPCM;
|
||||
}
|
||||
if (type & SOL_16BIT) return AV_CODEC_ID_PCM_S16LE;
|
||||
return AV_CODEC_ID_SOL_DPCM;
|
||||
|
||||
if (magic == 0x0B8D)
|
||||
return AV_CODEC_ID_PCM_U8;
|
||||
|
||||
if (type & SOL_16BIT)
|
||||
return AV_CODEC_ID_PCM_S16LE;
|
||||
|
||||
return AV_CODEC_ID_PCM_U8;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user