Click or drag to resize
Ab4d.SharpEngine logo

SceneComponent Class

SceneComponent class is a base abstract class for all components that are created by providing a Scene object. If Scene is initialized (has GpuDevice set), then the resources are initialized from the constructor. Otherwise the resources are initialized when the Scene is initialized or manually when the InitializeDeviceResources method is called.
Inheritance Hierarchy

Namespace: Ab4d.SharpEngine.Core
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 1.0.8740+deb2991acfe86a95cca780cd4f82bcae2805c1a5
Syntax
C#
public abstract class SceneComponent : ComponentBase, 
	ISceneComponent

The SceneComponent type exposes the following members.

Constructors
 NameDescription
Protected methodSceneComponent Initializes a new instance of the SceneComponent class.
Top
Properties
 NameDescription
Public propertyIsInitialized Gets a Boolean that specifies if this component has already been initialized by providing the VulkanDevice that was used to create resources.
Public propertyScene Gets the parent Scene (can be null).
Top
Methods
 NameDescription
Protected methodCheckIfInitialized CheckIfInitialized
Public methodInitializeDeviceResources Initializes this component with the GpuDevice that is set to the Scene object. This method calls a virtual OnInitializeDeviceResources(VulkanDevice) that can be used by a derived class to create the resources.
Protected methodOnInitializeDeviceResources Initializes resources with the specified GpuDevice. This method can be override and is called from InitializeDeviceResources method.
Protected methodOnResourcesInitialized OnResourcesInitialized
Top
Events
 NameDescription
Public eventDeviceResourcesInitialized ResourcesInitialized event is triggered after the resources were initialized by calling the InitializeDeviceResources method.
Top
See Also