Video capturing class
Inheritance Hierarchy
OpenCvSharpDisposableObject
OpenCvSharpDisposableCvObject
OpenCvSharpCvCapture
Namespace: OpenCvSharp
Assembly: OpenCvSharp (in OpenCvSharp.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
The CvCapture type exposes the following members.
Constructors
Name | Description | |
---|---|---|
CvCapture(Int32) |
Allocates and initialized the CvCapture structure for reading a video stream from the camera.
Currently two camera interfaces can be used on Windows: Video for Windows (VFW) and Matrox Imaging Library (MIL); and two on Linux: V4L and FireWire (IEEE1394).
| |
CvCapture(IntPtr) |
ポインタから初期化
| |
CvCapture(String) |
Allocates and initialized the CvCapture structure for reading the video stream from the specified file.
After the allocated structure is not used any more it should be released by cvReleaseCapture function.
| |
CvCapture(CaptureDevice) |
Allocates and initialized the CvCapture structure for reading a video stream from the camera.
Currently two camera interfaces can be used on Windows: Video for Windows (VFW) and Matrox Imaging Library (MIL); and two on Linux: V4L and FireWire (IEEE1394).
| |
CvCapture(CaptureDevice, Int32) |
Allocates and initialized the CvCapture structure for reading a video stream from the camera.
Currently two camera interfaces can be used on Windows: Video for Windows (VFW) and Matrox Imaging Library (MIL); and two on Linux: V4L and FireWire (IEEE1394).
|
Properties
Name | Description | |
---|---|---|
AllocatedMemory |
Gets or sets a memory address allocated by AllocMemory.
(Inherited from DisposableObject.) | |
AllocatedMemorySize |
Gets or sets the byte length of the allocated memory
(Inherited from DisposableObject.) | |
AutoExposure |
exposure control done by camera,
user can adjust refernce level using this feature
[CV_CAP_PROP_AUTO_EXPOSURE]
| |
AutoGrab |
property for highgui class CvCapture_Android only
[CV_CAP_PROP_AUTOGRAB]
| |
Brightness |
Gets or sets brightness of image (only for cameras)
| |
CaptureType |
Gets the capture type (File or Camera)
| |
Contrast |
Gets or sets contrast of image (only for cameras)
| |
ConvertRgb |
Boolean flags indicating whether images should be converted to RGB
| |
CvPtr |
Native pointer of OpenCV structure
(Inherited from DisposableCvObject.) | |
Exposure |
Exposure (only for cameras)
| |
Format |
The format of the Mat objects returned by retrieve()
| |
FourCC |
Gets or sets 4-character code of codec
| |
Fps |
Gets or sets frame rate
| |
FrameCount |
Gets number of frames in video file
| |
FrameHeight |
Gets or sets height of frames in the video stream
| |
FrameWidth |
Gets or sets width of frames in the video stream
| |
Gain |
Gain of the image (only for cameras)
| |
Gamma |
[CV_CAP_PROP_GAMMA]
| |
GStreamerQueueLength |
default is 1
[CV_CAP_GSTREAMER_QUEUE_LENGTH]
| |
Hue |
Gets or sets hue of image (only for cameras)
| |
IsDisposed |
Gets a value indicating whether this instance has been disposed.
(Inherited from DisposableObject.) | |
IsEnabledDispose |
Gets or sets a value indicating whether you permit disposing this instance.
(Inherited from DisposableObject.) | |
MaxDC1394 |
[CV_CAP_PROP_MAX_DC1394]
| |
Mode |
A backend-specific value indicating the current capture mode
| |
Monocrome | ||
OpenNI_Baseline |
in mm
[CV_CAP_PROP_OPENNI_BASELINE]
| |
OpenNI_DepthGeneratorBaseline |
[CV_CAP_OPENNI_DEPTH_GENERATOR_BASELINE]
| |
OpenNI_DepthGeneratorFocalLength |
[CV_CAP_OPENNI_DEPTH_GENERATOR_FOCAL_LENGTH]
| |
OpenNI_DepthGeneratorRegistrationON |
[CV_CAP_OPENNI_DEPTH_GENERATOR_REGISTRATION_ON]
| |
OpenNI_FocalLength |
in pixels
[CV_CAP_PROP_OPENNI_FOCAL_LENGTH]
| |
OpenNI_FrameMaxDepth |
in mm
[CV_CAP_PROP_OPENNI_FRAME_MAX_DEPTH]
| |
OpenNI_ImageGeneratorOutputMode |
[CV_CAP_OPENNI_IMAGE_GENERATOR_OUTPUT_MODE]
| |
OpenNI_OutputMode |
[CV_CAP_PROP_OPENNI_OUTPUT_MODE]
| |
OpenNI_Registratiob |
flag that synchronizes the remapping depth map to image map
by changing depth generator's view point (if the flag is "on") or
sets this view point to its normal one (if the flag is "off").
[CV_CAP_PROP_OPENNI_REGISTRATION]
| |
OpenNI_RegistrationON |
flag
[CV_CAP_PROP_OPENNI_REGISTRATION_ON]
| |
PosAviRatio |
Gets or sets relative position of video file
| |
PosFrames |
Gets or sets 0-based index of the frame to be decoded/captured next
| |
PosMsec |
Gets or sets film current position in milliseconds or video capture timestamp
| |
PreviewFormat |
readonly, tricky property, returns cpnst char* indeed
[CV_CAP_PROP_PREVIEW_FORMAT]
| |
PvAPIMulticastIP |
ip for anable multicast master mode. 0 for disable multicast
[CV_CAP_PROP_PVAPI_MULTICASTIP]
| |
Rectification |
TOWRITE (note: only supported by DC1394 v 2.x backend currently)
| |
Saturation |
Gets or sets saturation of image (only for cameras)
| |
Sharpness |
[CV_CAP_PROP_SHARPNESS]
| |
SupportedPreviewSizesString |
readonly, tricky property, returns cpnst char* indeed
[CV_CAP_PROP_SUPPORTED_PREVIEW_SIZES_STRING]
| |
Temperature |
[CV_CAP_PROP_TEMPERATURE]
| |
Trigger |
[CV_CAP_PROP_TRIGGER]
| |
TriggerDelay |
[CV_CAP_PROP_TRIGGER_DELAY]
| |
WhiteBalance | ||
WhiteBalanceRedV |
[CV_CAP_PROP_WHITE_BALANCE_RED_V]
| |
XI_AEAG |
Automatic exposure/gain
[CV_CAP_PROP_XI_AEAG]
| |
XI_AEAGLevel |
default is 1
[CV_CAP_PROP_XI_AEAG_LEVEL]
| |
XI_AEMaxLimit |
Maximum limit of exposure in AEAG procedure
[CV_CAP_PROP_XI_AE_MAX_LIMIT]
| |
XI_AGMaxLimit |
Maximum limit of gain in AEAG procedure
[CV_CAP_PROP_XI_AG_MAX_LIMIT]
| |
XI_AutoWB |
Automatic white balance
[CV_CAP_PROP_XI_AUTO_WB]
| |
XI_DataFormat |
Output data format.
[CV_CAP_PROP_XI_DATA_FORMAT]
| |
XI_Downsampling |
Change image resolution by binning or skipping.
[CV_CAP_PROP_XI_DOWNSAMPLING]
| |
XI_ExpPriority |
Exposure priority (0.5 - exposure 50%, gain 50%).
[CV_CAP_PROP_XI_EXP_PRIORITY]
| |
XI_GpiLevel |
Get general purpose level
[CV_CAP_PROP_XI_GPI_LEVEL]
| |
XI_GpiMode |
Set general purpose input mode
[CV_CAP_PROP_XI_GPI_MODE]
| |
XI_GpiSelector |
Selects general purpose input
[CV_CAP_PROP_XI_GPI_SELECTOR]
| |
XI_GpoMode |
Set general purpose output mode
[CV_CAP_PROP_XI_GPO_MODE]
| |
XI_GpoSelector |
Selects general purpose output
[CV_CAP_PROP_XI_GPO_SELECTOR]
| |
XI_LedMode |
Define camera signalling LED functionality
[CV_CAP_PROP_XI_LED_MODE]
| |
XI_LedSelector |
Selects camera signalling LED
[CV_CAP_PROP_XI_LED_SELECTOR]
| |
XI_ManualWB |
Calculates White Balance(must be called during acquisition)
[CV_CAP_PROP_XI_MANUAL_WB]
| |
XI_OffsetX |
Horizontal offset from the origin to the area of interest (in pixels).
[CV_CAP_PROP_XI_OFFSET_X]
| |
XI_OffsetY |
Vertical offset from the origin to the area of interest (in pixels).
[CV_CAP_PROP_XI_OFFSET_Y]
| |
XI_Timeout |
default is 1
[CV_CAP_PROP_XI_TIMEOUT]
| |
XI_TrgSoftware |
Generates an internal trigger. PRM_TRG_SOURCE must be set to TRG_SOFTWARE.
[CV_CAP_PROP_XI_TRG_SOFTWARE]
| |
XI_TrgSource |
Defines source of trigger.
[CV_CAP_PROP_XI_TRG_SOURCE]
|
Methods
Name | Description | |
---|---|---|
AllocGCHandle |
Pins the object to be allocated by cvSetData.
(Inherited from DisposableObject.) | |
AllocMemory |
Allocates the specified size of memory.
(Inherited from DisposableObject.) | |
Dispose |
Releases the resources
(Inherited from DisposableObject.) | |
Dispose(Boolean) |
Clean up any resources being used.
(Overrides DisposableCvObjectDispose(Boolean).) | |
Equals | (Inherited from Object.) | |
Finalize |
Destructor
(Inherited from DisposableObject.) | |
FromCamera(Int32) |
Allocates and initialized the CvCapture structure for reading a video stream from the camera.
Currently two camera interfaces can be used on Windows: Video for Windows (VFW) and Matrox Imaging Library (MIL); and two on Linux: V4L and FireWire (IEEE1394).
| |
FromCamera(CaptureDevice) |
Allocates and initialized the CvCapture structure for reading a video stream from the camera.
Currently two camera interfaces can be used on Windows: Video for Windows (VFW) and Matrox Imaging Library (MIL); and two on Linux: V4L and FireWire (IEEE1394).
| |
FromCamera(CaptureDevice, Int32) |
Allocates and initialized the CvCapture structure for reading a video stream from the camera.
Currently two camera interfaces can be used on Windows: Video for Windows (VFW) and Matrox Imaging Library (MIL); and two on Linux: V4L and FireWire (IEEE1394).
| |
FromFile |
Allocates and initialized the CvCapture structure for reading the video stream from the specified file.
After the allocated structure is not used any more it should be released by cvReleaseCapture function.
| |
GetCaptureProperty(Int32) |
Retrieves the specified property of camera or video file.
| |
GetCaptureProperty(CaptureProperty) |
Retrieves the specified property of camera or video file.
| |
GetHashCode | (Inherited from Object.) | |
GetType | (Inherited from Object.) | |
GrabFrame |
Grabs the frame from camera or file. The grabbed frame is stored internally.
The purpose of this function is to grab frame fast that is important for syncronization in case of reading from several cameras simultaneously.
The grabbed frames are not exposed because they may be stored in compressed format (as defined by camera/driver).
To retrieve the grabbed frame, cvRetrieveFrame should be used.
| |
MemberwiseClone | (Inherited from Object.) | |
NotifyMemoryPressure |
Notifies the allocated size of memory.
(Inherited from DisposableObject.) | |
QueryFrame |
Grabs a frame from camera or video file, decompresses and returns it.
This function is just a combination of cvGrabFrame and cvRetrieveFrame in one call.
The returned image should not be released or modified by user.
| |
RetrieveFrame |
Returns the pointer to the image grabbed with cvGrabFrame function.
The returned image should not be released or modified by user.
| |
RetrieveFrame(Int32) |
Returns the pointer to the image grabbed with cvGrabFrame function.
The returned image should not be released or modified by user.
| |
RetrieveFrame(CameraChannels) |
Returns the pointer to the image grabbed with cvGrabFrame function.
The returned image should not be released or modified by user.
| |
SetCaptureProperty(Int32, Double) |
Sets the specified property of video capturing.
| |
SetCaptureProperty(CaptureProperty, Double) |
Sets the specified property of video capturing.
| |
ThrowIfDisposed |
If this object is disposed, then ObjectDisposedException is thrown.
(Inherited from DisposableObject.) | |
ToString | (Inherited from Object.) |
Fields
Name | Description | |
---|---|---|
captureType |
Capture type (File or Camera)
| |
dataHandle |
Gets or sets a handle which allocates using cvSetData.
(Inherited from DisposableObject.) | |
disposed |
Track whether Dispose has been called
| |
ptr |
Data pointer
(Inherited from DisposableCvObject.) |
See Also