How can I count the pixels in a black and white image?
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
How can I count the pixels in a black and white image?
0 commentaires
Réponses (1)
Image Analyst
le 8 Juil 2020
Try this:
numberOfPixels = numel(binaryImage)
numberOfWhitePixels = nnz(binaryImage)
numberOfBlackPixels = numberOfPixels - numberOfWhitePixels
0 commentaires
Voir également
Catégories
En savoir plus sur Audio and Video Data dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!