Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(443)

Issue 6947072: Allow setting a scaleFactor in bench_pictures (and render_pictures). (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 12 months ago by Leon
Modified:
11 years, 12 months ago
Reviewers:
EricB, DerekS, reed1
CC:
skia-review_googlegroups.com
Base URL:
https://skia.googlecode.com/svn/trunk
Visibility:
Public.

Description

Allow setting a scaleFactor in bench_pictures (and render_pictures). In TiledPictureRenderer and CopyTilesRenderer, do a postTranslate so the translate is not affected by the scale factor. Likewise, use clipRegion for tiled renderer so it will be unaffected by the scale factor. Respect the viewport for record, playbackCreation, and pipe renderers. Committed: https://code.google.com/p/skia/source/detail?r=6853

Patch Set 1 #

Patch Set 2 : Small cleanups: limit to 100 chars and use gLogger + macro to exit. #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+72 lines, -20 lines) Patch
M tools/CopyTilesRenderer.cpp View 1 1 chunk +6 lines, -1 line 0 comments Download
M tools/PictureRenderer.h View 4 chunks +12 lines, -0 lines 2 comments Download
M tools/PictureRenderer.cpp View 6 chunks +31 lines, -17 lines 0 comments Download
M tools/bench_pictures_main.cpp View 1 5 chunks +11 lines, -1 line 0 comments Download
M tools/render_pictures_main.cpp View 5 chunks +12 lines, -1 line 0 comments Download

Messages

Total messages: 3
Leon
11 years, 12 months ago (2012-12-17 18:40:28 UTC) #1
DerekS
lgtm, but perhaps mike should verify that the postTranslate stuff is correct. https://codereview.appspot.com/6947072/diff/2001/tools/PictureRenderer.h File tools/PictureRenderer.h ...
11 years, 12 months ago (2012-12-17 19:04:46 UTC) #2
Leon
11 years, 12 months ago (2012-12-17 19:25:28 UTC) #3
Mike agrees with the math, and render_pictures gives me the expected result.

https://codereview.appspot.com/6947072/diff/2001/tools/PictureRenderer.h
File tools/PictureRenderer.h (right):

https://codereview.appspot.com/6947072/diff/2001/tools/PictureRenderer.h#newc...
tools/PictureRenderer.h:228: void scaleToScaleFactor(SkCanvas*);
On 2012/12/17 19:04:46, DerekS wrote:
> could this be simplified to just scaleCanvas?

As we discussed, I kind of like the current name, since it hints that we're
scaling by a particular amount.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b