You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
tl;dr: you can only use number (e.g. 0xff0000ff), string, or Float32Array.
In JsiSkColor::createCtor, if argument[0].isObject() (true for both Array and Float32Array), it's returned as the color value.
Then when it comes time to turn the jsi::Value to an SkColor in JsiSkColor::FromValue, it tries to get the .buffer property from the object (which is of course is not there on an array -- thus undefined).
Description
Hello! Thank you for this library, I'm having so much fun using it :)
Passing RGBA values to
Skia.Color
, for exampleSkia.Color([0, 128, 0, 255])
throws the following error:I know I can use
Float32Array
and0-1
scale:However, the
Color
type suggests I can passnumber[]
too. I would be grateful for clarification here 🙏Version
0.1.231
Steps to reproduce
Snack, code example, screenshot, or link to a repository
⬆️
The text was updated successfully, but these errors were encountered: