MGCL V10  V10
MGCL V10
 全て クラス 名前空間 関数 変数 型定義 列挙型 列挙値 フレンド グループ ページ
MGSnapAttrib クラス

Defines Snap attributes. [詳解]

公開型

enum  {
  BIT_END =0, BIT_KNOT =1, BIT_NEAR =2, BIT_VERTEX =3,
  BIT_CENTER =4, BIT_GRID =5, BIT_ORTHO =6
}
 

公開メンバ関数

 MGSnapAttrib ()
 
 MGSnapAttrib (float apx, float apy, bool bEnd=false, bool bKnot=false, bool bNear=false, bool bVertex=false, bool bCenter=false, bool bGrid=false, bool bOrtho=false)
 
 MGSnapAttrib (float apx, float apy, const std::bitset< 32 > &bits)
 
const float * getSnapAperture () const
 virtual ~MGSnapAttrib(); [詳解]
 
void setSnapAperture (const float Aperture[2])
 
void setSnapAperture (double x, double y)
 
bool getEnd () const
 
void setEnd (bool bEnd)
 
bool getKnot () const
 
void setKnot (bool bKnot)
 
bool getNear () const
 
void setNear (bool bNear)
 
bool getVertex () const
 
void setVertex (bool bVertex)
 
bool getCenter () const
 
void setCenter (bool bCenter)
 
bool getGrid () const
 
void setGrid (bool bGrid)
 
bool getOrtho () const
 
void setOrtho (bool bOrtho)
 
bool any () const
 Test if any of the attributes are set on. If on, return true. [詳解]
 
bool none () const
 Test if none of the attributes is set on. If none is on, return true. [詳解]
 
int count () const
 Get the number of attributes that are on. [詳解]
 
void clear_attrib ()
 clear all the attrib to false; [詳解]
 

フレンド

MG_DLL_DECLR friend std::ostream & operator<< (std::ostream &ostrm, const MGSnapAttrib &atr)
 Text output to stream. [詳解]
 
MG_DLL_DECLR friend MGOfstreamoperator<< (MGOfstream &buf, const MGSnapAttrib &atr)
 Serialization. [詳解]
 
MG_DLL_DECLR friend MGIfstreamoperator>> (MGIfstream &buf, MGSnapAttrib &atr)
 

詳解

Defines Snap attributes.

Snap means snap to designated location when inputting positional data from Cursor(generally mouse position). Currently MGCL supports the following enum's snap kind.

列挙型メンバ詳解

anonymous enum
列挙値
BIT_END 
BIT_KNOT 
BIT_NEAR 
BIT_VERTEX 
BIT_CENTER 
BIT_GRID 
BIT_ORTHO 

構築子と解体子

MGSnapAttrib::MGSnapAttrib ( )
MGSnapAttrib::MGSnapAttrib ( float  apx,
float  apy,
bool  bEnd = false,
bool  bKnot = false,
bool  bNear = false,
bool  bVertex = false,
bool  bCenter = false,
bool  bGrid = false,
bool  bOrtho = false 
)
MGSnapAttrib::MGSnapAttrib ( float  apx,
float  apy,
const std::bitset< 32 > &  bits 
)

関数詳解

bool MGSnapAttrib::any ( ) const
inline

Test if any of the attributes are set on. If on, return true.

void MGSnapAttrib::clear_attrib ( )
inline

clear all the attrib to false;

int MGSnapAttrib::count ( ) const
inline

Get the number of attributes that are on.

bool MGSnapAttrib::getCenter ( ) const
inline
bool MGSnapAttrib::getEnd ( ) const
inline
bool MGSnapAttrib::getGrid ( ) const
inline
bool MGSnapAttrib::getKnot ( ) const
inline
bool MGSnapAttrib::getNear ( ) const
inline
bool MGSnapAttrib::getOrtho ( ) const
inline
const float* MGSnapAttrib::getSnapAperture ( ) const
inline

virtual ~MGSnapAttrib();

Attribute reference

bool MGSnapAttrib::getVertex ( ) const
inline
bool MGSnapAttrib::none ( ) const
inline

Test if none of the attributes is set on. If none is on, return true.

void MGSnapAttrib::setCenter ( bool  bCenter)
inline
void MGSnapAttrib::setEnd ( bool  bEnd)
inline
void MGSnapAttrib::setGrid ( bool  bGrid)
inline
void MGSnapAttrib::setKnot ( bool  bKnot)
inline
void MGSnapAttrib::setNear ( bool  bNear)
inline
void MGSnapAttrib::setOrtho ( bool  bOrtho)
inline
void MGSnapAttrib::setSnapAperture ( const float  Aperture[2])
inline
void MGSnapAttrib::setSnapAperture ( double  x,
double  y 
)
inline
void MGSnapAttrib::setVertex ( bool  bVertex)
inline

フレンドと関連関数の詳解

MG_DLL_DECLR friend std::ostream& operator<< ( std::ostream &  ostrm,
const MGSnapAttrib atr 
)
friend

Text output to stream.

MG_DLL_DECLR friend MGOfstream& operator<< ( MGOfstream buf,
const MGSnapAttrib atr 
)
friend

Serialization.

MG_DLL_DECLR friend MGIfstream& operator>> ( MGIfstream buf,
MGSnapAttrib atr 
)
friend

このクラス詳解は次のファイルから抽出されました: