51 struct TestFormatColorTypeCombination;
65#if defined(GR_TEST_UTILS)
66 std::string_view deviceName()
const {
return fDeviceName; }
276 int sampleCount = 1)
const = 0;
469 int renderTargetSampleCnt,
521 kVulkanHasResolveLoadSubpass = 0x1,
564 int sampleCount)
const;
566#if defined(GR_TEST_UTILS)
567 virtual std::vector<GrTest::TestFormatColorTypeCombination> getTestingCombinations()
const = 0;
576#if defined(GR_TEST_UTILS)
577 void setDeviceName(
const char* n) {
670#if defined(GR_TEST_UTILS)
671 std::string fDeviceName;
702 bool fSuppressPrints : 1;
703 bool fWireframeMode : 1;
#define GR_MAKE_BITFIELD_CLASS_OPS(X)
static SkColorType colorType(AImageDecoder *decoder, const AImageDecoderHeaderInfo *headerInfo)
static constexpr bool SkToBool(const T &x)
bool discardStencilValuesAfterRenderPass() const
virtual void addExtraSamplerKey(skgpu::KeyBuilder *, GrSamplerState, const GrBackendFormat &) const
virtual skgpu::Swizzle onGetReadSwizzle(const GrBackendFormat &, GrColorType) const =0
bool fSupportsProtectedContent
bool advancedBlendEquationSupport() const
virtual void onApplyOptionsOverrides(const GrContextOptions &)
bool avoidLineDraws() const
bool transferFromBufferToBufferSupport() const
bool avoidWritePixelsFastPath() const
bool fDynamicStateArrayGeometryProcessorTextureSupport
int fMaxPreferredRenderTargetSize
bool shouldInitializeTextures() const
virtual uint64_t computeFormatKey(const GrBackendFormat &) const =0
bool reducedShaderMode() const
bool fFinishedProcAsyncCallbackSupport
std::tuple< GrColorType, GrBackendFormat > getFallbackColorTypeAndFormat(GrColorType, int sampleCount) const
bool fAvoidStencilBuffers
bool mipmapSupport() const
virtual GrInternalSurfaceFlags getExtraSurfaceFlagsForDeferredRT() const
bool disablePerspectiveSDFText() const
bool finishedProcAsyncCallbackSupport() const
bool fReadPixelsRowBytesSupport
bool performPartialClearsAsDraws() const
GrDstSampleFlags getDstSampleFlagsForProxy(const GrRenderTargetProxy *, bool drawUsesMSAA) const
bool crossContextTextureSupport() const
virtual bool isFormatTexturable(const GrBackendFormat &, GrTextureType) const =0
virtual GrDstSampleFlags onGetDstSampleFlagsForProxy(const GrRenderTargetProxy *) const
bool fNativeDrawIndexedIndirectIsBroken
const GrShaderCaps * shaderCaps() const
std::unique_ptr< GrShaderCaps > fShaderCaps
virtual SupportedWrite supportedWritePixelsColorType(GrColorType surfaceColorType, const GrBackendFormat &surfaceFormat, GrColorType srcColorType) const =0
bool fPreferClientSideDynamicBuffers
bool fMSAAResolvesAutomatically
virtual int maxRenderTargetSampleCount(const GrBackendFormat &) const =0
bool fReuseScratchTextures
bool anisoSupport() const
bool surfaceSupportsWritePixels(const GrSurface *) const
bool avoidReorderingRenderTasks() const
GrDriverBugWorkarounds fDriverBugWorkarounds
bool conservativeRasterSupport() const
size_t bufferUpdateDataPreserveAlignment() const
virtual skgpu::Swizzle getWriteSwizzle(const GrBackendFormat &, GrColorType) const =0
bool semaphoreSupport() const
bool fNativeDrawIndirectSupport
GrCaps(const GrContextOptions &)
bool fPreferVRAMUseOverFlushes
bool supportsProtectedContent() const
int maxTextureSize() const
virtual GrBackendFormat getBackendFormatFromCompressionType(SkTextureCompressionType) const =0
virtual SurfaceReadPixelsSupport surfaceSupportsReadPixels(const GrSurface *) const =0
bool transferFromBufferToTextureSupport() const
virtual GrProgramDesc makeDesc(GrRenderTarget *, const GrProgramInfo &, ProgramDescOverrideFlags overrideFlags=ProgramDescOverrideFlags::kNone) const =0
bool avoidStencilBuffers() const
uint32_t fMaxPushConstantsSize
int maxVertexAttributes() const
maximum number of attribute values per vertex
bool fTransferFromBufferToBufferSupport
int maxRenderTargetSize() const
bool backendSemaphoreSupport() const
virtual void onDumpJSON(SkJSONWriter *) const
bool fTransferFromBufferToTextureSupport
virtual bool onAreColorTypeAndFormatCompatible(GrColorType, const GrBackendFormat &) const =0
bool fTextureBarrierSupport
bool fAvoidLargeIndexBufferDraws
uint32_t fAdvBlendEqDisableFlags
bool wireframeMode() const
bool fBuffersAreInitiallyZero
bool fTransferPixelsToRowBytesSupport
bool clampToBorderSupport() const
bool preferDiscardableMSAAAttachment() const
virtual DstCopyRestrictions getDstCopyRestrictions(const GrRenderTargetProxy *src, GrColorType ct) const
size_t transferFromBufferToBufferAlignment() const
bool fMustSyncGpuDuringAbandon
bool wireframeSupport() const
virtual bool isFormatSRGB(const GrBackendFormat &) const =0
bool avoidLargeIndexBufferDraws() const
bool fBackendSemaphoreSupport
bool preferClientSideDynamicBuffers() const
@ kAdvancedCoherent_BlendEquationSupport
@ kLast_BlendEquationSupport
@ kAdvanced_BlendEquationSupport
@ kBasic_BlendEquationSupport
bool halfFloatVertexAttributeSupport() const
void dumpJSON(SkJSONWriter *) const
bool nativeDrawIndirectSupport() const
bool fHalfFloatVertexAttributeSupport
bool fClampToBorderSupport
bool fSampleLocationsSupport
bool fOversizedStencilSupport
bool buffersAreInitiallyZero() const
virtual bool isFormatCopyable(const GrBackendFormat &) const =0
bool nativeDrawIndexedIndirectIsBroken() const
bool areColorTypeAndFormatCompatible(GrColorType grCT, const GrBackendFormat &format) const
bool supportsDynamicMSAA(const GrRenderTargetProxy *) const
bool drawInstancedSupport() const
bool fTwoSidedStencilRefsAndMasksMustMatch
bool usePrimitiveRestart() const
GrBackendFormat getDefaultBackendFormat(GrColorType, GrRenderable) const
virtual bool onCanCopySurface(const GrSurfaceProxy *dst, const SkIRect &dstRect, const GrSurfaceProxy *src, const SkIRect &srcRect) const =0
bool fUsePrimitiveRestart
bool advancedCoherentBlendEquationSupport() const
virtual bool isFormatRenderable(const GrBackendFormat &format, int sampleCount) const =0
int maxPreferredRenderTargetSize() const
bool sampleLocationsSupport() const
int fInternalMultisampleCount
uint32_t maxPushConstantsSize() const
bool isFormatCompressed(const GrBackendFormat &format) const
bool npotTextureTileSupport() const
GR_DECL_BITFIELD_CLASS_OPS_FRIENDS(ProgramDescOverrideFlags)
bool fPerformPartialClearsAsDraws
uint32_t mapBufferFlags() const
bool fReuseScratchBuffers
virtual SupportedRead onSupportedReadPixelsColorType(GrColorType srcColorType, const GrBackendFormat &srcFormat, GrColorType dstColorType) const =0
bool fWritePixelsRowBytesSupport
bool fShouldCollapseSrcOverToSrcWhenAble
const GrDriverBugWorkarounds & workarounds() const
size_t fTransferBufferRowBytesAlignment
bool disableTessellationPathRenderer() const
bool dynamicStateArrayGeometryProcessorTextureSupport() const
bool isWindowRectanglesSupportedForRT(const GrBackendRenderTarget &rt) const
bool textureBarrierSupport() const
bool avoidDithering() const
size_t bufferMapThreshold() const
bool fPerformColorClearsAsDraws
bool fAvoidReorderingRenderTasks
bool useClientSideIndirectBuffers() const
bool twoSidedStencilRefsAndMasksMustMatch() const
SupportedRead supportedReadPixelsColorType(GrColorType srcColorType, const GrBackendFormat &srcFormat, GrColorType dstColorType) const
virtual bool isFormatAsColorTypeRenderable(GrColorType ct, const GrBackendFormat &format, int sampleCount=1) const =0
virtual bool onSupportsDynamicMSAA(const GrRenderTargetProxy *) const
bool fNPOTTextureTileSupport
bool validateSurfaceParams(const SkISize &, const GrBackendFormat &, GrRenderable renderable, int renderTargetSampleCnt, skgpu::Mipmapped, GrTextureType) const
bool fSupportsAHardwareBufferImages
bool isAdvancedBlendEquationDisabled(skgpu::BlendEquation equation) const
bool fTransferFromSurfaceToBufferSupport
bool fMustClearUploadedBufferData
bool reuseScratchBuffers() const
void finishInitialization(const GrContextOptions &options)
virtual bool onSurfaceSupportsWritePixels(const GrSurface *) const =0
bool mustClearUploadedBufferData() const
bool canCopySurface(const GrSurfaceProxy *dst, const SkIRect &dstRect, const GrSurfaceProxy *src, const SkIRect &srcRect) const
bool mustSyncGpuDuringAbandon() const
virtual bool dmsaaResolveCanBeUsedAsTextureInSameRenderPass() const
bool shouldCollapseSrcOverToSrcWhenAble() const
bool fShouldInitializeTextures
size_t transferBufferRowBytesAlignment() const
bool readPixelsRowBytesSupport() const
bool oversizedStencilSupport() const
bool performColorClearsAsDraws() const
bool preferFullscreenClears() const
virtual int getRenderTargetSampleCount(int requestedCount, const GrBackendFormat &) const =0
bool suppressPrints() const
virtual GrBackendFormat onGetDefaultBackendFormat(GrColorType) const =0
bool fAvoidWritePixelsFastPath
BlendEquationSupport fBlendEquationSupport
size_t fBufferUpdateDataPreserveAlignment
bool fPreferDiscardableMSAAAttachment
bool msaaResolvesAutomatically() const
bool fConservativeRasterSupport
bool writePixelsRowBytesSupport() const
BlendEquationSupport blendEquationSupport() const
bool transferPixelsToRowBytesSupport() const
bool reuseScratchTextures() const
bool fDisableTessellationPathRenderer
bool preferVRAMUseOverFlushes() const
int internalMultisampleCount(const GrBackendFormat &format) const
bool performStencilClearsAsDraws() const
bool fUseClientSideIndirectBuffers
bool fPerformStencilClearsAsDraws
bool fDrawInstancedSupport
size_t fTransferFromBufferToBufferAlignment
bool supportsAHardwareBufferImages() const
bool gpuTracingSupport() const
bool fDisablePerspectiveSDFText
virtual bool onIsWindowRectanglesSupportedForRT(const GrBackendRenderTarget &) const
bool fCrossContextTextureSupport
bool fPreferFullscreenClears
skgpu::Swizzle getReadSwizzle(const GrBackendFormat &format, GrColorType colorType) const
int maxWindowRectangles() const
bool transferFromSurfaceToBufferSupport() const
uint32_t uint32_t * format
static float min(float r, float g, float b)
static constexpr bool BlendEquationIsAdvanced(BlendEquation equation)
GrSurfaceProxy::RectsMustMatch fRectsMustMatch
size_t fOffsetAlignmentForTransferBuffer
size_t fOffsetAlignmentForTransferBuffer