FastUIDraw
|
A PainterStrokeShader holds shaders for stroking. It is to hold shaders for stroking paths linearly or via arcs with and without anti-aliasing along with meta-data to inform what shading is faster. More...
#include <painter_stroke_shader.hpp>
Public Types | |
enum | shader_type_t { non_aa_shader, aa_shader, number_shader_types } |
A PainterStrokeShader holds shaders for stroking. It is to hold shaders for stroking paths linearly or via arcs with and without anti-aliasing along with meta-data to inform what shading is faster.
Definition at line 113 of file painter_stroke_shader.hpp.
Enumeration to specify what shader
Enumerator | |
---|---|
non_aa_shader | Specify the shader for rendering a stroked path without anti-aliasing. The depth value emitted in the item's vertex shader should be z-value to guarantee that there is no overdraw, see StrokedPoint::depth() and ArcStrokedPoint::depth(). |
aa_shader | Specifies a two-pass shader where the first pass renders to the deferred coverage buffer (via PainterItemShader::coverage_shader()) and the second pass reads from it. The depth value emitted in the item's vertex shader should be z-value to guarantee that there is no overdraw, see StrokedPoint::depth() and ArcStrokedPoint::depth(). |
Definition at line 119 of file painter_stroke_shader.hpp.
fastuidraw::PainterStrokeShader::PainterStrokeShader | ( | void | ) |
Ctor
fastuidraw::PainterStrokeShader::PainterStrokeShader | ( | const PainterStrokeShader & | obj | ) |
Copy ctor.
enum PainterEnums::stroking_method_t fastuidraw::PainterStrokeShader::fastest_anti_aliased_stroking_method | ( | void | ) | const |
Return what PainterEnums::stroking_method_t is fastest to stroke with anti-aliasing.
PainterStrokeShader& fastuidraw::PainterStrokeShader::fastest_anti_aliased_stroking_method | ( | enum PainterEnums::stroking_method_t | v | ) |
Set the value returned by fastest_anti_aliased_stroking_method(void) const.
v | value to use |
enum PainterEnums::stroking_method_t fastuidraw::PainterStrokeShader::fastest_non_anti_aliased_stroking_method | ( | void | ) | const |
Return the fastest stroking method to use when stroking without anti-aliasing.
PainterStrokeShader& fastuidraw::PainterStrokeShader::fastest_non_anti_aliased_stroking_method | ( | enum PainterEnums::stroking_method_t | v | ) |
Set the value returned by fastest_non_anti_aliased_stroking_method(void) const.
v | value to use |
PainterStrokeShader& fastuidraw::PainterStrokeShader::operator= | ( | const PainterStrokeShader & | rhs | ) |
Assignment operator.
const reference_counted_ptr<PainterItemShader>& fastuidraw::PainterStrokeShader::shader | ( | enum PainterEnums::stroking_method_t | tp, |
enum shader_type_t | sh | ||
) | const |
Returns the PainterItemShader for a given pass of a given type of stroking.
tp | specify to return a shader for arc or linear stroking |
sh | spcify which shader to return |
PainterStrokeShader& fastuidraw::PainterStrokeShader::shader | ( | enum PainterEnums::stroking_method_t | tp, |
enum shader_type_t | sh, | ||
const reference_counted_ptr< PainterItemShader > & | v | ||
) |
Set the value returned by shader(enum PainterEnums::stroking_method_t, enum shader_type_t) const.
tp | specify to return shader for arc or linear stroking |
sh | spcify which shader to return |
v | value to use |
const reference_counted_ptr<const StrokingDataSelectorBase>& fastuidraw::PainterStrokeShader::stroking_data_selector | ( | void | ) | const |
Returns the StrokingDataSelectorBase associated to this PainterStrokeShader.
PainterStrokeShader& fastuidraw::PainterStrokeShader::stroking_data_selector | ( | const reference_counted_ptr< const StrokingDataSelectorBase > & | sh | ) |
Set the value returned by stroking_data_selector(void) const.
sh | value to use |
void fastuidraw::PainterStrokeShader::swap | ( | PainterStrokeShader & | obj | ) |
Swap operation
obj | object with which to swap |