v0.0.4pick_color
Um pacote Flutter que permite extrair cores e códigos hexadecimais de imagens com um toque simples.
29Curtidas 25Downloads em 30 dias140Pontos Pub
AndroidiOSWebmacOSWindowsLinux
Oauth-Celestial/image_color_picker open-source repository details.
{"sdk":"flutter"}^3.0.1{"sdk":"flutter"}Texto original em inglês. Visite o GitHub para a versão atual.
Pick_Color allows you to sample specific colors from an image and obtain their hex color code by just dragging over the image area.
pick_color
pick_color : any
Image image = Image.asset("assets/b.jpg");
ColorPicker(
child: image, # Your Image widget
onChanged: (response) {
String hexcode = response.hexCode;
// Get Selected Color
Color color = response.selectionColor;
// Get Red Channel Color
int redValue = response.redScale;
// Get Blue Channel Color
int blueValue = response.blueScale;
// Get Green Channel Color
int greenValue = response.greenScale;
});
That's all it takes 😃
Feel Free to contribute or file an issue happy coding.