FastUIDraw
Public Member Functions | List of all members
fastuidraw::PainterData::brush_value Class Reference

A brush_value stores the brush applied; it stores a pointer to a PainterBrushShader together with a PainterDataValue<PainterBrushShaderData>. If the pointer to the PainterBrushShader is null, then it indicates to use the standard brush shader, PainterBrushShaderSet::standard_brush(). More...

#include <painter_data.hpp>

Public Member Functions

 brush_value (void)
 
 brush_value (const PainterBrush *v)
 
 brush_value (const PainterCustomBrush &br)
 
 brush_value (const PainterDataValue< PainterBrushShaderData > &brush_data)
 
const PainterBrushShaderbrush_shader (void) const
 
const PainterDataValue< PainterBrushShaderData > & brush_shader_data (void) const
 
void make_packed (PainterPackedValuePool &pool)
 
bool packed (void) const
 
void set (const PainterBrush *v)
 
void set (const PainterCustomBrush &br)
 
void set (const PainterDataValue< PainterBrushShaderData > &brush_data)
 

Detailed Description

A brush_value stores the brush applied; it stores a pointer to a PainterBrushShader together with a PainterDataValue<PainterBrushShaderData>. If the pointer to the PainterBrushShader is null, then it indicates to use the standard brush shader, PainterBrushShaderSet::standard_brush().

Definition at line 54 of file painter_data.hpp.

Constructor & Destructor Documentation

◆ brush_value() [1/4]

fastuidraw::PainterData::brush_value::brush_value ( void  )
inline

Empty ctor that initializes to not have a brush source (custom or PainterBrush).

Definition at line 61 of file painter_data.hpp.

◆ brush_value() [2/4]

fastuidraw::PainterData::brush_value::brush_value ( const PainterBrush v)
inline

Ctor to set the brush_value to source from a PainterBrush.

Definition at line 69 of file painter_data.hpp.

◆ brush_value() [3/4]

fastuidraw::PainterData::brush_value::brush_value ( const PainterCustomBrush br)
inline

Ctor to set the brush_value to source from a custom brush.

Definition at line 78 of file painter_data.hpp.

◆ brush_value() [4/4]

fastuidraw::PainterData::brush_value::brush_value ( const PainterDataValue< PainterBrushShaderData > &  brush_data)
inline

Ctor to set the brush_value to source from a PainterBrush packed.

Definition at line 87 of file painter_data.hpp.

Member Function Documentation

◆ brush_shader()

const PainterBrushShader* fastuidraw::PainterData::brush_value::brush_shader ( void  ) const
inline

Returns the PainterBrushShader for the brush; a value of nullptr indicates to used the default brush that processes PainterBrush data.

Definition at line 129 of file painter_data.hpp.

◆ brush_shader_data()

const PainterDataValue<PainterBrushShaderData>& fastuidraw::PainterData::brush_value::brush_shader_data ( void  ) const
inline

Returns the PainterDataValue<PainterBrushShaderData> holding the brush data.

Definition at line 139 of file painter_data.hpp.

◆ make_packed()

void fastuidraw::PainterData::brush_value::make_packed ( PainterPackedValuePool pool)
inline

Packs the brush shader data.

Definition at line 148 of file painter_data.hpp.

◆ packed()

bool fastuidraw::PainterData::brush_value::packed ( void  ) const
inline

Provided as a conveniance, equivalent to

brush_shader_data().packed().

Definition at line 160 of file painter_data.hpp.

◆ set() [1/3]

void fastuidraw::PainterData::brush_value::set ( const PainterBrush v)
inline

Set to source from a PainterBrush

Definition at line 96 of file painter_data.hpp.

◆ set() [2/3]

void fastuidraw::PainterData::brush_value::set ( const PainterCustomBrush br)
inline

Set to source from a custom brush shader

Definition at line 107 of file painter_data.hpp.

◆ set() [3/3]

void fastuidraw::PainterData::brush_value::set ( const PainterDataValue< PainterBrushShaderData > &  brush_data)
inline

Set to source from a packed PainterBrush value.

Definition at line 117 of file painter_data.hpp.


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