]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/mpeg4video.h
decode: be more explicit about storing the last packet properties
[ffmpeg] / libavcodec / mpeg4video.h
index 5dc22033dd9932ed801f332d02f7b4f20c26aa0f..4a4995e21928872529296cf2a75c65c367730ccd 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * MPEG4 encoder/decoder internal header.
+ * MPEG-4 encoder/decoder internal header.
  * Copyright (c) 2000,2001 Fabrice Bellard
  * Copyright (c) 2002-2010 Michael Niedermayer <michaelni@gmx.at>
  *
 typedef struct Mpeg4DecContext {
     MpegEncContext m;
 
-    ///< number of bits to represent the fractional part of time
+    /// number of bits to represent the fractional part of time
     int time_increment_bits;
     int shape;
     int vol_sprite_usage;
     int sprite_brightness_change;
     int num_sprite_warping_points;
+    /// sprite trajectory points
+    uint16_t sprite_traj[4][2];
+    /// sprite shift [isChroma]
+    int sprite_shift[2];
 
     // reversible vlc
     int rvlc;
-    ///< could this stream contain resync markers
+    /// could this stream contain resync markers
     int resync_marker;
-    ///< time distance of first I -> B, used for interlaced b frames
+    /// time distance of first I -> B, used for interlaced B-frames
     int t_frame;
 
     int new_pred;
     int enhancement_type;
     int scalability;
+    int use_intra_dc_vlc;
+    /// QP above which the ac VLC should be used for intra dc
+    int intra_dc_threshold;
 
     /* bug workarounds */
     int divx_version;
     int divx_build;
     int xvid_build;
     int lavc_build;
-
+    /// flag for having shown the warning about invalid Divx B-frames
+    int showed_packed_warning;
+    /** does the stream contain the low_delay flag,
+     *  used to work around buggy encoders. */
+    int vol_control_parameters;
     int cplx_estimation_trash_i;
     int cplx_estimation_trash_p;
     int cplx_estimation_trash_b;
 } Mpeg4DecContext;
 
-/* dc encoding for mpeg4 */
+/* dc encoding for MPEG-4 */
 extern const uint8_t ff_mpeg4_DCtab_lum[13][2];
 extern const uint8_t ff_mpeg4_DCtab_chrom[13][2];
 
@@ -140,7 +151,6 @@ void ff_mpeg4_init_direct_mv(MpegEncContext *s);
 int ff_mpeg4_frame_end(AVCodecContext *avctx, const uint8_t *buf, int buf_size);
 
 /**
- *
  * @return the mb_type
  */
 int ff_mpeg4_set_direct_mv(MpegEncContext *s, int mx, int my);
@@ -212,7 +222,7 @@ static inline int ff_mpeg4_pred_dc(MpegEncContext *s, int n, int level,
     } else {
         level += pred;
         ret    = level;
-        if (s->err_recognition & AV_EF_BITSTREAM) {
+        if (s->avctx->err_recognition & AV_EF_BITSTREAM) {
             if (level < 0) {
                 av_log(s->avctx, AV_LOG_ERROR,
                        "dc<0 at %dx%d\n", s->mb_x, s->mb_y);