Open 3D Engine LyShine Gem API Reference
24.09
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
|
The ILyShine interface provides access to the other interfaces provided by the UI module. More...
#include <ILyShine.h>
Inherited by CLyShine.
Public Member Functions | |
AZ_RTTI (ILyShine, "{652ED9D7-0782-44E8-BCE7-65DD38C90907}") | |
virtual void | Release ()=0 |
Delete this object. | |
virtual IDraw2d * | GetDraw2d ()=0 |
Gets the IDraw2d interface. | |
virtual AZ::EntityId | CreateCanvas ()=0 |
Create an empty UI Canvas (in game) More... | |
virtual AZ::EntityId | LoadCanvas (const AZStd::string &assetIdPathname)=0 |
Load a UI Canvas from in-game. | |
virtual AZ::EntityId | CreateCanvasInEditor (UiEntityContext *entityContext)=0 |
Create an empty UI Canvas (for the UI editor) More... | |
virtual AZ::EntityId | LoadCanvasInEditor (const AZStd::string &assetIdPathname, const AZStd::string &sourceAssetPathname, UiEntityContext *entityContext)=0 |
Load a UI Canvas from the UI editor. | |
virtual AZ::EntityId | ReloadCanvasFromXml (const AZStd::string &xmlString, UiEntityContext *entityContext)=0 |
Reload a UI Canvas from xml. For use in the editor for the undo system only. | |
virtual AZ::EntityId | FindCanvasById (LyShine::CanvasId id)=0 |
virtual AZ::EntityId | FindLoadedCanvasByPathName (const AZStd::string &assetIdPathname)=0 |
virtual void | ReleaseCanvas (AZ::EntityId canvas, bool forEditor=false)=0 |
Release a canvas from use either in-game or in editor, destroy UI Canvas if no longer used in either. | |
virtual void | ReleaseCanvasDeferred (AZ::EntityId canvas)=0 |
Queue a canvas for release on the next tick (used in game mode) | |
virtual ISprite * | LoadSprite (const AZStd::string &pathname)=0 |
Load a sprite object. | |
virtual ISprite * | CreateSprite (const AZ::Data::Asset< AZ::RPI::AttachmentImageAsset > &attachmentImageAsset)=0 |
Create a sprite that references the specified render target asset. | |
virtual bool | DoesSpriteTextureAssetExist (const AZStd::string &pathname)=0 |
Check if a sprite's texture asset exists. The .sprite sidecar file is optional and is not checked. | |
virtual AZ::Data::Instance< AZ::RPI::Image > | LoadTexture (const AZStd::string &pathName)=0 |
Load an image asset by texture pathname. | |
virtual void | PostInit ()=0 |
Perform post-initialization (script system will be available) | |
virtual void | SetViewportSize (AZ::Vector2 viewportSize)=0 |
Set the current viewport size, this should be called before Update and Render are called. | |
virtual void | Update (float deltaTimeInSeconds)=0 |
virtual void | Render ()=0 |
Render 2D and UI elements that should be rendered at end of frame. | |
virtual void | ExecuteQueuedEvents ()=0 |
Execute events that were queued during a canvas update or input event handler. | |
virtual void | Reset ()=0 |
Reset the system (this happens at end of running game in Editor for example) | |
virtual void | OnLevelUnload ()=0 |
Unload canvases that should be unloaded when a level is unloaded. | |
virtual void | OnLoadScreenUnloaded ()=0 |
The ILyShine interface provides access to the other interfaces provided by the UI module.
|
pure virtual |
Create an empty UI Canvas (in game)
The system keeps track of all the loaded canvases and unloads them on game exit.
Implemented in CLyShine.
|
pure virtual |
Create an empty UI Canvas (for the UI editor)
The editor keeps track of the canvases it has open.
Implemented in CLyShine.
|
pure virtual |
Get a loaded canvas by CanvasId NOTE: this only searches canvases loaded in the game (not the editor)
Implemented in CLyShine.
|
pure virtual |
Get a loaded canvas by path name NOTE: this only searches canvases loaded in the game (not the editor)
Implemented in CLyShine.
|
pure virtual |
Called when a load screen is finished displaying (when a level load is complete). Used to mark all render graphs dirty in case the loaded canvases were already rendered before their textures were done loading. This happens when a load screen is being rendered during a level load. When other canvases associated with the level are loaded, they also get rendered by the UiLoadScreenComponent, but their texture loading is delayed until further down the level load process. Once a canvas is rendered, its render graph's dirty flag is cleared, so the render graph needs to be marked dirty again after the textures are loaded
Implemented in CLyShine.
|
pure virtual |
Update UI elements
deltaTimeInSeconds | the amount of time in seconds since the last call to this function |
Implemented in CLyShine.