Help to access color values
TheTheoM opened this issue · 1 comments
TheTheoM commented
Hey, How Do I access the color values of an LED?
It is doable in the python version.
intrueder commented
@TheTheoM , you need either CorsairGetLedsColors or CorsairGetLedsColorsByDeviceIndex function. As a colors
argument, pass an array of LED color objects, you can construct it manually or transform a result from CorsairGetLedPositions
function:
const leds = sdk.CorsairGetLedPositions().map(led => ({ ledId: led.ledId, r: 0, g: 0, b: 0 }));
sdk.CorsairGetLedsColors(leds);
console.log(leds);