Intersection Points

Hi-

In reading the newest draft of the 1.2 Spec, I noticed that intersections
are required in several sections, such as "10.1.2 Alpha compositing" and
various Vector Effects, such as veJoin, veUnion, veIntersect, and veExclude.
These look really great.

Since the math is being done in the viewer anyway, I think that the results
of this functionality should be exposed in the interface. It would be great
to have access to the vector math functions, since it could help with some
of the heavy-duty math that's hard to do in JavaScript, but that's probably
a bit much to ask.

In addition to getIntersectionList and getEnclosureList, which only return
the intersecting elements, I would very much like to get the points of
intersection as a list of SVGPoints. Something like:

getIntersectionPoints(element, referenceElement)
This method returns a dom::SVGPointList. The element parameter is of type
SVGElement.  The referenceElement parameter is of type SVGElement.

Use cases:
    Math apps - this would help with many visual tutorials and similar
math-related apps.
    CAD - precision intersections of machinery and walls.
    GIS - intersections of street, rivers, and other map features.

Again, since a conformant viewer already needs to have this functionality, I
think that there would be very little additional cost in exposing the
results in the interface. I think that this is something that could easily
be done in SVG1.2.

Regards-
-Doug

Received on Sunday, 14 March 2004 16:28:32 UTC