Ejemplo n.º 1
0
  /**
   * Draws the graphic as an ordered renderable.
   *
   * @param dc the current draw context.
   */
  protected void makeOrderedRenderable(DrawContext dc) {
    if (this.lines == null || this.position == null) return;

    this.computeGeometryIfNeeded(dc);

    // Don't draw if beyond the horizon.
    double horizon = dc.getView().getHorizonDistance();
    if (this.eyeDistance > horizon) return;

    if (this.intersectsFrustum(dc)) dc.addOrderedRenderable(this);

    if (dc.isPickingMode()) this.pickLayer = dc.getCurrentLayer();
  }