Lines Matching defs:GrContext
10 #include "GrContext.h"
46 "Defers rendering in GrContext via GrInOrderDrawBuffer.");
68 // Glorified typedef to avoid including GrDrawState.h in GrContext.h
69 class GrContext::AutoRestoreEffects : public GrDrawState::AutoRestoreEffects {};
71 class GrContext::AutoCheckFlush {
73 AutoCheckFlush(GrContext* context) : fContext(context) { SkASSERT(NULL != context); }
82 GrContext* fContext;
85 GrContext* GrContext::Create(GrBackend backend, GrBackendContext backendContext) {
86 GrContext* context = SkNEW(GrContext);
95 GrContext::GrContext() {
114 bool GrContext::init(GrBackend backend, GrBackendContext backendContext) {
145 GrContext::~GrContext() {
176 void GrContext::contextLost() {
181 void GrContext::contextDestroyed() {
210 void GrContext::resetContext(uint32_t state) {
214 void GrContext::freeGpuResources() {
230 void GrContext::getResourceCacheUsage(int* resourceCount, size_t* resourceBytes) const {
241 GrTexture* GrContext::findAndRefTexture(const GrTextureDesc& desc,
250 bool GrContext::isTextureInCache(const GrTextureDesc& desc,
257 void GrContext::addStencilBuffer(GrStencilBuffer* sb) {
266 GrStencilBuffer* GrContext::findStencilBuffer(int width, int height,
312 GrTexture* GrContext::createResizedTexture(const GrTextureDesc& desc,
385 GrTexture* GrContext::createTexture(const GrTextureParams* params,
434 GrTexture* GrContext::lockAndRefScratchTexture(const GrTextureDesc& inDesc, ScratchTexMatch match) {
497 void GrContext::addExistingTextureToCache(GrTexture* texture) {
531 void GrContext::unlockScratchTexture(GrTexture* texture) {
561 void GrContext::purgeCache() {
567 bool GrContext::OverbudgetCB(void* data) {
570 GrContext* context = reinterpret_cast<GrContext*>(data);
579 GrTexture* GrContext::createUncachedTexture(const GrTextureDesc& descIn,
586 void GrContext::getResourceCacheLimits(int* maxTextures, size_t* maxTextureBytes) const {
590 void GrContext::setResourceCacheLimits(int maxTextures, size_t maxTextureBytes) {
594 int GrContext::getMaxTextureSize() const {
598 int GrContext::getMaxRenderTargetSize() const {
602 int GrContext::getMaxSampleCount() const {
608 GrTexture* GrContext::wrapBackendTexture(const GrBackendTextureDesc& desc) {
612 GrRenderTarget* GrContext::wrapBackendRenderTarget(const GrBackendRenderTargetDesc& desc) {
618 bool GrContext::supportsIndex8PixelConfig(const GrTextureParams* params,
639 void GrContext::clear(const SkIRect* rect,
649 void GrContext::drawPaint(const GrPaint& origPaint) {
683 void GrContext::dumpFontCache() const {
780 void GrContext::drawRect(const GrPaint& paint,
795 GR_CREATE_TRACE_MARKER("GrContext::drawRect", target);
911 void GrContext::drawRectToRect(const GrPaint& paint,
920 GR_CREATE_TRACE_MARKER("GrContext::drawRectToRect", target);
963 void GrContext::drawVertices(const GrPaint& paint,
978 GR_CREATE_TRACE_MARKER("GrContext::drawVertices", target);
1020 void GrContext::drawRRect(const GrPaint& paint,
1038 GR_CREATE_TRACE_MARKER("GrContext::drawRRect", target);
1051 void GrContext::drawDRRect(const GrPaint& paint,
1062 GR_CREATE_TRACE_MARKER("GrContext::drawDRRect", target);
1077 void GrContext::drawOval(const GrPaint& paint,
1095 GR_CREATE_TRACE_MARKER("GrContext::drawOval", target);
1162 void GrContext::drawPath(const GrPaint& paint, const SkPath& path, const GrStrokeInfo& strokeInfo) {
1213 GR_CREATE_TRACE_MARKER("GrContext::drawPath", target);
1248 void GrContext::internalDrawPath(GrDrawTarget* target, bool useAA, const SkPath& path,
1252 GR_CREATE_TRACE_MARKER("GrContext::internalDrawPath", target);
1303 void GrContext::flush(int flagsBitfield) {
1316 bool GrContext::writeTexturePixels(GrTexture* texture,
1340 bool GrContext::readTexturePixels(GrTexture* texture,
1390 bool GrContext::readRenderTargetPixels(GrRenderTarget* target,
1533 void GrContext::resolveRenderTarget(GrRenderTarget* target) {
1543 void GrContext::discardRenderTarget(GrRenderTarget* target) {
1551 void GrContext::copyTexture(GrTexture* src, GrRenderTarget* dst, const SkIPoint* topLeft) {
1560 // GrContext::resolveRenderTarget.
1582 bool GrContext::writeRenderTargetPixels(GrRenderTarget* target,
1711 GrDrawTarget* GrContext::prepareToDraw(const GrPaint* paint,
1761 GrPathRenderer* GrContext::getPathRenderer(const SkPath& path,
1789 bool GrContext::isConfigRenderable(GrPixelConfig config, bool withMSAA) const {
1793 int GrContext::getRecommendedSampleCount(GrPixelConfig config,
1810 void GrContext::setupDrawBuffer() {
1831 GrDrawTarget* GrContext::getTextTarget() {
1835 const GrIndexBuffer* GrContext::getQuadIndexBuffer() const {
1840 void test_pm_conversions(GrContext* ctx, int* pmToUPMValue, int* upmToPMValue) {
1849 const GrEffectRef* GrContext::createPMToUPMEffect(GrTexture* texture,
1865 const GrEffectRef* GrContext::createUPMToPMEffect(GrTexture* texture,
1881 GrPath* GrContext::createPath(const SkPath& inPath, const SkStrokeRec& stroke) {
1897 void GrContext::addResourceToCache(const GrResourceKey& resourceKey, GrCacheable* resource) {
1902 GrCacheable* GrContext::findAndRefCachedResource(const GrResourceKey& resourceKey) {
1908 void GrContext::addGpuTraceMarker(const GrGpuTraceMarker* marker) {
1915 void GrContext::removeGpuTraceMarker(const GrGpuTraceMarker* marker) {
1924 void GrContext::printCacheStats() const {