본문으로 건너뛰기

Add

Overloads

NameDescription
Add(Vertex3D center, Vector3D dir, Vector3D upDir, float height, Color color, string text)Draw Text
Add(Vertex3D center, Vector3D dir, Vector3D upDir, float height, float fontSize, Color color, string text)Draw Text

Add(Vertex3D center, Vector3D dir, Vector3D upDir, float height, Color color, string text)

public TextDrawingItem Add(Vertex3D center, Vector3D dir, Vector3D upDir, float height, Color color, string text)

Draw Text

Parameters

NameTypeDescription
centerVertex3DText Center
dirVector3DText Direction : 텍스트가 작성되는 방향. Camera가 Z+ 인 경우, 텍스트는 X+ 방향으로 작성 (1, 0, 0)
upDirVector3DText Up Direction : 텍스트의 위쪽 방향. Camera가 Z+ 인 경우, 위쪽 방향은 Y+ 임 (0, 1, 0)
heightfloatText Height
colorColorText Color
textstringText

Returns

TypeDescription
TextDrawingItemText Drawing Item

Examples

private VIZCore3D.NET.VIZCore3DControl vizcore3d;

private void DrawText()
{
VIZCore3D.NET.Data.TextDrawingItem item = vizcore3d.TextDrawing.Add(
new VIZCore3D.NET.Data.Vertex3D(0, 0, 0)
, new VIZCore3D.NET.Data.Vector3D(1, 0, 0) /* X+ 방향으로 텍스트가 표시 */
, new VIZCore3D.NET.Data.Vector3D(0, 1, 0) /* 텍스트의 위쪽 방향 : Z+에서 볼때, Y+가 위쪽 임. */
, 3500
, Color.Black
, "ZONE_001"
);

vizcore3d.TextDrawing.Show(item.ID, true);
}

Add(Vertex3D center, Vector3D dir, Vector3D upDir, float height, float fontSize, Color color, string text)

public TextDrawingItem Add(Vertex3D center, Vector3D dir, Vector3D upDir, float height, float fontSize, Color color, string text)

Draw Text

Parameters

NameTypeDescription
centerVertex3DText Center
dirVector3DText Direction : 텍스트가 작성되는 방향. Camera가 Z+ 인 경우, 텍스트는 X+ 방향으로 작성 (1, 0, 0)
upDirVector3DText Up Direction : 텍스트의 위쪽 방향. Camera가 Z+ 인 경우, 위쪽 방향은 Y+ 임 (0, 1, 0)
heightfloatText Height
fontSizefloatFont Size : 34 ~ 250
colorColorText Color
textstringText

Returns

TypeDescription
TextDrawingItemText Drawing Item

Examples

private VIZCore3D.NET.VIZCore3DControl vizcore3d;

private void DrawText()
{
VIZCore3D.NET.Data.TextDrawingItem item = vizcore3d.TextDrawing.Add(
new VIZCore3D.NET.Data.Vertex3D(0, 0, 0)
, new VIZCore3D.NET.Data.Vector3D(1, 0, 0) /* X+ 방향으로 텍스트가 표시 */
, new VIZCore3D.NET.Data.Vector3D(0, 1, 0) /* 텍스트의 위쪽 방향 : Z+에서 볼때, Y+가 위쪽 임. */
, 3500
, 100
, Color.Black
, "ZONE_001"
);

vizcore3d.TextDrawing.Show(item.ID, true);
}