FastUIDraw
Public Member Functions | Protected Member Functions | List of all members
fastuidraw::AtlasIndexBackingStoreBase Class Referenceabstract

Represents the interface for the backing store for index data of images. More...

#include <image_atlas.hpp>

Inheritance diagram for fastuidraw::AtlasIndexBackingStoreBase:
Inheritance graph
[legend]

Public Member Functions

ivec3 dimensions (void) const
 
virtual void flush (void)=0
 
void resize (int new_num_layers)
 
virtual void set_data (int x, int y, int l, int w, int h, c_array< const ivec3 > data)=0
 
- Public Member Functions inherited from fastuidraw::reference_counted_base< T, Counter >
 reference_counted_base (void)
 

Protected Member Functions

 AtlasIndexBackingStoreBase (ivec3 whl)
 
 AtlasIndexBackingStoreBase (int w, int h, int l)
 
virtual void resize_implement (int new_num_layers)=0
 

Additional Inherited Members

- Static Public Member Functions inherited from fastuidraw::reference_counted_base< T, Counter >
static void add_reference (const reference_counted_base< T, Counter > *p)
 
static void remove_reference (const reference_counted_base< T, Counter > *p)
 

Detailed Description

Represents the interface for the backing store for index data of images.

For example in GL, this can be a GL_TEXTURE_2D_ARRAY. An implementation of the class does NOT need to be thread safe because the user of the backing store (ImageAtlas) performs calls to the backing store behind its own mutex.

Definition at line 142 of file image_atlas.hpp.

Constructor & Destructor Documentation

◆ AtlasIndexBackingStoreBase() [1/2]

fastuidraw::AtlasIndexBackingStoreBase::AtlasIndexBackingStoreBase ( ivec3  whl)
explicitprotected

Ctor.

Parameters
whldimensions of the backing store

◆ AtlasIndexBackingStoreBase() [2/2]

fastuidraw::AtlasIndexBackingStoreBase::AtlasIndexBackingStoreBase ( int  w,
int  h,
int  l 
)
protected

Ctor.

Parameters
wwidth of the backing store
hheight of the backing store
lnumber layers of the backing store

Member Function Documentation

◆ dimensions()

ivec3 fastuidraw::AtlasIndexBackingStoreBase::dimensions ( void  ) const

Returns the dimensions of the backing store (as passed in the ctor).

◆ flush()

virtual void fastuidraw::AtlasIndexBackingStoreBase::flush ( void  )
pure virtual

To be implemented by a derived class to flush set_data() to the backing store.

◆ resize()

void fastuidraw::AtlasIndexBackingStoreBase::resize ( int  new_num_layers)

Resize the object by increasing the number of layers.

◆ resize_implement()

virtual void fastuidraw::AtlasIndexBackingStoreBase::resize_implement ( int  new_num_layers)
protectedpure virtual

To be implemented by a derived class to resize the object. The resize changes ONLY the number of layers of the object and only increases the value as well. When called, the return value of dimensions() is the size before the resize completes.

Parameters
new_num_layersnew number of layers to which to resize the underlying store.

◆ set_data()

virtual void fastuidraw::AtlasIndexBackingStoreBase::set_data ( int  x,
int  y,
int  l,
int  w,
int  h,
c_array< const ivec3 data 
)
pure virtual

To be implemented by a derived class to fill index data into the backing store. The index data passed references back into this AtlasIndexBackingStore.

Parameters
xhorizontal position
yvertical position
llayer position
wwidth of data
hheight of data
datalist of tiles as returned by ImageAtlas::add_index_tile()

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