Tabnine Logo
GImageStatistics.mean
Code IndexAdd Tabnine to your IDE (free)

How to use
mean
method
in
boofcv.alg.misc.GImageStatistics

Best Java code snippets using boofcv.alg.misc.GImageStatistics.mean (Showing top 1 results out of 315)

origin: org.boofcv/demonstrations

public void process( BufferedImage input ) {
  setInputImage(input);
  this.input = input;
  workImage = ConvertBufferedImage.convertFromSingle(input, null, imageType);
  // update the binary histogram threshold for this image
  final double threshold = GImageStatistics.mean(workImage);
  binary.reshape(workImage.width,workImage.height);
  labeled.reshape(workImage.width,workImage.height);
  final int width = input.getWidth();
  final int height = input.getHeight();
  SwingUtilities.invokeLater(new Runnable() {
    public void run() {
      barBinary.setThreshold((int)threshold);
      barBinary.getHistogramPanel().update(workImage);
      panel.setPreferredSize(new Dimension(width,height));
      processedImage = true;
      doRefreshAll();
    }});
}
boofcv.alg.miscGImageStatisticsmean

Javadoc

Returns the mean pixel intensity value.

Popular methods of GImageStatistics

  • maxAbs
    Returns the absolute value of the element with the largest absolute value, across all bands
  • max
    Returns the maximum pixel value across all bands.
  • histogram
    Computes the histogram of intensity values for the image. For floating point images it is rounded to
  • min
    Returns the minimum pixel value across all bands
  • sum
    Returns the sum of all the pixels in the image across all bands.

Popular in Java

  • Reactive rest calls using spring rest template
  • onRequestPermissionsResult (Fragment)
  • putExtra (Intent)
  • scheduleAtFixedRate (Timer)
  • RandomAccessFile (java.io)
    Allows reading from and writing to a file in a random-access manner. This is different from the uni-
  • Locale (java.util)
    Locale represents a language/country/variant combination. Locales are used to alter the presentatio
  • Set (java.util)
    A Set is a data structure which does not allow duplicate elements.
  • SortedSet (java.util)
    SortedSet is a Set which iterates over its elements in a sorted order. The order is determined eithe
  • BoxLayout (javax.swing)
  • FileUtils (org.apache.commons.io)
    General file manipulation utilities. Facilities are provided in the following areas: * writing to a
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now