Hi everybody, hi have an RGB image and i want to remove all pixels which were equal to 1 from the following command:
FIND=(A(:,:,1)>=175 & (A(:,:,1)<=193));
with A that is the 4000x6000x3 uint8 image.
How can i do it?
Thank you!

 Akzeptierte Antwort

KSSV
KSSV am 27 Feb. 2019
Bearbeitet: KSSV am 27 Feb. 2019

0 Stimmen

YOu cannot remove them, replace them with any other value.......
A = I(:,:,1) ;
idx = A>=175 & A<=193;
A(idx) = 0 ;
I(:,:,1) = A ;

4 Kommentare

Riccardo Rossi
Riccardo Rossi am 27 Feb. 2019
Thank you for the answer, but what is I?
KSSV
KSSV am 27 Feb. 2019
I is your RGB image of size (m,n,3)
Riccardo Rossi
Riccardo Rossi am 27 Feb. 2019
okay, but i just want to select (A(:,:,1)>=175 & (A(:,:,1)<=193)) and not (A(:,:,i)>=175 & (A(:,:,i)<=193))
KSSV
KSSV am 27 Feb. 2019
Bearbeitet: KSSV am 27 Feb. 2019
Okay..then remove the loop.....Edited the code.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Images finden Sie in Hilfe-Center und File Exchange

Produkte

Version

R2018b

Gefragt:

am 27 Feb. 2019

Bearbeitet:

am 27 Feb. 2019

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by