Buffer.h
资源名称:fister.zip [点击查看]
上传用户:zjb_0001
上传日期:2007-01-11
资源大小:154k
文件大小:1k
源码类别:
Audio
开发平台:
Visual C++
- // Buffer.h: interface for the CBuffer class.
- //
- //////////////////////////////////////////////////////////////////////
- #if !defined(AFX_BUFFER_H__B4B9CF06_B948_49A5_9145_ECB3E318BF05__INCLUDED_)
- #define AFX_BUFFER_H__B4B9CF06_B948_49A5_9145_ECB3E318BF05__INCLUDED_
- #if _MSC_VER > 1000
- #pragma once
- #endif // _MSC_VER > 1000
- #include "errorprint.h"
- class CBuffer
- {
- public:
- void Erase();
- CBuffer(DWORD size, bool AutoDelete = true);
- CBuffer(void* buffer, DWORD length);
- virtual ~CBuffer();
- union PointerUnion{
- BYTE* b;
- char* c;
- WORD* w;
- short int* s;
- DWORD* d;
- int* i;
- float* f;
- double* r; // real
- void* v;
- }ptr;
- int ByteLen; // length in bytes
- private:
- bool m_bAutoDelete;
- };
- #endif // !defined(AFX_BUFFER_H__B4B9CF06_B948_49A5_9145_ECB3E318BF05__INCLUDED_)