congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
Shapes2D.transform
Code IndexAdd Tabnine to your IDE (free)

How to use
transform
method
in
org.apache.sis.geometry.Shapes2D

Best Java code snippets using org.apache.sis.geometry.Shapes2D.transform (Showing top 11 results out of 315)

origin: apache/sis

/**
 * Transforms a rectangle using the given math transform.
 * This transformation can not handle poles.
 */
@Override
Rectangle2D transform(CoordinateReferenceSystem targetCRS, MathTransform2D transform, Rectangle2D envelope) throws TransformException {
  return Shapes2D.transform(transform, envelope, null);
}
origin: apache/sis

/**
 * Transforms a rectangle using the given operation.
 * This transformation can handle poles.
 */
@Override
Rectangle2D transform(CoordinateOperation operation, Rectangle2D envelope) throws TransformException {
  return Shapes2D.transform(operation, envelope, null);
}
origin: Geomatys/geotoolkit

/**
 * Returns a high precision and more accurate bounding box of the shape than the
 * {@link #getBounds} method. This method returns an infinite rectangle if some
 * points can not be transformed.
 */
@Override
public Rectangle2D getBounds2D() {
  try {
    return Shapes2D.transform(projection, shape.getBounds2D(), null);
  } catch (TransformException exception) {
    Logging.recoverableException(null, ProjectedShape.class, "getBounds2D", exception);
    return XRectangle2D.INFINITY;
  }
}
origin: org.apache.sis.core/sis-referencing

return transform(transform, envelope, destination, new double[2]);
origin: apache/sis

return transform(transform, envelope, destination, new double[2]);
origin: Geomatys/geotoolkit

/**
 * Tests if the interior of this shape intersects the interior of a specified rectangle.
 * This method might conservatively return {@code true} if some points can not be transformed.
 *
 * @param  r The rectangle to be tested.
 * @return {@code true} if this shape intersects the given rectangle.
 */
@Override
public boolean intersects(final Rectangle2D r) {
  try {
    return shape.intersects(Shapes2D.transform(inverse(), r, rectangle));
  } catch (TransformException exception) {
    Logging.recoverableException(null, ProjectedShape.class, "intersects", exception);
    return true; // Consistent with the Shape interface contract.
  }
}
origin: Geomatys/geotoolkit

/**
 * Tests if the interior of this shape entirely contains the specified rectangle.
 * This method might conservatively return {@code false} if some points can not
 * be transformed.
 *
 * @param  r The rectangle to be tested.
 * @return {@code true} if this shape contains the given rectangle.
 */
@Override
public boolean contains(final Rectangle2D r) {
  try {
    return shape.contains(Shapes2D.transform(inverse(), r, rectangle));
  } catch (TransformException exception) {
    Logging.recoverableException(null, ProjectedShape.class, "contains", exception);
    return false; // Consistent with the Shape interface contract.
  }
}
origin: apache/sis

  r.setRect(Shapes2D.transform(CRS.findOperation(geographicArea.getCoordinateReferenceSystem(), sourceCRS, null), r, r));
  r.intersect(areaOfInterest);
final Rectangle2D bounds = Shapes2D.transform(op, areaOfInterest, null);
gridX = (((int)          (bounds.getMinX() / step))) * step;                    // Inclusive
gridY = (((int)          (bounds.getMinY() / step))) * step;
origin: apache/sis

cell.setRect(Shapes2D.transform(gridToAOI, cell, cell));
if (cell.intersects(areaOfInterest)) {          // Must be invoked on Envelope2D implementation.
  int x = gridX;
origin: apache/sis

destination = transform(mt, envelope, destination, center);
origin: org.apache.sis.core/sis-referencing

destination = transform(mt, envelope, destination, center);
org.apache.sis.geometryShapes2Dtransform

Javadoc

Transforms a rectangular envelope using the given coordinate operation. The transformation is only approximated: the returned envelope may be bigger than the smallest possible bounding box, but should not be smaller in most cases.

This method can handle the case where the rectangle contains the North or South pole, or when it cross the ±180° longitude.

Popular methods of Shapes2D

    Popular in Java

    • Finding current android device location
    • orElseThrow (Optional)
      Return the contained value, if present, otherwise throw an exception to be created by the provided s
    • scheduleAtFixedRate (ScheduledExecutorService)
    • onRequestPermissionsResult (Fragment)
    • FlowLayout (java.awt)
      A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
    • Rectangle (java.awt)
      A Rectangle specifies an area in a coordinate space that is enclosed by the Rectangle object's top-
    • File (java.io)
      An "abstract" representation of a file system entity identified by a pathname. The pathname may be a
    • FileWriter (java.io)
      A specialized Writer that writes to a file in the file system. All write requests made by calling me
    • OutputStream (java.io)
      A writable sink for bytes.Most clients will use output streams that write data to the file system (
    • ExecutorService (java.util.concurrent)
      An Executor that provides methods to manage termination and methods that can produce a Future for tr
    • PhpStorm for WordPress
    Tabnine Logo
    • Products

      Search for Java codeSearch for JavaScript code
    • IDE Plugins

      IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
    • Company

      About UsContact UsCareers
    • Resources

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