Example usage for java.awt.geom CubicCurve2D contains

List of usage examples for java.awt.geom CubicCurve2D contains

Introduction

In this page you can find the example usage for java.awt.geom CubicCurve2D contains.

Prototype

public boolean contains(double x, double y) 

Source Link

Usage

From source file:Main.java

public void paint(Graphics g) {
    Graphics2D g2d = (Graphics2D) g;

    CubicCurve2D cubcurve = new CubicCurve2D.Float(30, 400, 150, 400, 200, 500, 350, 450);
    g2d.draw(cubcurve);//  w  ww. j a  va 2 s  .  c  om

    System.out.println(cubcurve.contains(0.2F, 0.3F));
}