|
Blender
V2.59
|
00001 /* 00002 * $Id: MT_Plane3.h 35158 2011-02-25 11:49:19Z jesterking $ 00003 * ***** BEGIN GPL LICENSE BLOCK ***** 00004 * 00005 * This program is free software; you can redistribute it and/or 00006 * modify it under the terms of the GNU General Public License 00007 * as published by the Free Software Foundation; either version 2 00008 * of the License, or (at your option) any later version. 00009 * 00010 * This program is distributed in the hope that it will be useful, 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 * GNU General Public License for more details. 00014 * 00015 * You should have received a copy of the GNU General Public License 00016 * along with this program; if not, write to the Free Software Foundation, 00017 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 00018 * 00019 * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV. 00020 * All rights reserved. 00021 * 00022 * The Original Code is: all of this file. 00023 * 00024 * Contributor(s): none yet. 00025 * 00026 * ***** END GPL LICENSE BLOCK ***** 00027 */ 00028 00034 #ifndef MT_PLANE3 00035 #define MT_PLANE3 00036 00037 #include "MT_Tuple4.h" 00038 #include "MT_Point3.h" 00039 00051 class MT_Plane3 : public MT_Tuple4 00052 { 00053 public : 00058 MT_Plane3( 00059 const MT_Vector3 &a, 00060 const MT_Vector3 &b, 00061 const MT_Vector3 &c 00062 ); 00067 MT_Plane3( 00068 const MT_Vector3 &n, 00069 const MT_Vector3 &p 00070 ); 00071 00075 MT_Plane3( 00076 ); 00077 00082 MT_Plane3( 00083 const MT_Plane3 & p 00084 ): 00085 MT_Tuple4(p) 00086 { 00087 } 00088 00093 MT_Vector3 00094 Normal( 00095 ) const; 00096 00101 MT_Scalar 00102 Scalar( 00103 ) const ; 00104 00108 void 00109 Invert( 00110 ); 00111 00116 MT_Plane3 & 00117 operator = ( 00118 const MT_Plane3 & rhs 00119 ); 00120 00125 MT_Scalar 00126 signedDistance( 00127 const MT_Vector3 & 00128 ) const; 00129 00130 00131 }; 00132 00133 #ifdef GEN_INLINED 00134 #include "MT_Plane3.inl" 00135 #endif 00136 00137 #endif 00138