Package org.bzdev.p3d

Class Model3D.LineSegment

java.lang.Object
org.bzdev.p3d.Model3D.LineSegment
Enclosing class:
Model3D

public class Model3D.LineSegment extends Object
Class representing a straight line segment in 3 dimensions.
  • Constructor Details

    • LineSegment

      public LineSegment(double x1, double y1, double z1, double x2, double y2, double z2)
      Constructor. The line segment is a straight line going from one point to another.
      Parameters:
      x1 - the x coordinate of point 1
      y1 - the y coordinate of point 1
      z1 - the z coordinate of point 1
      x2 - the x coordinate of point 2
      y2 - the y coordinate of point 2
      z2 - the z coordinate of point 2
    • LineSegment

      public LineSegment(double x1, double y1, double z1, double x2, double y2, double z2, Color c)
      Constructor specifying a color. The line segment is a straight line going from one point to another.
      Parameters:
      x1 - the x coordinate of point 1
      y1 - the y coordinate of point 1
      z1 - the z coordinate of point 1
      x2 - the x coordinate of point 2
      y2 - the y coordinate of point 2
      z2 - the z coordinate of point 2
      c - the line segment's color
    • LineSegment

      public LineSegment(double x1, double y1, double z1, double x2, double y2, double z2, Color c, Object tag)
      Constructor specifying a color and tag. The line segment is a straight line going from one point to another.
      Parameters:
      x1 - the x coordinate of point 1
      y1 - the y coordinate of point 1
      z1 - the z coordinate of point 1
      x2 - the x coordinate of point 2
      y2 - the y coordinate of point 2
      z2 - the z coordinate of point 2
      c - the line segment's color
      tag - a label for the line segment indicating where it was created