[cvs] / xvidcore / src / encoder.h Repository:
ViewVC logotype

Diff of /xvidcore/src/encoder.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.18.2.9, Sat Jan 11 14:59:23 2003 UTC revision 1.21, Wed Sep 4 21:42:56 2002 UTC
# Line 3  Line 3 
3   *  XVID MPEG-4 VIDEO CODEC   *  XVID MPEG-4 VIDEO CODEC
4   *  - Encoder header -   *  - Encoder header -
5   *   *
6     *  Copyright(C) 2002 Michael Militzer
7     *
8   *  This program is an implementation of a part of one or more MPEG-4   *  This program is an implementation of a part of one or more MPEG-4
9   *  Video tools as specified in ISO/IEC 14496-2 standard.  Those intending   *  Video tools as specified in ISO/IEC 14496-2 standard.  Those intending
10   *  to use this software module in hardware or software products are   *  to use this software module in hardware or software products are
# Line 26  Line 28 
28   *  along with this program ; if not, write to the Free Software   *  along with this program ; if not, write to the Free Software
29   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
30   *   *
  ****************************************************************************/  
 /*****************************************************************************  
  *  
  *  History  
  *  
  *  - 13.06.2002 Added legal header  
  *  - 22.08.2001 Added support for EXT_MODE encoding mode  
  *               support for EXTENDED API  
  *  - 22.08.2001 fixed bug in iDQtab  
  *  
31   *  $Id$   *  $Id$
32   *   *
33   ****************************************************************************/   ****************************************************************************/
# Line 46  Line 38 
38  #include "xvid.h"  #include "xvid.h"
39  #include "portab.h"  #include "portab.h"
40  #include "global.h"  #include "global.h"
41    #include "image/image.h"
42  #include "utils/ratecontrol.h"  #include "utils/ratecontrol.h"
43    
44  /*****************************************************************************  /*****************************************************************************
# Line 69  Line 62 
62  {  {
63          I_VOP = 0,          I_VOP = 0,
64          P_VOP = 1,          P_VOP = 1,
65          B_VOP = 2,          B_VOP = 2
         S_VOP = 3  
66  }  }
67  VOP_TYPE;  VOP_TYPE;
68    
# Line 92  Line 84 
84          uint32_t fincr;          uint32_t fincr;
85          uint32_t fbase;          uint32_t fbase;
86    
87          /* constants */  #ifdef _SMP
88          int global;          int num_threads;
89          int bquant_ratio;  #endif
         int bquant_offset;  
         int frame_drop_ratio;  
   
         int iMaxKeyInterval;  
         int max_bframes;  
90    
91          /* rounding type; alternate 0-1 after each interframe */          /* rounding type; alternate 0-1 after each interframe */
92          /* 1 <= fixed_code <= 4          /* 1 <= fixed_code <= 4
# Line 110  Line 97 
97          uint32_t m_quant_type;          uint32_t m_quant_type;
98          uint32_t m_rounding_type;          uint32_t m_rounding_type;
99          uint32_t m_fcode;          uint32_t m_fcode;
         uint32_t m_quarterpel;  
         int m_reduced_resolution;       /* reduced_resolution_enable */  
100    
101          HINTINFO *hint;          HINTINFO *hint;
102    
103          int64_t m_stamp;          uint32_t m_seconds;
104  }          uint32_t m_ticks;
 MBParam;  
   
105    
 typedef struct  
 {  
         int iTextBits;  
         int iMvSum;  
         int iMvCount;  
         int kblks;  
         int mblks;  
         int ublks;  
         int gblks;  
106  }  }
107  Statistics;  MBParam;
108    
109    
110  typedef struct  typedef struct
# Line 141  Line 115 
115    
116          VOP_TYPE coding_type;          VOP_TYPE coding_type;
117          uint32_t rounding_type;          uint32_t rounding_type;
         uint32_t quarterpel;  
118          uint32_t fcode;          uint32_t fcode;
119          uint32_t bcode;          uint32_t bcode;
120    
121          uint32_t seconds;          uint32_t seconds;
122          uint32_t ticks;          uint32_t ticks;
         int64_t stamp;  
123    
124          IMAGE image;          IMAGE image;
125    
126          MACROBLOCK *mbs;          MACROBLOCK *mbs;
127    
         WARPPOINTS warp;                // as in bitstream  
         GMC_DATA gmc_data;              // common data for all MBs  
   
         Statistics sStat;  
128  }  }
129  FRAMEINFO;  FRAMEINFO;
130    
131    typedef struct
132    {
133            int iTextBits;
134            float fMvPrevSigma;
135            int iMvSum;
136            int iMvCount;
137            int kblks;
138            int mblks;
139            int ublks;
140    }
141    Statistics;
142    
143    
144    
145  typedef struct  typedef struct
146  {  {
147          MBParam mbParam;          MBParam mbParam;
148    
149          int iFrameNum;          int iFrameNum;
150            int iMaxKeyInterval;
151          int bitrate;          int bitrate;
152    
153          // images          // images
# Line 182  Line 164 
164          IMAGE vInterHV;          IMAGE vInterHV;
165          IMAGE vInterHVf;          IMAGE vInterHVf;
166    
167          IMAGE vGMC;          Statistics sStat;
   
         /* image queue */  
         int queue_head;  
         int queue_tail;  
         int queue_size;  
         IMAGE *queue;  
   
         /* bframe buffer */  
         int bframenum_head;  
         int bframenum_tail;  
         int flush_bframes;  
   
         FRAMEINFO **bframes;  
         IMAGE f_refh;  
         IMAGE f_refv;  
         IMAGE f_refhv;  
         int bframenum_dx50bvop;  
   
         int m_framenum; /* debug frame num counter; unlike iFrameNum, does not reset at ivop */  
   
168          RateControl rate_control;          RateControl rate_control;
   
         float fMvPrevSigma;  
169  }  }
170  Encoder;  Encoder;
171    

Legend:
Removed from v.1.18.2.9  
changed lines
  Added in v.1.21

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4