--- encoder.h 2002/07/19 14:56:00 1.15 +++ encoder.h 2005/12/09 04:45:35 1.29 @@ -1,16 +1,10 @@ /***************************************************************************** * * XVID MPEG-4 VIDEO CODEC - * - Encoder header - + * - Encoder related header - * - * This program is an implementation of a part of one or more MPEG-4 - * Video tools as specified in ISO/IEC 14496-2 standard. Those intending - * to use this software module in hardware or software products are - * advised that its use may infringe existing patents or copyrights, and - * any such use would be at such party's own risk. The original - * developer of this software module and his/her company, and subsequent - * editors and their companies, will have no liability for use of this - * software or modifications or derivatives thereof. + * Copyright(C) 2002-2003 Michael Militzer + * 2002-2003 Peter Ross * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -26,17 +20,7 @@ * along with this program ; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * - ****************************************************************************/ -/***************************************************************************** - * - * 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 - * - * $Id: encoder.h,v 1.15 2002/07/19 14:56:00 chl Exp $ + * $Id: encoder.h,v 1.29 2005/12/09 04:45:35 syskin Exp $ * ****************************************************************************/ @@ -46,19 +30,13 @@ #include "xvid.h" #include "portab.h" #include "global.h" -#include "image/image.h" -#include "utils/ratecontrol.h" /***************************************************************************** * Constants ****************************************************************************/ -/* Quatization type */ -#define H263_QUANT 0 -#define MPEG4_QUANT 1 - -/* Indicates no quantizer changes in INTRA_Q/INTER_Q modes */ -#define NO_CHANGE 64 +/* lambda base exponential. 1<= 0 */ + int m_framenum; /* debug frame num counter; unlike iFrameNum, does not reset at ivop */ -#endif - Statistics sStat; - RateControl rate_control; -} -Encoder; + float fMvPrevSigma; +} Encoder; /***************************************************************************** * Inline functions @@ -251,14 +261,10 @@ void init_encoder(uint32_t cpu_flags); -int encoder_create(XVID_ENC_PARAM * pParam); -int encoder_destroy(Encoder * pEnc); -int encoder_encode(Encoder * pEnc, - XVID_ENC_FRAME * pFrame, - XVID_ENC_STATS * pResult); - -int encoder_encode_bframes(Encoder * pEnc, - XVID_ENC_FRAME * pFrame, - XVID_ENC_STATS * pResult); +int enc_create(xvid_enc_create_t * create); +int enc_destroy(Encoder * pEnc); +int enc_encode(Encoder * pEnc, + xvid_enc_frame_t * pFrame, + xvid_enc_stats_t * stats); #endif