public void rotate(double angle, int axis) {
		if (axis != X_AXIS && axis != Y_AXIS && axis != Z_AXIS)
			return;
		
		double cosAngle = Math.cos(angle);
		double sinAngle = Math.sin(angle);
		
		double xNew, yNew, zNew;
		
		switch (axis) {
		case X_AXIS:
			yNew = y * cosAngle + z * sinAngle;
			zNew = -y * sinAngle + z * cosAngle;
			y = yNew;
			z = zNew;
			break;
			
		case Y_AXIS:
			zNew = z * cosAngle + x * sinAngle;
			xNew = -z * sinAngle + x * cosAngle;
			z = zNew;
			x = xNew;
			break;
			
		case Z_AXIS:
			xNew = x * cosAngle + y * sinAngle;
			yNew = -x * sinAngle + y * cosAngle;
			x = xNew;
			y = yNew;
			break;
		}
	}