mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
Add single precision planar RGB pixel formats
Add a pixel format flag to identify this family. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
This commit is contained in:
parent
8d2da0939c
commit
1460408703
@ -15,6 +15,9 @@ libavutil: 2015-08-28
|
||||
|
||||
API changes, most recent first:
|
||||
|
||||
2017-08-08 - xxxxxxx - lavu 55.74.100 - pixdesc.h
|
||||
Add AV_PIX_FMT_FLAG_FLOAT pixel format flag.
|
||||
|
||||
2017-08-08 - xxxxxxx - lavu 55.72.100 - imgutils.h
|
||||
Add av_image_fill_black().
|
||||
|
||||
|
@ -2183,6 +2183,60 @@ static const AVPixFmtDescriptor av_pix_fmt_descriptors[AV_PIX_FMT_NB] = {
|
||||
.name = "d3d11",
|
||||
.flags = AV_PIX_FMT_FLAG_HWACCEL,
|
||||
},
|
||||
[AV_PIX_FMT_GBRPF32BE] = {
|
||||
.name = "gbrpf32be",
|
||||
.nb_components = 3,
|
||||
.log2_chroma_w = 0,
|
||||
.log2_chroma_h = 0,
|
||||
.comp = {
|
||||
{ 2, 4, 0, 0, 32, 3, 31, 1 }, /* R */
|
||||
{ 0, 4, 0, 0, 32, 3, 31, 1 }, /* G */
|
||||
{ 1, 4, 0, 0, 32, 3, 31, 1 }, /* B */
|
||||
},
|
||||
.flags = AV_PIX_FMT_FLAG_BE | AV_PIX_FMT_FLAG_PLANAR |
|
||||
AV_PIX_FMT_FLAG_RGB | AV_PIX_FMT_FLAG_FLOAT,
|
||||
},
|
||||
[AV_PIX_FMT_GBRPF32LE] = {
|
||||
.name = "gbrpf32le",
|
||||
.nb_components = 3,
|
||||
.log2_chroma_w = 0,
|
||||
.log2_chroma_h = 0,
|
||||
.comp = {
|
||||
{ 2, 4, 0, 0, 32, 3, 31, 1 }, /* R */
|
||||
{ 0, 4, 0, 0, 32, 3, 31, 1 }, /* G */
|
||||
{ 1, 4, 0, 0, 32, 3, 31, 1 }, /* B */
|
||||
},
|
||||
.flags = AV_PIX_FMT_FLAG_PLANAR | AV_PIX_FMT_FLAG_FLOAT | AV_PIX_FMT_FLAG_RGB,
|
||||
},
|
||||
[AV_PIX_FMT_GBRAPF32BE] = {
|
||||
.name = "gbrapf32be",
|
||||
.nb_components = 4,
|
||||
.log2_chroma_w = 0,
|
||||
.log2_chroma_h = 0,
|
||||
.comp = {
|
||||
{ 2, 4, 0, 0, 32, 3, 31, 1 }, /* R */
|
||||
{ 0, 4, 0, 0, 32, 3, 31, 1 }, /* G */
|
||||
{ 1, 4, 0, 0, 32, 3, 31, 1 }, /* B */
|
||||
{ 3, 4, 0, 0, 32, 3, 31, 1 }, /* A */
|
||||
},
|
||||
.flags = AV_PIX_FMT_FLAG_BE | AV_PIX_FMT_FLAG_PLANAR |
|
||||
AV_PIX_FMT_FLAG_ALPHA | AV_PIX_FMT_FLAG_RGB |
|
||||
AV_PIX_FMT_FLAG_FLOAT,
|
||||
},
|
||||
[AV_PIX_FMT_GBRAPF32LE] = {
|
||||
.name = "gbrapf32le",
|
||||
.nb_components = 4,
|
||||
.log2_chroma_w = 0,
|
||||
.log2_chroma_h = 0,
|
||||
.comp = {
|
||||
{ 2, 4, 0, 0, 32, 3, 31, 1 }, /* R */
|
||||
{ 0, 4, 0, 0, 32, 3, 31, 1 }, /* G */
|
||||
{ 1, 4, 0, 0, 32, 3, 31, 1 }, /* B */
|
||||
{ 3, 4, 0, 0, 32, 3, 31, 1 }, /* A */
|
||||
},
|
||||
.flags = AV_PIX_FMT_FLAG_PLANAR | AV_PIX_FMT_FLAG_ALPHA |
|
||||
AV_PIX_FMT_FLAG_RGB | AV_PIX_FMT_FLAG_FLOAT,
|
||||
},
|
||||
};
|
||||
#if FF_API_PLUS1_MINUS1
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
|
@ -177,6 +177,12 @@ typedef struct AVPixFmtDescriptor {
|
||||
*/
|
||||
#define AV_PIX_FMT_FLAG_BAYER (1 << 8)
|
||||
|
||||
/**
|
||||
* The pixel format contains IEEE-754 floating point values. Precision (double,
|
||||
* single, or half) should be determined by the pixel size (64, 32, or 16 bits).
|
||||
*/
|
||||
#define AV_PIX_FMT_FLAG_FLOAT (1 << 9)
|
||||
|
||||
/**
|
||||
* Return the number of bits per pixel used by the pixel format
|
||||
* described by pixdesc. Note that this is not the same as the number
|
||||
|
@ -329,6 +329,11 @@ enum AVPixelFormat {
|
||||
AV_PIX_FMT_GRAY9BE, ///< Y , 9bpp, big-endian
|
||||
AV_PIX_FMT_GRAY9LE, ///< Y , 9bpp, little-endian
|
||||
|
||||
AV_PIX_FMT_GBRPF32BE, ///< IEEE-754 single precision planar GBR 4:4:4, 96bpp, big-endian
|
||||
AV_PIX_FMT_GBRPF32LE, ///< IEEE-754 single precision planar GBR 4:4:4, 96bpp, little-endian
|
||||
AV_PIX_FMT_GBRAPF32BE, ///< IEEE-754 single precision planar GBRA 4:4:4:4, 128bpp, big-endian
|
||||
AV_PIX_FMT_GBRAPF32LE, ///< IEEE-754 single precision planar GBRA 4:4:4:4, 128bpp, little-endian
|
||||
|
||||
AV_PIX_FMT_NB ///< number of pixel formats, DO NOT USE THIS if you want to link with shared libav* because the number of formats might differ between versions
|
||||
};
|
||||
|
||||
@ -393,6 +398,8 @@ enum AVPixelFormat {
|
||||
#define AV_PIX_FMT_BAYER_GBRG16 AV_PIX_FMT_NE(BAYER_GBRG16BE, BAYER_GBRG16LE)
|
||||
#define AV_PIX_FMT_BAYER_GRBG16 AV_PIX_FMT_NE(BAYER_GRBG16BE, BAYER_GRBG16LE)
|
||||
|
||||
#define AV_PIX_FMT_GBRPF32 AV_PIX_FMT_NE(GBRPF32BE, GBRPF32LE)
|
||||
#define AV_PIX_FMT_GBRAPF32 AV_PIX_FMT_NE(GBRAPF32BE, GBRAPF32LE)
|
||||
|
||||
#define AV_PIX_FMT_YUVA420P9 AV_PIX_FMT_NE(YUVA420P9BE , YUVA420P9LE)
|
||||
#define AV_PIX_FMT_YUVA422P9 AV_PIX_FMT_NE(YUVA422P9BE , YUVA422P9LE)
|
||||
|
@ -80,7 +80,7 @@
|
||||
|
||||
|
||||
#define LIBAVUTIL_VERSION_MAJOR 55
|
||||
#define LIBAVUTIL_VERSION_MINOR 73
|
||||
#define LIBAVUTIL_VERSION_MINOR 74
|
||||
#define LIBAVUTIL_VERSION_MICRO 100
|
||||
|
||||
#define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
|
||||
|
@ -112,11 +112,13 @@ isBE:
|
||||
gbrap10be
|
||||
gbrap12be
|
||||
gbrap16be
|
||||
gbrapf32be
|
||||
gbrp10be
|
||||
gbrp12be
|
||||
gbrp14be
|
||||
gbrp16be
|
||||
gbrp9be
|
||||
gbrpf32be
|
||||
gray10be
|
||||
gray12be
|
||||
gray16be
|
||||
@ -362,6 +364,8 @@ isRGB:
|
||||
gbrap12le
|
||||
gbrap16be
|
||||
gbrap16le
|
||||
gbrapf32be
|
||||
gbrapf32le
|
||||
gbrp
|
||||
gbrp10be
|
||||
gbrp10le
|
||||
@ -373,6 +377,8 @@ isRGB:
|
||||
gbrp16le
|
||||
gbrp9be
|
||||
gbrp9le
|
||||
gbrpf32be
|
||||
gbrpf32le
|
||||
rgb0
|
||||
rgb24
|
||||
rgb32
|
||||
@ -498,6 +504,8 @@ AnyRGB:
|
||||
gbrap12le
|
||||
gbrap16be
|
||||
gbrap16le
|
||||
gbrapf32be
|
||||
gbrapf32le
|
||||
gbrp
|
||||
gbrp10be
|
||||
gbrp10le
|
||||
@ -509,6 +517,8 @@ AnyRGB:
|
||||
gbrp16le
|
||||
gbrp9be
|
||||
gbrp9le
|
||||
gbrpf32be
|
||||
gbrpf32le
|
||||
monob
|
||||
monow
|
||||
rgb0
|
||||
@ -543,6 +553,8 @@ ALPHA:
|
||||
gbrap12le
|
||||
gbrap16be
|
||||
gbrap16le
|
||||
gbrapf32be
|
||||
gbrapf32le
|
||||
pal8
|
||||
rgb32
|
||||
rgb32_1
|
||||
@ -645,6 +657,8 @@ Planar:
|
||||
gbrap12le
|
||||
gbrap16be
|
||||
gbrap16le
|
||||
gbrapf32be
|
||||
gbrapf32le
|
||||
gbrp
|
||||
gbrp10be
|
||||
gbrp10le
|
||||
@ -656,6 +670,8 @@ Planar:
|
||||
gbrp16le
|
||||
gbrp9be
|
||||
gbrp9le
|
||||
gbrpf32be
|
||||
gbrpf32le
|
||||
nv12
|
||||
nv16
|
||||
nv20be
|
||||
@ -790,6 +806,8 @@ PlanarRGB:
|
||||
gbrap12le
|
||||
gbrap16be
|
||||
gbrap16le
|
||||
gbrapf32be
|
||||
gbrapf32le
|
||||
gbrp
|
||||
gbrp10be
|
||||
gbrp10le
|
||||
@ -801,6 +819,8 @@ PlanarRGB:
|
||||
gbrp16le
|
||||
gbrp9be
|
||||
gbrp9le
|
||||
gbrpf32be
|
||||
gbrpf32le
|
||||
|
||||
usePal:
|
||||
bgr4_byte
|
||||
|
Loading…
Reference in New Issue
Block a user