本文整理了Java中javax.media.jai.iterator.RectIter.finishedLines
方法的一些代码示例,展示了RectIter.finishedLines
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。RectIter.finishedLines
方法的具体详情如下:
包路径:javax.media.jai.iterator.RectIter
类名称:RectIter
方法名:finishedLines
暂无
代码示例来源:origin: geotools/geotools
/** Returns {@code true} if the bottom row of the bounding rectangle has been passed. */
public boolean finishedLines() {
boolean check = src.finishedLines();
if (check == dst.finishedLines()) {
return check;
}
throw new RasterFormatException(ERROR);
}
代码示例来源:origin: geotools/geotools
public RasterAsPointFeatureIterator(final RasterAsPointFeatureCollection fc) {
// checks
Utilities.ensureNonNull("fc", fc);
// get elements
this.fc = fc;
this.fb = new SimpleFeatureBuilder(fc.getSchema());
this.size = fc.size;
// create an iterator that only goes forward, it is the fastest one
iterator = RectIterFactory.create(fc.gc2d.getRenderedImage(), null);
//
// start the iterator
//
iterator.startLines();
if (iterator.finishedLines()) {
throw new NoSuchElementException("Index beyond size:" + index + ">" + size);
}
iterator.startPixels();
if (iterator.finishedPixels()) {
throw new NoSuchElementException("Index beyond size:" + index + ">" + size);
}
// appo
temp = new double[fc.numBands];
// grid convergence angle manager
if (fc.gridConvergenceAngleCorrectionNeeded) {
sourceCRSPosition = new DirectPosition2D();
targetCRSPosition = new DirectPosition2D(fc.targetCRS);
}
}
代码示例来源:origin: geotools/geotools
throw new NoSuchElementException("Index beyond size:" + index + ">" + size);
if (iterator.finishedLines()) {
throw new NoSuchElementException("Index beyond size:" + index + ">" + size);
代码示例来源:origin: org.geotools/gt2-coverageio
/**
* Returns true if the bottom row of the bounding rectangle has been passed.
*/
public boolean finishedLines() {
return iterator.finishedLines();
}
代码示例来源:origin: org.geotools/gt2-coverage
/**
* Returns {@code true} if the bottom row of the bounding rectangle has been passed.
*/
public boolean finishedLines() {
boolean check = src.finishedLines();
if (check == dst.finishedLines()) {
return check;
}
throw new RasterFormatException(ERROR);
}
代码示例来源:origin: org.geotools/gt-coverage
/**
* Returns {@code true} if the bottom row of the bounding rectangle has been passed.
*/
public boolean finishedLines() {
boolean check = src.finishedLines();
if (check == dst.finishedLines()) {
return check;
}
throw new RasterFormatException(ERROR);
}
代码示例来源:origin: Geomatys/geotoolkit
/**
* Returns {@code true} if the bottom row of the bounding rectangle has been passed.
*
* @return {@code true} if the iteration over lines is finished.
*/
@Override
public boolean finishedLines() {
boolean check = src.finishedLines();
if (check == dst.finishedLines()) {
return check;
}
throw new RasterFormatException(ERROR);
}
代码示例来源:origin: org.geotools/gt-process-raster
public RasterAsPointFeatureIterator(final RasterAsPointFeatureCollection fc) {
//checks
Utilities.ensureNonNull("fc", fc);
//get elements
this.fc= fc;
this.fb = new SimpleFeatureBuilder(fc.getSchema());
this.size=fc.size;
// create an iterator that only goes forward, it is the fastest one
iterator= RectIterFactory.create(fc.gc2d.getRenderedImage(), null);
//
//start the iterator
//
iterator.startLines();
if(iterator.finishedLines())
throw new NoSuchElementException("Index beyond size:"+index+">"+size);
iterator.startPixels();
if(iterator.finishedPixels())
throw new NoSuchElementException("Index beyond size:"+index+">"+size);
// appo
temp= new double[fc.numBands];
}
代码示例来源:origin: org.geotools/gt-process-raster
if(iterator.finishedLines())
throw new NoSuchElementException("Index beyond size:"+index+">"+size);
代码示例来源:origin: mapplus/spatial_statistics_for_geotools_udig
while (!readIter.finishedLines()) {
aRx[dy] = new int[numColumns];
aRy[dy] = new int[numColumns];
代码示例来源:origin: org.jaitools/jt-contour
while (!iter.finishedLines()) {
iter.startPixels();
while (!iter.finishedPixels()) {
代码示例来源:origin: com.googlecode.jaitools/jt-contour
while (!iter.finishedLines()) {
iter.startPixels();
while (!iter.finishedPixels()) {
代码示例来源:origin: org.geotools/gt2-coverageio
int numSampleValues = 0, nextProgress = 0;
if (!iterator.finishedBands()) do {
if (!iterator.finishedLines()) do {
if (numSampleValues >= nextProgress) {
代码示例来源:origin: mapplus/spatial_statistics_for_geotools_udig
public void visit(GridCoverage2D inputCoverage, Integer bandIndex) {
reset();
PlanarImage inputImage = (PlanarImage) inputCoverage.getRenderedImage();
RectIter readIter = RectIterFactory.create(inputImage, inputImage.getBounds());
readIter.startLines();
while (!readIter.finishedLines()) {
readIter.startPixels();
while (!readIter.finishedPixels()) {
double sampleValue = readIter.getSampleDouble(bandIndex);
visit(Double.valueOf(sampleValue));
readIter.nextPixel();
}
readIter.nextLine();
}
}
代码示例来源:origin: mapplus/spatial_statistics_for_geotools_udig
inputIter.startLines();
writerIter.startLines();
while (!inputIter.finishedLines() && !writerIter.finishedLines()) {
int column = inputBounds.x;
inputIter.startPixels();
代码示例来源:origin: mapplus/spatial_statistics_for_geotools_udig
redIter.startLines();
writerIter.startLines();
while (!nirIter.finishedLines() && !redIter.finishedLines() && !writerIter.finishedLines()) {
nirIter.startPixels();
redIter.startPixels();
代码示例来源:origin: Geomatys/geotoolkit
/**
* Ensures that all sample values in every bands are either inside the given range,
* or {@link Double#NaN}.
*
* @param minimum The lower bound of the range, inclusive.
* @param maximum The upper bound of the range, inclusive.
* @param image The image to test.
*
* @since 3.19
*/
public static void assertSampleValuesInRange(final double minimum, final double maximum,
final RenderedImage image)
{
final RectIter it = RectIterFactory.create(image, null);
if (!it.finishedLines()) do {
if (!it.finishedPixels()) do {
if (!it.finishedBands()) do {
final double value = it.getSampleDouble();
assertBetween("Sample value", minimum, maximum, value);
} while (!it.nextBandDone());
it.startBands();
} while (!it.nextPixelDone());
it.startPixels();
} while (!it.nextLineDone());
}
代码示例来源:origin: Geomatys/geotoolkit
final RectIter e = RectIterFactory.create(expected, null);
final RectIter a = RectIterFactory.create(actual, null);
if (!e.finishedLines()) do {
assertFalse(a.finishedLines());
if (!e.finishedPixels()) do {
assertFalse(a.finishedPixels());
e.startPixels();
} while (!e.nextLineDone());
assertTrue(a.finishedLines());
代码示例来源:origin: mapplus/spatial_statistics_for_geotools_udig
public GridCoverage2D execute(GridCoverage2D inputGc, double[] fuzzyValues) {
DiskMemImage outputImage = this.createDiskMemImage(inputGc, RasterPixelType.FLOAT);
PlanarImage inputImage = (PlanarImage) inputGc.getRenderedImage();
final double inputNoData = RasterHelper.getNoDataValue(inputGc);
this.NoData = RasterHelper.getDefaultNoDataValue(PixelType);
RectIter inputIter = RectIterFactory.create(inputImage, inputImage.getBounds());
WritableRectIter writerIter = RectIterFactory.createWritable(outputImage,
outputImage.getBounds());
inputIter.startLines();
writerIter.startLines();
while (!inputIter.finishedLines() && !writerIter.finishedLines()) {
inputIter.startPixels();
writerIter.startPixels();
while (!inputIter.finishedPixels() && !writerIter.finishedPixels()) {
final double inputVal = inputIter.getSampleDouble(0);
if (SSUtils.compareDouble(inputNoData, inputVal)) {
writerIter.setSample(0, NoData);
} else {
double fuzzyValue = getFuzzyValue(inputVal, fuzzyValues) * maxRange;
writerIter.setSample(0, fuzzyValue);
updateStatistics(inputVal);
}
inputIter.nextPixel();
writerIter.nextPixel();
}
inputIter.nextLine();
writerIter.nextLine();
}
return createGridCoverage("Fuzzy", outputImage);
}
代码示例来源:origin: mapplus/spatial_statistics_for_geotools_udig
inputIter.startLines();
writerIter.startLines();
while (!inputIter.finishedLines() && !writerIter.finishedLines()) {
int column = inputBounds.x;
inputIter.startPixels();
内容来源于网络,如有侵权,请联系作者删除!