Table of Contents

Class BillboardBase

Namespace
HelixToolkit.SharpDX
Assembly
HelixToolkit.SharpDX.dll
public abstract class BillboardBase : Geometry3D, INotifyPropertyChanged, IGUID, IBillboardText
Inheritance
BillboardBase
Implements
Derived
Inherited Members

Constructors

BillboardBase()

public BillboardBase()

Properties

BillboardVertices

Gets the billboard vertices.

public IList<BillboardVertex> BillboardVertices { get; }

Property Value

IList<BillboardVertex>

The billboard vertices.

Height

Gets the height.

public float Height { get; protected set; }

Property Value

float

The height.

IsInitialized

Gets a value indicating whether this billboard internal is initialized.

public bool IsInitialized { get; protected set; }

Property Value

bool

true if this instance is initialized; otherwise, false.

Texture

Gets the texture.

public TextureModel? Texture { get; protected set; }

Property Value

TextureModel

The texture.

Type

Gets the type.

public abstract BillboardType Type { get; }

Property Value

BillboardType

The type.

Width

Gets the width.

public float Width { get; protected set; }

Property Value

float

The width.

Methods

AssignResultAdditional(BillboardHitResult, int)

protected virtual void AssignResultAdditional(BillboardHitResult result, int index)

Parameters

result BillboardHitResult
index int

DrawTexture(IDeviceResources)

Draws the texture and fill the billboardverties. Called during initialize vertex buffer.

public void DrawTexture(IDeviceResources deviceResources)

Parameters

deviceResources IDeviceResources

The device resources.

GetQuadOffset(float, float, BillboardHorizontalAlignment, BillboardVerticalAlignment, out Vector2, out Vector2)

protected static void GetQuadOffset(float width, float height, BillboardHorizontalAlignment horizontalAlignment, BillboardVerticalAlignment verticalAlignment, out Vector2 topLeft, out Vector2 bottomRight)

Parameters

width float
height float
horizontalAlignment BillboardHorizontalAlignment
verticalAlignment BillboardVerticalAlignment
topLeft Vector2
bottomRight Vector2

HitTest(HitTestContext?, Matrix4x4, ref List<HitTestResult>, object?, bool)

Hits the test.

public abstract bool HitTest(HitTestContext? context, Matrix4x4 modelMatrix, ref List<HitTestResult> hits, object? originalSource, bool fixedSize)

Parameters

context HitTestContext

The context.

modelMatrix Matrix4x4

The model matrix.

hits List<HitTestResult>

The hits.

originalSource object

The original source.

fixedSize bool

if set to true [fixed size].

Returns

bool

HitTestFixedSize(HitTestContext?, ref Matrix4x4, ref List<HitTestResult>, object?, int)

Hits the size of the test fixed.

protected bool HitTestFixedSize(HitTestContext? context, ref Matrix4x4 modelMatrix, ref List<HitTestResult> hits, object? originalSource, int count)

Parameters

context HitTestContext

The context.

modelMatrix Matrix4x4

The model matrix.

hits List<HitTestResult>

The hits.

originalSource object

The original source.

count int

The count of vertices in BillboardVertices.

Returns

bool

HitTestNonFixedSize(HitTestContext?, ref Matrix4x4, ref List<HitTestResult>, object?, int)

Hits the size of the test non fixed.

protected bool HitTestNonFixedSize(HitTestContext? context, ref Matrix4x4 modelMatrix, ref List<HitTestResult> hits, object? originalSource, int count)

Parameters

context HitTestContext

The context.

modelMatrix Matrix4x4

The model matrix.

hits List<HitTestResult>

The hits.

originalSource object

The original source.

count int

The count of vertices in BillboardVertices.

Returns

bool

Invalidate()

public void Invalidate()

OnAssignTo(Geometry3D)

protected override void OnAssignTo(Geometry3D target)

Parameters

target Geometry3D

OnClearAllGeometryData()

protected override void OnClearAllGeometryData()

OnUpdateTextureAndBillboardVertices(IDeviceResources)

protected abstract void OnUpdateTextureAndBillboardVertices(IDeviceResources deviceResources)

Parameters

deviceResources IDeviceResources