35 |
* Constants |
* Constants |
36 |
****************************************************************************/ |
****************************************************************************/ |
37 |
|
|
38 |
|
/* lambda base exponential. 1<<LAMBDA_EXP is the neutral lambda */ |
39 |
|
#define LAMBDA_EXP 6 |
40 |
|
|
41 |
/***************************************************************************** |
/***************************************************************************** |
42 |
* Types |
* Types |
43 |
****************************************************************************/ |
****************************************************************************/ |
79 |
int par_width; |
int par_width; |
80 |
int par_height; |
int par_height; |
81 |
|
|
|
#ifdef _SMP |
|
|
int num_threads; |
|
|
#endif |
|
|
|
|
|
|
|
82 |
int iMaxKeyInterval; |
int iMaxKeyInterval; |
83 |
int max_bframes; |
int max_bframes; |
84 |
|
|
96 |
int64_t m_stamp; |
int64_t m_stamp; |
97 |
|
|
98 |
uint16_t *mpeg_quant_matrices; |
uint16_t *mpeg_quant_matrices; |
99 |
|
uint32_t last_quant_initialized_intra; /* needed for mpeg matrices initialization */ |
100 |
} MBParam; |
} MBParam; |
101 |
|
|
|
|
|
102 |
typedef struct |
typedef struct |
103 |
{ |
{ |
104 |
int iTextBits; |
int iTextBits; |
108 |
int mblks; |
int mblks; |
109 |
int ublks; |
int ublks; |
110 |
int gblks; |
int gblks; |
111 |
|
int iMVBits; |
112 |
} Statistics; |
} Statistics; |
113 |
|
|
|
|
|
114 |
/* encoding queue */ |
/* encoding queue */ |
115 |
typedef struct |
typedef struct |
116 |
{ |
{ |
120 |
IMAGE image; |
IMAGE image; |
121 |
} QUEUEINFO; |
} QUEUEINFO; |
122 |
|
|
|
|
|
123 |
typedef struct |
typedef struct |
124 |
{ |
{ |
125 |
int frame_num; |
int frame_num; |
152 |
int is_edged, is_interpolated; |
int is_edged, is_interpolated; |
153 |
} FRAMEINFO; |
} FRAMEINFO; |
154 |
|
|
155 |
|
#include "motion/motion_smp.h" |
156 |
|
|
157 |
typedef struct |
typedef struct |
158 |
{ |
{ |
173 |
|
|
174 |
int * temp_dquants; |
int * temp_dquants; |
175 |
|
|
176 |
|
/* lambda */ |
177 |
|
|
178 |
|
float * temp_lambda; |
179 |
|
|
180 |
/* images */ |
/* images */ |
181 |
|
|
182 |
FRAMEINFO *current; |
FRAMEINFO *current; |
212 |
int closed_bframenum; /* == -1 if there is no fixup intended */ |
int closed_bframenum; /* == -1 if there is no fixup intended */ |
213 |
QUEUEINFO closed_qframe; /* qFrame, only valid when >= 0 */ |
QUEUEINFO closed_qframe; /* qFrame, only valid when >= 0 */ |
214 |
|
|
215 |
|
/* multithreaded stuff */ |
216 |
|
int num_threads; /* number of additional threads */ |
217 |
|
SMPmotionData * motionData; /* data structures used to pass all thread-specific data */ |
218 |
|
|
219 |
int m_framenum; /* debug frame num counter; unlike iFrameNum, does not reset at ivop */ |
int m_framenum; /* debug frame num counter; unlike iFrameNum, does not reset at ivop */ |
220 |
|
|
221 |
float fMvPrevSigma; |
float fMvPrevSigma; |
253 |
return 0; |
return 0; |
254 |
} |
} |
255 |
|
|
|
|
|
256 |
/***************************************************************************** |
/***************************************************************************** |
257 |
* Prototypes |
* Prototypes |
258 |
****************************************************************************/ |
****************************************************************************/ |