8 flags are not enough.
---

I need an additional flags and 8 are already in use.

I'd land this patch as we are going to break the ABI soon anyway.

 libavutil/pixdesc.h | 21 +++++++++++++--------
 1 file changed, 13 insertions(+), 8 deletions(-)

diff --git a/libavutil/pixdesc.h b/libavutil/pixdesc.h
index cd1a573..e2a2444 100644
--- a/libavutil/pixdesc.h
+++ b/libavutil/pixdesc.h
@@ -68,7 +68,11 @@ typedef struct AVComponentDescriptor {
  */
 typedef struct AVPixFmtDescriptor {
     const char *name;
-    uint8_t nb_components;  ///< The number of components each pixel has, (1-4)
+    /**
+     * Alternative comma-separated names.
+     */
+    const char *alias;
+    int nb_components;  ///< The number of components each pixel has, (1-4)

     /**
      * Amount to shift the luma width right to find the chroma width.
@@ -77,7 +81,7 @@ typedef struct AVPixFmtDescriptor {
      * The note above is needed to ensure rounding up.
      * This value only refers to the chroma components.
      */
-    uint8_t log2_chroma_w;  ///< chroma_width = -((-luma_width 
)>>log2_chroma_w)
+    int log2_chroma_w;  ///< chroma_width = -((-luma_width )>>log2_chroma_w)

     /**
      * Amount to shift the luma height right to find the chroma height.
@@ -86,8 +90,13 @@ typedef struct AVPixFmtDescriptor {
      * The note above is needed to ensure rounding up.
      * This value only refers to the chroma components.
      */
-    uint8_t log2_chroma_h;
-    uint8_t flags;
+    int log2_chroma_h;
+
+    /**
+     * Pixel Format specification as or-ed
+     * AV_PIX_FMT_FLAGS
+     */
+    uint64_t flags;

     /**
      * Parameters that describe how pixels are packed. If the format
@@ -96,10 +105,6 @@ typedef struct AVPixFmtDescriptor {
      */
     AVComponentDescriptor comp[4];

-    /**
-     * Alternative comma-separated names.
-     */
-    const char *alias;
 } AVPixFmtDescriptor;

 /**
--
1.9.0

_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to