GuiCamera
<projects/gui/GuiCamera.h>
This is the abstract interface for all camera objects. Any new camera plugin has to follow this interface.
Member Fields
Field | Type | Notes |
---|---|---|
staticMetaObject | const QMetaObject |
MISSING |
Member Functions
(constructor) | |
Returns the index of the camera in the list of cameras. This is unique to each camera. |
|
Checks to see if there is an image waiting in the image buffer. Returns false on timeout. |
|
Helper function to make sure any writes to files or streams are cleaned up correctly. |
|
Closes the camera. |
|
Return the number of images captured. |
|
While capturing images there are lots of threads running to take those images from the image buffer and save them (GrabAndSaveImageTask). Whenever a thread associated with this camera finishes its work, it calls this function to decrease the count of the number of threads accessing this object. |
|
Returns the number of images dropped in the last capture. |
|
Return a string with the firmware level of the firware currently running on the camera. |
|
Function called by GrabAndSaveImageTask when it has finished its work. It checks to see if all the threads are done processing, and if so, cleans up file writes and then signals that the camera is done capturing. |
|
Returns the height of the images the camera is currently configured to capture. |
|
Returns the frame rate of the camera. |
|
Given the base directory, return the path for the image output directory that works with the project structure. |
|
Given the directory, returns the path for the file containing information about the timesteps of each image from the capture. This is mainly for debug/logging purposes. |
|
Increase the counter for the current image index value. Each image grabbed should have a unique number that represents where it should be placed in the sequence of images captured. If the user wants to capture 3000 images, then the images will have indexes from 0-2999 inclusive, and this function keeps track of that. When running in a multi-threaded environment this function needs the correct guards to ensure atomicity. |
|
Increase the number of dropped images by one. |
|
While capturing images there are lots of threads running to take those images from the image buffer and save them (GrabAndSaveImageTask). Whenever a thread associated with this camera starts its work, it calls this function to increase the count of the number of threads accessing this object. |
|
Initialize the files and streams needed for output and debug. |
|
Is the camera connected. This is checking if the camera has been associated with a device in the kernel. |
|
Is the camera currently set up to be triggered by a hardware trigger ( i.e. a TTL pulse )? |
|
Is the camera connected and open? When a camera is open it is in a state that settings can be set and retrieved on it. |
|
If the hardware trigger is set for the camera, has the camera prepared itself to recieve the trigger and is it currently waiting on said trigger? |
|
Have the camera connect. This usually involves registering the camera with a camera device, but is obviously dependent on the camera. |
|
What is the maximum size of the image buffer used to hold images. If the image buffer is too small and the camera is taking images fast enough, there will be images that are dropped. |
|
Return the name of the camera. This is usually just the model name with the serial number or something else uniquely identifiable included. |
|
Open the camera device for use. This is usually the first step of two to allow software to use a camera. First the camera device is opened, and then the camera device is connected. |
|
Configure the camera so that a data capture is saved as individual files and not a single video. |
|
Configure the camera so that it saves a data capture as a video and not as individual files. |
|
How many images were successfully captured during the recording operation? |
|
How long should the system wait before returning a failure when the image buffer is empty? |
|
Retrieve an image that is currently in the image buffer. Or, if not currently there, will be there in less than the value for the Retrieval Timeout. |
|
Set the camera to use a hardware trigger. This obviously requires the use of an external device for signalling to the cameras with a TTL pulse that they should capture. |
|
Have the camera use a software trigger. This means that if the frame rate of the cameras is sufficiently high, the timesteps of the images wil not line up. |
|
Signal that an error has been received. |
|
Signal that the camera is finished capturing images. |
|
Signal that a grab of an image from the image buffer was done and pass along the image that was grabbed. |
|
Signal that the camera has starting putting images in the image buffer. This is a signal to the GrabAndSaveImageTask that images are available to be dealt with. |
|
Signal that images were dropped while trying to collect them from the image buffer. |
|
Signal that an image has been successfully saved. |
|
Signal for all cameras to refresh their settings becausean event may have changed something important. A good example is hotplugging cameras. |
|
Instruct the camera to start grabbing images, but these images can be lossy as we are going to use them for a preview and not a strict image collection. If your camera has the ability to grab from the top of the image buffer and discard the rest, this is where that functionality should be used as we don’t care about dropped images since the human eye only see ~30 frames a second anyways. |
|
Start grabbing images that will be used for a capture. This tries not to drop any images. |
|
Ask the camera to stop capturing images into the image buffer. |
|
Update the configuration of the camera using an already saved GenApi configuration file. |
|
Return the width of the images that the currently configured camera can capture. |
|
Log information about the image. |
|
QT auto-generated function. Don’t directly call. |
|
No details given |
|
QT auto-generated function. Don’t directly call. |
|
QT auto-generated function. Don’t directly call. |
|
QT auto-generated function. Don’t directly call. |
|
QT auto-generated function. Don’t directly call. |
|
QT auto-generated function. Don’t directly call. |