1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-21 10:55:51 +02:00

avformat/fitsenc: reindent switch

This commit is contained in:
Paul B Mahol 2023-05-21 20:43:52 +02:00
parent 8a49341666
commit fd2ca3d4c5

View File

@ -84,48 +84,48 @@ static int write_image_header(AVFormatContext *s)
float datamax, datamin;
switch (encctx->format) {
case AV_PIX_FMT_GRAY8:
bitpix = 8;
naxis = 2;
datamin = 0;
datamax = 255;
break;
case AV_PIX_FMT_GRAY16BE:
bitpix = 16;
naxis = 2;
bzero = 32768;
datamin = 0;
datamax = 65535;
break;
case AV_PIX_FMT_GBRP:
case AV_PIX_FMT_GBRAP:
bitpix = 8;
naxis = 3;
rgb = 1;
if (encctx->format == AV_PIX_FMT_GBRP) {
naxis3 = 3;
} else {
naxis3 = 4;
}
datamin = 0;
datamax = 255;
break;
case AV_PIX_FMT_GBRP16BE:
case AV_PIX_FMT_GBRAP16BE:
bitpix = 16;
naxis = 3;
rgb = 1;
if (encctx->format == AV_PIX_FMT_GBRP16BE) {
naxis3 = 3;
} else {
naxis3 = 4;
}
bzero = 32768;
datamin = 0;
datamax = 65535;
break;
default:
return AVERROR(EINVAL);
case AV_PIX_FMT_GRAY8:
bitpix = 8;
naxis = 2;
datamin = 0;
datamax = 255;
break;
case AV_PIX_FMT_GRAY16BE:
bitpix = 16;
naxis = 2;
bzero = 32768;
datamin = 0;
datamax = 65535;
break;
case AV_PIX_FMT_GBRP:
case AV_PIX_FMT_GBRAP:
bitpix = 8;
naxis = 3;
rgb = 1;
if (encctx->format == AV_PIX_FMT_GBRP) {
naxis3 = 3;
} else {
naxis3 = 4;
}
datamin = 0;
datamax = 255;
break;
case AV_PIX_FMT_GBRP16BE:
case AV_PIX_FMT_GBRAP16BE:
bitpix = 16;
naxis = 3;
rgb = 1;
if (encctx->format == AV_PIX_FMT_GBRP16BE) {
naxis3 = 3;
} else {
naxis3 = 4;
}
bzero = 32768;
datamin = 0;
datamax = 65535;
break;
default:
return AVERROR(EINVAL);
}
if (fitsctx->first_image) {