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

Side by Side Diff: tools/render_pdfs_main.cpp

Issue 657353004: render_pdfs cull rect output formated better (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "SkCanvas.h" 8 #include "SkCanvas.h"
9 #include "SkCommandLineFlags.h" 9 #include "SkCommandLineFlags.h"
10 #include "SkDocument.h" 10 #include "SkDocument.h"
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after
247 } 247 }
248 248
249 SkAutoTUnref<SkPicture> picture( 249 SkAutoTUnref<SkPicture> picture(
250 SkPicture::CreateFromStream(&inputStream)); 250 SkPicture::CreateFromStream(&inputStream));
251 if (NULL == picture.get()) { 251 if (NULL == picture.get()) {
252 SkDebugf("Could not read an SkPicture from %s\n", 252 SkDebugf("Could not read an SkPicture from %s\n",
253 files[i].c_str()); 253 files[i].c_str());
254 ++failures; 254 ++failures;
255 continue; 255 continue;
256 } 256 }
257 SkDebugf("[%f,%f,%f,%f] %-*s", 257 SkDebugf("[%6g %6g %6g %6g] %-*s",
258 picture->cullRect().fLeft, picture->cullRect().fTop, 258 picture->cullRect().fLeft, picture->cullRect().fTop,
259 picture->cullRect().fRight, picture->cullRect().fBottom, 259 picture->cullRect().fRight, picture->cullRect().fBottom,
260 maximumPathLength, basename.c_str()); 260 maximumPathLength, basename.c_str());
261 261
262 SkAutoTDelete<SkWStream> stream(open_stream(outputDir, files[i])); 262 SkAutoTDelete<SkWStream> stream(open_stream(outputDir, files[i]));
263 if (!stream.get()) { 263 if (!stream.get()) {
264 ++failures; 264 ++failures;
265 continue; 265 continue;
266 } 266 }
267 if (!pdf_to_stream(picture, stream.get(), encode_to_dct_data)) { 267 if (!pdf_to_stream(picture, stream.get(), encode_to_dct_data)) {
(...skipping 30 matching lines...) Expand all
298 return -1; 298 return -1;
299 } 299 }
300 #endif 300 #endif
301 return 0; 301 return 0;
302 } 302 }
303 #if !defined SK_BUILD_FOR_IOS 303 #if !defined SK_BUILD_FOR_IOS
304 int main(int argc, char * const argv[]) { 304 int main(int argc, char * const argv[]) {
305 return tool_main(argc, (char**) argv); 305 return tool_main(argc, (char**) argv);
306 } 306 }
307 #endif 307 #endif
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698