How to delete selective part of image?
Mostra commenti meno recenti
I am working on a project part of which requires removal of certain part of the image can anyone please help me with that ???? The input image is a front view of a face(does not contain any disguise)I want to delete its eyes. Is that possible??
Risposta accettata
Più risposte (1)
Rushikesh Tade
il 15 Set 2014
By removing if you mean crop then,
Image(row_start:row_end,col_start:col_end)=[];
5 Commenti
David Young
il 15 Set 2014
It's a good idea to test answers before posting them. Unless you are deleting complete columns or complete rows, this will just produce a "Subscripted assignment dimension mismatch" error.
Replacing [] with 0 might sometimes be a useful thing to do. The nub of the question is more likely to be how to detect the eyes in the first place.
Madhura Bombatkar
il 15 Set 2014
David Young
il 15 Set 2014
No, it's not cropping the image. It's throwing an error, in general.
Madhura Bombatkar
il 16 Set 2014
Image Analyst
il 16 Set 2014
Let's make it crystal clear: You flat out cannot do what Rushikesh said in general. Just try it and see. The only way to get it to work is like David said and if those indexes indicate an entire row or column, meaning the start has to be 1 and the ends have to be "end".
What you can do is what I said, and that is to create new, smaller images where you've identified the rectangles in the image and used imcrop() to crop those out, thus forming the new images but leaving the original image intact.
Categorie
Scopri di più su Image Category Classification in Centro assistenza e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


