72 return "ComponentExposure";
74 return "ComponentAnalogGain";
76 return "ComponentDigitalGain";
78 return "ComponentCombinedGain";
80 return "ComponentHostGain";
82 return "ComponentGain";
118 PEAK_AFL_BEGIN_DISABLE_DEPRECATED_WARNINGS
119 switch (componentType)
136 PEAK_AFL_END_DISABLE_DEPRECATED_WARNINGS
142class GenericAutoBrightness;
196 m_parent->UnRegisterComponentCallback(detail::ToCType(m_componentType));
211 friend class detail::GenericAutoBrightness;
222 return m_componentType;
234 m_parent->BrightnessComponentSetMode(detail::ToCType(m_componentType), detail::ToCType(mode));
246 return detail::ToControllerMode(m_parent->BrightnessComponentGetMode(detail::ToCType(m_componentType)));
258 m_limit->Set(interval);
270 return m_limit->Get();
285 m_limit->Serialize(*limitArchive);
299 auto limitArchive = archive.
GetArchive(
"Limit");
300 m_limit->Deserialize(*limitArchive);
315 return m_FinishedCallbackManager.RegisterCallback(callback);
327 m_FinishedCallbackManager.UnregisterCallback(callbackHandle);
341 std::unique_ptr<features::BrightnessLimit> limit)
343 , m_componentType(componentType)
344 , m_limit{ std::move(limit) }
346 m_parent->
RegisterComponentCallback(detail::ToCType(m_componentType), [
this]() { m_FinishedCallbackManager.TriggerCallbacks(); });
350 peak::core::TTriggerCallbackManager<BrightnessComponent::FinishedCallbackHandle, BrightnessComponent::FinishedCallback>
351 m_FinishedCallbackManager;
354 std::shared_ptr<peak::afl::Controller> m_parent;
358 std::unique_ptr<features::BrightnessLimit> m_limit{};
void RegisterComponentCallback(peak_afl_controller_brightness_component component, const callback::FinishedCallback &callback)
Set component callback for a controller.
Definition peak_afl.hpp:2913
The exception thrown for signaling an unspecified error.
Definition peak_afl.hpp:340
The exception thrown for passing an invalid parameter to a function.
Definition peak_afl.hpp:391
Interface for a hierarchical key-value archive system.
Definition peak_common_iarchive.hpp:59
virtual std::shared_ptr< IArchive > GetArchive(const std::string &key) const =0
Retrieves a nested archive by key.
virtual std::string GetString(const std::string &key) const =0
Retrieves a string value by key.
virtual std::shared_ptr< IArchive > CreateArchive() const =0
Creates a new, empty archive instance.
virtual void SetArchive(const std::string &key, const std::shared_ptr< IArchive > &value)=0
Stores a nested archive object.
virtual void SetString(const std::string &key, const std::string &value)=0
Stores a UTF-8 string.
std::function< void()> FinishedCallback
Callback function type for component completion notifications.
Definition peak_afl_brightness_component.hpp:203
void Serialize(peak::common::serialization::IArchive &archive) const
Serializes component configuration to archive.
Definition peak_afl_brightness_component.hpp:280
BrightnessComponent(BrightnessComponent &&)=delete
Move constructor deleted to prevent moving.
BrightnessComponent & operator=(BrightnessComponent &&)=delete
Move assignment deleted to prevent moving.
FinishedCallbackHandle RegisterFinishedCallback(const BrightnessComponent::FinishedCallback &callback)
Registers a callback for component completion.
Definition peak_afl_brightness_component.hpp:313
void SetMode(ControllerMode mode)
Sets the control mode for this component.
Definition peak_afl_brightness_component.hpp:232
void Deserialize(const peak::common::serialization::IArchive &archive)
Deserializes component configuration from archive.
Definition peak_afl_brightness_component.hpp:297
FinishedCallback * FinishedCallbackHandle
Handle type for managing callback registrations.
Definition peak_afl_brightness_component.hpp:208
IntervalD GetLimit()
Gets the current value limits.
Definition peak_afl_brightness_component.hpp:268
BrightnessComponentType GetType() const
Gets the brightness component type.
Definition peak_afl_brightness_component.hpp:220
~BrightnessComponent()
Destructor that properly unregisters callbacks.
Definition peak_afl_brightness_component.hpp:194
void UnregisterFinishedCallback(BrightnessComponent::FinishedCallbackHandle callbackHandle)
Unregisters a previously registered callback.
Definition peak_afl_brightness_component.hpp:325
BrightnessComponent & operator=(const BrightnessComponent &)=delete
Copy assignment deleted to prevent copying.
void SetLimit(const IntervalD &interval)
Sets the value limits for this component.
Definition peak_afl_brightness_component.hpp:256
ControllerMode GetMode() const
Gets the current control mode.
Definition peak_afl_brightness_component.hpp:244
BrightnessComponent(const BrightnessComponent &)=delete
Copy constructor deleted to prevent copying.
peak_afl_controller_brightness_component
Brightness control components.
Definition peak_afl.h:877
@ PEAK_AFL_CONTROLLER_BRIGHTNESS_COMPONENT_INVALID
Invalid or uninitialized component.
Definition peak_afl.h:884
@ PEAK_AFL_CONTROLLER_BRIGHTNESS_COMPONENT_ANALOG_GAIN
Analog gain control.
Definition peak_afl.h:919
@ PEAK_AFL_CONTROLLER_BRIGHTNESS_COMPONENT_GAIN
Generic gain control.
Definition peak_afl.h:907
@ PEAK_AFL_CONTROLLER_BRIGHTNESS_COMPONENT_COMBINED_GAIN
Combined analog and digital gain.
Definition peak_afl.h:943
@ PEAK_AFL_CONTROLLER_BRIGHTNESS_COMPONENT_HOST_GAIN
Host-based software gain.
Definition peak_afl.h:955
@ PEAK_AFL_CONTROLLER_BRIGHTNESS_COMPONENT_DIGITAL_GAIN
Digital gain control.
Definition peak_afl.h:931
@ PEAK_AFL_CONTROLLER_BRIGHTNESS_COMPONENT_EXPOSURE
Camera exposure time control.
Definition peak_afl.h:896
@ PEAK_AFL_STATUS_INVALID_PARAMETER
Invalid parameter provided.
Definition peak_afl.h:419
@ PEAK_AFL_STATUS_ERROR
General error occurred.
Definition peak_afl.h:399
ControllerMode
Controller operation mode enumeration.
Definition peak_afl_icontroller.hpp:59
std::string ToString(ControllerType mode)
Converts ControllerType enumeration to string representation.
Definition peak_afl_icontroller.hpp:78
BrightnessComponentType
Brightness component type enumeration.
Definition peak_afl_brightness_component.hpp:38
@ CombinedGain
Combined gain component - both analog and digital (combined) gain.
Definition peak_afl_brightness_component.hpp:48
@ Gain
Automatic gain component - automatic gain control.
Definition peak_afl_brightness_component.hpp:52
@ Invalid
Invalid or uninitialized component type.
Definition peak_afl_brightness_component.hpp:40
@ AnalogGain
Analog gain component - hardware gain applied before digitization.
Definition peak_afl_brightness_component.hpp:44
@ DigitalGain
Digital gain component - gain applied after digitization.
Definition peak_afl_brightness_component.hpp:46
@ HostGain
Host gain component - software-based gain processing.
Definition peak_afl_brightness_component.hpp:50
@ Exposure
Exposure time component - controls sensor integration time.
Definition peak_afl_brightness_component.hpp:42
Interface definitions and implementations for individual module types used within a pipeline.
Definition peak_afl_generic_auto_brightness.hpp:39
Interfaces and implementations for defining and controlling data processing pipelines.
Definition peak_afl_generic_auto_brightness.hpp:37
peak::common::detail::IntervalT< double > IntervalD
Type alias for double-precision interval values.
Definition peak_afl_ifeature.hpp:28