◆
~PolygonReduction()
成员函数文档编制
◆
Alloc()
Allocates a
PolygonReduction
. Destroy the allocated
PolygonReduction
with
Free()
。使用
AutoAlloc
to automate the allocation and destruction based on scope.
-
返回
-
The allocated
PolygonReduction
,或
nullptr
if the allocation failed.
◆
Free()
Destructs PolygonReductions allocated with
Alloc()
。使用
AutoAlloc
to automate the allocation and destruction based on scope.
-
参数
-
[in]
|
node
|
The
PolygonReduction
to destruct. If the pointer is
nullptr
nothing happens. The pointer is assigned
nullptr
afterwards.
|
◆
PreProcess()
Starts the background or synchronous preprocessing that sets up the polygon reduction cache.
-
参数
-
[in]
|
data
|
The data for the reduction.
|
-
返回
-
true
if successful, otherwise
false
.
◆
IsPreprocessing()
Checks whether the background preprocessing thread is still running.
-
返回
-
true
if preprocessing is ongoing, otherwise
false
.
◆
StopPreprocessing()
void StopPreprocessing
|
(
|
|
)
|
|
Aborts preprocessing if it is running in the background. Resets the interactive settings values.
◆
Reset()
Aborts preprocessing if it is running in the background and frees all temporary data.
◆
SetReductionStrengthLevel()
Bool
SetReductionStrengthLevel
|
(
|
Float
|
strengthLevel
|
)
|
|
Sets the reduction strength level if the desired level is different than the current one.
-
参数
-
[in]
|
strengthLevel
|
The desired reduction strength level.
|
-
返回
-
true
if successful, otherwise
false
.
◆
SetTriangleLevel()
Reduces or restores the mesh to the desired number of triangles.
-
注意
-
If the desired level is different than the current level, at least one edge collapse or restore will be performed. The actual resulting number of triangles may be slightly different.
-
参数
-
[in]
|
desiredLevel
|
The desired number of triangles on call.
|
-
返回
-
true
if successful, otherwise
false
.
◆
SetVertexLevel()
Reduces or restores the mesh to the desired number of vertices.
-
注意
-
If the desired level is different than the current level, at least one edge collapse or restore will be performed. The actual resulting number of vertices may be slightly different.
-
参数
-
[in]
|
desiredLevel
|
The desired number of vertices on call.
|
-
返回
-
true
if successful, otherwise
false
.
◆
SetRemainingEdgesLevel()
Bool
SetRemainingEdgesLevel
|
(
|
Int32
|
desiredLevel
|
)
|
|
Reduces or restores the mesh to the desired number of edges remaining to collapse.
-
注意
-
If the desired level is different than the current level, at least one edge collapse or restore will be performed. The actual resulting number of edges may be slightly different.
-
参数
-
[in]
|
desiredLevel
|
The desired collapse stack index.
|
-
返回
-
true
if successful, otherwise
false
.
◆
GetReductionStrengthLevel()
Float
GetReductionStrengthLevel
|
(
|
|
)
|
const
|
Queries the current reduction strength level.
-
返回
-
The reduction strength percentage:
0
means no reduction performed,
1
means maximum reduction performed.
◆
GetTriangleLevel()
Int32
GetTriangleLevel
|
(
|
|
)
|
const
|
Queries the current triangle count.
-
返回
-
The triangle count.
◆
GetVertexLevel()
Int32
GetVertexLevel
|
(
|
|
)
|
const
|
Queries the current vertex count.
-
返回
-
The vertex count.
◆
GetRemainingEdgesLevel()
Int32
GetRemainingEdgesLevel
|
(
|
|
)
|
const
|
Queries the current remaining number of edges available to collapse.
-
返回
-
The remaining edges level.
◆
GetMaxReductionStrengthLevel()
Float
GetMaxReductionStrengthLevel
|
(
|
|
)
|
const
|
Queries the maximum reduction strength percentage.
-
返回
-
The maximum reduction strength percentage. Always
1.0
.
◆
GetMaxTriangleLevel()
Int32
GetMaxTriangleLevel
|
(
|
|
)
|
const
|
Queries the triangle count when no reduction has been performed.
-
返回
-
The maximum triangle count.
◆
GetMaxVertexLevel()
Int32
GetMaxVertexLevel
|
(
|
|
)
|
const
|
Queries the vertex count when no reduction has been performed.
-
返回
-
The maximum vertex count.
◆
GetMaxRemainingEdgesLevel()
Int32
GetMaxRemainingEdgesLevel
|
(
|
|
)
|
const
|
Queries the total number of possible edge collapses.
-
返回
-
The maximum collapse count.
◆
GetMinTriangleLevel()
Int32
GetMinTriangleLevel
|
(
|
|
)
|
const
|
Queries the triangle count when complete reduction has been performed.
-
返回
-
The minimum triangle count. May be non-zero if border constraints are enabled.
◆
GetMinVertexLevel()
Int32
GetMinVertexLevel
|
(
|
|
)
|
const
|
Queries the vertex count when complete reduction has been performed.
-
返回
-
The minimum vertex count. May be non-zero if border constraints are enabled.
◆
GetData()
Retrieves the associated
PolygonReductionData
.
-
返回
-
The polygon reduction data.
◆
IsValid()
Checks if a valid object and a valid document are associated with the
PolygonReduction
instance.
-
返回
-
true
若
PolygonReduction
instance is valid, otherwise
false
.