W3C home > Mailing lists > Public > www-svg@w3.org > December 2012

Re: SVG2 - suggestion for a new path command to close a subpath smoothly

From: Rik Cabanier <cabanier@gmail.com>
Date: Sun, 2 Dec 2012 21:14:35 -0800
Message-ID: <CAGN7qDCt5qGM0MGQQjxSGmmt=SGO2x7qCRqmN4PiVihsOH0puw@mail.gmail.com>
To: "Dr. Olaf Hoffmann" <Dr.O.Hoffmann@gmx.de>
Cc: www-svg@w3.org
Hi Dr Olaf,

I have a couple of concerns with your proposal.

1. If we go this route, UA's will have to remember the first and last
control point in case this operator is used. This will introduce some
overhead.
2. We are trying to harmonize our path operators with Canvas. If we add
this to SVG, we need to have it in Canvas as well.
3.Beziers have the peculiar property that they can draw even if the start
and end point are the same. So, if the last point coincides with the start
point and you use this new operator, you will see a small oval. This is
most likely not desired.

On Sat, Dec 1, 2012 at 9:01 AM, Dr. Olaf Hoffmann <Dr.O.Hoffmann@gmx.de>wrote:

> Hello,
>
> there was already some discussion about new
> path commands in SVG2 to simplify the work
> of authors.
> I propose to introduce a new path command
> as an extension of the commands S and Z.
>
> This closes a subpath similar to the Z command,
> but not with a straight line. It uses a cubic
> curve like the S command. The first control
> point it determined by the previous point and
> its direction as for the S command.
> The second control point is determined in a
> similar way, but the first point of the subpath
> that has to be closed is used and its direction.
> The resulting effect is, that it is simpler for
> authors to close shapes in a smooth way without
> a corner.
> Today authors have to compute especially the
> second control point manually to get this effect.
> With some knowlegde in analysis (mathematics), this
> is not difficult, but unfortunately it cannot be
> assumed, that all authors have such capabilities.
>
> If information about the direction to determine the
> control points is not available, corresponding rules
> as for S apply (typically with the result, that there
> will be corners again, but to avoid this is usually a
> simple task for authors).
>
>
> Suggestions for naming:
> Because '' (ligature for 'sz') would be only an intuitive
> name for german speaking people, maybe another name
> would be more preferable like 'Y' or 'R'. 'O' would be very
> suggestive, but can be mixed up with '0' (zero). 'B' would be
> another, less suggestive choice, but with less problems as 'O'.
>
>
> Olaf
>
>
>
Received on Monday, 3 December 2012 05:15:10 GMT

This archive was generated by hypermail 2.3.1 : Friday, 8 March 2013 15:54:53 GMT