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

Common base class to PainterItemShaderData, PainterBrushShaderData and PainterBlendShaderData to hold shader data for custom shaders. More...

#include <painter_shader_data.hpp>

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

Public Member Functions

virtual unsigned int data_size (void) const =0
 
virtual unsigned int number_resources (void) const
 
virtual void pack_data (c_array< uvec4 > dst) const =0
 
virtual void save_resources (c_array< reference_counted_ptr< const resource_base > > dst) const
 

Detailed Description

Common base class to PainterItemShaderData, PainterBrushShaderData and PainterBlendShaderData to hold shader data for custom shaders.

Definition at line 40 of file painter_shader_data.hpp.

Member Function Documentation

◆ data_size()

virtual unsigned int fastuidraw::PainterShaderData::data_size ( void  ) const
pure virtual

To be implemented by a derived class to return the number of uvec4 blocks needed to pack the data.

Implemented in fastuidraw::PainterDashedStrokeParams, and fastuidraw::PainterStrokeParams.

◆ number_resources()

virtual unsigned int fastuidraw::PainterShaderData::number_resources ( void  ) const
inlinevirtual

To be optionally implemented by a derived class to return the number of resources that need to be resident after packing. Default implementation returns 0.

Definition at line 85 of file painter_shader_data.hpp.

◆ pack_data()

virtual void fastuidraw::PainterShaderData::pack_data ( c_array< uvec4 dst) const
pure virtual

To be implemented by a derived class to pack the data.

Parameters
dstlocation to which to pack the data

Implemented in fastuidraw::PainterDashedStrokeParams, and fastuidraw::PainterStrokeParams.

◆ save_resources()

virtual void fastuidraw::PainterShaderData::save_resources ( c_array< reference_counted_ptr< const resource_base > >  dst) const
inlinevirtual

To be optionally implemented by a derived class to save references to resources that need to be resident after packing. Default implementation does nothing.

Parameters
dstlocation to which to save resources.

Definition at line 73 of file painter_shader_data.hpp.


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