// CodeGear C++Builder
// Copyright (c) 1995, 2015 by Embarcadero Technologies, Inc.
// All rights reserved

// (DO NOT EDIT: machine generated header) 'videocap.pas' rev: 30.00 (Windows)

#ifndef VideocapHPP
#define VideocapHPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member 
#pragma pack(push,8)
#include <System.hpp>
#include <SysInit.hpp>
#include <Winapi.Windows.hpp>
#include <Winapi.Messages.hpp>
#include <System.SysUtils.hpp>
#include <Vcl.StdCtrls.hpp>
#include <System.Classes.hpp>
#include <Vcl.Graphics.hpp>
#include <Vcl.Controls.hpp>
#include <Vcl.Forms.hpp>
#include <imageenview.hpp>
#include <imageenproc.hpp>
#include <hyiedefs.hpp>
#include <ievect.hpp>
#include <ieview.hpp>
#include <hyieutils.hpp>
#include <System.Types.hpp>
#include <System.UITypes.hpp>

//-- user supplied -----------------------------------------------------------

namespace Videocap
{
//-- forward type declarations -----------------------------------------------
class DELPHICLASS TVideoCapException;
struct TCAPDRIVERCAPS;
struct TVIDEOHDR;
struct TCAPSTATUS;
struct TCAPTUREPARMS;
struct TWAVEFORMATEX;
class DELPHICLASS TImageEnVideoView;
//-- type declarations -------------------------------------------------------
#pragma pack(push,4)
class PASCALIMPLEMENTATION TVideoCapException : public System::Sysutils::Exception
{
	typedef System::Sysutils::Exception inherited;
	
public:
	/* Exception.Create */ inline __fastcall TVideoCapException(const System::UnicodeString Msg) : System::Sysutils::Exception(Msg) { }
	/* Exception.CreateFmt */ inline __fastcall TVideoCapException(const System::UnicodeString Msg, System::TVarRec const *Args, const int Args_High) : System::Sysutils::Exception(Msg, Args, Args_High) { }
	/* Exception.CreateRes */ inline __fastcall TVideoCapException(NativeUInt Ident)/* overload */ : System::Sysutils::Exception(Ident) { }
	/* Exception.CreateRes */ inline __fastcall TVideoCapException(System::PResStringRec ResStringRec)/* overload */ : System::Sysutils::Exception(ResStringRec) { }
	/* Exception.CreateResFmt */ inline __fastcall TVideoCapException(NativeUInt Ident, System::TVarRec const *Args, const int Args_High)/* overload */ : System::Sysutils::Exception(Ident, Args, Args_High) { }
	/* Exception.CreateResFmt */ inline __fastcall TVideoCapException(System::PResStringRec ResStringRec, System::TVarRec const *Args, const int Args_High)/* overload */ : System::Sysutils::Exception(ResStringRec, Args, Args_High) { }
	/* Exception.CreateHelp */ inline __fastcall TVideoCapException(const System::UnicodeString Msg, int AHelpContext) : System::Sysutils::Exception(Msg, AHelpContext) { }
	/* Exception.CreateFmtHelp */ inline __fastcall TVideoCapException(const System::UnicodeString Msg, System::TVarRec const *Args, const int Args_High, int AHelpContext) : System::Sysutils::Exception(Msg, Args, Args_High, AHelpContext) { }
	/* Exception.CreateResHelp */ inline __fastcall TVideoCapException(NativeUInt Ident, int AHelpContext)/* overload */ : System::Sysutils::Exception(Ident, AHelpContext) { }
	/* Exception.CreateResHelp */ inline __fastcall TVideoCapException(System::PResStringRec ResStringRec, int AHelpContext)/* overload */ : System::Sysutils::Exception(ResStringRec, AHelpContext) { }
	/* Exception.CreateResFmtHelp */ inline __fastcall TVideoCapException(System::PResStringRec ResStringRec, System::TVarRec const *Args, const int Args_High, int AHelpContext)/* overload */ : System::Sysutils::Exception(ResStringRec, Args, Args_High, AHelpContext) { }
	/* Exception.CreateResFmtHelp */ inline __fastcall TVideoCapException(NativeUInt Ident, System::TVarRec const *Args, const int Args_High, int AHelpContext)/* overload */ : System::Sysutils::Exception(Ident, Args, Args_High, AHelpContext) { }
	/* Exception.Destroy */ inline __fastcall virtual ~TVideoCapException(void) { }
	
};

#pragma pack(pop)

enum DECLSPEC_DENUM TVCDisplayMode : unsigned char { dmPreview, dmOverlay };

typedef void __fastcall (__closure *TVideoFrameEvent)(System::TObject* Sender, Hyieutils::TIEDibbitmap* Bitmap);

typedef void __fastcall (__closure *TVideoFrameRawEvent)(System::TObject* Sender, NativeUInt hDib, void * pData);

struct DECLSPEC_DRECORD TCAPDRIVERCAPS
{
public:
	int wDeviceIndex;
	System::LongBool fHasOverlay;
	System::LongBool fHasDlgVideoSource;
	System::LongBool fHasDlgVideoFormat;
	System::LongBool fHasDlgVideoDisplay;
	System::LongBool fCaptureInitialized;
	System::LongBool fDriverSuppliesPalettes;
	NativeUInt hVideoIn;
	NativeUInt hVideoOut;
	NativeUInt hVideoExtIn;
	NativeUInt hVideoExtout;
};


typedef TCAPDRIVERCAPS *PCAPDRIVERCAPS;

struct DECLSPEC_DRECORD TVIDEOHDR
{
public:
	System::Byte *lpData;
	unsigned dwBufferLength;
	unsigned dwBytesUsed;
	unsigned dwTimeCaptured;
	unsigned dwUser;
	unsigned dwFlags;
	System::StaticArray<unsigned, 4> dwReserved;
};


typedef TVIDEOHDR *PVIDEOHDR;

struct DECLSPEC_DRECORD TCAPSTATUS
{
public:
	unsigned uiImageWidth;
	unsigned uiImageHeight;
	System::LongBool fLiveWindow;
	System::LongBool fOverlayWindow;
	System::LongBool fScale;
	System::Types::TPoint ptScroll;
	System::LongBool fUsingDefaultPalette;
	System::LongBool fAudioHardware;
	System::LongBool fCapFileExists;
	unsigned dwCurrentVideoFrame;
	unsigned dwCurrentVideoFramesDropped;
	unsigned dwCurrentWaveSamples;
	unsigned dwCurrentTimeElapsedMS;
	NativeUInt hPalCurrent;
	System::LongBool fCapturingNow;
	unsigned dwReturn;
	unsigned wNumVideoAllocated;
	unsigned wNumAudioAllocated;
};


typedef TCAPSTATUS *PCAPSTATUS;

typedef TCAPTUREPARMS *PCAPTUREPARMS;

struct DECLSPEC_DRECORD TCAPTUREPARMS
{
public:
	unsigned dwRequestMicroSecPerFrame;
	System::LongBool fMakeUserHitOKToCapture;
	unsigned wPercentDropForError;
	System::LongBool fYield;
	unsigned dwIndexSize;
	unsigned wChunkGranularity;
	System::LongBool fUsingDOSMemory;
	unsigned wNumVideoRequested;
	System::LongBool fCaptureAudio;
	unsigned wNumAudioRequested;
	unsigned vKeyAbort;
	System::LongBool fAbortLeftMouse;
	System::LongBool fAbortRightMouse;
	System::LongBool fLimitEnabled;
	unsigned wTimeLimit;
	System::LongBool fMCIControl;
	System::LongBool fStepMCIDevice;
	unsigned dwMCIStartTime;
	unsigned dwMCIStopTime;
	System::LongBool fStepCaptureAt2x;
	unsigned wStepCaptureAverageFrames;
	unsigned dwAudioBufferSize;
	System::LongBool fDisableWriteCache;
	unsigned AVStreamMaster;
};


typedef TWAVEFORMATEX *PWAVEFORMATEX;

struct DECLSPEC_DRECORD TWAVEFORMATEX
{
public:
	System::Word wFormatTag;
	System::Word nChannels;
	unsigned nSamplesPerSec;
	unsigned nAvgBytesPerSec;
	System::Word nBlockAlign;
	System::Word wBitsPerSample;
	System::Word cbSize;
};


class PASCALIMPLEMENTATION TImageEnVideoView _DEPRECATED_ATTRIBUTE0  : public Ievect::TImageEnVect
{
	typedef Ievect::TImageEnVect inherited;
	
private:
	bool fShowVideo _DEPRECATED_ATTRIBUTE0 ;
	bool fFreeze _DEPRECATED_ATTRIBUTE0 ;
	TVCDisplayMode fDisplayMode _DEPRECATED_ATTRIBUTE0 ;
	HWND fWndC _DEPRECATED_ATTRIBUTE0 ;
	System::Classes::TStringList* fDrivers _DEPRECATED_ATTRIBUTE0 ;
	int fVideoSource _DEPRECATED_ATTRIBUTE0 ;
	System::Uitypes::TScrollStyle fSScrollBars _DEPRECATED_ATTRIBUTE0 ;
	int fPreviewRate _DEPRECATED_ATTRIBUTE0 ;
	bool fCallBackFrame _DEPRECATED_ATTRIBUTE0 ;
	TVideoFrameEvent fOnVideoFrame _DEPRECATED_ATTRIBUTE0 ;
	TVideoFrameRawEvent fOnVideoFrameRaw _DEPRECATED_ATTRIBUTE0 ;
	NativeUInt fhBitmapInfo _DEPRECATED_ATTRIBUTE0 ;
	bool fBitmapInfoUp _DEPRECATED_ATTRIBUTE0 ;
	bool fConnected _DEPRECATED_ATTRIBUTE0 ;
	bool fFitFreeze _DEPRECATED_ATTRIBUTE0 ;
	Hyiedefs::TIEJobEvent fOnJob _DEPRECATED_ATTRIBUTE0 ;
	NativeUInt fHDrawDib _DEPRECATED_ATTRIBUTE0 ;
	bool fGrabFrame _DEPRECATED_ATTRIBUTE0 ;
	System::AnsiString fRecFileName _DEPRECATED_ATTRIBUTE0 ;
	int fRecFrameRate _DEPRECATED_ATTRIBUTE0 ;
	bool fRecAudio _DEPRECATED_ATTRIBUTE0 ;
	bool fRecMultitask _DEPRECATED_ATTRIBUTE0 ;
	bool fRecording _DEPRECATED_ATTRIBUTE0 ;
	bool fCreatingCaptureWindow _DEPRECATED_ATTRIBUTE0 ;
	
protected:
	void __fastcall SetShowVideo _DEPRECATED_ATTRIBUTE0 (bool v);
	void __fastcall SetFreeze _DEPRECATED_ATTRIBUTE0 (bool v);
	void __fastcall SetDisplayMode _DEPRECATED_ATTRIBUTE0 (TVCDisplayMode v);
	HIDESBASE MESSAGE void __fastcall WMSize _DEPRECATED_ATTRIBUTE0 (Winapi::Messages::TWMSize &Message);
	bool __fastcall DriverConnect _DEPRECATED_ATTRIBUTE0 (void);
	bool __fastcall DriverConnectNE _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall DriverDisconnect _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall SetVideoSource _DEPRECATED_ATTRIBUTE0 (int v);
	virtual void __fastcall SetScrollBars _DEPRECATED_ATTRIBUTE0 (System::Uitypes::TScrollStyle v);
	bool __fastcall GetHasDlgVideoSource _DEPRECATED_ATTRIBUTE0 (void);
	bool __fastcall GetHasDlgVideoFormat _DEPRECATED_ATTRIBUTE0 (void);
	bool __fastcall GetHasDlgVideoDisplay _DEPRECATED_ATTRIBUTE0 (void);
	bool __fastcall GetHasOverlay _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall GetCaps _DEPRECATED_ATTRIBUTE0 (TCAPDRIVERCAPS &fDriverCaps);
	void __fastcall SetPreviewRate _DEPRECATED_ATTRIBUTE0 (int v);
	void __fastcall SetCallBackFrame _DEPRECATED_ATTRIBUTE0 (bool v);
	void __fastcall SetOnVideoFrame _DEPRECATED_ATTRIBUTE0 (TVideoFrameEvent v);
	void __fastcall SetOnVideoFrameRaw _DEPRECATED_ATTRIBUTE0 (TVideoFrameRawEvent v);
	bool __fastcall FillBitmapInfo _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall CreateCaptureWindow _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall DestroyCaptureWindow _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall DoJob _DEPRECATED_ATTRIBUTE0 (Hyiedefs::TIEJob job, int per);
	void __fastcall DecompRawFrame _DEPRECATED_ATTRIBUTE0 (Hyieutils::TIEDibbitmap* OutBitmap, void * pix);
	System::Word __fastcall GetAudioFormat _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall SetAudioFormat _DEPRECATED_ATTRIBUTE0 (System::Word v);
	System::Word __fastcall GetAudioChannels _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall SetAudioChannels _DEPRECATED_ATTRIBUTE0 (System::Word v);
	unsigned __fastcall GetAudioSamplesPerSec _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall SetAudioSamplesPerSec _DEPRECATED_ATTRIBUTE0 (unsigned v);
	System::Word __fastcall GetAudioBitsPerSample _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall SetAudioBitsPerSample _DEPRECATED_ATTRIBUTE0 (System::Word v);
	void __fastcall GetWaveFormat _DEPRECATED_ATTRIBUTE0 (TWAVEFORMATEX &wf);
	void __fastcall SetWaveFormat _DEPRECATED_ATTRIBUTE0 (TWAVEFORMATEX &wf);
	
public:
	__fastcall virtual TImageEnVideoView _DEPRECATED_ATTRIBUTE0 (System::Classes::TComponent* Owner);
	__fastcall virtual ~TImageEnVideoView _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall FillDrivers _DEPRECATED_ATTRIBUTE0 (void);
	virtual void __fastcall Paint _DEPRECATED_ATTRIBUTE0 (void);
	virtual void __fastcall Select _DEPRECATED_ATTRIBUTE0 (int x1, int y1, int x2, int y2, Imageenview::TIESelOp Op);
	bool __fastcall DoConfigureSource _DEPRECATED_ATTRIBUTE0 (void);
	bool __fastcall DoConfigureFormat _DEPRECATED_ATTRIBUTE0 (void);
	bool __fastcall DoConfigureDisplay _DEPRECATED_ATTRIBUTE0 (void);
	bool __fastcall DoConfigureCompression _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall Freeze _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall UnFreeze _DEPRECATED_ATTRIBUTE0 (void);
	__property bool Frozen = {read=fFreeze, write=SetFreeze, default=0};
	void __fastcall SaveFrame _DEPRECATED_ATTRIBUTE0 (void);
	__property System::Classes::TStringList* VideoSourceList = {read=fDrivers};
	__property bool HasOverlay = {read=GetHasOverlay, nodefault};
	__property bool HasDlgVideoSource = {read=GetHasDlgVideoSource, nodefault};
	__property bool HasDlgVideoFormat = {read=GetHasDlgVideoFormat, nodefault};
	__property bool HasDlgVideoDisplay = {read=GetHasDlgVideoDisplay, nodefault};
	bool __fastcall StartRecord _DEPRECATED_ATTRIBUTE0 (void);
	void __fastcall StopRecord _DEPRECATED_ATTRIBUTE0 (void);
	__property System::AnsiString RecFileName = {read=fRecFileName, write=fRecFileName};
	__property int RecFrameRate = {read=fRecFrameRate, write=fRecFrameRate, nodefault};
	__property bool RecAudio = {read=fRecAudio, write=fRecAudio, nodefault};
	__property bool RecMultitask = {read=fRecMultitask, write=fRecMultitask, nodefault};
	__property HWND WndCaptureHandle = {read=fWndC, nodefault};
	System::Types::TRect __fastcall GetVideoSize _DEPRECATED_ATTRIBUTE0 (void);
	__property System::Word AudioFormat = {read=GetAudioFormat, write=SetAudioFormat, nodefault};
	__property System::Word AudioChannels = {read=GetAudioChannels, write=SetAudioChannels, nodefault};
	__property unsigned AudioSamplesPerSec = {read=GetAudioSamplesPerSec, write=SetAudioSamplesPerSec, nodefault};
	__property System::Word AudioBitsPerSample = {read=GetAudioBitsPerSample, write=SetAudioBitsPerSample, nodefault};
	
__published:
	__property bool FitFreeze = {read=fFitFreeze, write=fFitFreeze, default=1};
	__property TVCDisplayMode DisplayMode = {read=fDisplayMode, write=SetDisplayMode, default=0};
	__property bool ShowVideo = {read=fShowVideo, write=SetShowVideo, default=0};
	__property int VideoSource = {read=fVideoSource, write=SetVideoSource, default=0};
	__property int PreviewRate = {read=fPreviewRate, write=SetPreviewRate, default=60};
	__property TVideoFrameEvent OnVideoFrame = {read=fOnVideoFrame, write=SetOnVideoFrame};
	__property TVideoFrameRawEvent OnVideoFrameRaw = {read=fOnVideoFrameRaw, write=SetOnVideoFrameRaw};
	__property Hyiedefs::TIEJobEvent OnJob = {read=fOnJob, write=fOnJob};
public:
	/* TWinControl.CreateParented */ inline __fastcall TImageEnVideoView(HWND ParentWindow) : Ievect::TImageEnVect(ParentWindow) { }
	
};


//-- var, const, procedure ---------------------------------------------------
}	/* namespace Videocap */
#if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_VIDEOCAP)
using namespace Videocap;
#endif
#pragma pack(pop)
#pragma option pop

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// VideocapHPP
