1

I want to get color of some pixels of an image by js or node.js. How can I do?

I want to find color of every pixels of a png image for choosing pixels with special color in the image

  • https://stackoverflow.com/questions/72082372/getting-the-color-of-a-pixel-on-an-image, and https://www.npmjs.com/package/get-image-colors – Mostafa Fakhraei Dec 31 '22 at 15:14
  • You will need to tranfer the PNG to a HTML `` and read/manipulate the canvas pixels. MDN has a nice reference page with examples on the subject: [Pixel manipulation with canvas](https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas). – Rene van der Lende Dec 31 '22 at 15:26
  • Read this https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas – shreyasm-dev Jan 01 '23 at 01:17

0 Answers0