Add comment about template being convex

This commit is contained in:
Chris Greening 2022-10-09 20:58:23 +01:00
parent aa9e328944
commit 6eff5bcc3a

View file

@ -106,6 +106,7 @@
"outputs": [], "outputs": [],
"source": [ "source": [
"# templates must be simetric around the X axis and must include the center points on both size (e.g. (X1, 0).... (X2, 0) )\n", "# templates must be simetric around the X axis and must include the center points on both size (e.g. (X1, 0).... (X2, 0) )\n",
"# template must also be convex\n",
"template = [\n", "template = [\n",
" (-0.6, 0),\n", " (-0.6, 0),\n",
" (-0.6, -0.6),\n", " (-0.6, -0.6),\n",
@ -168,6 +169,7 @@
" point2, point1, point2, spacing, (template_index + 1) // template_length\n", " point2, point1, point2, spacing, (template_index + 1) // template_length\n",
" )\n", " )\n",
" # add an intermediate point which is the intersection of this new line with the previous line (if there is one)\n", " # add an intermediate point which is the intersection of this new line with the previous line (if there is one)\n",
" # this prevents any cutting of corners\n",
" if len(coil_points) >= 2:\n", " if len(coil_points) >= 2:\n",
" # create a line from the previous two points\n", " # create a line from the previous two points\n",
" line1 = Line(\n", " line1 = Line(\n",