OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 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 // This is a GPU-backend specific test. It relies on static intializers to work | 8 // This is a GPU-backend specific test. It relies on static intializers to work |
9 | 9 |
10 #include "SkTypes.h" | 10 #include "SkTypes.h" |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 tex1->unref(); | 130 tex1->unref(); |
131 } else { | 131 } else { |
132 REPORTER_ASSERT(reporter, !canCreate); | 132 REPORTER_ASSERT(reporter, !canCreate); |
133 } | 133 } |
134 } | 134 } |
135 | 135 |
136 DEF_GPUTEST(VkUploadPixelsTests, reporter, factory) { | 136 DEF_GPUTEST(VkUploadPixelsTests, reporter, factory) { |
137 GrContextOptions opts; | 137 GrContextOptions opts; |
138 opts.fSuppressPrints = true; | 138 opts.fSuppressPrints = true; |
139 GrContextFactory debugFactory(opts); | 139 GrContextFactory debugFactory(opts); |
140 for (int type = 0; type < GrContextFactory::kLastGLContextType; ++type) { | 140 for (int type = 0; type < GrContextFactory::kContextTypeCnt; ++type) { |
141 if (static_cast<GrContextFactory::GLContextType>(type) != | 141 if (static_cast<GrContextFactory::ContextType>(type) != |
142 GrContextFactory::kNative_GLContextType) { | 142 GrContextFactory::kNativeGL_ContextType) { |
143 continue; | 143 continue; |
144 } | 144 } |
145 GrContext* context = debugFactory.get(static_cast<GrContextFactory::GLCo
ntextType>(type)); | 145 GrContext* context = debugFactory.get(static_cast<GrContextFactory::Cont
extType>(type)); |
146 if (context) { | 146 if (context) { |
147 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, fals
e, false); | 147 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, fals
e, false); |
148 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, true
, false); | 148 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, true
, false); |
149 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, fals
e, true); | 149 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, fals
e, true); |
150 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, true
, true); | 150 basic_texture_test(reporter, context, kRGBA_8888_GrPixelConfig, true
, true); |
151 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, fals
e, false); | 151 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, fals
e, false); |
152 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, true
, false); | 152 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, true
, false); |
153 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, fals
e, true); | 153 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, fals
e, true); |
154 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, true
, true); | 154 basic_texture_test(reporter, context, kBGRA_8888_GrPixelConfig, true
, true); |
155 } | 155 } |
156 | 156 |
157 } | 157 } |
158 } | 158 } |
159 | 159 |
160 #endif | 160 #endif |
OLD | NEW |