Scene
Overview
Scene is a class in Aspose.3D FOSS for .NET.
Inherits from: SceneObject, INamedObject.
A scene is a top-level object that contains the nodes, geometries, materials, textures, animation, poses, sub-scenes and etc. Scene can have sub-scenes, acts as multiple-document support in files like collada/blender/fbx Node hierarchy can be accessed through is used to keep a reference of unattached objects during serialization(like meta data or custom objects) so it can be used as a library.
This class provides 15 methods for working with Scene objects in .NET programs.
Available methods include: A3DObject, Clear, CreateAnimationClip, FindProperty, FromFile, FromStream, GetAnimationClip, GetProperty, Open, RemoveProperty, Render, Save, and 3 additional methods.
All public members are accessible to any .NET application after installing the Aspose.3D FOSS for .NET package.
Properties: AnimationClips, AssetInfo, CurrentAnimationClip, Library, Name, Poses, and 4 more.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
SubScenes | IList<Scene> | Read | Gets the sub scenes. |
Library | IList<A3DObject> | Read | Gets the library. |
AnimationClips | IList<AnimationClip> | Read | Gets the animation clips. |
CurrentAnimationClip | AnimationClip? | Read/Write | Gets or sets the current animation clip. |
AssetInfo | AssetInfo? | Read/Write | Gets or sets the asset info. |
Poses | ICollection<Pose> | Read | Gets the poses. |
RootNode | Node | Read | Gets the root node. |
Scene | Scene | Read | Gets the scene. |
Name | string | Read/Write | Gets or sets the name. |
Properties | PropertyCollection | Read | Gets the properties. |
Methods
| Signature | Description |
|---|---|
Scene() | |
Scene(entity: Entity) | |
Scene(parentScene: Scene, name: string) | |
GetAnimationClip(name: string) | Gets a named AnimationClip |
Clear() | Clears the scene content and restores the default settings. |
CreateAnimationClip(name: string) | A shorthand function to create and register the The first AnimationClip will be assigned to the |
Open(stream: Stream, format: FileFormat, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
Open(stream: Stream, options: LoadOptions, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
Open(stream: Stream) | Opens the scene from given stream using specified file format. |
Open(stream: Stream, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
Open(stream: Stream, fileName: string) | Opens the scene from given stream using specified file format. |
Open(stream: Stream, fileName: string, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
Open(stream: Stream, options: LoadOptions) | Opens the scene from given stream using specified file format. |
Open(fileName: string, format: FileFormat, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
Open(fileName: string, options: LoadOptions) | Opens the scene from given stream using specified file format. |
Open(fileName: string, options: LoadOptions, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
Open(fileName: string) | Opens the scene from given stream using specified file format. |
Open(fileName: string, format: FileFormat) | Opens the scene from given stream using specified file format. |
Open(fileName: string, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
FromStream(stream: Stream, format: FileFormat, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
FromStream(stream: Stream, options: LoadOptions, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
FromStream(stream: Stream, cancellationToken: CancellationToken) | Opens the scene from given stream using specified file format. |
FromFile(fileName: string, format: FileFormat, cancellationToken: CancellationToken) | Opens the scene from given path using specified file format. |
FromFile(fileName: string, options: LoadOptions, cancellationToken: CancellationToken) | Opens the scene from given path using specified file format. |
FromFile(fileName: string) | Opens the scene from given path using specified file format. |
FromFile(fileName: string, cancellationToken: CancellationToken) | Opens the scene from given path using specified file format. |
Save(stream: Stream, format: FileFormat) | Saves the scene to stream using specified file format. |
Save(stream: Stream, format: FileFormat, cancellationToken: CancellationToken) | Saves the scene to stream using specified file format. |
Save(stream: Stream, options: SaveOptions) | Saves the scene to stream using specified file format. |
Save(stream: Stream, options: SaveOptions, cancellationToken: CancellationToken) | Saves the scene to stream using specified file format. |
Save(fileName: string, format: FileFormat, cancellationToken: CancellationToken) | Saves the scene to stream using specified file format. |
Save(fileName: string) | Saves the scene to stream using specified file format. |
Save(fileName: string, format: FileFormat) | Saves the scene to stream using specified file format. |
Save(fileName: string, options: SaveOptions) | Saves the scene to stream using specified file format. |
Save(fileName: string, options: SaveOptions, cancellationToken: CancellationToken) | Saves the scene to stream using specified file format. |
Render(camera: Entities.Camera, fileName: string) | Not implemented in the FOSS edition — throws at runtime. Render the scene into external file from given camera’s perspective. The default output size is 1024x768 and output format is png |
Render(camera: Entities.Camera, fileName: string, size: Vector2, format: string) | Not implemented in the FOSS edition — throws at runtime. Render the scene into external file from given camera’s perspective. The default output size is 1024x768 and output format is png |
Render(camera: Entities.Camera, fileName: string, size: Vector2, format: string, options: ImageRenderOptions) | Not implemented in the FOSS edition — throws at runtime. Render the scene into external file from given camera’s perspective. The default output size is 1024x768 and output format is png |
Render(camera: Entities.Camera, bitmap: object) | Not implemented in the FOSS edition — throws at runtime. \u003C/summary> |
Render(camera: Entities.Camera, bitmap: object, options: ImageRenderOptions) | Not implemented in the FOSS edition — throws at runtime. \u003C/summary> |
SceneObject(name: string) | |
A3DObject() | |
RemoveProperty(property: Property) | Removes a dynamic property. |
GetProperty(property: string) | Get the value of specified property |
SetProperty(property: string, value: object?) | Sets the value of specified property |
FindProperty(propertyName: string) | Finds the property. It can be a dynamic property (Created by CreateDynamicProperty/SetProperty) or native property(Identified by its name) |