/** * Determine the y source pixel location * * @param y * y pixel * @param destTop * destination top most pixel * @param srcTop * source top most pixel * @param heightRatio * source over destination height ratio * @return y source pixel */ protected float getYSource(int y, float destTop, float srcTop, float heightRatio) { float dest = getYEncodedLocation(y, encoding); float source = getSource(dest, destTop, srcTop, heightRatio); return source; }
/** * Get the min, max, and offset of the source Y pixel * * @param source * source y pixel * @return source y pixel information */ protected CoverageDataSourcePixel getYSourceMinAndMax(float source) { int floor = (int) Math.floor(source); float valueLocation = getYEncodedLocation(floor, griddedCoverage.getGridCellEncodingType()); CoverageDataSourcePixel pixel = getSourceMinAndMax(source, floor, valueLocation); return pixel; }