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

Side by Side Diff: tests/ImageIsOpaqueTest.cpp

Issue 848903004: Require budget decision when creating a RenderTarget SkSurface (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Make compatible with chrome 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
OLDNEW
1 /* 1 /*
2 * Copyright 2014 Google Inc. 2 * Copyright 2014 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 #include "SkTypes.h" 8 #include "SkTypes.h"
9 #include "Test.h" 9 #include "Test.h"
10 10
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 continue; 73 continue;
74 } 74 }
75 75
76 GrContext* context = factory->get(glCtxType); 76 GrContext* context = factory->get(glCtxType);
77 77
78 if (NULL == context) { 78 if (NULL == context) {
79 continue; 79 continue;
80 } 80 }
81 81
82 SkImageInfo infoTransparent = SkImageInfo::MakeN32Premul(5, 5); 82 SkImageInfo infoTransparent = SkImageInfo::MakeN32Premul(5, 5);
83 SkAutoTUnref<SkSurface> surfaceTransparent(SkSurface::NewRenderTarget(co ntext, infoTransparent)); 83 SkAutoTUnref<SkSurface> surfaceTransparent(SkSurface::NewRenderTarget(co ntext,
robertphillips 2015/01/15 21:30:36 Tab this over?
bsalomon 2015/01/15 22:15:50 Done.
84 SkSurface::kNo_Budgeted, infoTransparent));
84 check_isopaque(reporter, surfaceTransparent, false); 85 check_isopaque(reporter, surfaceTransparent, false);
85 86
86 SkImageInfo infoOpaque = SkImageInfo::MakeN32(5, 5, kOpaque_SkAlphaType) ; 87 SkImageInfo infoOpaque = SkImageInfo::MakeN32(5, 5, kOpaque_SkAlphaType) ;
87 SkAutoTUnref<SkSurface> surfaceOpaque(SkSurface::NewRenderTarget(context , infoOpaque)); 88 SkAutoTUnref<SkSurface> surfaceOpaque(SkSurface::NewRenderTarget(context ,
robertphillips 2015/01/15 21:30:36 This too ?
bsalomon 2015/01/15 22:15:50 Done.
89 SkSurface::kNo_Budgeted, infoOpaque));
88 #if 0 90 #if 0
89 // this is failing right now : TODO fix me 91 // this is failing right now : TODO fix me
90 check_isopaque(reporter, surfaceOpaque, true); 92 check_isopaque(reporter, surfaceOpaque, true);
91 #endif 93 #endif
92 } 94 }
93 } 95 }
94 96
95 #endif 97 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698