55 |
#include "utils/timer.h" |
#include "utils/timer.h" |
56 |
#include "bitstream/mbcoding.h" |
#include "bitstream/mbcoding.h" |
57 |
|
|
58 |
int xvid_init(void *handle, int opt, void *param1, void *param2) |
int |
59 |
|
xvid_init(void *handle, |
60 |
|
int opt, |
61 |
|
void *param1, |
62 |
|
void *param2) |
63 |
{ |
{ |
64 |
int cpu_flags; |
int cpu_flags; |
65 |
XVID_INIT_PARAM *init_param; |
XVID_INIT_PARAM *init_param; |
213 |
fdct = fdct_sse2; |
fdct = fdct_sse2; |
214 |
#endif |
#endif |
215 |
} |
} |
|
|
|
216 |
#endif |
#endif |
217 |
#ifdef ARCH_PPC |
#ifdef ARCH_PPC |
218 |
#ifdef ARCH_PPC_ALTIVEC |
#ifdef ARCH_PPC_ALTIVEC |
237 |
return XVID_ERR_OK; |
return XVID_ERR_OK; |
238 |
} |
} |
239 |
|
|
240 |
int xvid_decore(void * handle, int opt, void * param1, void * param2) |
int |
241 |
{ |
xvid_decore(void *handle, |
242 |
switch (opt) |
int opt, |
243 |
|
void *param1, |
244 |
|
void *param2) |
245 |
{ |
{ |
246 |
|
switch (opt) { |
247 |
case XVID_DEC_DECODE : |
case XVID_DEC_DECODE : |
248 |
return decoder_decode((DECODER *) handle, (XVID_DEC_FRAME *) param1); |
return decoder_decode((DECODER *) handle, (XVID_DEC_FRAME *) param1); |
249 |
|
|
259 |
} |
} |
260 |
|
|
261 |
|
|
262 |
int xvid_encore(void * handle, int opt, void * param1, void * param2) |
int |
263 |
{ |
xvid_encore(void *handle, |
264 |
switch (opt) |
int opt, |
265 |
|
void *param1, |
266 |
|
void *param2) |
267 |
{ |
{ |
268 |
|
switch (opt) { |
269 |
case XVID_ENC_ENCODE : |
case XVID_ENC_ENCODE : |
270 |
return encoder_encode((Encoder *) handle, (XVID_ENC_FRAME *) param1, (XVID_ENC_STATS *) param2); |
return encoder_encode((Encoder *) handle, (XVID_ENC_FRAME *) param1, |
271 |
|
(XVID_ENC_STATS *) param2); |
272 |
|
|
273 |
case XVID_ENC_CREATE : |
case XVID_ENC_CREATE : |
274 |
return encoder_create((XVID_ENC_PARAM *) param1); |
return encoder_create((XVID_ENC_PARAM *) param1); |