summaryrefslogtreecommitdiff
path: root/graphics/asymptote/examples
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-11-07 03:01:39 +0000
committerNorbert Preining <norbert@preining.info>2019-11-07 03:01:39 +0000
commit2e1d63b8ed8c6b7c6d206bfe9e2712797108e8bd (patch)
tree7ea198b043998590117b2730e9dec10327ef3da3 /graphics/asymptote/examples
parent590fd8b560523cdaea19c59aea61e781138e87f8 (diff)
CTAN sync 201911070301
Diffstat (limited to 'graphics/asymptote/examples')
-rw-r--r--graphics/asymptote/examples/orthocenter.asy4
-rw-r--r--graphics/asymptote/examples/transparentCubes.asy15
2 files changed, 17 insertions, 2 deletions
diff --git a/graphics/asymptote/examples/orthocenter.asy b/graphics/asymptote/examples/orthocenter.asy
index 8470de7fdd..a7caaf1412 100644
--- a/graphics/asymptote/examples/orthocenter.asy
+++ b/graphics/asymptote/examples/orthocenter.asy
@@ -3,7 +3,7 @@ import math;
size(7cm,0);
-asy(nativeformat(),"examples/Pythagoras");
+if(!settings.xasy && settings.outformat != "svg") settings.tex="pdflatex";
real theta=degrees(asin(0.5/sqrt(7)));
@@ -37,4 +37,4 @@ dot("$A'$",Ap,dir(A--Ap),red);
dot("$B'$",Bp,dir(B--Bp),red);
dot("$C'$",Cp,dir(C--Cp),red);
-label(graphic(outdirectory()+"Pythagoras","width=2.5cm"),Ap,5ENE);
+label(graphic("piicon.png","width=2.5cm, bb=0 0 147 144"),Ap,5ENE);
diff --git a/graphics/asymptote/examples/transparentCubes.asy b/graphics/asymptote/examples/transparentCubes.asy
new file mode 100644
index 0000000000..ceead22199
--- /dev/null
+++ b/graphics/asymptote/examples/transparentCubes.asy
@@ -0,0 +1,15 @@
+import three;
+
+size(100,100);
+currentprojection=perspective(10,7,40);
+
+int N=4;
+real f=1+1/N;
+
+for(int k=0; k < N; ++k) {
+ for(int m=0; m < N; ++m) {
+ for(int n=0; n < N; ++n) {
+ draw(shift((n,m,k)*f)*unitcube,red+opacity(0.5));
+ }
+ }
+}