Class LineStroker

java.lang.Object
processing.opengl.LineStroker

public class LineStroker extends Object
  • Constructor Details

    • LineStroker

      public LineStroker()
      Empty constructor. setOutput and setParameters must be called prior to calling any other methods.
    • LineStroker

      public LineStroker(LineStroker output, int lineWidth, int capStyle, int joinStyle, int miterLimit, PMatrix2D transform)
      Constructs a LineStroker.
      Parameters:
      output - an output LineStroker.
      lineWidth - the desired line width in pixels, in S15.16 format.
      capStyle - the desired end cap style, one of CAP_BUTT, CAP_ROUND or CAP_SQUARE.
      joinStyle - the desired line join style, one of JOIN_MITER, JOIN_ROUND or JOIN_BEVEL.
      miterLimit - the desired miter limit, in S15.16 format.
      transform - a Transform4 object indicating the transform that has been previously applied to all incoming coordinates. This is required in order to produce consistently shaped end caps and joins.
  • Method Details

    • setOutput

      public void setOutput(LineStroker output)
      Sets the output LineStroker of this LineStroker.
      Parameters:
      output - an output LineStroker.
    • setParameters

      public void setParameters(int lineWidth, int capStyle, int joinStyle, int miterLimit, PMatrix2D transform)
      Sets the parameters of this LineStroker.
      Parameters:
      lineWidth - the desired line width in pixels, in S15.16 format.
      capStyle - the desired end cap style, one of CAP_BUTT, CAP_ROUND or CAP_SQUARE.
      joinStyle - the desired line join style, one of JOIN_MITER, JOIN_ROUND or JOIN_BEVEL.
      miterLimit - the desired miter limit, in S15.16 format.
      transform - a Transform4 object indicating the transform that has been previously applied to all incoming coordinates. This is required in order to produce consistently shaped end caps and joins.
    • moveTo

      public void moveTo(int x0, int y0, int c0)
    • lineJoin

      public void lineJoin()
    • lineTo

      public void lineTo(int x1, int y1, int c1)
    • close

      public void close()
    • end

      public void end()