OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 "SkBBoxHierarchy.h" | 8 #include "SkBBoxHierarchy.h" |
9 #include "SkBlurImageFilter.h" | 9 #include "SkBlurImageFilter.h" |
10 #include "SkCanvas.h" | 10 #include "SkCanvas.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 #include "SkPixelRef.h" | 24 #include "SkPixelRef.h" |
25 #include "SkPixelSerializer.h" | 25 #include "SkPixelSerializer.h" |
26 #include "SkMiniRecorder.h" | 26 #include "SkMiniRecorder.h" |
27 #include "SkRRect.h" | 27 #include "SkRRect.h" |
28 #include "SkRandom.h" | 28 #include "SkRandom.h" |
29 #include "SkRecord.h" | 29 #include "SkRecord.h" |
30 #include "SkShader.h" | 30 #include "SkShader.h" |
31 #include "SkStream.h" | 31 #include "SkStream.h" |
32 #include "sk_tool_utils.h" | 32 #include "sk_tool_utils.h" |
33 | 33 |
34 #if SK_SUPPORT_GPU | |
35 #include "SkSurface.h" | |
36 #include "GrContextFactory.h" | |
37 #endif | |
38 #include "Test.h" | 34 #include "Test.h" |
39 | 35 |
40 #include "SkLumaColorFilter.h" | 36 #include "SkLumaColorFilter.h" |
41 #include "SkColorFilterImageFilter.h" | 37 #include "SkColorFilterImageFilter.h" |
42 | 38 |
43 static void make_bm(SkBitmap* bm, int w, int h, SkColor color, bool immutable) { | 39 static void make_bm(SkBitmap* bm, int w, int h, SkColor color, bool immutable) { |
44 bm->allocN32Pixels(w, h); | 40 bm->allocN32Pixels(w, h); |
45 bm->eraseColor(color); | 41 bm->eraseColor(color); |
46 if (immutable) { | 42 if (immutable) { |
47 bm->setImmutable(); | 43 bm->setImmutable(); |
(...skipping 1335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1383 | 1379 |
1384 SkAutoTDelete<SkStream> rstream(wstream.detachAsStream()); | 1380 SkAutoTDelete<SkStream> rstream(wstream.detachAsStream()); |
1385 SkAutoTUnref<SkPicture> deserializedPicture(SkPicture::CreateFromStream(rstr
eam)); | 1381 SkAutoTUnref<SkPicture> deserializedPicture(SkPicture::CreateFromStream(rstr
eam)); |
1386 | 1382 |
1387 REPORTER_ASSERT(r, SkToBool(deserializedPicture)); | 1383 REPORTER_ASSERT(r, SkToBool(deserializedPicture)); |
1388 REPORTER_ASSERT(r, deserializedPicture->cullRect().left() == 1); | 1384 REPORTER_ASSERT(r, deserializedPicture->cullRect().left() == 1); |
1389 REPORTER_ASSERT(r, deserializedPicture->cullRect().top() == 2); | 1385 REPORTER_ASSERT(r, deserializedPicture->cullRect().top() == 2); |
1390 REPORTER_ASSERT(r, deserializedPicture->cullRect().right() == 3); | 1386 REPORTER_ASSERT(r, deserializedPicture->cullRect().right() == 3); |
1391 REPORTER_ASSERT(r, deserializedPicture->cullRect().bottom() == 4); | 1387 REPORTER_ASSERT(r, deserializedPicture->cullRect().bottom() == 4); |
1392 } | 1388 } |
OLD | NEW |