Mise à jour de la version utilisant le moteur tikz
[delaunay.git] / test / delaunay.tex
index 5b98391..adb9525 100644 (file)
@@ -7,15 +7,21 @@
 \pagestyle{empty}
 \begin{document}
 
+
+\section{MetaPost}
+
 \buildMeshBW[print=points,  meshpoint = I, color=red]{(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(3,1);(6,1.5)}
 
 %\buildMeshBW[tikz, bbox = show]{(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(3,1);(6,1.5)}
 
 \buildMeshBW[mode=ext,bbox = show, color=red,colorBbox = blue]{mesh.txt}
 
+\tracePointsMesh[mode=ext,bbox = show, color=red,print=points]{mesh.txt}
+
+\tracePointsMesh[mode=ext,bbox = show, color=red]{mesh.txt}
+
 
-\buildMeshBWinc[mode=ext,bbox = show, color=red,colorBbox =
-blue]{mesh.txt}{%
+\buildMeshBWinc[mode=ext,bbox = show, color=red,colorBbox = blue]{mesh.txt}{%
   beginfig(0);
 }%
 {%
@@ -31,13 +37,13 @@ colorCircle = green!70,
 scale=0.6cm]
 {(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(6,4)}{(3,1)}
 \meshAddPointBW[
-color = green,
-meshpoint = x,
-colorBack=red!10,
-colorNew = green!20!red,
-scale=0.6cm,
-step=cavity]
-{(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(6,4)}{(3,1)}
+ color = green,
+ meshpoint = x,
+ colorBack=red!10,
+ colorNew = green!20!red,
+ scale=0.6cm,
+ step=cavity]
+ {(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(6,4)}{(3,1)}
 \meshAddPointBW[
 meshpoint = x,
 colorBack=red!10,
@@ -75,9 +81,62 @@ colorBbox = blue!20,
 beginfig(0);
 }%
 {%
-  draw (-1,-1)*u--(8.5,-1)*u--(8.5,6)*u--(-1,6)*u--cycle;
+  draw (-1,-1)*u--(8.5,-1)*u--(8.5,6)*u--(-1,6)*u--cycle withcolor \mpcolor{red};
 endfig;
 }
 
 
+\section{tikz}
+
+\buildMeshBW[tikz,print=points,  meshpoint = I,
+color=red]{(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(3,1);(6,1.5)}
+
+\buildMeshBW[tikz,mode=ext, color=red]{mesh.txt}
+
+\tracePointsMesh[tikz,mode=ext,bbox = show,
+color=red,print=points]{mesh.txt}
+\tracePointsMesh[tikz,mode=ext,bbox = show, color=red]{mesh.txt}
+
+\buildMeshBWinc[tikz,mode=ext,bbox = show, colorBbox = blue]{mesh.txt}{%
+}%
+{%
+  \draw[color = red] (0,0) -- (3,3);
+}
+
+\meshAddPointBW[
+tikz,
+color = green,
+meshpoint = x,
+colorBack=red!10,
+colorNew = green!20!red,
+scale=0.6cm,
+step=cavity]
+{(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(6,4)}{(3,1)}
+
+\meshAddPointBWinc[
+tikz,
+meshpoint = x,
+colorBack=red!10,
+colorNew = green!20!red,
+scale=0.6cm,
+step=badtriangles,
+newpoint = y,
+bbox = show,
+colorBbox = blue!20,
+]{(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(6,4)}{(3,1)}
+{}{\draw[color=green] (0,0) -- (3,3);}
+
+\meshAddPointBW[
+tikz,
+meshpoint = x,
+colorBack=red!10,
+colorNew = green!20!red,
+scale=0.6cm,
+step=badtriangles,
+newpoint = y,
+bbox = show,
+colorBbox = black
+]
+{(0,0);(3.5,3);(7,0);(7.5,5);(1.61,3.14);(6,4)}{(3,1)}
+
 \end{document}

Licence Creative Commons Les fichiers de Syracuse sont mis à disposition (sauf mention contraire) selon les termes de la
Licence Creative Commons Attribution - Pas d’Utilisation Commerciale - Partage dans les Mêmes Conditions 4.0 International.