Class representing a camera. More...
Classes | |
| class | FrameChangedEventArgs |
| Argument class passed with the event that occurs when the stream image frame has changed. More... | |
| class | PictureStateChangedEventArgs |
| Argument class passed with the event that occurs when the picture state has changed. More... | |
Public Member Functions | |
| Camera (int cameraId) | |
| Constructor that activates a camera and creates an instance The instance must be destroyed using the Dispose method Because only one camera can be used, when using a different camera, a new instance must be created after deleting the current instance. | |
| void | Dispose () |
| Destroy the camera instance. | |
| void | Open () |
| Open the stream with the default resolution. | |
| void | Open (int sizeId) |
| Open the stream with the specified resolution. | |
| void | Close () |
| Close the stream. | |
| void | Start () |
| Starts image streaming Reads data asynchronously to the buffer when the FrameChanged event is set. | |
| void | Stop () |
| Stops image streaming. | |
| void | Read () |
| Reads data of the stream to the buffer. | |
| void | TakePicture (int sizeId) |
| Takes a photograph The format of the taken photograph is JPEG The taken photograph will be stored in a file This method can only be called while an image is being streamed. | |
Static Public Member Functions | |
| static int | GetNumberOfCameras () |
| Obtain the number of cameras. | |
| static CameraInfo | GetCameraInfo (int cameraId) |
| Obtain detailed information of the camera. | |
Protected Member Functions | |
| void | Dispose (bool disposing) |
| Destroy the camera instance. | |
Properties | |
| CameraState | CameraState [get] |
| Obtain the operational state of a camera. | |
| PictureState | PictureState [get] |
| Obtain the camera's photo taking state. | |
| CameraSize | CurrentPreviewSize [get] |
| Obtains the currently set stream image's resolution. | |
| CameraImageFormat | CurrentPreviewImageFormat [get] |
| Obtains the currently set stream data format. | |
| string | PictureFilename [get] |
| Obtains the file path of the taken photograph. | |
Events | |
|
EventHandler < FrameChangedEventArgs > | FrameChanged |
| Event that occurs when the stream image frame has changed Occurs asynchronously in a thread separate from the thread that called the Start method. | |
|
EventHandler < PictureStateChangedEventArgs > | PictureStateChanged |
| Event that occurs when the picture state has changed Occurs asynchronously in a thread separate from the thread that called the TakePicture method. | |
Class representing a camera.
| Camera | ( | int | cameraId | ) |
Constructor that activates a camera and creates an instance
The instance must be destroyed using the Dispose method
Because only one camera can be used, when using a different camera, a new instance must be created after deleting the current instance.
| cameraId | Camera number |
| void Dispose | ( | bool | disposing | ) | [protected] |
Destroy the camera instance.
| disposing | Whether an instance is being destroyed or not |
| static CameraInfo GetCameraInfo | ( | int | cameraId | ) | [static] |
Obtain detailed information of the camera.
| cameraId | Camera number |
| static int GetNumberOfCameras | ( | ) | [static] |
Obtain the number of cameras.
| void Open | ( | int | sizeId | ) |
Open the stream with the specified resolution.
| sizeId | Number of the resolution for an image to be used in a stream |
| void TakePicture | ( | int | sizeId | ) |
Takes a photograph
The format of the taken photograph is JPEG
The taken photograph will be stored in a file
This method can only be called while an image is being streamed.
| sizeId | Number of the resolution for an image to be used in taking a photograph |