Display gray color only from grayscale image
Mostrar comentarios más antiguos
Hi all
Apology for my ignorance as this is quite new to me.
I'm currently working on MRI images and have tried numerous times using some thresholding methods to display gray area of MRI image/s but to no avail.
Any pixel with grayscale value (0-255) of less than 5 & more than 250 will be eliminated and thus only showing pixels within 6-249.
Any helps are much appreciated.
Regards Demon
2 comentarios
Walter Roberson
el 17 de En. de 2013
The places where those pixels were: do you need those places to be transparent?
Demons
el 17 de En. de 2013
Respuesta aceptada
Más respuestas (2)
Amith Kamath
el 17 de En. de 2013
For most tasks of analysing pixel values and thresholding, I've found http://www.mathworks.com/matlabcentral/fileexchange/6770 very useful.
You could use:
[levelLow bwLow] = thresh_tool(IM);
[levelHi bwHi] = thresh_tool(IM);
%to get the mask for each of the lower and upper level in bw.
depending on the datatype of your image, you can then just do an and operation between your image and the bw images.
1 comentario
Demons
el 17 de En. de 2013
Categorías
Más información sobre Images en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!