Compress.h
上传用户:popouu88
上传日期:2013-02-11
资源大小:2894k
文件大小:1k
源码类别:

IP电话/视频会议

开发平台:

Visual C++

  1. #ifndef _COMPRESS_H_
  2. #define _COMPRESS_H_
  3. #define SIZE_AUDIO_FRAME 4800
  4. #define SIZE_AUDIO_PACKED 300
  5. class CCompress
  6. {
  7. public:
  8. enum{ GSM610 = 1 , G729a };
  9.          CCompress() { type = 0; }
  10. virtual ~CCompress() {}
  11. virtual int    GetType( void ){ return type; }
  12. virtual char * Compress(char* src,int * srclen ) = 0;
  13. virtual char * UnCompress(char* src,int * srclen ) = 0;
  14. protected:
  15. int  type;
  16. char compress_buffer[ 2* SIZE_AUDIO_FRAME ];
  17. char uncompress_buffer[ 2* SIZE_AUDIO_FRAME ];
  18. };
  19. #endif