[FFmpeg-devel] [PATCH] HAM6/HAM8 support for IFF demuxer/decoder

Alex Converse alex.converse
Thu May 6 18:40:29 CEST 2010


On Thu, May 6, 2010 at 11:52 AM, Sebastian Vater
<cdgs.basty at googlemail.com> wrote:
> Martin Storsj? a ?crit :
>
> Please review current patch I just attached with this post.
>
> I also now added some more brief documentation to the header file and
> fixed some UINTxx_C issues in the new macros.
>

+/**
+ * Puts an uint8_t/uint16_t/uint32_t/uint64_t value using big endian mode
+ * if, and only if the extradata context is allocated
+ */
+#define PUT_EXCTX_INT8(x,offset,v)  if ((x) != NULL)
             \
+                                       (((uint8_t *) (x))[(offset)] = (v))
+#define PUT_EXCTX_INT16(x,offset,v) if ((x) != NULL)
             \
+                                       AV_WB16(((uint8_t *) (x)) +
(offset), (v))
+#define PUT_EXCTX_INT32(x,offset,v) if ((x) != NULL)
             \
+                                       AV_WB32(((uint8_t *) (x)) +
(offset), (v))
+#define PUT_EXCTX_INT64(x,offset,v) if ((x) != NULL)
             \
+                                       AV_WB64(((uint8_t *) (x)) +
(offset), (v))
+

What do these macros actually accomplish? They are only used where x
is already uint8_t and not null.



More information about the ffmpeg-devel mailing list