Class PoRectangle

All Implemented Interfaces:
SafeDisposable

public class PoRectangle extends PoGraphMaster
Class for a 2D rectangle. Class to build a rectangle in the plane XY. A rectangle is defined by two points, p and q, representing one of its diagonals.

File format/default:

PoRectangle {

    p 0 0
    q 1 1
}

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> <html> <head> <link REL="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style"> <title></title> </head> <BODY> <h1></h1> <h4> <A NAME="Heading249">CATALOG PARTS</A></h4> <ul><b>PoRectangle</b> {</ul> <ul><ul><b>Separator</b> <tt>alternateRep</tt> (from PoBase) {<br> </ul></ul> <ul><ul><ul><b>AppearanceKit</b> <tt>appearance</tt> (from PoBase)</ul></ul></ul> <ul><ul><ul><i>Specifies the appearance of all the kit. By default lightModel.model=BASE_COLOR.</i></ul></ul></ul> <ul><ul><ul><b>MatrixTransform</b> <tt>domainTransform</tt> (from PoBase)</ul></ul></ul> <ul><ul><ul><i>Corresponds to the domain transformation.</i></ul></ul></ul> <ul><ul><ul><ul></ul></ul></ul></ul> <ul><ul><ul><b>Group</b> <tt>rectangle</tt></ul></ul></ul> <ul><ul><ul><i>Contains a SoFaceSet shape to draw the rectangle.</i></ul></ul></ul> <ul><ul>}</ul></ul> <ul>}<br> <br> </ul> </body> </html>

  • Field Details

    • p

      public final SoSFVec2f p
      First point of one of the diagonals of the rectangle.
    • q

      public final SoSFVec2f q
      Second point of the same diagonal.
  • Constructor Details

    • PoRectangle

      public PoRectangle(SbVec2f p1, SbVec2f p2)
      Constructor.
    • PoRectangle

      public PoRectangle()
      Default constructor.
  • Method Details