Codota Logo
PixelInterleavedRasterData.getColumns
Code IndexAdd Codota to your IDE (free)

How to use
getColumns
method
in
org.deegree.coverage.raster.data.nio.PixelInterleavedRasterData

Best Java code snippets using org.deegree.coverage.raster.data.nio.PixelInterleavedRasterData.getColumns (Showing top 3 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
OutputStreamWriter o =
  • Codota IconOutputStream out;new OutputStreamWriter(out)
  • Codota IconOutputStream out;String charsetName;new OutputStreamWriter(out, charsetName)
  • Codota IconHttpURLConnection connection;new OutputStreamWriter(connection.getOutputStream())
  • Smart code suggestions by Codota
}
origin: deegree/deegree3

private TextureTile getTextureTile( double minX, double minY, double maxX, double maxY ) {
  int width = (int) ( ( maxX - minX ) / res );
  int height = (int) ( ( maxY - minY ) / res );
  LOG.debug( "Fetching texture tile (" + width + "x" + height + ") via WMSClient." );
  Envelope bbox = fac.createEnvelope( minX, minY, maxX, maxY, requestedCRS );
  SimpleRaster raster = null;
  try {
    raster = getMapAsSimpleRaster( client, layers, width, height, bbox, requestedCRS, requestedFormat, true,
                    true, requestTimeout ).first;
    LOG.debug( "Success" );
  } catch ( IOException e ) {
    LOG.debug( "Failed: " + e.getMessage(), e );
    // this must never happen, cause the above request uses errorsInImage=true
    throw new RuntimeException( e.getMessage() );
  }
  PixelInterleavedRasterData rasterData = (PixelInterleavedRasterData) raster.getRasterData();
  return new TextureTile( minX, minY, maxX, maxY, rasterData.getColumns(), rasterData.getRows(),
              rasterData.getByteBuffer(), true, true );
}
origin: deegree/deegree3

int effectiveCols = raster.getColumns();
int effectiveRows = raster.getRows();
int subWidth = clampSize( getColumns(), dstX, effectiveCols, 0, width );
int subHeight = clampSize( getRows(), dstY, effectiveRows, 0, height );
origin: deegree/deegree3

private void setSubset( PixelInterleavedRasterData targetData, int x0, int y0, int width, int height,
            RasterData sourceRaster ) {
  // clamp to maximum possible size
  int subWidth = min( targetData.getColumns() - x0, width, sourceRaster.getColumns() );
  int subHeight = min( targetData.getRows() - y0, height, sourceRaster.getRows() );
  byte[] tmp = new byte[targetData.getDataInfo().getDataSize()];
  for ( int y = 0; y < subHeight; y++ ) {
    for ( int x = 0; x < subWidth; x++ ) {
      byte[] color = new byte[3];
      byte[] c = new byte[1];
      c = sourceRaster.getSample( x, y, 0, c );
      color[0] = c[0];
      c = sourceRaster.getSample( x, y, 1, c );
      color[1] = c[0];
      c = sourceRaster.getSample( x, y, 2, c );
      color[2] = c[0];
      if ( !shouldBeTransparent( color ) ) {
        targetData.setSample( x0 + x, y0 + y, 0, sourceRaster.getSample( x, y, 0, tmp ) );
        targetData.setSample( x0 + x, y0 + y, 1, sourceRaster.getSample( x, y, 1, tmp ) );
        targetData.setSample( x0 + x, y0 + y, 2, sourceRaster.getSample( x, y, 2, tmp ) );
      }
    }
  }
}
org.deegree.coverage.raster.data.nioPixelInterleavedRasterDatagetColumns

Popular methods of PixelInterleavedRasterData

  • getRows
  • getByteBuffer
  • <init>
    Creates a new PixelInterleavedRasterData with given size, number of bands and data type
  • calculatePos
  • clampSize
  • createRasterDataInfo
  • getDataInfo
  • getDataRect
  • getOriginalHeight
  • getOriginalWidth
  • getPixelStride
  • getView
  • getPixelStride,
  • getView,
  • isOutside,
  • isWithinDataArea,
  • setSample

Popular in Java

  • Creating JSON documents from java classes using gson
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • getResourceAsStream (ClassLoader)
    Returns a stream for the resource with the specified name. See #getResource(String) for a descriptio
  • onRequestPermissionsResult (Fragment)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • Point (java.awt)
    A point representing a location in (x, y) coordinate space, specified in integer precision.
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • Scanner (java.util)
    A parser that parses a text string of primitive types and strings with the help of regular expressio
  • TreeSet (java.util)
    A NavigableSet implementation based on a TreeMap. The elements are ordered using their Comparable, o
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now