00001 package edu.tum.cs.vis.model.util; 00002 00003 import javax.vecmath.Point3f; 00004 00005 import processing.core.PApplet; 00006 00013 public class Line extends DrawObject { 00014 00018 public Appearance appearance; 00019 00023 public Line() { 00024 position = new Point3f[2]; 00025 } 00026 00033 public void draw(PApplet applet) { 00034 applet.stroke(appearance.colour.red * 255, 00035 appearance.colour.green * 255, appearance.colour.blue * 255); 00036 applet.strokeWeight(2); 00037 applet.line(position[0].x, position[0].y, position[0].z, position[1].x, 00038 position[1].y, position[1].z); 00039 } 00040 }