Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: image processing
Date: Fri, 14 Aug 2009 01:44:02 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 20
Message-ID: <h62fh2$l12$1@fred.mathworks.com>
References: <h61jf0$7em$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1250214242 21538 172.30.248.37 (14 Aug 2009 01:44:02 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Fri, 14 Aug 2009 01:44:02 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1933798
Xref: news.mathworks.com comp.soft-sys.matlab:563294


a binary image is a matrix of 1s and 0s, so if you now the position of the pixels that you want to change then work it as a matrix
X is the image of 50x50 if you want a 1 in position (x,y)= (3,5) then go X(3,5)=1 and you have your one in that position.
If is more extense my first thought you can work with for loops in the same way
for example if you want 1 in the portion from x=30 to 50 and y=10 to 15 then

for i=30:50
  for j=10:15
    X(i,j)=1
 end 
end
I hope is what you want to do:)

"Mathew Thomas" <mathew99@gmail.com> wrote in message <h61jf0$7em$1@fred.mathworks.com>...
> Hey All,
> 
> I have a binary image. On the black portion of the image, I want some known pixels to be white...How to do I change these pixel colors to white??
> 
> Thanks,
> 
> Matt