All pastes #2053862 Raw Edit

Square constructor

public text v1 · immutable
#2053862 ·published 2011-05-04 15:51 UTC
rendered paste body
public class Square:Triangle
	{
		Vector3F pointA, pointB, pointC;
		Vector3F normA, normB, normC;
		float xmin, ymin, zmin, xmax, ymax, zmax;
		Plane surfacePlane;
		Material surfaceMaterial;
		bool isLightSource;

		public Square (Vector3F pointA, Vector3F pointB, Vector3F pointC)
		{
			
			this.pointA = pointA;
			this.pointB = pointB;
			this.pointC = pointC;
			Vector3F normal = getNormal ();
			surfacePlane = new Plane (normal, pointA);
			computeBoundaries ();
		}

}