71 lines
1.3 KiB
C++
71 lines
1.3 KiB
C++
#ifndef _VIDCAP_BMPCAP_HPP_
|
|
#define _VIDCAP_BMPCAP_HPP_
|
|
#ifndef _COMMON_BITMAPINFO_HPP_
|
|
#include <common/bminfo.hpp>
|
|
#endif
|
|
|
|
#ifndef _CODEC_VIDEOCODEC_HPP_
|
|
#include <codec/vidc.hpp>
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#ifndef _VIDCAP_VIDCAP_HPP_
|
|
#include <vidcap/vidcap.hpp>
|
|
#endif
|
|
|
|
|
|
class BmpCap : public VidCap
|
|
{
|
|
public:
|
|
BmpCap(HWND hParentWnd,DWORD driverIndex);
|
|
BmpCap(void);
|
|
virtual ~BmpCap();
|
|
void initialize(HWND hParentWnd,DWORD driverIndex);
|
|
bool saveFrames(void)const;
|
|
void saveFrames(bool saveFrames);
|
|
const String &getCaptureFileName(void)const;
|
|
void setCaptureFileName(const String &strPathCaptureFile);
|
|
protected:
|
|
virtual void message(const String &message);
|
|
virtual void frameHandler(VIDEOHDR &videoHeader);
|
|
private:
|
|
BitmapInfo mBitmapInfo;
|
|
BitmapInfo mDstBitmapInfo;
|
|
CaptureStatus mCaptureStatus;
|
|
VideoCodec mVideoCodec;
|
|
int mSequence;
|
|
bool mSaveFrames;
|
|
bool mUseSequence;
|
|
DWORD mCaptureWidth;
|
|
DWORD mCaptureHeight;
|
|
DWORD mQuality;
|
|
String mCaptureFile;
|
|
};
|
|
|
|
inline
|
|
bool BmpCap::saveFrames(void)const
|
|
{
|
|
return mSaveFrames;
|
|
}
|
|
|
|
inline
|
|
void BmpCap::saveFrames(bool saveFrames)
|
|
{
|
|
mSaveFrames=saveFrames;
|
|
}
|
|
|
|
inline
|
|
const String &BmpCap::getCaptureFileName(void)const
|
|
{
|
|
return mCaptureFile;
|
|
}
|
|
|
|
inline
|
|
void BmpCap::setCaptureFileName(const String &strPathCaptureFile)
|
|
{
|
|
mCaptureFile=strPathCaptureFile;
|
|
}
|
|
#endif
|