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

Method key_image_format

src/info.rs:229–275  ·  view source on GitHub ↗

Image format used by the Stream Deck kind

(&self)

Source from the content-addressed store, hash-verified

227
228 /// Image format used by the Stream Deck kind
229 pub fn key_image_format(&self) -> ImageFormat {
230 match self {
231 Kind::Original => ImageFormat {
232 mode: ImageMode::BMP,
233 size: (72, 72),
234 rotation: ImageRotation::Rot0,
235 mirror: ImageMirroring::Both,
236 },
237
238 Kind::OriginalV2 | Kind::Mk2 | Kind::Mk2Scissor | Kind::Mk2Module => ImageFormat {
239 mode: ImageMode::JPEG,
240 size: (72, 72),
241 rotation: ImageRotation::Rot0,
242 mirror: ImageMirroring::Both,
243 },
244
245 Kind::Mini | Kind::MiniMk2 | Kind::MiniDiscord | Kind::MiniMk2Module => ImageFormat {
246 mode: ImageMode::BMP,
247 size: (80, 80),
248 rotation: ImageRotation::Rot90,
249 mirror: ImageMirroring::X,
250 },
251
252 Kind::Neo | Kind::Xl | Kind::XlV2 | Kind::XlV2Module => ImageFormat {
253 mode: ImageMode::JPEG,
254 size: (96, 96),
255 rotation: ImageRotation::Rot0,
256 mirror: ImageMirroring::Both,
257 },
258
259 Kind::Plus => ImageFormat {
260 mode: ImageMode::JPEG,
261 size: (120, 120),
262 rotation: ImageRotation::Rot0,
263 mirror: ImageMirroring::None,
264 },
265
266 Kind::PlusXl => ImageFormat {
267 mode: ImageMode::JPEG,
268 size: (120, 120),
269 rotation: ImageRotation::Rot270,
270 mirror: ImageMirroring::None,
271 },
272
273 Kind::Pedal => ImageFormat::default(),
274 }
275 }
276
277 /// Image format used by LCD screen, used for filling LCD
278 pub fn lcd_image_format(&self) -> Option<ImageFormat> {

Callers 2

convert_imageFunction · 0.80
blank_imageMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected