congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
HistogramDescriptor.create
Code IndexAdd Tabnine to your IDE (free)

How to use
create
method
in
javax.media.jai.operator.HistogramDescriptor

Best Java code snippets using javax.media.jai.operator.HistogramDescriptor.create (Showing top 7 results out of 315)

origin: it.geosolutions.jaiext.utilities/jt-utilities

public void setImage(PlanarImage wrapRenderedImage)
{
  try {
    setHistogram((Histogram) HistogramDescriptor.create(
        wrapRenderedImage,
        null,
        1,
        1,
        new int[] { 65536 },
        new double[] { 0 },
        new double[] { 65535 },
        null).getProperty("histogram"));
  } catch(Exception e) {
    e.printStackTrace();
    setHistogram(null);
  }
}
origin: geosolutions-it/jai-ext

public void setImage(PlanarImage wrapRenderedImage)
{
  try {
    setHistogram((Histogram) HistogramDescriptor.create(
        wrapRenderedImage,
        null,
        1,
        1,
        new int[] { 65536 },
        new double[] { 0 },
        new double[] { 65535 },
        null).getProperty("histogram"));
  } catch(Exception e) {
    e.printStackTrace();
    setHistogram(null);
  }
}
origin: bcdev/beam

public static Histogram computeHistogram(RenderedImage image, ROI roi, int numBins, Range range) {
  final double min = range.getMin();
  final double max = range.getMax();
  Histogram histogram;
  if (min < max) {
    final RenderedOp histogramOp = HistogramDescriptor.create(image, 
                                 roi, 
                                 1, 
                                 1, 
                                 new int[]{numBins},
                                 new double[]{min},
                                 new double[]{max},
                                 null);
    histogram = getBeamHistogram(histogramOp);
  } else {
    final long imageSize = (long) image.getWidth() * image.getHeight();
    final int numPixels = (int) Math.min(Integer.MAX_VALUE, imageSize);
    histogram = new Histogram(new int[]{numPixels} , min, min);
  }
  return histogram;
}

origin: org.imajine.image/org-imajine-image-plugin-jai

/*******************************************************************************
 * 
 * @inheritDoc
 * 
 *******************************************************************************/
private void compute()
 {
  SampleModel sampleModel = renderedImage.getSampleModel();
  bandCount = sampleModel.getNumBands();
  int bits = DataBuffer.getDataTypeSize(sampleModel.getDataType());
  ROI roi = null;
  int[] bins = new int[bandCount];
  min = new double[bandCount];
  max = new double[bandCount];
  int maxxx = 1 << bits;
  for (int i = 0; i < bandCount; i++)
   {
    bins[i] = maxxx;
    min[i] = 0;
    max[i] = maxxx;
   }
  RenderingHints renderingHints = null;
  Integer xPeriod = new Integer(1);
  Integer yPeriod = new Integer(1);
  RenderedOp op = HistogramDescriptor.create(renderedImage, roi, xPeriod, yPeriod, bins, min, max, renderingHints);
  delegate = (Histogram)op.getProperty("histogram");
 }
origin: org.imajine/org-imajine-image-plugin-jai

/*******************************************************************************
 * 
 * @inheritDoc
 * 
 *******************************************************************************/
private void compute()
 {
  SampleModel sampleModel = renderedImage.getSampleModel();
  bandCount = sampleModel.getNumBands();
  int bits = DataBuffer.getDataTypeSize(sampleModel.getDataType());
  ROI roi = null;
  int[] bins = new int[bandCount];
  min = new double[bandCount];
  max = new double[bandCount];
  int maxxx = 1 << bits;
  for (int i = 0; i < bandCount; i++)
   {
    bins[i] = maxxx;
    min[i] = 0;
    max[i] = maxxx;
   }
  RenderingHints renderingHints = null;
  Integer xPeriod = new Integer(1);
  Integer yPeriod = new Integer(1);
  RenderedOp op = HistogramDescriptor.create(renderedImage, roi, xPeriod, yPeriod, bins, min, max, renderingHints);
  delegate = (Histogram)op.getProperty("histogram");
 }
origin: geosolutions-it/jai-ext

      xPeriod, yPeriod, false, 1, null);
} else if (STATISTIC == 2) {
  imageStats = javax.media.jai.operator.HistogramDescriptor.create(testImage,
      roi, xPeriod, yPeriod, numBinsTest, minBoundsTest, maxBoundsTest, null);
origin: org.geotools/gt-render

final RenderedOp hist = HistogramDescriptor.create(inputImage,
    null, Integer.valueOf(1), Integer.valueOf(1),
    new int[] { 256 }, new double[] { 0 },
javax.media.jai.operatorHistogramDescriptorcreate

Popular methods of HistogramDescriptor

    Popular in Java

    • Making http requests using okhttp
    • setRequestProperty (URLConnection)
    • notifyDataSetChanged (ArrayAdapter)
    • requestLocationUpdates (LocationManager)
    • PrintStream (java.io)
      Fake signature of an existing Java class.
    • Collections (java.util)
      This class consists exclusively of static methods that operate on or return collections. It contains
    • HashSet (java.util)
      HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
    • ReentrantLock (java.util.concurrent.locks)
      A reentrant mutual exclusion Lock with the same basic behavior and semantics as the implicit monitor
    • Manifest (java.util.jar)
      The Manifest class is used to obtain attribute information for a JarFile and its entries.
    • ImageIO (javax.imageio)
    • Top Sublime Text 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