Flutter Engine
The Flutter Engine
Classes | Public Member Functions | Public Attributes | List of all members
GrMockOptions Struct Reference

#include <GrMockTypes.h>

Classes

struct  ConfigOptions
 

Public Member Functions

 GrMockOptions ()
 

Public Attributes

bool fMipmapSupport = false
 
bool fDrawInstancedSupport = false
 
bool fHalfFloatVertexAttributeSupport = false
 
uint32_t fMapBufferFlags = 0
 
int fMaxTextureSize = 2048
 
int fMaxRenderTargetSize = 2048
 
int fMaxWindowRectangles = 0
 
int fMaxVertexAttributes = 16
 
ConfigOptions fConfigOptions [kGrColorTypeCnt]
 
ConfigOptions fCompressedOptions [kSkTextureCompressionTypeCount]
 
bool fIntegerSupport = false
 
bool fFlatInterpolationSupport = false
 
int fMaxVertexSamplers = 0
 
int fMaxFragmentSamplers = 8
 
bool fShaderDerivativeSupport = true
 
bool fDualSourceBlendingSupport = false
 
bool fFailTextureAllocations = false
 

Detailed Description

A pointer to this type is used as the GrBackendContext when creating a Mock GrContext. It can be used to specify capability options for the mock context. If nullptr is used a default constructed GrMockOptions is used.

Definition at line 118 of file GrMockTypes.h.

Constructor & Destructor Documentation

◆ GrMockOptions()

GrMockOptions::GrMockOptions ( )
inline

Definition at line 119 of file GrMockTypes.h.

119 {
120 using Renderability = ConfigOptions::Renderability;
121 // By default RGBA_8888 and BGRA_8888 are textureable and renderable and
122 // A8 and RGB565 are texturable.
123 fConfigOptions[(int)GrColorType::kRGBA_8888].fRenderability = Renderability::kNonMSAA;
124 fConfigOptions[(int)GrColorType::kRGBA_8888].fTexturable = true;
125 fConfigOptions[(int)GrColorType::kAlpha_8].fTexturable = true;
126 fConfigOptions[(int)GrColorType::kBGR_565].fTexturable = true;
127 fConfigOptions[(int)GrColorType::kRGB_565].fTexturable = true;
128
130
134 }
ConfigOptions fCompressedOptions[kSkTextureCompressionTypeCount]
Definition: GrMockTypes.h:152
ConfigOptions fConfigOptions[kGrColorTypeCnt]
Definition: GrMockTypes.h:151

Member Data Documentation

◆ fCompressedOptions

ConfigOptions GrMockOptions::fCompressedOptions[kSkTextureCompressionTypeCount]

Definition at line 152 of file GrMockTypes.h.

◆ fConfigOptions

ConfigOptions GrMockOptions::fConfigOptions[kGrColorTypeCnt]

Definition at line 151 of file GrMockTypes.h.

◆ fDrawInstancedSupport

bool GrMockOptions::fDrawInstancedSupport = false

Definition at line 144 of file GrMockTypes.h.

◆ fDualSourceBlendingSupport

bool GrMockOptions::fDualSourceBlendingSupport = false

Definition at line 160 of file GrMockTypes.h.

◆ fFailTextureAllocations

bool GrMockOptions::fFailTextureAllocations = false

Definition at line 163 of file GrMockTypes.h.

◆ fFlatInterpolationSupport

bool GrMockOptions::fFlatInterpolationSupport = false

Definition at line 156 of file GrMockTypes.h.

◆ fHalfFloatVertexAttributeSupport

bool GrMockOptions::fHalfFloatVertexAttributeSupport = false

Definition at line 145 of file GrMockTypes.h.

◆ fIntegerSupport

bool GrMockOptions::fIntegerSupport = false

Definition at line 155 of file GrMockTypes.h.

◆ fMapBufferFlags

uint32_t GrMockOptions::fMapBufferFlags = 0

Definition at line 146 of file GrMockTypes.h.

◆ fMaxFragmentSamplers

int GrMockOptions::fMaxFragmentSamplers = 8

Definition at line 158 of file GrMockTypes.h.

◆ fMaxRenderTargetSize

int GrMockOptions::fMaxRenderTargetSize = 2048

Definition at line 148 of file GrMockTypes.h.

◆ fMaxTextureSize

int GrMockOptions::fMaxTextureSize = 2048

Definition at line 147 of file GrMockTypes.h.

◆ fMaxVertexAttributes

int GrMockOptions::fMaxVertexAttributes = 16

Definition at line 150 of file GrMockTypes.h.

◆ fMaxVertexSamplers

int GrMockOptions::fMaxVertexSamplers = 0

Definition at line 157 of file GrMockTypes.h.

◆ fMaxWindowRectangles

int GrMockOptions::fMaxWindowRectangles = 0

Definition at line 149 of file GrMockTypes.h.

◆ fMipmapSupport

bool GrMockOptions::fMipmapSupport = false

Definition at line 143 of file GrMockTypes.h.

◆ fShaderDerivativeSupport

bool GrMockOptions::fShaderDerivativeSupport = true

Definition at line 159 of file GrMockTypes.h.


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