How to find the pixel value of the center pixel and the maximum pixel value difference of the image?
    5 visualizzazioni (ultimi 30 giorni)
  
       Mostra commenti meno recenti
    
    Warid Islam
      
 il 30 Set 2022
  
    
    
    
    
    Commentato: Warid Islam
      
 il 30 Set 2022
            I want to extract a couple of properties from an image, They are:
1) Pixel value of the center pixel
2) Maximum pixel value difference of the image.
I tried impixel for the first part but I don't get any value. Any suggestions would be appreciated. Thank you.

0 Commenti
Risposta accettata
  Image Analyst
      
      
 il 30 Set 2022
        Try this
[rows, columns, numberOfColorChannels] = size(yourImage);
% Find location of the center pixel.
middleRow = round(rows/2);
middleColumn = round(columns/2);
% Get its gray level.
centerPixelValue = yourImage(middleRow, middleColumn, :)
To get the max pixel value difference over the whole image do
maxGrayLevelRange = range(yourImage, 'all')
Più risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

