html - Generating arcs with SVG paths -


using following, perfect semi circle specified start , end points;

<path      d="m100,100 l100,200         a50,50 0 1, 1 100,100             "      stroke="black" stroke-width="2" fill="none" /> 

if circle complete, have x , y radius 50 (as specified first argument of part of path) centred on arc start point 100,200 , end point 100,100.

if update path following;

<path      d="m100,100 l100,150         a50,50 0 1, 1 100,100             "      stroke="black" stroke-width="2" fill="none" /> 

i see circle 'spill' out left of line.

assumption: because distance between start , end point of arc less required 100px (diameter), centre point of circle calculated away line drawn between start , end of arc, , further equidistant these 2 points. therefore specified 50 radius acting minimum radius , not 'scaled down' if distance between start , end point less 2 * radius.

if update path following;

<path      d="m100,100 l100,400         a50,50 0 1, 1 100,100             "      stroke="black" stroke-width="2" fill="none" /> 

if arc part of circle, again (as per first arc setup) it's centred on line time x , y radius's have magnified accommodate additional distance between defined start , end points.

assumption: whilst 50px radius acts minimum, not act maximum , in fact scaled if width between start , end points > 100 (diameter).

are of assumptions correct or off mark?


Comments

Popular posts from this blog

Java 3D LWJGL collision -

spring - SubProtocolWebSocketHandler - No handlers -

methods - python can't use function in submodule -