Selecting Pixels of a Particular Color

S
Posted By
stmx3
Jan 11, 2005
Views
2885
Replies
11
Status
Closed
Given an image of randomly colored pixels, is it possible to select from the image only those pixels of a particular RGB color? I.e. can I specify (100,100,100) as my RGB value and select all pixels of that particular color?

-stmx3

MacBook Pro 16” Mockups 🔥

– in 4 materials (clay versions included)

– 12 scenes

– 48 MacBook Pro 16″ mockups

– 6000 x 4500 px

C
Corey
Jan 11, 2005
Try using your Magic Wand with "contiguous" unchecked and a tolerance of zero. Make a tiny patch, just a pixel or two of the color you want to select (RGB value) and then click on it with the Magic Wand. It should select the tiny patch and every thing else that specific color.

I’m not sure if this will work 100% accurately, but it may.

Peadge 🙂

"stmx3" wrote in message
Given an image of randomly colored pixels, is it possible to select from the image only those pixels of a particular RGB color? I.e. can I specify (100,100,100) as my RGB value and select all pixels of that particular color?

-stmx3
JM
John McWilliams
Jan 11, 2005
stmx3 wrote:
Given an image of randomly colored pixels, is it possible to select from the image only those pixels of a particular RGB color? I.e. can I specify (100,100,100) as my RGB value and select all pixels of that particular color?

What is it you are trying to do?


John McWilliams
BF
Black Forrest
Jan 11, 2005
Yep, under Selection use "choose range" with zero tolerance. Don’t know if this is the right word, have the german Version.

Greetings
Bee Dee

"stmx3" schrieb im Newsbeitrag
Given an image of randomly colored pixels, is it possible to select from the image only those pixels of a particular RGB color? I.e. can I specify (100,100,100) as my RGB value and select all pixels of that particular color?

-stmx3
S
stmx3
Jan 11, 2005
I’m trying to create a hidden message for an entry at geocaching.com. Basically, armed with a gps, people go looking for a cache in the woods at some coordinates. In this case, upon finding mine, hidden inside will be an RGB value. Given an image of random colors, by applying the correct RGB value they can then tease out the coordinates for another cache.

It’s all very fun, and in this case, gets them to delve into the uses of graphics software.

-stmx3
JM
John McWilliams
Jan 11, 2005
stmx3 wrote:
I’m trying to create a hidden message for an entry at geocaching.com. Basically, armed with a gps, people go looking for a cache in the woods at some coordinates. In this case, upon finding mine, hidden inside will be an RGB value. Given an image of random colors, by applying the correct RGB value they can then tease out the coordinates for another cache.

It’s all very fun, and in this case, gets them to delve into the uses of graphics software.
Whoa! That’s a helluva neat use. Peadge’s reply seemed to cover what I might have said- did that do it for you?


john mcwilliams
T
tacitr
Jan 11, 2005
Given an image of randomly colored pixels, is it possible to select from the image only those pixels of a particular RGB color?

Yes. there are two ways to do it.

The clumsy way is to use the Magic Wand with a Tolerance value of 0, as long as the sample size is set to 1×1. (By default, when you click with the wand or eyedropper, it grabs the nearest pixels and averages hem.)

The easy way is to use the Select->Color Range command. That’s what it’s for.


Art, literature, shareware, polyamory, kink, and more:
http://www.xeromag.com/franklin.html
S
stmx3
Jan 11, 2005
Thanks for everyone’s help. It sounds so easy now but I was really struggling to figure out a way with my old 5.0 LE version of the program. One of the driving issues will be the availability a program for all to download, whether it be an evaluation copy or not. But, it looks like the solution can be had fairly easily using the methods you’ve mentioned.

Again, thank you.
-stmx3
C
Corey
Jan 12, 2005
"Tacit" wrote in message
Given an image of randomly colored pixels, is it possible to select from the image only those pixels of a particular RGB color?

Yes. there are two ways to do it.

The clumsy way is to use the Magic Wand with a Tolerance value of 0, as
long as
the sample size is set to 1×1. (By default, when you click with the wand
or
eyedropper, it grabs the nearest pixels and averages hem.)
The easy way is to use the Select->Color Range command. That’s what it’s
for.

Art, literature, shareware, polyamory, kink, and more:
http://www.xeromag.com/franklin.html

Clumsy? In what way? Surely the Magic Wand Tool isn’t too heavy or awkward! 😉

It seems to be incredibly fast and quite accurate, the antithesis to "clumsy."

The Color Picker, on the other hand, can be a PITA, especially for someone new to the tool. Even a bit clumsy, perhaps.

Peadge 🙂
T
tacitr
Jan 13, 2005
Clumsy? In what way? Surely the Magic Wand Tool isn’t too heavy or awkward! 😉

It seems to be incredibly fast and quite accurate, the antithesis to "clumsy."

The Magic Wand tool is clumsy because by default, it averages the colors it samples (which needs to be changed to select just one shade of color with perfect precision), because by default it selects contiguous colors only (which needs to be changed to select all of a given color), and by default it creates an antialiased selection. It also does not give visual feedback before creating the selection; if the selection doesn’t work out exactly right, you need to change the selection manually or adjust the Tolerance setting and try again.

Select->Color Range provides feedback about the selection it will make, allowing the user to change the tolerance of the selection interactively before making the selection. It also allows the user to set a tolerance for the selection and then include or exclude specific colors, again interactively, before creating the selection–something the Magic Wand doesn’t allow.

When I first started using Photoshop, back in 1992, I found myself using the Magic Wand often. Nowadays I touch the Magic Wand tool perhaps once a month, and I use Photoshop 30 hours a week. 🙂


Art, literature, shareware, polyamory, kink, and more:
http://www.xeromag.com/franklin.html
C
Corey
Jan 13, 2005
"Tacit" wrote in message
Clumsy? In what way? Surely the Magic Wand Tool isn’t too heavy or
awkward!
😉

It seems to be incredibly fast and quite accurate, the antithesis to "clumsy."

The Magic Wand tool is clumsy because by default, it averages the colors
it
samples (which needs to be changed to select just one shade of color with perfect precision), because by default it selects contiguous colors only
(which
needs to be changed to select all of a given color), and by default it
creates
an antialiased selection. It also does not give visual feedback before
creating
the selection; if the selection doesn’t work out exactly right, you need
to
change the selection manually or adjust the Tolerance setting and try
again.
Select->Color Range provides feedback about the selection it will make, allowing the user to change the tolerance of the selection interactively
before
making the selection. It also allows the user to set a tolerance for the selection and then include or exclude specific colors, again
interactively,
before creating the selection–something the Magic Wand doesn’t allow.
When I first started using Photoshop, back in 1992, I found myself using
the
Magic Wand often. Nowadays I touch the Magic Wand tool perhaps once a
month,
and I use Photoshop 30 hours a week. 🙂


Art, literature, shareware, polyamory, kink, and more:
http://www.xeromag.com/franklin.html

All good points, Tacit. The Color Picker does offer much more control and a far wider range of options. But in this case, where some of the OP’s geo-caching buddies, who may not be very familiar with Photoshop and might be forced to download a trial version of Photoshop or even Elements, the Magic Wand may prove to be far less of a challenge. But then challenge seems to be the intended goal! Regardless of which tool is used, the idea itself it quite fascinating. I sent it to some friends who geo-cache and they thought it was very cool. Thanks for the detailed response!

Peadge 🙂
S
stmx3
Jan 17, 2005
Peadge wrote:
"Tacit" wrote in message
Clumsy? In what way? Surely the Magic Wand Tool isn’t too heavy or
awkward!
😉

It seems to be incredibly fast and quite accurate, the antithesis
to
"clumsy."

The Magic Wand tool is clumsy because by default, it averages the
colors
it
samples (which needs to be changed to select just one shade of
color with
perfect precision), because by default it selects contiguous colors
only
(which
needs to be changed to select all of a given color), and by default
it
creates
an antialiased selection. It also does not give visual feedback
before
creating
the selection; if the selection doesn’t work out exactly right, you
need
to
change the selection manually or adjust the Tolerance setting and
try
again.
Select->Color Range provides feedback about the selection it will
make,
allowing the user to change the tolerance of the selection
interactively
before
making the selection. It also allows the user to set a tolerance
for the
selection and then include or exclude specific colors, again
interactively,
before creating the selection–something the Magic Wand doesn’t
allow.
When I first started using Photoshop, back in 1992, I found myself
using
the
Magic Wand often. Nowadays I touch the Magic Wand tool perhaps once
a
month,
and I use Photoshop 30 hours a week. 🙂


Art, literature, shareware, polyamory, kink, and more:
http://www.xeromag.com/franklin.html

All good points, Tacit. The Color Picker does offer much more control
and a
far wider range of options. But in this case, where some of the OP’s geo-caching buddies, who may not be very familiar with Photoshop and
might
be forced to download a trial version of Photoshop or even Elements,
the
Magic Wand may prove to be far less of a challenge. But then
challenge
seems to be the intended goal! Regardless of which tool is used, the
idea
itself it quite fascinating. I sent it to some friends who geo-cache
and
they thought it was very cool. Thanks for the detailed response!
Peadge 🙂

That’s it exactly. You hit the nail on the head, Peadge. The users, if they don’t already have the program, must be able to download a trial version freely. The bigger the challenge, the better the puzzle. With limitations imposed by a free/trial version, I see the user as having to paint a swath of the given RGB onto the image and then, with the wand, select that color and all similar with tolerance set to zero, copy and past results onto a blank canvas, thereby revealing the "secret message".

My next step is to create a random image of "noisy" pixels…i.e. random colored pixels over the entire canvas. I would prefer to do that over selecting some image and discretely modifying
pixels…although this is the route I may end up taking.

-stmx3

MacBook Pro 16” Mockups 🔥

– in 4 materials (clay versions included)

– 12 scenes

– 48 MacBook Pro 16″ mockups

– 6000 x 4500 px

Related Discussion Topics

Nice and short text about related topics in discussion sections