mirror of
https://github.com/Evolution-X-Devices/device_xiaomi_sm6150-common
synced 2026-01-27 12:07:36 +00:00
sm6150-common: camera: Implement setTorchModeExt
Change-Id: Id61420be75b7efd1d13a4b0ee1d103ebd3835516 Signed-off-by: bengris32 <bengris32@protonmail.ch> Signed-off-by: therealmharc <therealmharc@gmail.com>
This commit is contained in:
@@ -73,3 +73,8 @@ void setTorchStrengthLevelExt(int32_t torchStrength) {
|
|||||||
if (torchStrength > 0)
|
if (torchStrength > 0)
|
||||||
set(TOGGLE_SWITCH, 255);
|
set(TOGGLE_SWITCH, 255);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void setTorchModeExt(bool enabled) {
|
||||||
|
int32_t strength = getTorchDefaultStrengthLevelExt();
|
||||||
|
setTorchStrengthLevelExt(enabled ? strength : 0);
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user