Scene.FromFile
Contents
[
Hide
]FromFile(string, FileFormat, CancellationToken)
Opens the scene from given path using specified file format.
public static Scene FromFile(string fileName, FileFormat format,
CancellationToken cancellationToken = default)
Parameter | Type | Description |
---|---|---|
fileName | String | File name. |
format | FileFormat | File format. |
cancellationToken | CancellationToken | Cancellation token to the load task |
Examples
The following code shows how to create a scene from a file
var cts = new CancellationTokenSource();
Scene scene = Scene.FromFile("input.fbx", FileFormat.FBX7400ASCII, cts.Token);
See Also
- class FileFormat
- class Scene
- namespace Aspose.ThreeD
- assembly Aspose.3D
FromFile(string, LoadOptions, CancellationToken)
Opens the scene from given path using specified file format.
public static Scene FromFile(string fileName, LoadOptions options,
CancellationToken cancellationToken = default)
Parameter | Type | Description |
---|---|---|
fileName | String | File name. |
options | LoadOptions | More detailed configuration to open the stream. |
cancellationToken | CancellationToken | Cancellation token to the load task |
Examples
The following code shows how to create a scene from a file
var cts = new CancellationTokenSource();
var opt = new FbxLoadOptions();
opt.LookupPaths.Add("textures");
Scene scene = Scene.FromFile("input.fbx", opt, cts.Token);
See Also
- class LoadOptions
- class Scene
- namespace Aspose.ThreeD
- assembly Aspose.3D
FromFile(string)
Opens the scene from given path
public static Scene FromFile(string fileName)
Parameter | Type | Description |
---|---|---|
fileName | String | File name. |
Examples
The following code shows how to create a scene from a file
Scene scene = Scene.FromFile("input.fbx");
See Also
- class Scene
- namespace Aspose.ThreeD
- assembly Aspose.3D
FromFile(string, CancellationToken)
Opens the scene from given path
public static Scene FromFile(string fileName, CancellationToken cancellationToken)
Parameter | Type | Description |
---|---|---|
fileName | String | File name. |
cancellationToken | CancellationToken | Cancellation token to the load task |
Examples
The following code shows how to create a scene from a file
var cts = new CancellationTokenSource();
Scene scene = Scene.FromFile("input.fbx", cts.Token);
See Also
- class Scene
- namespace Aspose.ThreeD
- assembly Aspose.3D