OLD | NEW |
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 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 SkImageInfo infoOpaque = SkImageInfo::MakeN32(5, 5, kOpaque_SkAlphaType); | 61 SkImageInfo infoOpaque = SkImageInfo::MakeN32(5, 5, kOpaque_SkAlphaType); |
62 SkAutoTUnref<SkSurface> surfaceOpaque(SkSurface::NewRaster(infoOpaque)); | 62 SkAutoTUnref<SkSurface> surfaceOpaque(SkSurface::NewRaster(infoOpaque)); |
63 check_isopaque(reporter, surfaceOpaque, true); | 63 check_isopaque(reporter, surfaceOpaque, true); |
64 } | 64 } |
65 | 65 |
66 #if SK_SUPPORT_GPU | 66 #if SK_SUPPORT_GPU |
67 | 67 |
68 DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ImageIsOpaqueTest_Gpu, reporter, context) { | 68 DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ImageIsOpaqueTest_Gpu, reporter, context) { |
69 SkImageInfo infoTransparent = SkImageInfo::MakeN32Premul(5, 5); | 69 SkImageInfo infoTransparent = SkImageInfo::MakeN32Premul(5, 5); |
70 SkAutoTUnref<SkSurface> surfaceTransparent( | 70 SkAutoTUnref<SkSurface> surfaceTransparent( |
71 SkSurface::NewRenderTarget(context, SkSurface::kNo_Budgeted, infoTranspa
rent)); | 71 SkSurface::NewRenderTarget(context, SkBudgeted::kNo, infoTransparent)); |
72 check_isopaque(reporter, surfaceTransparent, false); | 72 check_isopaque(reporter, surfaceTransparent, false); |
73 | 73 |
74 SkImageInfo infoOpaque = SkImageInfo::MakeN32(5, 5, kOpaque_SkAlphaType); | 74 SkImageInfo infoOpaque = SkImageInfo::MakeN32(5, 5, kOpaque_SkAlphaType); |
75 SkAutoTUnref<SkSurface> surfaceOpaque( | 75 SkAutoTUnref<SkSurface> surfaceOpaque( |
76 SkSurface::NewRenderTarget(context,SkSurface::kNo_Budgeted, infoOpaque))
; | 76 SkSurface::NewRenderTarget(context,SkBudgeted::kNo, infoOpaque)); |
77 | 77 |
78 check_isopaque(reporter, surfaceOpaque, true); | 78 check_isopaque(reporter, surfaceOpaque, true); |
79 } | 79 } |
80 | 80 |
81 #endif | 81 #endif |
OLD | NEW |