MCPcopy Create free account
hub / github.com/OpenActionAPI/rust-elgato-streamdeck / set_button_image

Method set_button_image

src/asynchronous.rs:162–167  ·  view source on GitHub ↗

Sets specified button's image, changes must be flushed with `.flush()` before they will appear on the device!

(&self, key: u8, image: DynamicImage)

Source from the content-addressed store, hash-verified

160 /// Sets specified button's image, changes must be flushed with `.flush()` before
161 /// they will appear on the device!
162 pub async fn set_button_image(&self, key: u8, image: DynamicImage) -> Result<(), StreamDeckError> {
163 let image = convert_image_async(self.kind, image)?;
164
165 let device = self.device.lock().await;
166 block_in_place(move || device.write_image(key, &image))
167 }
168
169 /// Sets specified touch point's led strip color
170 pub async fn set_touchpoint_color(&self, point: u8, red: u8, green: u8, blue: u8) -> Result<(), StreamDeckError> {

Callers

nothing calls this directly

Calls 2

convert_image_asyncFunction · 0.85
write_imageMethod · 0.45

Tested by

no test coverage detected