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

Side by Side Diff: src/gpu/GrTest.cpp

Issue 1333383002: Move some of the adding stencil attachment logic of Gpu and into Render Target. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: spelling Created 5 years, 3 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 | « src/gpu/GrResourceProvider.cpp ('k') | src/gpu/gl/GrGLGpu.h » ('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 /* 2 /*
3 * Copyright 2013 Google Inc. 3 * Copyright 2013 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "GrTest.h" 9 #include "GrTest.h"
10 10
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 248
249 bool onWritePixels(GrSurface* surface, 249 bool onWritePixels(GrSurface* surface,
250 int left, int top, int width, int height, 250 int left, int top, int width, int height,
251 GrPixelConfig config, const void* buffer, 251 GrPixelConfig config, const void* buffer,
252 size_t rowBytes) override { 252 size_t rowBytes) override {
253 return false; 253 return false;
254 } 254 }
255 255
256 void onResolveRenderTarget(GrRenderTarget* target) override { return; } 256 void onResolveRenderTarget(GrRenderTarget* target) override { return; }
257 257
258 bool createStencilAttachmentForRenderTarget(GrRenderTarget*, int width, int height) override { 258 GrStencilAttachment* createStencilAttachmentForRenderTarget(const GrRenderTa rget*,
259 return false; 259 int width,
260 } 260 int height) over ride {
261 261 return nullptr;
262 bool attachStencilAttachmentToRenderTarget(GrStencilAttachment*, GrRenderTar get*) override {
263 return false;
264 } 262 }
265 263
266 void clearStencil(GrRenderTarget* target) override {} 264 void clearStencil(GrRenderTarget* target) override {}
267 265
268 GrBackendObject createTestingOnlyBackendTexture(void* pixels, int w, int h, 266 GrBackendObject createTestingOnlyBackendTexture(void* pixels, int w, int h,
269 GrPixelConfig config) const override { 267 GrPixelConfig config) const override {
270 return 0; 268 return 0;
271 } 269 }
272 bool isTestingOnlyBackendTexture(GrBackendObject id) const override { return false; } 270 bool isTestingOnlyBackendTexture(GrBackendObject id) const override { return false; }
273 void deleteTestingOnlyBackendTexture(GrBackendObject id) const override {} 271 void deleteTestingOnlyBackendTexture(GrBackendObject id) const override {}
(...skipping 14 matching lines...) Expand all
288 SkASSERT(nullptr == fGpu); 286 SkASSERT(nullptr == fGpu);
289 fGpu = new MockGpu(this, options); 287 fGpu = new MockGpu(this, options);
290 SkASSERT(fGpu); 288 SkASSERT(fGpu);
291 this->initCommon(); 289 this->initCommon();
292 290
293 // We delete these because we want to test the cache starting with zero reso urces. Also, none of 291 // We delete these because we want to test the cache starting with zero reso urces. Also, none of
294 // these objects are required for any of tests that use this context. TODO: make stop allocating 292 // these objects are required for any of tests that use this context. TODO: make stop allocating
295 // resources in the buffer pools. 293 // resources in the buffer pools.
296 fDrawingMgr.abandon(); 294 fDrawingMgr.abandon();
297 } 295 }
OLDNEW
« no previous file with comments | « src/gpu/GrResourceProvider.cpp ('k') | src/gpu/gl/GrGLGpu.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698