//NetTalk
/*------------------------------------------------------------------------------*\
 =============================
   模块名称: CodecMgr.h
 =============================
 
 [版权]
 
   2000-2002  115软件工厂  版权所有
                                              
\*------------------------------------------------------------------------------*/
/*
音频：G729a

视频：H.263 (Microsoft H.263 codec in VCM)
   支持：
   1.帧碾压                    VIDCF_CRUNCH
   2.实时压缩，自保留前一帧    VIDCF_COMPRESSFRAMES
   3.图象质量参数              VIDCF_QUALITY
   4.VIDCF_TEMPORAL,Driver supports inter-frame compression(MSDN,不知道怎么翻译)
*/
#ifndef _CODECMGR_H_
#define _CODECMGR_H_
#include <vfw.h>
class CAVIOMgr;
class CCodecMgr
{
public:
	void DestroyCodecA();
	BOOL InitCodecA();
	
	void DestroyCodecV();
	BOOL InitCodecV();
	virtual  ~CCodecMgr();
	CCodecMgr();
	
	friend class CAVIOMgr;
protected:
	
	
	BITMAPINFO m_BmpU;
	BITMAPINFO m_BmpC;
	COMPVARS m_cv;
	BOOL EncodeVideoData(char* pin,int len,char* pout,int* lenr,BOOL* pKey);
	BOOL DecodeVideoData(char *pin,int len,char* pout,int *lenr,DWORD flag);
	BOOL EncodeAudioData(char *pin,int len,char* pout,int* lenr);
	BOOL DecodeAudioData(char *pin,int len,char* pout,int* lenr);

	
	HIC m_hIC;
	
};



#endif