MGCL V10  V10
MGCL V10
 全て クラス 名前空間 関数 変数 型定義 列挙型 列挙値 フレンド グループ ページ
FPoint.h
1 /********************************************************************/
2 /* Copyright (c) 2015 DG Technologies Inc. and Yuzi Mizuno */
3 /* All rights reserved. */
4 /********************************************************************/
5 #ifndef _MGFPoint_HH_
6 #define _MGFPoint_HH_
7 
8 #include "mg/Position.h"
9 class MGFSurface;
15 
20 class MG_DLL_DECLR MGFPoint{
21 
22 public:
23 
25 MG_DLL_DECLR friend std::ostream& operator<< (std::ostream&, const MGFPoint& );
26 
28 MGFPoint():m_face(0){;};
29 
32  const MGFSurface& face,
33  const MGPosition& uv
34  ):m_face(&face), m_uv(uv){;};
35 
37 
42 bool operator< (const MGFPoint& fp)const;
43 bool operator> (const MGFPoint& fp)const{return fp<(*this);};
44 bool operator<= (const MGFPoint& fp)const{return !(fp<(*this));};
45 bool operator>= (const MGFPoint& fp)const{return !((*this)<fp);};
46 
49 bool operator== (const MGFPoint& fp)const;
50 bool operator!= (const MGFPoint& fp)const{return !operator==(fp);};
51 
53 
56 MGVector eval(int ndu=0, int ndv=0)const;
57 
59 const MGFSurface& fsurface()const{return *m_face;};
60 
62 const MGPosition& uv()const{return m_uv;};
63 
64 private:
65  const MGFSurface* m_face;
66  MGPosition m_uv;
67 
68 };
69 
71 
73 MG_DLL_DECLR MGVector eval(
74  const MGFPoint& uv,
75  int ndu=0, int ndv=0
76 );
77 
79 MG_DLL_DECLR MGVector normal(const MGFPoint& uv);
80 
82 MG_DLL_DECLR MGUnit_vector unit_normal(const MGFPoint& uv);
83  // end of GEORelated group
85 
86 #endif
std::ostream & operator<<(std::ostream &ostrm, const MGisect &is)
Debug Function.
Definition: isect.h:95
Vector of a general n space dimension.
Definition: Vector.h:26
Represent a positional data.
Definition: Position.h:28
const MGPosition & uv() const
Return the parameter value of the face.
Definition: FPoint.h:62
const MGFSurface & fsurface() const
return the face.
Definition: FPoint.h:59
MGFPoint()
Definition: FPoint.h:28
MGFSurface is an abstract class to provide the comman interfaces to MGFace and MGSurface.
Definition: FSurface.h:33
MGFPoint is to represent a Face or Surface point.
Definition: FPoint.h:20
MGFPoint(const MGFSurface &face, const MGPosition &uv)
void constructor.
Definition: FPoint.h:31
Define a unit vector, is a MGVector.
Definition: Unit_vector.h:17