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

Issue 6208089: Add to skdiff: test images for bitwise equality before testing for pixel-wise equality (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
12 years, 3 months ago by epoger
Modified:
12 years, 3 months ago
Reviewers:
reed1, TomH
CC:
skia-review_googlegroups.com
Base URL:
http://skia.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Add to skdiff: test images for bitwise equality before testing for pixel-wise equality - we now check for bitwise equality of files before bothering with pixel comparisons (this will help with formats for which we don't have good decoders, like PDF) - unparsable files are now reported as differing, unless they are bitwise equal (before, they were always reported as matching!) - "largest area mismatch" is now based on same-size image pairs only; previously, if any image pairs had mismatching size, it was 100% - removed repetitive "image size mismatch, so no diff to display" messages - changed format of leftmost table cells to be more readable BUG=http://code.google.com/p/skia/issues/detail?id=473 Committed: https://code.google.com/p/skia/source/detail?r=4027

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+181 lines, -100 lines) Patch
M tools/skdiff_main.cpp View 11 chunks +163 lines, -84 lines 2 comments Download
M tools/tests/skdiff/test1/output-expected/index.html View 1 chunk +11 lines, -9 lines 0 comments Download
M tools/tests/skdiff/test1/output-expected/stdout View 2 chunks +4 lines, -3 lines 0 comments Download
M tools/tests/skdiff/test2/output-expected/stdout View 2 chunks +3 lines, -4 lines 0 comments Download

Messages

Total messages: 4
epoger
If you want to visually compare the new output from the old one, you can ...
12 years, 3 months ago (2012-05-21 19:28:39 UTC) #1
TomH
LGTM https://codereview.appspot.com/6208089/diff/1/tools/skdiff_main.cpp File tools/skdiff_main.cpp (right): https://codereview.appspot.com/6208089/diff/1/tools/skdiff_main.cpp#newcode319 tools/skdiff_main.cpp:319: return SkData::NewFromMalloc(bufferStart, bytesInFile); Does this take care of ...
12 years, 3 months ago (2012-05-21 19:37:10 UTC) #2
reed1
It does take ownership. I will update the dox to make that clearer.
12 years, 3 months ago (2012-05-21 19:59:01 UTC) #3
epoger
12 years, 3 months ago (2012-05-22 17:25:55 UTC) #4
https://codereview.appspot.com/6208089/diff/1/tools/skdiff_main.cpp
File tools/skdiff_main.cpp (right):

https://codereview.appspot.com/6208089/diff/1/tools/skdiff_main.cpp#newcode319
tools/skdiff_main.cpp:319: return SkData::NewFromMalloc(bufferStart,
bytesInFile);
On 2012/05/21 19:37:10, TomH wrote:
> Does this take care of ownership of the malloc'd buffer?

Yes... I had wondered also, so I have already confirmed that the unref() calls
around line 695 actually do call sk_free() on the buffer.

Thanks for noting this!
Sign in to reply to this message.

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