Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: src/gpu/GrGpu.h

Issue 859013002: Make stencil buffers uncached for uncached render target textures (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | src/gpu/GrGpu.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef GrGpu_DEFINED 8 #ifndef GrGpu_DEFINED
9 #define GrGpu_DEFINED 9 #define GrGpu_DEFINED
10 10
(...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after
462 int left, int top, int width, int height, 462 int left, int top, int width, int height,
463 GrPixelConfig config, const void* buffer, 463 GrPixelConfig config, const void* buffer,
464 size_t rowBytes) = 0; 464 size_t rowBytes) = 0;
465 465
466 // overridden by backend-specific derived class to perform the resolve 466 // overridden by backend-specific derived class to perform the resolve
467 virtual void onResolveRenderTarget(GrRenderTarget* target) = 0; 467 virtual void onResolveRenderTarget(GrRenderTarget* target) = 0;
468 468
469 // width and height may be larger than rt (if underlying API allows it). 469 // width and height may be larger than rt (if underlying API allows it).
470 // Should attach the SB to the RT. Returns false if compatible sb could 470 // Should attach the SB to the RT. Returns false if compatible sb could
471 // not be created. 471 // not be created.
472 virtual bool createStencilBufferForRenderTarget(GrRenderTarget*, int width, int height) = 0; 472 virtual bool createStencilBufferForRenderTarget(GrRenderTarget*, bool budget ed,
473 int width, int height) = 0;
473 474
474 // attaches an existing SB to an existing RT. 475 // attaches an existing SB to an existing RT.
475 virtual bool attachStencilBufferToRenderTarget(GrStencilBuffer*, GrRenderTar get*) = 0; 476 virtual bool attachStencilBufferToRenderTarget(GrStencilBuffer*, GrRenderTar get*) = 0;
476 477
477 // clears target's entire stencil buffer to 0 478 // clears target's entire stencil buffer to 0
478 virtual void clearStencil(GrRenderTarget* target) = 0; 479 virtual void clearStencil(GrRenderTarget* target) = 0;
479 480
480 // Given a rt, find or create a stencil buffer and attach it 481 // Given a rt, find or create a stencil buffer and attach it
481 bool attachStencilBufferToRenderTarget(GrRenderTarget* target); 482 bool attachStencilBufferToRenderTarget(GrRenderTarget* target, bool budgeted );
482 483
483 virtual void didAddGpuTraceMarker() = 0; 484 virtual void didAddGpuTraceMarker() = 0;
484 virtual void didRemoveGpuTraceMarker() = 0; 485 virtual void didRemoveGpuTraceMarker() = 0;
485 486
486 void resetContext() { 487 void resetContext() {
487 this->onResetContext(fResetBits); 488 this->onResetContext(fResetBits);
488 fResetBits = 0; 489 fResetBits = 0;
489 ++fResetTimestamp; 490 ++fResetTimestamp;
490 } 491 }
491 492
(...skipping 11 matching lines...) Expand all
503 int fGpuTrac eMarkerCount; 504 int fGpuTrac eMarkerCount;
504 GrTraceMarkerSet fActiveT raceMarkers; 505 GrTraceMarkerSet fActiveT raceMarkers;
505 GrTraceMarkerSet fStoredT raceMarkers; 506 GrTraceMarkerSet fStoredT raceMarkers;
506 // The context owns us, not vice-versa, so this ptr is not ref'ed by Gpu. 507 // The context owns us, not vice-versa, so this ptr is not ref'ed by Gpu.
507 GrContext* fContext ; 508 GrContext* fContext ;
508 509
509 typedef SkRefCnt INHERITED; 510 typedef SkRefCnt INHERITED;
510 }; 511 };
511 512
512 #endif 513 #endif
OLDNEW
« no previous file with comments | « no previous file | src/gpu/GrGpu.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698