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

Issue 6300086: Fix the problem of rendering closePath not properly after a moveTo call in (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
12 years, 6 months ago by Stephen Chenney
Modified:
12 years, 6 months ago
Reviewers:
yunchao.he, bsalomon, reed1
CC:
skia-review_googlegroups.com
Base URL:
http://skia.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Fix the problem of rendering closePath not properly after a moveTo call in canvas 2D interface. If there is a polyline, followed by a moveTo and a closePath, both the moveTo and the closePath should be ignored for the purposes of drawing, and the polyline should not be closed (unless force closed is true (for filling, for instance). Tested for path with both valid and degenerate content, when asked to consume degenerates and not, force closed and not. This patch also includes a uni test refactoring to reduce the amount of code to test path iteration and zero length paths. BUG=6297049 TEST=tests/PathTest.cpp, testIter method. Committed: https://code.google.com/p/skia/source/detail?r=4247

Patch Set 1 #

Patch Set 2 : #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+142 lines, -276 lines) Patch
M src/core/SkPath.cpp View 1 1 chunk +3 lines, -3 lines 2 comments Download
M tests/PathTest.cpp View 1 2 chunks +139 lines, -273 lines 0 comments Download

Messages

Total messages: 10
reed1
Is there a more compact, data-drive way to structure the unit-tests? That is a huge ...
12 years, 6 months ago (2012-06-12 14:31:20 UTC) #1
Stephen Chenney
On 2012/06/12 14:31:20, reed1 wrote: > Is there a more compact, data-drive way to structure ...
12 years, 6 months ago (2012-06-12 14:34:25 UTC) #2
Stephen Chenney
12 years, 6 months ago (2012-06-13 15:56:08 UTC) #3
reed1
much more gooder. Would some local macros help condense those long lines? e.g. #define M ...
12 years, 6 months ago (2012-06-13 16:09:04 UTC) #4
reed1
can we restore the { } braces? https://codereview.appspot.com/6300086/diff/3001/src/core/SkPath.cpp File src/core/SkPath.cpp (right): https://codereview.appspot.com/6300086/diff/3001/src/core/SkPath.cpp#newcode1489 src/core/SkPath.cpp:1489: // follows ...
12 years, 6 months ago (2012-06-13 16:09:43 UTC) #5
Stephen Chenney
I'll leave the test as it is for now. Things are confusing enough as it ...
12 years, 6 months ago (2012-06-13 16:24:06 UTC) #6
Stephen Chenney
Committed revision 4247.
12 years, 6 months ago (2012-06-13 17:06:14 UTC) #7
yunchao.he
On 2012/06/13 17:06:14, Stephen Chenney wrote: > Committed revision 4247. Hi, stephen, I thought you ...
12 years, 6 months ago (2012-06-14 02:54:33 UTC) #8
yunchao.he
On 2012/06/14 02:54:33, yunchao.he wrote: > On 2012/06/13 17:06:14, Stephen Chenney wrote: > > Committed ...
12 years, 6 months ago (2012-06-14 08:28:49 UTC) #9
Stephen Chenney
12 years, 6 months ago (2012-06-14 15:12:25 UTC) #10
On 2012/06/14 08:28:49, yunchao.he wrote:
> On 2012/06/14 02:54:33, yunchao.he wrote:
> > On 2012/06/13 17:06:14, Stephen Chenney wrote:
> > > Committed revision 4247.
> > 
> > Hi, stephen, I thought you are a committer, then I CC to you in skia
> community.
> > But you commit a new patch as your own according to the
> > problem I state clearly, and exactly the code location I provide, even you
> code
> > are exactly the same meaning as mine--just simplified my code. As a
committer,
> > It is the right way? I am a new comer, don't know the way it is.
> > 
> > If you are not a committer, it is my fault.
> 
> I wonder whether I didn't write test case, I found that you wrote a test case
> for it, in addition to simplified my code.

Hi Yunchao, sorry I didn't originally add you as a reviewer on this patch. It
was oversight on my part. I should also have added your name in the Changelog.
My apologies.

You did the right thing in initially investigating and proposing a patch. I
grabbed it because the testing was quite complicated and needed to cover all of
the ways in which the path iterator can be used. That testing led to the code
changes I made.
Sign in to reply to this message.

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