Click or drag to resize

Object3DManagerGetPartialNode Method

부분적인 정보(노드 인덱스, 이름, 유형-어셈블리,파트,바디)만 채워진 노드 반환

Namespace:  VIZCore3D.NET.Manager
Assembly:  VIZCore3D.NET (in VIZCore3D.NET.dll) Version: 2.8.24.1104 (2.8.24.1104)
Syntax
C#
public List<Node> GetPartialNode(
	bool assembly,
	bool part,
	bool body
)

Parameters

assembly
Type: SystemBoolean
어셈블리 노드 포함
part
Type: SystemBoolean
파트 노드 포함
body
Type: SystemBoolean
바디 노드 포함

Return Value

Type: ListNode
노드 목록
Examples
C#
// VIZCore3D.NET Control
private VIZCore3D.NET.VIZCore3DControl vizcore3d;

private void Example()
{
    // 어셈블리 노드 목록
    List<VIZCore3D.NET.Data.Node> items = vizcore3d.Object3D.GetPartialNode(true, false, false);

    List<VIZCore3D.NET.Data.Node> result = new List<VIZCore3D.NET.Data.Node>();

    // 필터링
    foreach (VIZCore3D.NET.Data.Node item in items)
    {
        string[] vals = item.SplitNodeName("/");
        if (vals.Length != 4) continue;

        result.Add(item);
    }

    // 노드의 부가정보 채우기 : Index 및 Node Name만 필요한 경우, 호출 불필요.
    result = vizcore3d.Object3D.FillNodeData(result);
}

private void CheckPerformance()
{
    System.Text.StringBuilder sb = new System.Text.StringBuilder();

    sb.AppendLine(string.Format("NODE COUNT : {0:#,0} EA", vizcore3d.Object3D.GetNodeCount()));
    sb.AppendLine();

    System.Diagnostics.Stopwatch sw = new System.Diagnostics.Stopwatch();

    sw.Start();
    List<VIZCore3D.NET.Data.Node> allSync = vizcore3d.Object3D.FromFilter(Data.Object3dFilter.ALL);
    sw.Stop();
    sb.AppendLine(string.Format("SYNC. ALL : {0:#,0} milliseconds", sw.ElapsedMilliseconds));

    sw.Restart();
    List<VIZCore3D.NET.Data.Node> allAssemblySync = vizcore3d.Object3D.FromFilter(Data.Object3dFilter.ASSEMBLY);
    sw.Stop();
    sb.AppendLine(string.Format("SYNC. ASSEMBLY : {0:#,0} milliseconds", sw.ElapsedMilliseconds));

    sw.Restart();
    List<VIZCore3D.NET.Data.Node> allPartSync = vizcore3d.Object3D.FromFilter(Data.Object3dFilter.PART);
    sw.Stop();
    sb.AppendLine(string.Format("SYNC. PART : {0:#,0} milliseconds", sw.ElapsedMilliseconds));
    sb.AppendLine();

    sw.Restart();
    List<VIZCore3D.NET.Data.Node> allAsync = vizcore3d.Object3D.GetPartialNode(true, true, true);
    sw.Stop();
    sb.AppendLine(string.Format("ASYNC. ALL : {0:#,0} milliseconds", sw.ElapsedMilliseconds));

    sw.Restart();
    List<VIZCore3D.NET.Data.Node> allAssyPartAsync = vizcore3d.Object3D.GetPartialNode(true, true, false);
    sw.Stop();
    sb.AppendLine(string.Format("ASYNC. ASSEMBLY + PART : {0:#,0} milliseconds", sw.ElapsedMilliseconds));

    sw.Restart();
    List<VIZCore3D.NET.Data.Node> allAssemblyAsync = vizcore3d.Object3D.GetPartialNode(true, false, false);
    sw.Stop();
    sb.AppendLine(string.Format("ASYNC. ASSEMBLY : {0:#,0} milliseconds", sw.ElapsedMilliseconds));

    sw.Restart();
    List<VIZCore3D.NET.Data.Node> allPartAsync = vizcore3d.Object3D.GetPartialNode(false, true, false);
    sw.Stop();
    sb.AppendLine(string.Format("ASYNC. PART : {0:#,0} milliseconds", sw.ElapsedMilliseconds));

    sw.Restart();
    List<VIZCore3D.NET.Data.Node> allBodyAsync = vizcore3d.Object3D.GetPartialNode(false, false, true);
    sw.Stop();
    sb.AppendLine(string.Format("ASYNC. BODY : {0:#,0} milliseconds", sw.ElapsedMilliseconds));

    MessageBox.Show(sb.ToString());
}
See Also