Arnold Engine
 
Loading...
Searching...
No Matches
AE::Core::LayerStack Class Reference

Manages a stack of layers with separate overlay layers. More...

#include <LayerStack.h>

Public Member Functions

void PushLayer (Layer *layer)
 Adds a regular layer to the stack.
 
void PushOverlay (Layer *overlay)
 Adds an overlay layer to the stack.
 
void PopLayer (const Layer *layer)
 Removes a regular layer from the stack.
 
void PopOverlay (const Layer *overlay)
 Removes an overlay layer from the stack.
 
std::vector< Layer * >::iterator begin ()
 Gets iterator to the beginning of the layer stack.
 
std::vector< Layer * >::iterator end ()
 Gets iterator to the end of the layer stack.
 

Detailed Description

Manages a stack of layers with separate overlay layers.

The LayerStack provides ordered management of layers and overlays:

  • Regular layers are rendered in the middle of the stack
  • Overlay layers are always rendered on top
  • Supports dynamic adding/removing of layers
  • Maintains proper render and update order
Note
Layers are processed from bottom to top for updates, and top to bottom for events

Member Function Documentation

◆ begin()

std::vector< Layer * >::iterator AE::Core::LayerStack::begin ( )
inline

Gets iterator to the beginning of the layer stack.

Returns
Iterator pointing to first layer

◆ end()

std::vector< Layer * >::iterator AE::Core::LayerStack::end ( )
inline

Gets iterator to the end of the layer stack.

Returns
Iterator pointing past the last layer

◆ PopLayer()

void AE::Core::LayerStack::PopLayer ( const Layer * layer)

Removes a regular layer from the stack.

Parameters
layerPointer to the layer to remove

◆ PopOverlay()

void AE::Core::LayerStack::PopOverlay ( const Layer * overlay)

Removes an overlay layer from the stack.

Parameters
overlayPointer to the overlay layer to remove

◆ PushLayer()

void AE::Core::LayerStack::PushLayer ( Layer * layer)

Adds a regular layer to the stack.

Parameters
layerPointer to the layer to add

Regular layers are inserted before overlay layers to maintain proper rendering order

◆ PushOverlay()

void AE::Core::LayerStack::PushOverlay ( Layer * overlay)

Adds an overlay layer to the stack.

Parameters
overlayPointer to the overlay layer to add

Overlay layers are always added to the end of the stack to render on top


The documentation for this class was generated from the following files: