mirror of
https://github.com/home-assistant/core.git
synced 2025-07-26 14:47:38 +00:00
Add Reolink image settings (#105415)
This commit is contained in:
parent
09b65f14b9
commit
ba0cb3bd05
@ -371,6 +371,76 @@ NUMBER_ENTITIES = (
|
|||||||
value=lambda api, ch: api.daynight_threshold(ch),
|
value=lambda api, ch: api.daynight_threshold(ch),
|
||||||
method=lambda api, ch, value: api.set_daynight_threshold(ch, int(value)),
|
method=lambda api, ch, value: api.set_daynight_threshold(ch, int(value)),
|
||||||
),
|
),
|
||||||
|
ReolinkNumberEntityDescription(
|
||||||
|
key="image_brightness",
|
||||||
|
cmd_key="GetImage",
|
||||||
|
translation_key="image_brightness",
|
||||||
|
icon="mdi:image-edit",
|
||||||
|
entity_category=EntityCategory.CONFIG,
|
||||||
|
entity_registry_enabled_default=False,
|
||||||
|
native_step=1,
|
||||||
|
native_min_value=0,
|
||||||
|
native_max_value=255,
|
||||||
|
supported=lambda api, ch: api.supported(ch, "isp_bright"),
|
||||||
|
value=lambda api, ch: api.image_brightness(ch),
|
||||||
|
method=lambda api, ch, value: api.set_image(ch, bright=int(value)),
|
||||||
|
),
|
||||||
|
ReolinkNumberEntityDescription(
|
||||||
|
key="image_contrast",
|
||||||
|
cmd_key="GetImage",
|
||||||
|
translation_key="image_contrast",
|
||||||
|
icon="mdi:image-edit",
|
||||||
|
entity_category=EntityCategory.CONFIG,
|
||||||
|
entity_registry_enabled_default=False,
|
||||||
|
native_step=1,
|
||||||
|
native_min_value=0,
|
||||||
|
native_max_value=255,
|
||||||
|
supported=lambda api, ch: api.supported(ch, "isp_contrast"),
|
||||||
|
value=lambda api, ch: api.image_contrast(ch),
|
||||||
|
method=lambda api, ch, value: api.set_image(ch, contrast=int(value)),
|
||||||
|
),
|
||||||
|
ReolinkNumberEntityDescription(
|
||||||
|
key="image_saturation",
|
||||||
|
cmd_key="GetImage",
|
||||||
|
translation_key="image_saturation",
|
||||||
|
icon="mdi:image-edit",
|
||||||
|
entity_category=EntityCategory.CONFIG,
|
||||||
|
entity_registry_enabled_default=False,
|
||||||
|
native_step=1,
|
||||||
|
native_min_value=0,
|
||||||
|
native_max_value=255,
|
||||||
|
supported=lambda api, ch: api.supported(ch, "isp_satruation"),
|
||||||
|
value=lambda api, ch: api.image_saturation(ch),
|
||||||
|
method=lambda api, ch, value: api.set_image(ch, saturation=int(value)),
|
||||||
|
),
|
||||||
|
ReolinkNumberEntityDescription(
|
||||||
|
key="image_sharpness",
|
||||||
|
cmd_key="GetImage",
|
||||||
|
translation_key="image_sharpness",
|
||||||
|
icon="mdi:image-edit",
|
||||||
|
entity_category=EntityCategory.CONFIG,
|
||||||
|
entity_registry_enabled_default=False,
|
||||||
|
native_step=1,
|
||||||
|
native_min_value=0,
|
||||||
|
native_max_value=255,
|
||||||
|
supported=lambda api, ch: api.supported(ch, "isp_sharpen"),
|
||||||
|
value=lambda api, ch: api.image_sharpness(ch),
|
||||||
|
method=lambda api, ch, value: api.set_image(ch, sharpen=int(value)),
|
||||||
|
),
|
||||||
|
ReolinkNumberEntityDescription(
|
||||||
|
key="image_hue",
|
||||||
|
cmd_key="GetImage",
|
||||||
|
translation_key="image_hue",
|
||||||
|
icon="mdi:image-edit",
|
||||||
|
entity_category=EntityCategory.CONFIG,
|
||||||
|
entity_registry_enabled_default=False,
|
||||||
|
native_step=1,
|
||||||
|
native_min_value=0,
|
||||||
|
native_max_value=255,
|
||||||
|
supported=lambda api, ch: api.supported(ch, "isp_hue"),
|
||||||
|
value=lambda api, ch: api.image_hue(ch),
|
||||||
|
method=lambda api, ch, value: api.set_image(ch, hue=int(value)),
|
||||||
|
),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
@ -308,6 +308,21 @@
|
|||||||
},
|
},
|
||||||
"day_night_switch_threshold": {
|
"day_night_switch_threshold": {
|
||||||
"name": "Day night switch threshold"
|
"name": "Day night switch threshold"
|
||||||
|
},
|
||||||
|
"image_brightness": {
|
||||||
|
"name": "Image brightness"
|
||||||
|
},
|
||||||
|
"image_contrast": {
|
||||||
|
"name": "Image contrast"
|
||||||
|
},
|
||||||
|
"image_saturation": {
|
||||||
|
"name": "Image saturation"
|
||||||
|
},
|
||||||
|
"image_sharpness": {
|
||||||
|
"name": "Image sharpness"
|
||||||
|
},
|
||||||
|
"image_hue": {
|
||||||
|
"name": "Image hue"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"select": {
|
"select": {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user