Hi All,
I need to replace white pixels of an image with blue pixels
Does someone have a useful script to do that ?
Thanks
Jean-Marc
Replace pixel color of an image
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Replace pixel color of an image
https://alternatic.ch
Re: Replace pixel color of an image
Salut Jean-Marc,
here is a little stack that replaces white pixels with blue pixels. Please look at the explanation and the script of the button.
Kind regards
Bernd
here is a little stack that replaces white pixels with blue pixels. Please look at the explanation and the script of the button.
Kind regards
Bernd
- Attachments
-
- replaceWhiteWithBlueInImage.livecode.zip
- (181.22 KiB) Downloaded 350 times
Re: Replace pixel color of an image
Jean-Marc:
Shades of Steve Maller's "ThePixel" XFCN for HC, or Rinaldi's "PixelColor". All from around the Pleistocene.
These returned the value of the pixel under the cursor. But read-only.
And Matthew Reagan wrote a XCMD that would change all the black pixels to any color. close to what you wanted.
It seems impossible that LC does not have a "setPixel" command and "getPixel" function. Could not find one, though.
Craig
Shades of Steve Maller's "ThePixel" XFCN for HC, or Rinaldi's "PixelColor". All from around the Pleistocene.
These returned the value of the pixel under the cursor. But read-only.
And Matthew Reagan wrote a XCMD that would change all the black pixels to any color. close to what you wanted.
It seems impossible that LC does not have a "setPixel" command and "getPixel" function. Could not find one, though.
Craig
Re: Replace pixel color of an image
Bernd.
Ah. So there is such a tool, even though it requires that the entire imageData be processed. Very cool.
Craig
Ah. So there is such a tool, even though it requires that the entire imageData be processed. Very cool.
Craig
Re: Replace pixel color of an image
Bernd, Craig,
Thank for your fast reply
I will test the Bernd's stack tomorrow
Kind regards
Jean-Marc
Thank for your fast reply
I will test the Bernd's stack tomorrow
Kind regards
Jean-Marc
https://alternatic.ch