Skia
2DGraphicsLibrary
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GrShaderCaps Class Reference
Inheritance diagram for GrShaderCaps:
SkRefCnt SkRefCntBase

Classes

struct  PrecisionInfo
 Info about shader variable precision within a given shader stage. More...
 

Public Member Functions

virtual SkString dump () const
 
bool shaderDerivativeSupport () const
 
bool geometryShaderSupport () const
 
bool pathRenderingSupport () const
 
bool dstReadInShaderSupport () const
 
bool dualSourceBlendingSupport () const
 
bool integerSupport () const
 
bool texelBufferSupport () const
 
const PrecisionInfogetFloatShaderPrecisionInfo (GrShaderType shaderType, GrSLPrecision precision) const
 Get the precision info for a variable of type kFloat_GrSLType, kVec2f_GrSLType, etc in a given shader type. More...
 
bool floatPrecisionVaries () const
 Is there any difference between the float shader variable precision types? If this is true then unless the shader type is not supported, any call to getFloatShaderPrecisionInfo() would report the same info for all precisions in all shader types.
 
int pixelLocalStorageSize () const
 PLS storage size in bytes (0 when not supported). More...
 
bool plsPathRenderingSupport () const
 True if this context supports the necessary extensions and features to enable the PLS path renderer.
 
- Public Member Functions inherited from SkRefCntBase
 SkRefCntBase ()
 Default construct, initializing the reference count to 1.
 
virtual ~SkRefCntBase ()
 Destruct, asserting that the reference count is 1.
 
int32_t getRefCnt () const
 Return the reference count. More...
 
void validate () const
 
bool unique () const
 May return true if the caller is the only owner. More...
 
void ref () const
 Increment the reference count. More...
 
void unref () const
 Decrement the reference count. More...
 

Protected Member Functions

void applyOptionsOverrides (const GrContextOptions &options)
 Subclasses must call this after initialization in order to apply caps overrides requested by the client. More...
 
- Protected Member Functions inherited from SkRefCntBase
void internal_dispose_restore_refcnt_to_1 () const
 Allow subclasses to call this if they've overridden internal_dispose so they can reset fRefCnt before the destructor is called or if they choose not to call the destructor (e.g. More...
 

Protected Attributes

bool fShaderDerivativeSupport: 1
 
bool fGeometryShaderSupport: 1
 
bool fPathRenderingSupport: 1
 
bool fDstReadInShaderSupport: 1
 
bool fDualSourceBlendingSupport: 1
 
bool fIntegerSupport: 1
 
bool fTexelBufferSupport: 1
 
bool fShaderPrecisionVaries
 
PrecisionInfo fFloatPrecisions [kGrShaderTypeCount][kGrSLPrecisionCount]
 
int fPixelLocalStorageSize
 
bool fPLSPathRenderingSupport
 

Private Types

typedef SkRefCnt INHERITED
 

Private Member Functions

virtual void onApplyOptionsOverrides (const GrContextOptions &)
 

Member Function Documentation

void GrShaderCaps::applyOptionsOverrides ( const GrContextOptions options)
protected

Subclasses must call this after initialization in order to apply caps overrides requested by the client.

Note that overrides will only reduce the caps never expand them.

const PrecisionInfo& GrShaderCaps::getFloatShaderPrecisionInfo ( GrShaderType  shaderType,
GrSLPrecision  precision 
) const
inline

Get the precision info for a variable of type kFloat_GrSLType, kVec2f_GrSLType, etc in a given shader type.

If the shader type is not supported or the precision level is not supported in that shader type then the returned struct will report false when supported() is called.

int GrShaderCaps::pixelLocalStorageSize ( ) const
inline

PLS storage size in bytes (0 when not supported).

The PLS spec defines a minimum size of 16 bytes whenever PLS is supported.


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