libcamera: camera_sensor_properties: Add sensor control delays
Add properties covering the sensor control application delays to both the static CameraSensorProperties definitions. The values used are taken from Raspberry Pi's CamHelper class definitions. Where no more specific values are known the delay struct is defined as empty and defaults supplied through the getter function. Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com>
This commit is contained in:
parent
f5db849732
commit
ca64f0514a
5 changed files with 155 additions and 0 deletions
|
@ -21,6 +21,7 @@
|
|||
#include <libcamera/transform.h>
|
||||
|
||||
#include "libcamera/internal/bayer_format.h"
|
||||
#include "libcamera/internal/camera_sensor_properties.h"
|
||||
#include "libcamera/internal/v4l2_subdevice.h"
|
||||
|
||||
namespace libcamera {
|
||||
|
@ -73,6 +74,7 @@ public:
|
|||
virtual const std::vector<controls::draft::TestPatternModeEnum> &
|
||||
testPatternModes() const = 0;
|
||||
virtual int setTestPatternMode(controls::draft::TestPatternModeEnum mode) = 0;
|
||||
virtual const CameraSensorProperties::SensorDelays &sensorDelays() = 0;
|
||||
};
|
||||
|
||||
class CameraSensorFactoryBase
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
#pragma once
|
||||
|
||||
#include <map>
|
||||
#include <stdint.h>
|
||||
#include <string>
|
||||
|
||||
#include <libcamera/control_ids.h>
|
||||
|
@ -16,10 +17,18 @@
|
|||
namespace libcamera {
|
||||
|
||||
struct CameraSensorProperties {
|
||||
struct SensorDelays {
|
||||
uint8_t exposureDelay;
|
||||
uint8_t gainDelay;
|
||||
uint8_t vblankDelay;
|
||||
uint8_t hblankDelay;
|
||||
};
|
||||
|
||||
static const CameraSensorProperties *get(const std::string &sensor);
|
||||
|
||||
Size unitCellSize;
|
||||
std::map<controls::draft::TestPatternModeEnum, int32_t> testPatternModes;
|
||||
SensorDelays sensorDelays;
|
||||
};
|
||||
|
||||
} /* namespace libcamera */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue