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

Side by Side Diff: tests/ResourceCacheTest.cpp

Issue 682223002: rename GrTextureDesc->GrSurfaceDesc, GrTextureFlags->GrSurfaceFlags (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: const Created 6 years, 1 month 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 | « tests/ReadWriteAlphaTest.cpp ('k') | tests/WritePixelsTest.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 2013 Google Inc. 2 * Copyright 2013 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 #if SK_SUPPORT_GPU 8 #if SK_SUPPORT_GPU
9 9
10 #include "GrContext.h" 10 #include "GrContext.h"
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 for (int type = 0; type < GrContextFactory::kLastGLContextType; ++type) { 256 for (int type = 0; type < GrContextFactory::kLastGLContextType; ++type) {
257 GrContextFactory::GLContextType glType = static_cast<GrContextFactory::G LContextType>(type); 257 GrContextFactory::GLContextType glType = static_cast<GrContextFactory::G LContextType>(type);
258 if (!GrContextFactory::IsRenderingGLContext(glType)) { 258 if (!GrContextFactory::IsRenderingGLContext(glType)) {
259 continue; 259 continue;
260 } 260 }
261 GrContext* context = factory->get(glType); 261 GrContext* context = factory->get(glType);
262 if (NULL == context) { 262 if (NULL == context) {
263 continue; 263 continue;
264 } 264 }
265 265
266 GrTextureDesc desc; 266 GrSurfaceDesc desc;
267 desc.fConfig = kSkia8888_GrPixelConfig; 267 desc.fConfig = kSkia8888_GrPixelConfig;
268 desc.fFlags = kRenderTarget_GrTextureFlagBit; 268 desc.fFlags = kRenderTarget_GrSurfaceFlag;
269 desc.fWidth = gWidth; 269 desc.fWidth = gWidth;
270 desc.fHeight = gHeight; 270 desc.fHeight = gHeight;
271 SkImageInfo info = SkImageInfo::MakeN32Premul(gWidth, gHeight); 271 SkImageInfo info = SkImageInfo::MakeN32Premul(gWidth, gHeight);
272 SkAutoTUnref<SkSurface> surface(SkSurface::NewRenderTarget(context, info )); 272 SkAutoTUnref<SkSurface> surface(SkSurface::NewRenderTarget(context, info ));
273 273
274 test_cache(reporter, context, surface->getCanvas()); 274 test_cache(reporter, context, surface->getCanvas());
275 test_purge_invalidated(reporter, context); 275 test_purge_invalidated(reporter, context);
276 test_cache_delete_on_destruction(reporter, context); 276 test_cache_delete_on_destruction(reporter, context);
277 test_resource_size_changed(reporter, context); 277 test_resource_size_changed(reporter, context);
278 } 278 }
279 } 279 }
280 280
281 #endif 281 #endif
OLDNEW
« no previous file with comments | « tests/ReadWriteAlphaTest.cpp ('k') | tests/WritePixelsTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698