summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/latex-graphics-companion/4-8-4.ltx
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-05-23 00:23:51 +0000
committerKarl Berry <karl@freefriends.org>2009-05-23 00:23:51 +0000
commita683c3d7e9fac38ec713f23fb6b9d2c7143aea82 (patch)
tree424ab223921f85fd3f167a4ccd0e2d37d05c2927 /Master/texmf-dist/doc/latex/latex-graphics-companion/4-8-4.ltx
parent5beb5368a684995153c8566797ba054f21c666af (diff)
move english latex doc out of texmf-doc
git-svn-id: svn://tug.org/texlive/trunk@13412 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/latex-graphics-companion/4-8-4.ltx')
-rw-r--r--Master/texmf-dist/doc/latex/latex-graphics-companion/4-8-4.ltx60
1 files changed, 60 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/latex-graphics-companion/4-8-4.ltx b/Master/texmf-dist/doc/latex/latex-graphics-companion/4-8-4.ltx
new file mode 100644
index 00000000000..29c3f55d8fb
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/latex-graphics-companion/4-8-4.ltx
@@ -0,0 +1,60 @@
+\documentclass{ppex}
+\nonstopmode
+\usepackage {pstcol,pst-3d}
+\pagestyle{empty}
+
+\begin{document}
+\ResetPreambleCommands
+\ReadyForTheFray
+\usepackage {pstcol,pst-3d}
+\def\CubeSide#1#2#3#4{
+\ThreeDput[normal=#1](#2){
+\psframe*[linecolor=#3](4,4)
+\rput(2,2){\footnotesize#4}}
+}
+\catcode`\<=12
+\catcode`\>=12
+\def\TheCube#1#2{%
+\begin{pspicture}(-9,-7)(9,9)
+\bfseries
+\ifcase #1 \relax
+\or %1
+ \psset{viewpoint=-1 -1 #2}
+ \rput[l](-8,-6){{\normalsize Viewpoint: -1 -1 #2}}
+ \ifnum#2>0\ThreeDput[normal=0 0 1]{\psgrid(-3,-3)(6,6)}\fi
+ \CubeSide{-1 0 0}{0,4,0}{yellow}{FRONT}
+ \CubeSide{0 -1 0}{0,0,0}{blue}{FRONT}
+\or %2
+ \psset{viewpoint=1 -1 #2}
+ \rput[l](-8,-6){{\normalsize Viewpoint: 1 -1 #2}}
+ \ifnum#2>0\ThreeDput[normal=0 0 1]{\psgrid(-3,-3)(6,6)}\fi
+ \CubeSide{0 -1 0}{0,0,0}{blue}{FRONT}
+ \CubeSide{1 0 0}{4,0,0}{white}{BACK}
+\or %3
+ \psset{viewpoint=1 1 #2}
+ \rput[l](-8,-6){{\normalsize Viewpoint: 1 1 #2}}
+ \ifnum#2>0\ThreeDput[normal=0 0 1]{\psgrid(-3,-3)(6,6)}\fi
+ \CubeSide{1 0 0}{4,0,0}{white}{BACK}
+ \CubeSide{0 1 0}{4,4,0}{green}{BACK}
+\or %4
+ \psset{viewpoint=-1 1 #2}
+ \rput[l](-8,-6){{\normalsize Viewpoint: -1 1 #2}}
+ \ifnum#2>0\ThreeDput[normal=0 0 1]{\psgrid(-3,-3)(6,6)}\fi
+ \CubeSide{0 1 0}{4,4,0}{green}{BACK}
+ \CubeSide{-1 0 0}{0,4,0}{yellow}{FRONT}
+\fi
+\ifnum#2<0
+ \CubeSide{0 0 -1}{0,4,0}{magenta}{BOT}
+\else
+ \CubeSide{0 0 1}{0,0,4}{red}{TOP}
+\fi
+\end{pspicture}
+}
+\psset{unit=.3cm,subgriddiv=0}
+\begin{tabular}{cc}
+\TheCube{1}{1}&
+\TheCube{2}{1}\\[-10pt]
+\TheCube{3}{1}&
+\TheCube{4}{1}\\
+\end{tabular}
+\end{document}