FastUIDraw
Public Types | Public Member Functions | List of all members
fastuidraw::PainterBlendShader Class Reference

A PainterBlendShader represents a shader for performing blending operations. More...

#include <painter_blend_shader.hpp>

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

Public Types

enum  shader_type { single_src, dual_src, framebuffer_fetch, number_types }
 Enumeration to specify how blend shader operates. More...
 

Public Member Functions

 PainterBlendShader (enum shader_type tp, unsigned int num_sub_shaders=1)
 
 PainterBlendShader (reference_counted_ptr< PainterBlendShader > parent, unsigned int sub_shader)
 
enum shader_type type (void) const
 
- Public Member Functions inherited from fastuidraw::PainterShader
 PainterShader (unsigned int num_sub_shaders=1)
 
 PainterShader (reference_counted_ptr< PainterShader > parent, unsigned int sub_shader)
 
uint32_t group (const PainterShaderRegistrar &) const
 
uint32_t ID (const PainterShaderRegistrar &) const
 
unsigned int number_sub_shaders (void) const
 
const reference_counted_ptr< PainterShader > & parent (void) const
 
bool registered_to (const PainterShaderRegistrar &) const
 
uint32_t sub_shader (void) const
 
Tag tag (const PainterShaderRegistrar &) const
 
- Public Member Functions inherited from fastuidraw::reference_counted_base< T, Counter >
 reference_counted_base (void)
 

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

A PainterBlendShader represents a shader for performing blending operations.

Definition at line 36 of file painter_blend_shader.hpp.

Member Enumeration Documentation

◆ shader_type

Enumeration to specify how blend shader operates.

Enumerator
single_src 

Indicates blending is via fixed function blending with single source blending.

dual_src 

Indicates blending is via fixed function blending with dual source blending.

framebuffer_fetch 

Indicates blending is via framebuffer fetch.

number_types 

The number of different types of valid shader_type values; also used to indicate an invalid value.

Definition at line 43 of file painter_blend_shader.hpp.

Constructor & Destructor Documentation

◆ PainterBlendShader() [1/2]

fastuidraw::PainterBlendShader::PainterBlendShader ( enum shader_type  tp,
unsigned int  num_sub_shaders = 1 
)
inlineexplicit

Ctor for creating a PainterBlendShader which has multiple sub-shaders. The purpose of sub-shaders is for the case where multiple shaders have almost same code and those code differences can be realized by examining a sub-shader ID.

Parameters
tpthe "how" the blend shader operates
num_sub_shadersnumber of sub-shaders

Definition at line 79 of file painter_blend_shader.hpp.

◆ PainterBlendShader() [2/2]

fastuidraw::PainterBlendShader::PainterBlendShader ( reference_counted_ptr< PainterBlendShader parent,
unsigned int  sub_shader 
)
inline

Ctor to create a PainterBlendShader realized as a sub-shader of an existing PainterBlendShader

Parameters
parentparent PainterBlendShader that has sub-shaders
sub_shaderwhich sub-shader of the parent PainterBlendShader

Definition at line 91 of file painter_blend_shader.hpp.

Member Function Documentation

◆ type()

enum shader_type fastuidraw::PainterBlendShader::type ( void  ) const
inline

Returns how the PainterBlendShader operates.

Definition at line 101 of file painter_blend_shader.hpp.


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