Class STLRuntime
STL file loader at runtime. Source: https://github.com/karl-/pb_Stl/blob/master/Runtime/Importer.cs.
Namespace: Evergine.Runtimes.STL
Assembly: Evergine.Runtimes.STL.dll
Syntax
public class STLRuntime : ModelRuntime
Fields
Instance
Gets the unique instance of the class (Singleton).
Declaration
public static readonly STLRuntime Instance
Field Value
Type | Description |
---|---|
STLRuntime |
Properties
Extentsion
Gets the 3D format extension.
Declaration
public override string Extentsion { get; }
Property Value
Type | Description |
---|---|
string |
Overrides
Methods
Read(Stream, Func<MaterialData, Task<Material>>)
Reads an STL from the stream.
Declaration
public override Task<Model> Read(Stream stream, Func<MaterialData, Task<Material>> materialAssigner = null)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The stream. |
Func<MaterialData, Task<Material>> | materialAssigner | The material assigner function. |
Returns
Type | Description |
---|---|
Task<Model> | The model. |
Overrides
Read(string, Func<MaterialData, Task<Material>>)
Reads an STL from the file path.
Declaration
public Task<Model> Read(string filePath, Func<MaterialData, Task<Material>> materialAssigner = null)
Parameters
Type | Name | Description |
---|---|---|
string | filePath | The file path. |
Func<MaterialData, Task<Material>> | materialAssigner | The material assigner. |
Returns
Type | Description |
---|---|
Task<Model> | The model. |