SelectionChanger Class Reference Library » Selection Changer

#include <lib_selectionchanger.h>

详细描述

Convenience class for changing a selection type i.e. polygon selection to edge selection. The class owns all returned selections. Must be initialized before use.

注意
Has to be created with Alloc() and destroyed with Free() 。使用 AutoAlloc to automate the allocation and destruction based on scope.

私有成员函数

  SelectionChanger ()
  ~SelectionChanger ()

Alloc/Free

static SelectionChanger Alloc (void)
static void  Free ( SelectionChanger *&node)

Init

Bool   InitFromTag ( BaseTag *targtag, PolygonObject *op=nullptr)
Bool   InitFromSelection ( BaseSelect *selection, Int32 selection_mode, PolygonObject *op=nullptr)

Get Conversion

BaseSelect GetPointS (void)
BaseSelect GetPolygonS (void)
BaseSelect GetEdgeS (void)

构造函数 & 析构函数文档编制

◆  SelectionChanger()

SelectionChanger () private

◆  ~SelectionChanger()

~ SelectionChanger () private

成员函数文档编制

◆  Alloc()

static SelectionChanger * Alloc ( void  )
static

Allocates a selection changer. Destroy the allocated selection changer with Free() 。使用 AutoAlloc to automate the allocation and destruction based on scope.

返回
The allocated selection changer, or nullptr if the allocation failed.

◆  Free()

static void Free ( SelectionChanger *&  node )
static

Destructs selection changers allocated with Alloc() 。使用 AutoAlloc to automate the allocation and destruction based on scope.

参数
[in,out] node The selection changer to destruct. If the pointer is nullptr nothing happens. The pointer is assigned nullptr afterwards.

◆  InitFromTag()

Bool InitFromTag ( BaseTag targtag ,
PolygonObject op = nullptr  
)

Initializes the selection changer from a selection tag.

参数
[in] targtag The selection tag used for input. The caller owns the pointed tag.
[in] op The object the tag is on. Generally required for most transformations to take place. The caller owns the pointed object.
返回
true if successful, otherwise false .

◆  InitFromSelection()

Bool InitFromSelection ( BaseSelect selection ,
Int32   selection_mode ,
PolygonObject op = nullptr  
)

Initializes the selection changer from a selection object and a specific selection mode.

参数
[in] selection The selection used for input.
[in] selection_mode The mode of the selection: Mpoints or Mpolygons or Medges .
[in] op The object the tag is on. Generally required if the selection is on a polygon object (but not on a spline object).
返回
true if successful, otherwise false .

◆  GetPointS()

BaseSelect * GetPointS ( void  )

Retrieves the converted selection in points mode.

返回
The converted selection. The selection changer owns the pointed selection.

◆  GetPolygonS()

BaseSelect * GetPolygonS ( void  )

Retrieves the converted selection in polygon mode.

返回
The converted selection. The selection changer owns the pointed selection.

◆  GetEdgeS()

BaseSelect * GetEdgeS ( void  )

Retrieves the converted selection in edge mode.

返回
The converted selection. The selection changer owns the pointed selection.