Empeld
Empeld plugin documentation.
pluginbase.Objects.Models.IModelFactory Interface Reference

Injectable Dependency responsible for loading and caching models More...

Public Member Functions

bool IsModelLoaded (string resource)
 Determines whether or not a specified model resource has been loaded More...
 
IReadonlyModel LoadModel (string resource)
 Load a model to a readonly model instance More...
 
IModelInstance CreateModelInstance (string resource)
 Loads a model, and creates an unpositioned instance of that model More...
 
IReadonlyModel CreateMesh (Mesh mesh)
 Creates a model given a mesh More...
 
IReadonlyModel CreateMesh (IEnumerable< Mesh > frames, float fps)
 Creates a model with a given animated set of meshes More...
 
IDynamicTextModel CreateTextBillboard (float size, Rgba color, string text, params object[] args)
 Creates a text object that is a billboard More...
 
IDynamicTextModel CreateText (Vector3 dir, Vector3 up, float size, Rgba color, string text, params object[] args)
 Creates text More...
 
IDynamicTextModel CreateText (float size, string text, params object[] args)
 Creates text. Default dir = +x, up = +y More...
 
IUiScreenModel CreateUiScreenModel (Mesh mesh, int uiWidth=256, int uiHeight=256)
 Loads a BUI control to be rendered onto a mesh NOTE: Won't work if the system doesn't support Framebuffer Objects (FBO) In that case, it will fallback to the material texture on the Mesh More...
 

Detailed Description

Injectable Dependency responsible for loading and caching models

Attribute: Injectable

Member Function Documentation

◆ CreateMesh() [1/2]

IReadonlyModel pluginbase.Objects.Models.IModelFactory.CreateMesh ( Mesh  mesh)

Creates a model given a mesh

Returns
The mesh.
Parameters
meshMesh.

◆ CreateMesh() [2/2]

IReadonlyModel pluginbase.Objects.Models.IModelFactory.CreateMesh ( IEnumerable< Mesh frames,
float  fps 
)

Creates a model with a given animated set of meshes

Returns
The mesh.
Parameters
framesFrames.
fpsFps.

◆ CreateModelInstance()

IModelInstance pluginbase.Objects.Models.IModelFactory.CreateModelInstance ( string  resource)

Loads a model, and creates an unpositioned instance of that model

Returns
The model instance.
Parameters
resourceResource.

◆ CreateText() [1/2]

IDynamicTextModel pluginbase.Objects.Models.IModelFactory.CreateText ( Vector3  dir,
Vector3  up,
float  size,
Rgba  color,
string  text,
params object []  args 
)

Creates text

Returns
The text.
Parameters
dirDirection vector
upUp vector
sizeSize.
colorColor
textText.
argsArguments.

◆ CreateText() [2/2]

IDynamicTextModel pluginbase.Objects.Models.IModelFactory.CreateText ( float  size,
string  text,
params object []  args 
)

Creates text. Default dir = +x, up = +y

Returns
The text.
Parameters
sizeSize.
textText.
argsArguments.

◆ CreateTextBillboard()

IDynamicTextModel pluginbase.Objects.Models.IModelFactory.CreateTextBillboard ( float  size,
Rgba  color,
string  text,
params object []  args 
)

Creates a text object that is a billboard

Returns
The text billboard.
Parameters
sizeSize of text
colorColor
textText.
argsArguments.

◆ CreateUiScreenModel()

IUiScreenModel pluginbase.Objects.Models.IModelFactory.CreateUiScreenModel ( Mesh  mesh,
int  uiWidth = 256,
int  uiHeight = 256 
)

Loads a BUI control to be rendered onto a mesh NOTE: Won't work if the system doesn't support Framebuffer Objects (FBO) In that case, it will fallback to the material texture on the Mesh

Returns
The bui screen model.
Parameters
meshMesh.

◆ IsModelLoaded()

bool pluginbase.Objects.Models.IModelFactory.IsModelLoaded ( string  resource)

Determines whether or not a specified model resource has been loaded

Returns
true if this instance is model loaded the specified resource; otherwise, false.
Parameters
resourceResource.

◆ LoadModel()

IReadonlyModel pluginbase.Objects.Models.IModelFactory.LoadModel ( string  resource)

Load a model to a readonly model instance

Returns
The model.
Parameters
resourceResource.

The documentation for this interface was generated from the following file: