android: Add soong blueprint makefiles generated by ninja-to-soong
This commit is contained in:
@@ -0,0 +1,513 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2019, Google Inc.
|
||||
*
|
||||
* Controls ID list
|
||||
*
|
||||
* This file is auto-generated. Do not edit.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <array>
|
||||
#include <map>
|
||||
#include <stdint.h>
|
||||
#include <string>
|
||||
#include <string_view>
|
||||
|
||||
#include <libcamera/controls.h>
|
||||
|
||||
namespace libcamera {
|
||||
|
||||
namespace controls {
|
||||
|
||||
extern const ControlIdMap controls;
|
||||
|
||||
|
||||
enum {
|
||||
AE_ENABLE = 1,
|
||||
AE_STATE = 2,
|
||||
AE_METERING_MODE = 3,
|
||||
AE_CONSTRAINT_MODE = 4,
|
||||
AE_EXPOSURE_MODE = 5,
|
||||
EXPOSURE_VALUE = 6,
|
||||
EXPOSURE_TIME = 7,
|
||||
EXPOSURE_TIME_MODE = 8,
|
||||
ANALOGUE_GAIN = 9,
|
||||
ANALOGUE_GAIN_MODE = 10,
|
||||
AE_FLICKER_MODE = 11,
|
||||
AE_FLICKER_PERIOD = 12,
|
||||
AE_FLICKER_DETECTED = 13,
|
||||
BRIGHTNESS = 14,
|
||||
CONTRAST = 15,
|
||||
LUX = 16,
|
||||
AWB_ENABLE = 17,
|
||||
AWB_MODE = 18,
|
||||
AWB_LOCKED = 19,
|
||||
COLOUR_GAINS = 20,
|
||||
COLOUR_TEMPERATURE = 21,
|
||||
SATURATION = 22,
|
||||
SENSOR_BLACK_LEVELS = 23,
|
||||
SHARPNESS = 24,
|
||||
FOCUS_FO_M = 25,
|
||||
COLOUR_CORRECTION_MATRIX = 26,
|
||||
SCALER_CROP = 27,
|
||||
DIGITAL_GAIN = 28,
|
||||
FRAME_DURATION = 29,
|
||||
FRAME_DURATION_LIMITS = 30,
|
||||
SENSOR_TEMPERATURE = 31,
|
||||
SENSOR_TIMESTAMP = 32,
|
||||
AF_MODE = 33,
|
||||
AF_RANGE = 34,
|
||||
AF_SPEED = 35,
|
||||
AF_METERING = 36,
|
||||
AF_WINDOWS = 37,
|
||||
AF_TRIGGER = 38,
|
||||
AF_PAUSE = 39,
|
||||
LENS_POSITION = 40,
|
||||
AF_STATE = 41,
|
||||
AF_PAUSE_STATE = 42,
|
||||
HDR_MODE = 43,
|
||||
HDR_CHANNEL = 44,
|
||||
GAMMA = 45,
|
||||
DEBUG_METADATA_ENABLE = 46,
|
||||
FRAME_WALL_CLOCK = 47,
|
||||
WDR_MODE = 48,
|
||||
WDR_STRENGTH = 49,
|
||||
WDR_MAX_BRIGHT_PIXELS = 50,
|
||||
LENS_DEWARP_ENABLE = 51,
|
||||
LENS_SHADING_CORRECTION_ENABLE = 52,
|
||||
HUE = 53,
|
||||
};
|
||||
|
||||
|
||||
extern const Control<bool> AeEnable;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_ENABLE
|
||||
enum AeStateEnum {
|
||||
AeStateIdle = 0,
|
||||
AeStateSearching = 1,
|
||||
AeStateConverged = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> AeStateValues;
|
||||
extern const std::map<std::string, int32_t> AeStateNameValueMap;
|
||||
extern const Control<int32_t> AeState;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_STATE
|
||||
enum AeMeteringModeEnum {
|
||||
MeteringCentreWeighted = 0,
|
||||
MeteringSpot = 1,
|
||||
MeteringMatrix = 2,
|
||||
MeteringCustom = 3,
|
||||
};
|
||||
extern const std::array<const ControlValue, 4> AeMeteringModeValues;
|
||||
extern const std::map<std::string, int32_t> AeMeteringModeNameValueMap;
|
||||
extern const Control<int32_t> AeMeteringMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_METERING_MODE
|
||||
enum AeConstraintModeEnum {
|
||||
ConstraintNormal = 0,
|
||||
ConstraintHighlight = 1,
|
||||
ConstraintShadows = 2,
|
||||
ConstraintCustom = 3,
|
||||
};
|
||||
extern const std::array<const ControlValue, 4> AeConstraintModeValues;
|
||||
extern const std::map<std::string, int32_t> AeConstraintModeNameValueMap;
|
||||
extern const Control<int32_t> AeConstraintMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_CONSTRAINT_MODE
|
||||
enum AeExposureModeEnum {
|
||||
ExposureNormal = 0,
|
||||
ExposureShort = 1,
|
||||
ExposureLong = 2,
|
||||
ExposureCustom = 3,
|
||||
};
|
||||
extern const std::array<const ControlValue, 4> AeExposureModeValues;
|
||||
extern const std::map<std::string, int32_t> AeExposureModeNameValueMap;
|
||||
extern const Control<int32_t> AeExposureMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_EXPOSURE_MODE
|
||||
extern const Control<float> ExposureValue;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_EXPOSURE_VALUE
|
||||
extern const Control<int32_t> ExposureTime;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_EXPOSURE_TIME
|
||||
enum ExposureTimeModeEnum {
|
||||
ExposureTimeModeAuto = 0,
|
||||
ExposureTimeModeManual = 1,
|
||||
};
|
||||
extern const std::array<const ControlValue, 2> ExposureTimeModeValues;
|
||||
extern const std::map<std::string, int32_t> ExposureTimeModeNameValueMap;
|
||||
extern const Control<int32_t> ExposureTimeMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_EXPOSURE_TIME_MODE
|
||||
extern const Control<float> AnalogueGain;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_ANALOGUE_GAIN
|
||||
enum AnalogueGainModeEnum {
|
||||
AnalogueGainModeAuto = 0,
|
||||
AnalogueGainModeManual = 1,
|
||||
};
|
||||
extern const std::array<const ControlValue, 2> AnalogueGainModeValues;
|
||||
extern const std::map<std::string, int32_t> AnalogueGainModeNameValueMap;
|
||||
extern const Control<int32_t> AnalogueGainMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_ANALOGUE_GAIN_MODE
|
||||
enum AeFlickerModeEnum {
|
||||
FlickerOff = 0,
|
||||
FlickerManual = 1,
|
||||
FlickerAuto = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> AeFlickerModeValues;
|
||||
extern const std::map<std::string, int32_t> AeFlickerModeNameValueMap;
|
||||
extern const Control<int32_t> AeFlickerMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_FLICKER_MODE
|
||||
extern const Control<int32_t> AeFlickerPeriod;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_FLICKER_PERIOD
|
||||
extern const Control<int32_t> AeFlickerDetected;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AE_FLICKER_DETECTED
|
||||
extern const Control<float> Brightness;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_BRIGHTNESS
|
||||
extern const Control<float> Contrast;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_CONTRAST
|
||||
extern const Control<float> Lux;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_LUX
|
||||
extern const Control<bool> AwbEnable;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AWB_ENABLE
|
||||
enum AwbModeEnum {
|
||||
AwbAuto = 0,
|
||||
AwbIncandescent = 1,
|
||||
AwbTungsten = 2,
|
||||
AwbFluorescent = 3,
|
||||
AwbIndoor = 4,
|
||||
AwbDaylight = 5,
|
||||
AwbCloudy = 6,
|
||||
AwbCustom = 7,
|
||||
};
|
||||
extern const std::array<const ControlValue, 8> AwbModeValues;
|
||||
extern const std::map<std::string, int32_t> AwbModeNameValueMap;
|
||||
extern const Control<int32_t> AwbMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AWB_MODE
|
||||
extern const Control<bool> AwbLocked;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AWB_LOCKED
|
||||
extern const Control<Span<const float, 2>> ColourGains;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_COLOUR_GAINS
|
||||
extern const Control<int32_t> ColourTemperature;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_COLOUR_TEMPERATURE
|
||||
extern const Control<float> Saturation;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_SATURATION
|
||||
extern const Control<Span<const int32_t, 4>> SensorBlackLevels;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_SENSOR_BLACK_LEVELS
|
||||
extern const Control<float> Sharpness;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_SHARPNESS
|
||||
extern const Control<int32_t> FocusFoM;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_FOCUS_FO_M
|
||||
extern const Control<Span<const float, 9>> ColourCorrectionMatrix;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_COLOUR_CORRECTION_MATRIX
|
||||
extern const Control<Rectangle> ScalerCrop;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_SCALER_CROP
|
||||
extern const Control<float> DigitalGain;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_DIGITAL_GAIN
|
||||
extern const Control<int64_t> FrameDuration;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_FRAME_DURATION
|
||||
extern const Control<Span<const int64_t, 2>> FrameDurationLimits;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_FRAME_DURATION_LIMITS
|
||||
extern const Control<float> SensorTemperature;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_SENSOR_TEMPERATURE
|
||||
extern const Control<int64_t> SensorTimestamp;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_SENSOR_TIMESTAMP
|
||||
enum AfModeEnum {
|
||||
AfModeManual = 0,
|
||||
AfModeAuto = 1,
|
||||
AfModeContinuous = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> AfModeValues;
|
||||
extern const std::map<std::string, int32_t> AfModeNameValueMap;
|
||||
extern const Control<int32_t> AfMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_MODE
|
||||
enum AfRangeEnum {
|
||||
AfRangeNormal = 0,
|
||||
AfRangeMacro = 1,
|
||||
AfRangeFull = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> AfRangeValues;
|
||||
extern const std::map<std::string, int32_t> AfRangeNameValueMap;
|
||||
extern const Control<int32_t> AfRange;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_RANGE
|
||||
enum AfSpeedEnum {
|
||||
AfSpeedNormal = 0,
|
||||
AfSpeedFast = 1,
|
||||
};
|
||||
extern const std::array<const ControlValue, 2> AfSpeedValues;
|
||||
extern const std::map<std::string, int32_t> AfSpeedNameValueMap;
|
||||
extern const Control<int32_t> AfSpeed;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_SPEED
|
||||
enum AfMeteringEnum {
|
||||
AfMeteringAuto = 0,
|
||||
AfMeteringWindows = 1,
|
||||
};
|
||||
extern const std::array<const ControlValue, 2> AfMeteringValues;
|
||||
extern const std::map<std::string, int32_t> AfMeteringNameValueMap;
|
||||
extern const Control<int32_t> AfMetering;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_METERING
|
||||
extern const Control<Span<const Rectangle>> AfWindows;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_WINDOWS
|
||||
enum AfTriggerEnum {
|
||||
AfTriggerStart = 0,
|
||||
AfTriggerCancel = 1,
|
||||
};
|
||||
extern const std::array<const ControlValue, 2> AfTriggerValues;
|
||||
extern const std::map<std::string, int32_t> AfTriggerNameValueMap;
|
||||
extern const Control<int32_t> AfTrigger;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_TRIGGER
|
||||
enum AfPauseEnum {
|
||||
AfPauseImmediate = 0,
|
||||
AfPauseDeferred = 1,
|
||||
AfPauseResume = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> AfPauseValues;
|
||||
extern const std::map<std::string, int32_t> AfPauseNameValueMap;
|
||||
extern const Control<int32_t> AfPause;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_PAUSE
|
||||
extern const Control<float> LensPosition;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_LENS_POSITION
|
||||
enum AfStateEnum {
|
||||
AfStateIdle = 0,
|
||||
AfStateScanning = 1,
|
||||
AfStateFocused = 2,
|
||||
AfStateFailed = 3,
|
||||
};
|
||||
extern const std::array<const ControlValue, 4> AfStateValues;
|
||||
extern const std::map<std::string, int32_t> AfStateNameValueMap;
|
||||
extern const Control<int32_t> AfState;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_STATE
|
||||
enum AfPauseStateEnum {
|
||||
AfPauseStateRunning = 0,
|
||||
AfPauseStatePausing = 1,
|
||||
AfPauseStatePaused = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> AfPauseStateValues;
|
||||
extern const std::map<std::string, int32_t> AfPauseStateNameValueMap;
|
||||
extern const Control<int32_t> AfPauseState;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_AF_PAUSE_STATE
|
||||
enum HdrModeEnum {
|
||||
HdrModeOff = 0,
|
||||
HdrModeMultiExposureUnmerged = 1,
|
||||
HdrModeMultiExposure = 2,
|
||||
HdrModeSingleExposure = 3,
|
||||
HdrModeNight = 4,
|
||||
};
|
||||
extern const std::array<const ControlValue, 5> HdrModeValues;
|
||||
extern const std::map<std::string, int32_t> HdrModeNameValueMap;
|
||||
extern const Control<int32_t> HdrMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_HDR_MODE
|
||||
enum HdrChannelEnum {
|
||||
HdrChannelNone = 0,
|
||||
HdrChannelShort = 1,
|
||||
HdrChannelMedium = 2,
|
||||
HdrChannelLong = 3,
|
||||
};
|
||||
extern const std::array<const ControlValue, 4> HdrChannelValues;
|
||||
extern const std::map<std::string, int32_t> HdrChannelNameValueMap;
|
||||
extern const Control<int32_t> HdrChannel;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_HDR_CHANNEL
|
||||
extern const Control<float> Gamma;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_GAMMA
|
||||
extern const Control<bool> DebugMetadataEnable;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_DEBUG_METADATA_ENABLE
|
||||
extern const Control<int64_t> FrameWallClock;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_FRAME_WALL_CLOCK
|
||||
enum WdrModeEnum {
|
||||
WdrOff = 0,
|
||||
WdrLinear = 1,
|
||||
WdrPower = 2,
|
||||
WdrExponential = 3,
|
||||
WdrHistogramEqualization = 4,
|
||||
};
|
||||
extern const std::array<const ControlValue, 5> WdrModeValues;
|
||||
extern const std::map<std::string, int32_t> WdrModeNameValueMap;
|
||||
extern const Control<int32_t> WdrMode;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_WDR_MODE
|
||||
extern const Control<float> WdrStrength;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_WDR_STRENGTH
|
||||
extern const Control<float> WdrMaxBrightPixels;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_WDR_MAX_BRIGHT_PIXELS
|
||||
extern const Control<bool> LensDewarpEnable;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_LENS_DEWARP_ENABLE
|
||||
extern const Control<bool> LensShadingCorrectionEnable;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_LENS_SHADING_CORRECTION_ENABLE
|
||||
extern const Control<float> Hue;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_CONTROLS_HUE
|
||||
|
||||
namespace draft {
|
||||
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS
|
||||
|
||||
|
||||
enum {
|
||||
AE_PRECAPTURE_TRIGGER = 10001,
|
||||
NOISE_REDUCTION_MODE = 10002,
|
||||
COLOR_CORRECTION_ABERRATION_MODE = 10003,
|
||||
AWB_STATE = 10004,
|
||||
SENSOR_ROLLING_SHUTTER_SKEW = 10005,
|
||||
LENS_SHADING_MAP_MODE = 10006,
|
||||
PIPELINE_DEPTH = 10007,
|
||||
MAX_LATENCY = 10008,
|
||||
TEST_PATTERN_MODE = 10009,
|
||||
FACE_DETECT_MODE = 10010,
|
||||
FACE_DETECT_FACE_RECTANGLES = 10011,
|
||||
FACE_DETECT_FACE_SCORES = 10012,
|
||||
FACE_DETECT_FACE_LANDMARKS = 10013,
|
||||
FACE_DETECT_FACE_IDS = 10014,
|
||||
};
|
||||
|
||||
|
||||
enum AePrecaptureTriggerEnum {
|
||||
AePrecaptureTriggerIdle = 0,
|
||||
AePrecaptureTriggerStart = 1,
|
||||
AePrecaptureTriggerCancel = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> AePrecaptureTriggerValues;
|
||||
extern const std::map<std::string, int32_t> AePrecaptureTriggerNameValueMap;
|
||||
extern const Control<int32_t> AePrecaptureTrigger;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_AE_PRECAPTURE_TRIGGER
|
||||
enum NoiseReductionModeEnum {
|
||||
NoiseReductionModeOff = 0,
|
||||
NoiseReductionModeFast = 1,
|
||||
NoiseReductionModeHighQuality = 2,
|
||||
NoiseReductionModeMinimal = 3,
|
||||
NoiseReductionModeZSL = 4,
|
||||
};
|
||||
extern const std::array<const ControlValue, 5> NoiseReductionModeValues;
|
||||
extern const std::map<std::string, int32_t> NoiseReductionModeNameValueMap;
|
||||
extern const Control<int32_t> NoiseReductionMode;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_NOISE_REDUCTION_MODE
|
||||
enum ColorCorrectionAberrationModeEnum {
|
||||
ColorCorrectionAberrationOff = 0,
|
||||
ColorCorrectionAberrationFast = 1,
|
||||
ColorCorrectionAberrationHighQuality = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> ColorCorrectionAberrationModeValues;
|
||||
extern const std::map<std::string, int32_t> ColorCorrectionAberrationModeNameValueMap;
|
||||
extern const Control<int32_t> ColorCorrectionAberrationMode;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_COLOR_CORRECTION_ABERRATION_MODE
|
||||
enum AwbStateEnum {
|
||||
AwbStateInactive = 0,
|
||||
AwbStateSearching = 1,
|
||||
AwbConverged = 2,
|
||||
AwbLocked = 3,
|
||||
};
|
||||
extern const std::array<const ControlValue, 4> AwbStateValues;
|
||||
extern const std::map<std::string, int32_t> AwbStateNameValueMap;
|
||||
extern const Control<int32_t> AwbState;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_AWB_STATE
|
||||
extern const Control<int64_t> SensorRollingShutterSkew;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_SENSOR_ROLLING_SHUTTER_SKEW
|
||||
enum LensShadingMapModeEnum {
|
||||
LensShadingMapModeOff = 0,
|
||||
LensShadingMapModeOn = 1,
|
||||
};
|
||||
extern const std::array<const ControlValue, 2> LensShadingMapModeValues;
|
||||
extern const std::map<std::string, int32_t> LensShadingMapModeNameValueMap;
|
||||
extern const Control<int32_t> LensShadingMapMode;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_LENS_SHADING_MAP_MODE
|
||||
extern const Control<int32_t> PipelineDepth;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_PIPELINE_DEPTH
|
||||
extern const Control<int32_t> MaxLatency;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_MAX_LATENCY
|
||||
enum TestPatternModeEnum {
|
||||
TestPatternModeOff = 0,
|
||||
TestPatternModeSolidColor = 1,
|
||||
TestPatternModeColorBars = 2,
|
||||
TestPatternModeColorBarsFadeToGray = 3,
|
||||
TestPatternModePn9 = 4,
|
||||
TestPatternModeCustom1 = 256,
|
||||
};
|
||||
extern const std::array<const ControlValue, 6> TestPatternModeValues;
|
||||
extern const std::map<std::string, int32_t> TestPatternModeNameValueMap;
|
||||
extern const Control<int32_t> TestPatternMode;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_TEST_PATTERN_MODE
|
||||
enum FaceDetectModeEnum {
|
||||
FaceDetectModeOff = 0,
|
||||
FaceDetectModeSimple = 1,
|
||||
FaceDetectModeFull = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> FaceDetectModeValues;
|
||||
extern const std::map<std::string, int32_t> FaceDetectModeNameValueMap;
|
||||
extern const Control<int32_t> FaceDetectMode;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_FACE_DETECT_MODE
|
||||
extern const Control<Span<const Rectangle>> FaceDetectFaceRectangles;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_FACE_DETECT_FACE_RECTANGLES
|
||||
extern const Control<Span<const uint8_t>> FaceDetectFaceScores;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_FACE_DETECT_FACE_SCORES
|
||||
extern const Control<Span<const Point>> FaceDetectFaceLandmarks;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_FACE_DETECT_FACE_LANDMARKS
|
||||
extern const Control<Span<const int32_t>> FaceDetectFaceIds;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_CONTROLS_FACE_DETECT_FACE_IDS
|
||||
|
||||
} /* namespace draft */
|
||||
|
||||
namespace rpi {
|
||||
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS
|
||||
|
||||
|
||||
enum {
|
||||
STATS_OUTPUT_ENABLE = 20001,
|
||||
BCM2835_STATS_OUTPUT = 20002,
|
||||
SCALER_CROPS = 20003,
|
||||
PISP_STATS_OUTPUT = 20004,
|
||||
SYNC_MODE = 20005,
|
||||
SYNC_READY = 20006,
|
||||
SYNC_TIMER = 20007,
|
||||
SYNC_FRAMES = 20008,
|
||||
CNN_OUTPUT_TENSOR = 20009,
|
||||
CNN_OUTPUT_TENSOR_INFO = 20010,
|
||||
CNN_ENABLE_INPUT_TENSOR = 20011,
|
||||
CNN_INPUT_TENSOR = 20012,
|
||||
CNN_INPUT_TENSOR_INFO = 20013,
|
||||
CNN_KPI_INFO = 20014,
|
||||
};
|
||||
|
||||
|
||||
extern const Control<bool> StatsOutputEnable;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_STATS_OUTPUT_ENABLE
|
||||
extern const Control<Span<const uint8_t>> Bcm2835StatsOutput;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_BCM2835_STATS_OUTPUT
|
||||
extern const Control<Span<const Rectangle>> ScalerCrops;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_SCALER_CROPS
|
||||
extern const Control<Span<const uint8_t>> PispStatsOutput;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_PISP_STATS_OUTPUT
|
||||
enum SyncModeEnum {
|
||||
SyncModeOff = 0,
|
||||
SyncModeServer = 1,
|
||||
SyncModeClient = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> SyncModeValues;
|
||||
extern const std::map<std::string, int32_t> SyncModeNameValueMap;
|
||||
extern const Control<int32_t> SyncMode;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_SYNC_MODE
|
||||
extern const Control<bool> SyncReady;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_SYNC_READY
|
||||
extern const Control<int64_t> SyncTimer;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_SYNC_TIMER
|
||||
extern const Control<int32_t> SyncFrames;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_SYNC_FRAMES
|
||||
extern const Control<Span<const float>> CnnOutputTensor;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_CNN_OUTPUT_TENSOR
|
||||
extern const Control<Span<const uint8_t>> CnnOutputTensorInfo;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_CNN_OUTPUT_TENSOR_INFO
|
||||
extern const Control<bool> CnnEnableInputTensor;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_CNN_ENABLE_INPUT_TENSOR
|
||||
extern const Control<Span<const uint8_t>> CnnInputTensor;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_CNN_INPUT_TENSOR
|
||||
extern const Control<Span<const uint8_t>> CnnInputTensorInfo;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_CNN_INPUT_TENSOR_INFO
|
||||
extern const Control<Span<const int32_t, 2>> CnnKpiInfo;
|
||||
#define LIBCAMERA_HAS_RPI_VENDOR_CONTROLS_CNN_KPI_INFO
|
||||
|
||||
} /* namespace rpi */
|
||||
|
||||
namespace debug {
|
||||
|
||||
#define LIBCAMERA_HAS_DEBUG_VENDOR_CONTROLS
|
||||
|
||||
|
||||
|
||||
|
||||
} /* namespace debug */
|
||||
|
||||
} /* namespace controls */
|
||||
|
||||
} /* namespace libcamera */
|
||||
@@ -0,0 +1,124 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* Formats
|
||||
*
|
||||
* This file is auto-generated. Do not edit.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include <libcamera/pixel_format.h>
|
||||
|
||||
namespace libcamera {
|
||||
|
||||
namespace formats {
|
||||
|
||||
namespace {
|
||||
|
||||
constexpr uint32_t __fourcc(char a, char b, char c, char d)
|
||||
{
|
||||
return (static_cast<uint32_t>(a) << 0) |
|
||||
(static_cast<uint32_t>(b) << 8) |
|
||||
(static_cast<uint32_t>(c) << 16) |
|
||||
(static_cast<uint32_t>(d) << 24);
|
||||
}
|
||||
|
||||
constexpr uint64_t __mod(unsigned int vendor, unsigned int mod)
|
||||
{
|
||||
return (static_cast<uint64_t>(vendor) << 56) |
|
||||
(static_cast<uint64_t>(mod) << 0);
|
||||
}
|
||||
|
||||
constexpr uint32_t kDrmFormatBigEndian = uint32_t(1) << 31; /* DRM_FORMAT_BIG_ENDIAN */
|
||||
|
||||
} /* namespace */
|
||||
|
||||
constexpr PixelFormat R8(__fourcc('R', '8', ' ', ' '), __mod(0, 0));
|
||||
constexpr PixelFormat R10(__fourcc('R', '1', '0', ' '), __mod(0, 0));
|
||||
constexpr PixelFormat R12(__fourcc('R', '1', '2', ' '), __mod(0, 0));
|
||||
constexpr PixelFormat R16(__fourcc('R', '1', '6', ' '), __mod(0, 0));
|
||||
constexpr PixelFormat RGB565(__fourcc('R', 'G', '1', '6'), __mod(0, 0));
|
||||
constexpr PixelFormat RGB565_BE(__fourcc('R', 'G', '1', '6') | kDrmFormatBigEndian, __mod(0, 0));
|
||||
constexpr PixelFormat RGB888(__fourcc('R', 'G', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat BGR888(__fourcc('B', 'G', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat XRGB8888(__fourcc('X', 'R', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat XBGR8888(__fourcc('X', 'B', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat RGBX8888(__fourcc('R', 'X', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat BGRX8888(__fourcc('B', 'X', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat ARGB8888(__fourcc('A', 'R', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat ABGR8888(__fourcc('A', 'B', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat RGBA8888(__fourcc('R', 'A', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat BGRA8888(__fourcc('B', 'A', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat RGB161616(__fourcc('R', 'G', '4', '8'), __mod(0, 0));
|
||||
constexpr PixelFormat BGR161616(__fourcc('B', 'G', '4', '8'), __mod(0, 0));
|
||||
constexpr PixelFormat YUYV(__fourcc('Y', 'U', 'Y', 'V'), __mod(0, 0));
|
||||
constexpr PixelFormat YVYU(__fourcc('Y', 'V', 'Y', 'U'), __mod(0, 0));
|
||||
constexpr PixelFormat UYVY(__fourcc('U', 'Y', 'V', 'Y'), __mod(0, 0));
|
||||
constexpr PixelFormat VYUY(__fourcc('V', 'Y', 'U', 'Y'), __mod(0, 0));
|
||||
constexpr PixelFormat AVUY8888(__fourcc('A', 'V', 'U', 'Y'), __mod(0, 0));
|
||||
constexpr PixelFormat XVUY8888(__fourcc('X', 'V', 'U', 'Y'), __mod(0, 0));
|
||||
constexpr PixelFormat NV12(__fourcc('N', 'V', '1', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat NV21(__fourcc('N', 'V', '2', '1'), __mod(0, 0));
|
||||
constexpr PixelFormat NV16(__fourcc('N', 'V', '1', '6'), __mod(0, 0));
|
||||
constexpr PixelFormat NV61(__fourcc('N', 'V', '6', '1'), __mod(0, 0));
|
||||
constexpr PixelFormat NV24(__fourcc('N', 'V', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat NV42(__fourcc('N', 'V', '4', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat YUV420(__fourcc('Y', 'U', '1', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat YVU420(__fourcc('Y', 'V', '1', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat YUV422(__fourcc('Y', 'U', '1', '6'), __mod(0, 0));
|
||||
constexpr PixelFormat YVU422(__fourcc('Y', 'V', '1', '6'), __mod(0, 0));
|
||||
constexpr PixelFormat YUV444(__fourcc('Y', 'U', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat YVU444(__fourcc('Y', 'V', '2', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat MJPEG(__fourcc('M', 'J', 'P', 'G'), __mod(0, 0));
|
||||
constexpr PixelFormat SRGGB8(__fourcc('R', 'G', 'G', 'B'), __mod(0, 0));
|
||||
constexpr PixelFormat SGRBG8(__fourcc('G', 'R', 'B', 'G'), __mod(0, 0));
|
||||
constexpr PixelFormat SGBRG8(__fourcc('G', 'B', 'R', 'G'), __mod(0, 0));
|
||||
constexpr PixelFormat SBGGR8(__fourcc('B', 'A', '8', '1'), __mod(0, 0));
|
||||
constexpr PixelFormat SRGGB10(__fourcc('R', 'G', '1', '0'), __mod(0, 0));
|
||||
constexpr PixelFormat SGRBG10(__fourcc('B', 'A', '1', '0'), __mod(0, 0));
|
||||
constexpr PixelFormat SGBRG10(__fourcc('G', 'B', '1', '0'), __mod(0, 0));
|
||||
constexpr PixelFormat SBGGR10(__fourcc('B', 'G', '1', '0'), __mod(0, 0));
|
||||
constexpr PixelFormat SRGGB12(__fourcc('R', 'G', '1', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat SGRBG12(__fourcc('B', 'A', '1', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat SGBRG12(__fourcc('G', 'B', '1', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat SBGGR12(__fourcc('B', 'G', '1', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat SRGGB14(__fourcc('R', 'G', '1', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat SGRBG14(__fourcc('B', 'A', '1', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat SGBRG14(__fourcc('G', 'B', '1', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat SBGGR14(__fourcc('B', 'G', '1', '4'), __mod(0, 0));
|
||||
constexpr PixelFormat SRGGB16(__fourcc('R', 'G', 'B', '6'), __mod(0, 0));
|
||||
constexpr PixelFormat SGRBG16(__fourcc('G', 'R', '1', '6'), __mod(0, 0));
|
||||
constexpr PixelFormat SGBRG16(__fourcc('G', 'B', '1', '6'), __mod(0, 0));
|
||||
constexpr PixelFormat SBGGR16(__fourcc('B', 'Y', 'R', '2'), __mod(0, 0));
|
||||
constexpr PixelFormat R10_CSI2P(__fourcc('R', '1', '0', ' '), __mod(11, 1));
|
||||
constexpr PixelFormat R12_CSI2P(__fourcc('R', '1', '2', ' '), __mod(11, 1));
|
||||
constexpr PixelFormat SRGGB10_CSI2P(__fourcc('R', 'G', '1', '0'), __mod(11, 1));
|
||||
constexpr PixelFormat SGRBG10_CSI2P(__fourcc('B', 'A', '1', '0'), __mod(11, 1));
|
||||
constexpr PixelFormat SGBRG10_CSI2P(__fourcc('G', 'B', '1', '0'), __mod(11, 1));
|
||||
constexpr PixelFormat SBGGR10_CSI2P(__fourcc('B', 'G', '1', '0'), __mod(11, 1));
|
||||
constexpr PixelFormat SRGGB12_CSI2P(__fourcc('R', 'G', '1', '2'), __mod(11, 1));
|
||||
constexpr PixelFormat SGRBG12_CSI2P(__fourcc('B', 'A', '1', '2'), __mod(11, 1));
|
||||
constexpr PixelFormat SGBRG12_CSI2P(__fourcc('G', 'B', '1', '2'), __mod(11, 1));
|
||||
constexpr PixelFormat SBGGR12_CSI2P(__fourcc('B', 'G', '1', '2'), __mod(11, 1));
|
||||
constexpr PixelFormat SRGGB14_CSI2P(__fourcc('R', 'G', '1', '4'), __mod(11, 1));
|
||||
constexpr PixelFormat SGRBG14_CSI2P(__fourcc('B', 'A', '1', '4'), __mod(11, 1));
|
||||
constexpr PixelFormat SGBRG14_CSI2P(__fourcc('G', 'B', '1', '4'), __mod(11, 1));
|
||||
constexpr PixelFormat SBGGR14_CSI2P(__fourcc('B', 'G', '1', '4'), __mod(11, 1));
|
||||
constexpr PixelFormat SRGGB10_IPU3(__fourcc('R', 'G', '1', '0'), __mod(1, 13));
|
||||
constexpr PixelFormat SGRBG10_IPU3(__fourcc('B', 'A', '1', '0'), __mod(1, 13));
|
||||
constexpr PixelFormat SGBRG10_IPU3(__fourcc('G', 'B', '1', '0'), __mod(1, 13));
|
||||
constexpr PixelFormat SBGGR10_IPU3(__fourcc('B', 'G', '1', '0'), __mod(1, 13));
|
||||
constexpr PixelFormat RGGB_PISP_COMP1(__fourcc('R', 'G', 'B', '6'), __mod(12, 1));
|
||||
constexpr PixelFormat GRBG_PISP_COMP1(__fourcc('G', 'R', '1', '6'), __mod(12, 1));
|
||||
constexpr PixelFormat GBRG_PISP_COMP1(__fourcc('G', 'B', '1', '6'), __mod(12, 1));
|
||||
constexpr PixelFormat BGGR_PISP_COMP1(__fourcc('B', 'Y', 'R', '2'), __mod(12, 1));
|
||||
constexpr PixelFormat MONO_PISP_COMP1(__fourcc('R', '1', '6', ' '), __mod(12, 1));
|
||||
|
||||
|
||||
} /* namespace formats */
|
||||
|
||||
} /* namespace libcamera */
|
||||
@@ -0,0 +1,237 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* Tracepoints with lttng
|
||||
*
|
||||
* This file is auto-generated. Do not edit.
|
||||
*/
|
||||
#ifndef __LIBCAMERA_INTERNAL_TRACEPOINTS_H__
|
||||
#define __LIBCAMERA_INTERNAL_TRACEPOINTS_H__
|
||||
|
||||
#if HAVE_TRACING
|
||||
#define LIBCAMERA_TRACEPOINT(...) tracepoint(libcamera, __VA_ARGS__)
|
||||
|
||||
#define LIBCAMERA_TRACEPOINT_IPA_BEGIN(pipe, func) \
|
||||
tracepoint(libcamera, ipa_call_begin, #pipe, #func)
|
||||
|
||||
#define LIBCAMERA_TRACEPOINT_IPA_END(pipe, func) \
|
||||
tracepoint(libcamera, ipa_call_end, #pipe, #func)
|
||||
|
||||
#else
|
||||
|
||||
namespace {
|
||||
|
||||
template <typename ...Args>
|
||||
inline void unused([[maybe_unused]] Args&& ...args)
|
||||
{
|
||||
}
|
||||
|
||||
} /* namespace */
|
||||
|
||||
#define LIBCAMERA_TRACEPOINT(category, ...) unused(__VA_ARGS__)
|
||||
|
||||
#define LIBCAMERA_TRACEPOINT_IPA_BEGIN(pipe, func)
|
||||
#define LIBCAMERA_TRACEPOINT_IPA_END(pipe, func)
|
||||
|
||||
#endif /* HAVE_TRACING */
|
||||
|
||||
#endif /* __LIBCAMERA_INTERNAL_TRACEPOINTS_H__ */
|
||||
|
||||
|
||||
#if HAVE_TRACING
|
||||
|
||||
#undef TRACEPOINT_PROVIDER
|
||||
#define TRACEPOINT_PROVIDER libcamera
|
||||
|
||||
#undef TRACEPOINT_INCLUDE
|
||||
#define TRACEPOINT_INCLUDE "libcamera/internal/tracepoints.h"
|
||||
|
||||
#if !defined(INCLUDE_LIBCAMERA_INTERNAL_TRACEPOINTS_TP_H) || defined(TRACEPOINT_HEADER_MULTI_READ)
|
||||
#define INCLUDE_LIBCAMERA_INTERNAL_TRACEPOINTS_TP_H
|
||||
|
||||
#include <lttng/tracepoint.h>
|
||||
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* buffer_enums.tp - Tracepoint definition for enums in the buffer class
|
||||
*/
|
||||
|
||||
TRACEPOINT_ENUM(
|
||||
libcamera,
|
||||
buffer_status,
|
||||
TP_ENUM_VALUES(
|
||||
ctf_enum_value("FrameSuccess", 0)
|
||||
ctf_enum_value("FrameError", 1)
|
||||
ctf_enum_value("FrameCancelled", 2)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* request_enums.tp - Tracepoint definition for enums in the request class
|
||||
*/
|
||||
|
||||
TRACEPOINT_ENUM(
|
||||
libcamera,
|
||||
request_status,
|
||||
TP_ENUM_VALUES(
|
||||
ctf_enum_value("RequestPending", 0)
|
||||
ctf_enum_value("RequestComplete", 1)
|
||||
ctf_enum_value("RequestCancelled", 2)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* pipeline.tp - Tracepoints for pipelines
|
||||
*/
|
||||
|
||||
TRACEPOINT_EVENT(
|
||||
libcamera,
|
||||
ipa_call_begin,
|
||||
TP_ARGS(
|
||||
const char *, pipe,
|
||||
const char *, func
|
||||
),
|
||||
TP_FIELDS(
|
||||
ctf_string(pipeline_name, pipe)
|
||||
ctf_string(function_name, func)
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT(
|
||||
libcamera,
|
||||
ipa_call_end,
|
||||
TP_ARGS(
|
||||
const char *, pipe,
|
||||
const char *, func
|
||||
),
|
||||
TP_FIELDS(
|
||||
ctf_string(pipeline_name, pipe)
|
||||
ctf_string(function_name, func)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* request.tp - Tracepoints for the request object
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include <libcamera/framebuffer.h>
|
||||
|
||||
#include "libcamera/internal/request.h"
|
||||
|
||||
TRACEPOINT_EVENT_CLASS(
|
||||
libcamera,
|
||||
request,
|
||||
TP_ARGS(
|
||||
libcamera::Request *, req
|
||||
),
|
||||
TP_FIELDS(
|
||||
ctf_integer_hex(uintptr_t, request, reinterpret_cast<uintptr_t>(req))
|
||||
ctf_integer(uint64_t, cookie, req->cookie())
|
||||
ctf_enum(libcamera, request_status, uint32_t, status, req->status())
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_construct,
|
||||
TP_ARGS(
|
||||
libcamera::Request *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_destroy,
|
||||
TP_ARGS(
|
||||
libcamera::Request *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_reuse,
|
||||
TP_ARGS(
|
||||
libcamera::Request *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_queue,
|
||||
TP_ARGS(
|
||||
libcamera::Request *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_device_queue,
|
||||
TP_ARGS(
|
||||
libcamera::Request *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_complete,
|
||||
TP_ARGS(
|
||||
libcamera::Request::Private *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_cancel,
|
||||
TP_ARGS(
|
||||
libcamera::Request::Private *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT(
|
||||
libcamera,
|
||||
request_complete_buffer,
|
||||
TP_ARGS(
|
||||
libcamera::Request::Private *, req,
|
||||
libcamera::FrameBuffer *, buf
|
||||
),
|
||||
TP_FIELDS(
|
||||
ctf_integer_hex(uintptr_t, request, reinterpret_cast<uintptr_t>(req))
|
||||
ctf_integer(uint64_t, cookie, req->_o<libcamera::Request>()->cookie())
|
||||
ctf_integer(int, status, req->_o<libcamera::Request>()->status())
|
||||
ctf_integer_hex(uintptr_t, buffer, reinterpret_cast<uintptr_t>(buf))
|
||||
ctf_enum(libcamera, buffer_status, uint32_t, buf_status, buf->metadata().status)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
#endif /* INCLUDE_LIBCAMERA_INTERNAL_TRACEPOINTS_TP_H */
|
||||
|
||||
#include <lttng/tracepoint-event.h>
|
||||
|
||||
#endif /* HAVE_TRACING */
|
||||
Binary file not shown.
@@ -0,0 +1,163 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* libcamera core definitions for Image Processing Algorithms
|
||||
*
|
||||
* This file is auto-generated. Do not edit.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
#include <libcamera/controls.h>
|
||||
#include <libcamera/framebuffer.h>
|
||||
#include <libcamera/geometry.h>
|
||||
|
||||
#include <libcamera/ipa/ipa_interface.h>
|
||||
|
||||
namespace libcamera {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
struct IPACameraSensorInfo
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
IPACameraSensorInfo() = default;
|
||||
|
||||
template<
|
||||
typename T1 = std::string,
|
||||
typename T2 = uint32_t,
|
||||
typename T3 = uint32_t,
|
||||
typename T4 = Size,
|
||||
typename T5 = Rectangle,
|
||||
typename T6 = Size,
|
||||
typename T7 = uint64_t,
|
||||
typename T8 = uint32_t,
|
||||
typename T9 = uint32_t,
|
||||
typename T10 = uint32_t,
|
||||
typename T11 = uint32_t,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, std::string>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T3&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T4&&, Size>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T5&&, Rectangle>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T6&&, Size>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T7&&, uint64_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T8&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T9&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T10&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T11&&, uint32_t>> * = nullptr
|
||||
>
|
||||
IPACameraSensorInfo(T1 &&_model, T2 &&_bitsPerPixel, T3 &&_cfaPattern, T4 &&_activeAreaSize, T5 &&_analogCrop, T6 &&_outputSize, T7 &&_pixelRate, T8 &&_minLineLength, T9 &&_maxLineLength, T10 &&_minFrameLength, T11 &&_maxFrameLength)
|
||||
: model(std::forward<T1>(_model))
|
||||
, bitsPerPixel(std::forward<T2>(_bitsPerPixel))
|
||||
, cfaPattern(std::forward<T3>(_cfaPattern))
|
||||
, activeAreaSize(std::forward<T4>(_activeAreaSize))
|
||||
, analogCrop(std::forward<T5>(_analogCrop))
|
||||
, outputSize(std::forward<T6>(_outputSize))
|
||||
, pixelRate(std::forward<T7>(_pixelRate))
|
||||
, minLineLength(std::forward<T8>(_minLineLength))
|
||||
, maxLineLength(std::forward<T9>(_maxLineLength))
|
||||
, minFrameLength(std::forward<T10>(_minFrameLength))
|
||||
, maxFrameLength(std::forward<T11>(_maxFrameLength))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
std::string model;
|
||||
uint32_t bitsPerPixel{ 0 };
|
||||
uint32_t cfaPattern{ 0 };
|
||||
Size activeAreaSize;
|
||||
Rectangle analogCrop;
|
||||
Size outputSize;
|
||||
uint64_t pixelRate{ 0 };
|
||||
uint32_t minLineLength{ 0 };
|
||||
uint32_t maxLineLength{ 0 };
|
||||
uint32_t minFrameLength{ 0 };
|
||||
uint32_t maxFrameLength{ 0 };
|
||||
};
|
||||
|
||||
struct IPABuffer
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
IPABuffer() = default;
|
||||
|
||||
template<
|
||||
typename T1 = uint32_t,
|
||||
typename T2 = std::vector<FrameBuffer::Plane>,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, std::vector<FrameBuffer::Plane>>> * = nullptr
|
||||
>
|
||||
IPABuffer(T1 &&_id, T2 &&_planes)
|
||||
: id(std::forward<T1>(_id))
|
||||
, planes(std::forward<T2>(_planes))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
uint32_t id{ 0 };
|
||||
std::vector<FrameBuffer::Plane> planes;
|
||||
};
|
||||
|
||||
struct IPASettings
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
IPASettings() = default;
|
||||
|
||||
template<
|
||||
typename T1 = std::string,
|
||||
typename T2 = std::string,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, std::string>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, std::string>> * = nullptr
|
||||
>
|
||||
IPASettings(T1 &&_configurationFile, T2 &&_sensorModel)
|
||||
: configurationFile(std::forward<T1>(_configurationFile))
|
||||
, sensorModel(std::forward<T2>(_sensorModel))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
std::string configurationFile;
|
||||
std::string sensorModel;
|
||||
};
|
||||
|
||||
struct IPAStream
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
IPAStream() = default;
|
||||
|
||||
template<
|
||||
typename T1 = uint32_t,
|
||||
typename T2 = Size,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, Size>> * = nullptr
|
||||
>
|
||||
IPAStream(T1 &&_pixelFormat, T2 &&_size)
|
||||
: pixelFormat(std::forward<T1>(_pixelFormat))
|
||||
, size(std::forward<T2>(_size))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
uint32_t pixelFormat{ 0 };
|
||||
Size size;
|
||||
};
|
||||
|
||||
|
||||
} /* namespace libcamera */
|
||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
@@ -0,0 +1,377 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* Image Processing Algorithm interface for raspberrypi
|
||||
*
|
||||
* This file is auto-generated. Do not edit.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
|
||||
#include <string>
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
#include <libcamera/base/flags.h>
|
||||
#include <libcamera/base/signal.h>
|
||||
|
||||
#include <libcamera/controls.h>
|
||||
#include <libcamera/framebuffer.h>
|
||||
#include <libcamera/geometry.h>
|
||||
|
||||
#include <libcamera/ipa/core_ipa_interface.h>
|
||||
#include <libcamera/ipa/ipa_interface.h>
|
||||
|
||||
namespace libcamera {
|
||||
|
||||
namespace ipa {
|
||||
|
||||
namespace RPi {
|
||||
|
||||
|
||||
|
||||
const uint32_t MaxLsGridSize = 0x8000;
|
||||
|
||||
|
||||
enum class _RPiCmd {
|
||||
Exit = 0,
|
||||
Init = 1,
|
||||
Start = 2,
|
||||
Stop = 3,
|
||||
Configure = 4,
|
||||
MapBuffers = 5,
|
||||
UnmapBuffers = 6,
|
||||
PrepareIsp = 7,
|
||||
ProcessStats = 8,
|
||||
};
|
||||
|
||||
enum class _RPiEventCmd {
|
||||
PrepareIspComplete = 1,
|
||||
ProcessStatsComplete = 2,
|
||||
MetadataReady = 3,
|
||||
SetIspControls = 4,
|
||||
SetDelayedControls = 5,
|
||||
SetLensControls = 6,
|
||||
SetCameraTimeout = 7,
|
||||
};
|
||||
|
||||
|
||||
struct SensorConfig
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
SensorConfig() = default;
|
||||
|
||||
template<
|
||||
typename T1 = uint32_t,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, uint32_t>> * = nullptr
|
||||
>
|
||||
SensorConfig(T1 &&_sensorMetadata)
|
||||
: sensorMetadata(std::forward<T1>(_sensorMetadata))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
uint32_t sensorMetadata{ 0 };
|
||||
};
|
||||
|
||||
struct InitParams
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
InitParams() = default;
|
||||
|
||||
template<
|
||||
typename T1 = bool,
|
||||
typename T2 = IPACameraSensorInfo,
|
||||
typename T3 = float,
|
||||
typename T4 = SharedFD,
|
||||
typename T5 = SharedFD,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, bool>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, IPACameraSensorInfo>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T3&&, float>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T4&&, SharedFD>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T5&&, SharedFD>> * = nullptr
|
||||
>
|
||||
InitParams(T1 &&_lensPresent, T2 &&_sensorInfo, T3 &&_controllerMinFrameDurationUs, T4 &&_fe, T5 &&_be)
|
||||
: lensPresent(std::forward<T1>(_lensPresent))
|
||||
, sensorInfo(std::forward<T2>(_sensorInfo))
|
||||
, controllerMinFrameDurationUs(std::forward<T3>(_controllerMinFrameDurationUs))
|
||||
, fe(std::forward<T4>(_fe))
|
||||
, be(std::forward<T5>(_be))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
bool lensPresent{ 0 };
|
||||
IPACameraSensorInfo sensorInfo;
|
||||
float controllerMinFrameDurationUs{ 0 };
|
||||
SharedFD fe{ -1 };
|
||||
SharedFD be{ -1 };
|
||||
};
|
||||
|
||||
struct InitResult
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
InitResult() = default;
|
||||
|
||||
template<
|
||||
typename T1 = SensorConfig,
|
||||
typename T2 = ControlInfoMap,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, SensorConfig>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, ControlInfoMap>> * = nullptr
|
||||
>
|
||||
InitResult(T1 &&_sensorConfig, T2 &&_controlInfo)
|
||||
: sensorConfig(std::forward<T1>(_sensorConfig))
|
||||
, controlInfo(std::forward<T2>(_controlInfo))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
SensorConfig sensorConfig;
|
||||
ControlInfoMap controlInfo;
|
||||
};
|
||||
|
||||
struct BufferIds
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
BufferIds() = default;
|
||||
|
||||
template<
|
||||
typename T1 = uint32_t,
|
||||
typename T2 = uint32_t,
|
||||
typename T3 = uint32_t,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T3&&, uint32_t>> * = nullptr
|
||||
>
|
||||
BufferIds(T1 &&_bayer, T2 &&_embedded, T3 &&_stats)
|
||||
: bayer(std::forward<T1>(_bayer))
|
||||
, embedded(std::forward<T2>(_embedded))
|
||||
, stats(std::forward<T3>(_stats))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
uint32_t bayer{ 0 };
|
||||
uint32_t embedded{ 0 };
|
||||
uint32_t stats{ 0 };
|
||||
};
|
||||
|
||||
struct ConfigParams
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
ConfigParams() = default;
|
||||
|
||||
template<
|
||||
typename T1 = uint32_t,
|
||||
typename T2 = ControlInfoMap,
|
||||
typename T3 = ControlInfoMap,
|
||||
typename T4 = ControlInfoMap,
|
||||
typename T5 = SharedFD,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, ControlInfoMap>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T3&&, ControlInfoMap>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T4&&, ControlInfoMap>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T5&&, SharedFD>> * = nullptr
|
||||
>
|
||||
ConfigParams(T1 &&_transform, T2 &&_sensorControls, T3 &&_ispControls, T4 &&_lensControls, T5 &&_lsTableHandle)
|
||||
: transform(std::forward<T1>(_transform))
|
||||
, sensorControls(std::forward<T2>(_sensorControls))
|
||||
, ispControls(std::forward<T3>(_ispControls))
|
||||
, lensControls(std::forward<T4>(_lensControls))
|
||||
, lsTableHandle(std::forward<T5>(_lsTableHandle))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
uint32_t transform{ 0 };
|
||||
ControlInfoMap sensorControls;
|
||||
ControlInfoMap ispControls;
|
||||
ControlInfoMap lensControls;
|
||||
SharedFD lsTableHandle{ -1 };
|
||||
};
|
||||
|
||||
struct ConfigResult
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
ConfigResult() = default;
|
||||
|
||||
template<
|
||||
typename T1 = float,
|
||||
typename T2 = ControlInfoMap,
|
||||
typename T3 = ControlList,
|
||||
typename T4 = ControlList,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, float>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, ControlInfoMap>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T3&&, ControlList>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T4&&, ControlList>> * = nullptr
|
||||
>
|
||||
ConfigResult(T1 &&_modeSensitivity, T2 &&_controlInfo, T3 &&_sensorControls, T4 &&_lensControls)
|
||||
: modeSensitivity(std::forward<T1>(_modeSensitivity))
|
||||
, controlInfo(std::forward<T2>(_controlInfo))
|
||||
, sensorControls(std::forward<T3>(_sensorControls))
|
||||
, lensControls(std::forward<T4>(_lensControls))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
float modeSensitivity{ 0 };
|
||||
ControlInfoMap controlInfo;
|
||||
ControlList sensorControls;
|
||||
ControlList lensControls;
|
||||
};
|
||||
|
||||
struct StartResult
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
StartResult() = default;
|
||||
|
||||
template<
|
||||
typename T1 = ControlList,
|
||||
typename T2 = int32_t,
|
||||
typename T3 = int32_t,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, ControlList>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, int32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T3&&, int32_t>> * = nullptr
|
||||
>
|
||||
StartResult(T1 &&_controls, T2 &&_startupFrameCount, T3 &&_invalidFrameCount)
|
||||
: controls(std::forward<T1>(_controls))
|
||||
, startupFrameCount(std::forward<T2>(_startupFrameCount))
|
||||
, invalidFrameCount(std::forward<T3>(_invalidFrameCount))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
ControlList controls;
|
||||
int32_t startupFrameCount{ 0 };
|
||||
int32_t invalidFrameCount{ 0 };
|
||||
};
|
||||
|
||||
struct PrepareParams
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
PrepareParams() = default;
|
||||
|
||||
template<
|
||||
typename T1 = BufferIds,
|
||||
typename T2 = ControlList,
|
||||
typename T3 = ControlList,
|
||||
typename T4 = uint32_t,
|
||||
typename T5 = uint32_t,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, BufferIds>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, ControlList>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T3&&, ControlList>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T4&&, uint32_t>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T5&&, uint32_t>> * = nullptr
|
||||
>
|
||||
PrepareParams(T1 &&_buffers, T2 &&_sensorControls, T3 &&_requestControls, T4 &&_ipaContext, T5 &&_delayContext)
|
||||
: buffers(std::forward<T1>(_buffers))
|
||||
, sensorControls(std::forward<T2>(_sensorControls))
|
||||
, requestControls(std::forward<T3>(_requestControls))
|
||||
, ipaContext(std::forward<T4>(_ipaContext))
|
||||
, delayContext(std::forward<T5>(_delayContext))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
BufferIds buffers;
|
||||
ControlList sensorControls;
|
||||
ControlList requestControls;
|
||||
uint32_t ipaContext{ 0 };
|
||||
uint32_t delayContext{ 0 };
|
||||
};
|
||||
|
||||
struct ProcessParams
|
||||
{
|
||||
public:
|
||||
#ifndef __DOXYGEN__
|
||||
ProcessParams() = default;
|
||||
|
||||
template<
|
||||
typename T1 = BufferIds,
|
||||
typename T2 = uint32_t,
|
||||
std::enable_if_t<std::is_convertible_v<T1&&, BufferIds>> * = nullptr,
|
||||
std::enable_if_t<std::is_convertible_v<T2&&, uint32_t>> * = nullptr
|
||||
>
|
||||
ProcessParams(T1 &&_buffers, T2 &&_ipaContext)
|
||||
: buffers(std::forward<T1>(_buffers))
|
||||
, ipaContext(std::forward<T2>(_ipaContext))
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
BufferIds buffers;
|
||||
uint32_t ipaContext{ 0 };
|
||||
};
|
||||
|
||||
class IPARPiInterface : public IPAInterface
|
||||
{
|
||||
public:
|
||||
|
||||
virtual int32_t init(
|
||||
const IPASettings &settings,
|
||||
const InitParams ¶ms,
|
||||
InitResult *result) = 0;
|
||||
|
||||
virtual void start(
|
||||
const ControlList &controls,
|
||||
StartResult *result) = 0;
|
||||
|
||||
virtual void stop() = 0;
|
||||
|
||||
virtual int32_t configure(
|
||||
const IPACameraSensorInfo &sensorInfo,
|
||||
const ConfigParams ¶ms,
|
||||
ConfigResult *result) = 0;
|
||||
|
||||
virtual void mapBuffers(
|
||||
const std::vector<libcamera::IPABuffer> &buffers) = 0;
|
||||
|
||||
virtual void unmapBuffers(
|
||||
const std::vector<uint32_t> &ids) = 0;
|
||||
|
||||
virtual void prepareIsp(
|
||||
const PrepareParams ¶ms) = 0;
|
||||
|
||||
virtual void processStats(
|
||||
const ProcessParams ¶ms) = 0;
|
||||
|
||||
Signal<const BufferIds &, bool> prepareIspComplete;
|
||||
|
||||
Signal<const BufferIds &> processStatsComplete;
|
||||
|
||||
Signal<const ControlList &> metadataReady;
|
||||
|
||||
Signal<const ControlList &> setIspControls;
|
||||
|
||||
Signal<const ControlList &, uint32_t> setDelayedControls;
|
||||
|
||||
Signal<const ControlList &> setLensControls;
|
||||
|
||||
Signal<uint32_t> setCameraTimeout;
|
||||
};
|
||||
|
||||
} /* namespace RPi */
|
||||
|
||||
} /* namespace ipa */
|
||||
|
||||
} /* namespace libcamera */
|
||||
@@ -0,0 +1,239 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2020, Google Inc.
|
||||
*
|
||||
* Image Processing Algorithm proxy for raspberrypi
|
||||
*
|
||||
* This file is auto-generated. Do not edit.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <libcamera/ipa/ipa_interface.h>
|
||||
#include <libcamera/ipa/raspberrypi_ipa_interface.h>
|
||||
|
||||
#include <libcamera/base/object.h>
|
||||
#include <libcamera/base/thread.h>
|
||||
|
||||
#include "libcamera/internal/control_serializer.h"
|
||||
#include "libcamera/internal/ipa_proxy.h"
|
||||
#include "libcamera/internal/ipc_pipe.h"
|
||||
#include "libcamera/internal/ipc_pipe_unixsocket.h"
|
||||
#include "libcamera/internal/ipc_unixsocket.h"
|
||||
|
||||
namespace libcamera {
|
||||
|
||||
namespace ipa {
|
||||
|
||||
namespace RPi {
|
||||
|
||||
|
||||
class IPAProxyRPiThreaded;
|
||||
class IPAProxyRPiIsolated;
|
||||
|
||||
class IPAProxyRPi : public IPAProxy, public IPARPiInterface, public Object
|
||||
{
|
||||
public:
|
||||
using Threaded = IPAProxyRPiThreaded;
|
||||
using Isolated = IPAProxyRPiIsolated;
|
||||
|
||||
protected:
|
||||
using IPAProxy::IPAProxy;
|
||||
};
|
||||
|
||||
class IPAProxyRPiThreaded : public IPAProxyRPi
|
||||
{
|
||||
public:
|
||||
IPAProxyRPiThreaded(IPAModule *ipam, const CameraManager &cm);
|
||||
~IPAProxyRPiThreaded();
|
||||
|
||||
|
||||
int32_t init(
|
||||
const IPASettings &settings,
|
||||
const InitParams ¶ms,
|
||||
InitResult *result) override;
|
||||
|
||||
void start(
|
||||
const ControlList &controls,
|
||||
StartResult *result) override;
|
||||
|
||||
void stop() override;
|
||||
|
||||
int32_t configure(
|
||||
const IPACameraSensorInfo &sensorInfo,
|
||||
const ConfigParams ¶ms,
|
||||
ConfigResult *result) override;
|
||||
|
||||
void mapBuffers(
|
||||
const std::vector<libcamera::IPABuffer> &buffers) override;
|
||||
|
||||
void unmapBuffers(
|
||||
const std::vector<uint32_t> &ids) override;
|
||||
|
||||
void prepareIsp(
|
||||
const PrepareParams ¶ms) override;
|
||||
|
||||
void processStats(
|
||||
const ProcessParams ¶ms) override;
|
||||
|
||||
|
||||
private:
|
||||
|
||||
void prepareIspCompleteHandler(
|
||||
const BufferIds &buffers,
|
||||
const bool stitchSwapBuffers);
|
||||
|
||||
void processStatsCompleteHandler(
|
||||
const BufferIds &buffers);
|
||||
|
||||
void metadataReadyHandler(
|
||||
const ControlList &metadata);
|
||||
|
||||
void setIspControlsHandler(
|
||||
const ControlList &controls);
|
||||
|
||||
void setDelayedControlsHandler(
|
||||
const ControlList &controls,
|
||||
const uint32_t delayContext);
|
||||
|
||||
void setLensControlsHandler(
|
||||
const ControlList &controls);
|
||||
|
||||
void setCameraTimeoutHandler(
|
||||
const uint32_t maxFrameLengthMs);
|
||||
|
||||
|
||||
/* Helper class to invoke async functions in another thread. */
|
||||
class ThreadProxy : public Object
|
||||
{
|
||||
public:
|
||||
ThreadProxy()
|
||||
: ipa_(nullptr)
|
||||
{
|
||||
}
|
||||
|
||||
void setIPA(IPARPiInterface *ipa)
|
||||
{
|
||||
ipa_ = ipa;
|
||||
}
|
||||
|
||||
void stop()
|
||||
{
|
||||
ipa_->stop();
|
||||
}
|
||||
|
||||
void start(
|
||||
const ControlList &controls,
|
||||
StartResult *result)
|
||||
{
|
||||
ipa_->start(controls, result);
|
||||
}
|
||||
void prepareIsp(
|
||||
const PrepareParams ¶ms)
|
||||
{
|
||||
ipa_->prepareIsp(params);
|
||||
}
|
||||
void processStats(
|
||||
const ProcessParams ¶ms)
|
||||
{
|
||||
ipa_->processStats(params);
|
||||
}
|
||||
|
||||
private:
|
||||
IPARPiInterface *ipa_;
|
||||
};
|
||||
|
||||
Thread thread_;
|
||||
ThreadProxy proxy_;
|
||||
std::unique_ptr<IPARPiInterface> ipa_;
|
||||
};
|
||||
|
||||
class IPAProxyRPiIsolated : public IPAProxyRPi
|
||||
{
|
||||
public:
|
||||
IPAProxyRPiIsolated(IPAModule *ipam, const CameraManager &cm);
|
||||
~IPAProxyRPiIsolated();
|
||||
|
||||
|
||||
int32_t init(
|
||||
const IPASettings &settings,
|
||||
const InitParams ¶ms,
|
||||
InitResult *result) override;
|
||||
|
||||
void start(
|
||||
const ControlList &controls,
|
||||
StartResult *result) override;
|
||||
|
||||
void stop() override;
|
||||
|
||||
int32_t configure(
|
||||
const IPACameraSensorInfo &sensorInfo,
|
||||
const ConfigParams ¶ms,
|
||||
ConfigResult *result) override;
|
||||
|
||||
void mapBuffers(
|
||||
const std::vector<libcamera::IPABuffer> &buffers) override;
|
||||
|
||||
void unmapBuffers(
|
||||
const std::vector<uint32_t> &ids) override;
|
||||
|
||||
void prepareIsp(
|
||||
const PrepareParams ¶ms) override;
|
||||
|
||||
void processStats(
|
||||
const ProcessParams ¶ms) override;
|
||||
|
||||
|
||||
private:
|
||||
void recvMessage(const IPCMessage &data);
|
||||
|
||||
|
||||
void prepareIspCompleteHandler(
|
||||
std::vector<uint8_t>::const_iterator data,
|
||||
size_t dataSize,
|
||||
const std::vector<SharedFD> &fds);
|
||||
|
||||
void processStatsCompleteHandler(
|
||||
std::vector<uint8_t>::const_iterator data,
|
||||
size_t dataSize,
|
||||
const std::vector<SharedFD> &fds);
|
||||
|
||||
void metadataReadyHandler(
|
||||
std::vector<uint8_t>::const_iterator data,
|
||||
size_t dataSize,
|
||||
const std::vector<SharedFD> &fds);
|
||||
|
||||
void setIspControlsHandler(
|
||||
std::vector<uint8_t>::const_iterator data,
|
||||
size_t dataSize,
|
||||
const std::vector<SharedFD> &fds);
|
||||
|
||||
void setDelayedControlsHandler(
|
||||
std::vector<uint8_t>::const_iterator data,
|
||||
size_t dataSize,
|
||||
const std::vector<SharedFD> &fds);
|
||||
|
||||
void setLensControlsHandler(
|
||||
std::vector<uint8_t>::const_iterator data,
|
||||
size_t dataSize,
|
||||
const std::vector<SharedFD> &fds);
|
||||
|
||||
void setCameraTimeoutHandler(
|
||||
std::vector<uint8_t>::const_iterator data,
|
||||
size_t dataSize,
|
||||
const std::vector<SharedFD> &fds);
|
||||
|
||||
|
||||
std::unique_ptr<IPCPipeUnixSocket> ipc_;
|
||||
|
||||
ControlSerializer controlSerializer_;
|
||||
|
||||
|
||||
uint32_t seq_;
|
||||
};
|
||||
|
||||
} /* namespace RPi */
|
||||
|
||||
} /* namespace ipa */
|
||||
|
||||
} /* namespace libcamera */
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,28 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/* This file is auto-generated, do not edit! */
|
||||
/*
|
||||
* Copyright (C) 2018-2019, Google Inc.
|
||||
*
|
||||
* libcamera public API
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <libcamera/camera.h>
|
||||
#include <libcamera/camera_manager.h>
|
||||
#include <libcamera/color_space.h>
|
||||
#include <libcamera/control_ids.h>
|
||||
#include <libcamera/controls.h>
|
||||
#include <libcamera/fence.h>
|
||||
#include <libcamera/formats.h>
|
||||
#include <libcamera/framebuffer_allocator.h>
|
||||
#include <libcamera/framebuffer.h>
|
||||
#include <libcamera/geometry.h>
|
||||
#include <libcamera/logging.h>
|
||||
#include <libcamera/orientation.h>
|
||||
#include <libcamera/pixel_format.h>
|
||||
#include <libcamera/property_ids.h>
|
||||
#include <libcamera/request.h>
|
||||
#include <libcamera/stream.h>
|
||||
#include <libcamera/transform.h>
|
||||
#include <libcamera/version.h>
|
||||
@@ -0,0 +1,99 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
/*
|
||||
* Copyright (C) 2019, Google Inc.
|
||||
*
|
||||
* Properties ID list
|
||||
*
|
||||
* This file is auto-generated. Do not edit.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <array>
|
||||
#include <map>
|
||||
#include <stdint.h>
|
||||
#include <string>
|
||||
#include <string_view>
|
||||
|
||||
#include <libcamera/controls.h>
|
||||
|
||||
namespace libcamera {
|
||||
|
||||
namespace properties {
|
||||
|
||||
extern const ControlIdMap properties;
|
||||
|
||||
|
||||
enum {
|
||||
LOCATION = 1,
|
||||
ROTATION = 2,
|
||||
MODEL = 3,
|
||||
UNIT_CELL_SIZE = 4,
|
||||
PIXEL_ARRAY_SIZE = 5,
|
||||
PIXEL_ARRAY_OPTICAL_BLACK_RECTANGLES = 6,
|
||||
PIXEL_ARRAY_ACTIVE_AREAS = 7,
|
||||
SCALER_CROP_MAXIMUM = 8,
|
||||
SENSOR_SENSITIVITY = 9,
|
||||
SYSTEM_DEVICES = 10,
|
||||
PIPELINE_HANDLER = 11,
|
||||
};
|
||||
|
||||
|
||||
enum LocationEnum {
|
||||
CameraLocationFront = 0,
|
||||
CameraLocationBack = 1,
|
||||
CameraLocationExternal = 2,
|
||||
};
|
||||
extern const std::array<const ControlValue, 3> LocationValues;
|
||||
extern const std::map<std::string, int32_t> LocationNameValueMap;
|
||||
extern const Control<int32_t> Location;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_LOCATION
|
||||
extern const Control<int32_t> Rotation;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_ROTATION
|
||||
extern const Control<std::string_view> Model;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_MODEL
|
||||
extern const Control<Size> UnitCellSize;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_UNIT_CELL_SIZE
|
||||
extern const Control<Size> PixelArraySize;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_PIXEL_ARRAY_SIZE
|
||||
extern const Control<Span<const Rectangle>> PixelArrayOpticalBlackRectangles;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_PIXEL_ARRAY_OPTICAL_BLACK_RECTANGLES
|
||||
extern const Control<Span<const Rectangle>> PixelArrayActiveAreas;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_PIXEL_ARRAY_ACTIVE_AREAS
|
||||
extern const Control<Rectangle> ScalerCropMaximum;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_SCALER_CROP_MAXIMUM
|
||||
extern const Control<float> SensorSensitivity;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_SENSOR_SENSITIVITY
|
||||
extern const Control<Span<const int64_t>> SystemDevices;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_SYSTEM_DEVICES
|
||||
extern const Control<std::string_view> PipelineHandler;
|
||||
#define LIBCAMERA_HAS_LIBCAMERA_VENDOR_PROPERTIES_PIPELINE_HANDLER
|
||||
|
||||
namespace draft {
|
||||
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_PROPERTIES
|
||||
|
||||
|
||||
enum {
|
||||
COLOR_FILTER_ARRANGEMENT = 10001,
|
||||
};
|
||||
|
||||
|
||||
enum ColorFilterArrangementEnum {
|
||||
RGGB = 0,
|
||||
GRBG = 1,
|
||||
GBRG = 2,
|
||||
BGGR = 3,
|
||||
RGB = 4,
|
||||
MONO = 5,
|
||||
};
|
||||
extern const std::array<const ControlValue, 6> ColorFilterArrangementValues;
|
||||
extern const std::map<std::string, int32_t> ColorFilterArrangementNameValueMap;
|
||||
extern const Control<int32_t> ColorFilterArrangement;
|
||||
#define LIBCAMERA_HAS_DRAFT_VENDOR_PROPERTIES_COLOR_FILTER_ARRANGEMENT
|
||||
|
||||
} /* namespace draft */
|
||||
|
||||
} /* namespace properties */
|
||||
|
||||
} /* namespace libcamera */
|
||||
Reference in New Issue
Block a user