| 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 #include <stdio.h> | 8 #include <stdio.h> |
| 9 #include <stdlib.h> | 9 #include <stdlib.h> |
| 10 #include "SkForceLinking.h" |
| 11 |
| 12 __SK_FORCE_IMAGE_DECODER_LINKING; |
| 10 | 13 |
| 11 #include "fiddle_main.h" | 14 #include "fiddle_main.h" |
| 12 | 15 |
| 13 // Globals externed in fiddle_main.h | 16 // Globals externed in fiddle_main.h |
| 14 SkBitmap source; | 17 SkBitmap source; |
| 15 sk_sp<SkImage> image; | 18 sk_sp<SkImage> image; |
| 16 | 19 |
| 17 static void encode_to_base64(const void* data, size_t size, FILE* out) { | 20 static void encode_to_base64(const void* data, size_t size, FILE* out) { |
| 18 const uint8_t* input = reinterpret_cast<const uint8_t*>(data); | 21 const uint8_t* input = reinterpret_cast<const uint8_t*>(data); |
| 19 const uint8_t* end = &input[size]; | 22 const uint8_t* end = &input[size]; |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 | 155 |
| 153 printf("{\n"); | 156 printf("{\n"); |
| 154 dump_output(rasterData, "Raster", !gpuData && !pdfData && !skpData); | 157 dump_output(rasterData, "Raster", !gpuData && !pdfData && !skpData); |
| 155 dump_output(gpuData, "Gpu", !pdfData && !skpData); | 158 dump_output(gpuData, "Gpu", !pdfData && !skpData); |
| 156 dump_output(pdfData, "Pdf", !skpData); | 159 dump_output(pdfData, "Pdf", !skpData); |
| 157 dump_output(skpData, "Skp"); | 160 dump_output(skpData, "Skp"); |
| 158 printf("}\n"); | 161 printf("}\n"); |
| 159 | 162 |
| 160 return 0; | 163 return 0; |
| 161 } | 164 } |
| OLD | NEW |