diff options
Diffstat (limited to 'Master/texmf-dist/doc/generic/pst-perspective/pst-perspective-docEN.tex')
-rw-r--r-- | Master/texmf-dist/doc/generic/pst-perspective/pst-perspective-docEN.tex | 141 |
1 files changed, 85 insertions, 56 deletions
diff --git a/Master/texmf-dist/doc/generic/pst-perspective/pst-perspective-docEN.tex b/Master/texmf-dist/doc/generic/pst-perspective/pst-perspective-docEN.tex index c279a888f6e..23895c58c54 100644 --- a/Master/texmf-dist/doc/generic/pst-perspective/pst-perspective-docEN.tex +++ b/Master/texmf-dist/doc/generic/pst-perspective/pst-perspective-docEN.tex @@ -4,11 +4,12 @@ smallheadings, headexclude,footexclude,oneside]{pst-doc} \usepackage[utf8]{inputenc} \usepackage[dvipsnames]{xcolor} %% Farben sind im Dokument xcolor.pdf definiert -\usepackage{multido,pst-grad,pst-eucl,pstricks-add} +\usepackage{multido,pst-grad,pst-eucl,pst-3dplot,pstricks-add} \usepackage{pst-perspective} -\lstset{language=PSTricks,morekeywords={pstransTSK,pstransTSX,pstransTS,pstMarkAngle,psIntersectionPoint}} +\lstset{language=PSTricks,morekeywords={pstransTSK,pstransTSX,pstransTS,pstMarkAngle,psIntersectionPoint,psboxTS}} +\def\fileversion{1.02} \let\pstPerspectiveFV\fileversion \renewcommand\bgImage{\psscalebox{0.85}{% \begin{pspicture}[showgrid=false](0.5,-0.5)(11.5,8.5) @@ -81,12 +82,12 @@ With the macro \Lcs{ThreeDput} from the package \texttt{pst-3d}, only planes and I think that with some of the already existing PSTricks packages a realisation of perspectives in the wanted form could have surely been managed. I couldn't see this however and wanted some simple macros, without loading mighty packages. -To make a long story short: I decided to write a small PSTricks package, that will fit all my needs. This package contains only two small macros, so unwanted crashes with other PSTricks packages are not awaited. +To make a long story short: I decided to write a small PSTricks package, that will fit all my needs. This package contains only four small macros, so unwanted crashes with other PSTricks packages are not awaited. \section{General} -The described macros should help you to easily draw a perspective of a geometrical object like often used is school. +The described macros should help you to easily draw a perspective of a geometrical object like often used in school. There are three macros, the first two called \Lcs{pstransTS} and \Lcs{pstransTSX} are used to draw a perspective of a geometrical object laying in the $x,y$-plane and transforms every vertex. The points first get projected orthogonally to the base line (parameter \Lkeyword{base}), parallel to the $x$-axis, and therefrom they get transformed with an arbitrarily chosen angle measured from the positive $x$-axis (parameter \Lkeyword{phi}) and shortened (multiplied with the shortening factor \Lkeyword{vkf}). You then can use these transformed points with its given node names. It is similar with \Lcs{pstransTSX}, but the difference is, that the points are projected orthogonally onto a base line (Parameter \Lkeyword{base}) parallel to the $y$-axis, and therefrom they get transformed with an arbitrarily chosen angle (parameter \Lkeyword{phi}) and shortened (multiplied with the shortening factor \Lkeyword{vkf}). These two cases correspond to a projection of an object of the drawing plane into the $x$-$y$-plane or $x$-$z$-plane. @@ -696,6 +697,37 @@ A change of the shortening factor leads to the following designs. \end{pspicture} \end{LTXexample} + +\newpage + + +\section{The macro \nxLcs{psboxTS}} +\begin{BDef} +\Lcs{psboxTS}\OptArgs$(x,y,z)$\Largb{\rm{length in }x}\Largb{\rm{width in }y}\Largb{\rm{height in }z}\Largb{\rm{color}} +\end{BDef} + + +With the macro \Lcs{psboxTS} we can easily draw cuboids. For its three coordinates we use the left, bottom vertex in the back and put them in parentheses separated by commas, followed by its length, width and height and last by its color---all these four arguments are put in curly braces. + +With the option \Lkeyset{hideline=true} the hidden lines are shown with the keys \Lkeyset{hidelinewidth=}, \Lkeyset{hidelinestyle=} and \Lkeyset{hidecolor=}. + +This macro and the others as well can be used in combination with the pst-3dplot package with the settings: \Lkeyset{coorType=1}, \Lkeyset{xThreeDunit=vkf} and \Lkeyset{phi = 180 Alpha sub}. + +\begin{LTXexample}[pos=t] +\begin{pspicture}[showgrid=false](-2,-2.5)(6,6) +\psset{xMin=0,yMin=0,zMin=0,xMax=11,yMax=11,zMax=4,Alpha=155,Beta=20,Dx=1,Dy=1,Dz=1,arrowsize=.2,arrowinset=0.1,coorType=1,xThreeDunit=0.5,phi=180 155 sub}% +\pstThreeDPlaneGrid[planeGrid=xy,linewidth=0.3pt,linecolor=gray!70,xsubticks=7,ysubticks=7](0,0)(7,7)% +\pstThreeDPlaneGrid[planeGrid=xz,linewidth=0.3pt,linecolor=gray!70,xsubticks=7,ysubticks=5](0,0)(7,5)% +\pstThreeDPlaneGrid[planeGrid=yz,linewidth=0.3pt,linecolor=gray!70,xsubticks=7,ysubticks=5](0,0)(7,5)% +%-------------------------------------- +\psboxTS(0,2,3){3}{4}{1}{blue} +\psboxTS[hideline=true,dash=2pt 2pt,hidelinewidth=0.5pt](4,0,0){2}{1}{4}{yellow} +\psboxTS[opacity=0.75,hideline=true,hidelinewidth=1.2pt,hidelinestyle=dotted,hidecolor=green,dotsep=1.5pt](3,4,0){4}{2}{1}{brown} +%-------------------------------------- +\end{pspicture} +\end{LTXexample} + + \newpage \section{Examples} @@ -1131,63 +1163,60 @@ A change of the shortening factor leads to the following designs. \end{LTXexample} +\newpage + \begin{LTXexample}[pos=t,wide] \psscalebox{0.6}{% -\begin{pspicture}[showgrid=false](-0.5,0)(17,10.4) -\psset{linejoin=2,phi=80,vkf=0.6} -{\psset{translineK=false}% -\pstransTSK(0,0){1}{A1}{B1} -\pstransTSK(2,0){1}{A2}{B2} -\pstransTSK(2,3){1}{A3}{B3} -\pstransTSK(0,2){1}{A4}{B4} -%---------------------------- -\pstransTSK(0,0){6}{A1}{C1} -\pstransTSK(2,0){6}{A2}{C2} -\pstransTSK(2,3){6}{A3}{C3} -\pstransTSK(0,2){6}{A4}{C4} +\begin{pspicture}[showgrid=false](-2,-2.5)(6,6) +\psset{xMin=0,yMin=0,zMin=0,xMax=11,yMax=11,zMax=4,Alpha=155,Beta=20,Dx=1,Dy=1,Dz=1,arrowsize=.2,arrowinset=0.1,coorType=1,xThreeDunit=0.5,phi=180 155 sub}% +\pstThreeDPlaneGrid[planeGrid=xy,linewidth=0.3pt,linecolor=gray!70,xsubticks=7,ysubticks=7](0,0)(7,7)% +%-------------------------------------- +\multido{\i=0+1}{5}{% +\multido{\n=0+1}{5}{% +\multido{\r=0+1}{2}{% +\psboxTS(\i,\n,\r){1}{1}{1}{blue}}}} +%-------------------------------------- +\multido{\i=0+1}{2}{% +\multido{\n=0+1}{5}{% +\multido{\r=2+1}{3}{% +\psboxTS(\i,\n,\r){1}{1}{1}{blue}}}} +%-------------------------------------- +\multido{\i=2+1}{3}{% +\multido{\n=0+1}{2}{% +\multido{\r=2+1}{3}{% +\psboxTS(\i,\n,\r){1}{1}{1}{blue}}}} +%\pstPlanePut[plane=xy](6,1,0){\fbox{\Huge\red xy plane}} +\end{pspicture} } -\psline[linestyle=dashed](C1)(C4) -\psline[linestyle=dashed](B1)(C1)(C2) -\pspolygon[fillstyle=solid,fillcolor=green!30,opacity=0.7](B1)(B2)(B3)(B4) -\pspolygon[fillstyle=solid,fillcolor=green!30,opacity=0.7](B2)(C2)(C3)(B3) -\pspolygon[fillstyle=vlines*,fillcolor=BrickRed,opacity=0.7,hatchangle=120,hatchsep=1.5pt](B4)(B3)(C3)(C4) -%---------------------------- -\pstransTSK(2,0){6}{A5}{C5} -\pstransTSK(6,0){6}{A6}{C6} -\pstransTSK(6,4){6}{A7}{C7} -\pstransTSK(4,6){6}{A8}{C8} -\pstransTSK(2,4){6}{A9}{C9} -%---------------------------- -\pspolygon[fillstyle=solid,fillcolor=yellow!50,opacity=0.2](C5)(C6)(C7)(C9) -\pspolygon[fillstyle=solid,fillcolor=yellow!50,opacity=0.2](C7)(C8)(C9) -\pspolygon[fillstyle=solid,fillcolor=yellow!50,opacity=0.7](A5)(A6)(A7)(A9) -\pspolygon[fillstyle=solid,fillcolor=yellow!50,opacity=0.7](A7)(A8)(A9) -\pspolygon[fillstyle=solid,fillcolor=yellow!50,opacity=0.7](A6)(C6)(C7)(A7) -\pspolygon[fillstyle=vlines*,fillcolor=BrickRed,opacity=0.7,hatchangle=45,hatchsep=1.5pt](A7)(C7)(C8)(A8) -\pspolygon[fillstyle=vlines*,fillcolor=BrickRed,opacity=0.7,hatchangle=135,hatchsep=1.5pt](A9)(A8)(C8)(C9) -%---------------------------- -\pstransTSK(6,0){2}{A10}{C10} -\pstransTSK(8,0){2}{A11}{C11} -\pstransTSK(8,8){2}{A12}{C12} -\pstransTSK(6,8){2}{A13}{C13} -\pstransTSK(8.2,8){-0.2}{A14}{B14} -\pstransTSK(5.8,8){-0.2}{A15}{B15} -\pstransTSK(8.2,8){2.2}{A14}{C14} -\pstransTSK(5.8,8){2.2}{A15}{C15} -\pstransTSK[translineK=false](8,10){2}{A16}{C16} -\pstransTSK[translineK=false](6,10){2}{A17}{C17} -\psIntersectionPoint(A16)(C17)(A17)(C16){SB1} -%---------------------------- -\pspolygon[fillstyle=solid,fillcolor=cyan!50,opacity=0.2](C10)(C11)(C12)(C13) -\pspolygon[fillstyle=solid,fillcolor=cyan!50,opacity=0.7](A10)(A11)(A12)(A13) -\pspolygon[fillstyle=solid,fillcolor=cyan!50,opacity=0.7](A11)(C11)(C12)(A12) -\pspolygon[fillstyle=vlines*,fillcolor=BrickRed,opacity=0.2,hatchangle=45,hatchsep=1.5pt](C14)(C15)(SB1) -\pspolygon[fillstyle=vlines*,fillcolor=BrickRed,opacity=0.2,hatchangle=45,hatchsep=1.5pt](B15)(C15)(SB1) -\pspolygon[fillstyle=vlines*,fillcolor=BrickRed,opacity=0.7,hatchangle=45,hatchsep=1.5pt](B14)(B15)(SB1) -\pspolygon[fillstyle=vlines*,fillcolor=BrickRed,opacity=0.7,hatchangle=45,hatchsep=1.5pt](B14)(C14)(SB1) -\end{pspicture}} \end{LTXexample} +\newpage + +\begin{LTXexample}[pos=t,wide] +\psscalebox{0.6}{% +\begin{pspicture}[showgrid=false](-2,-2.5)(6,6) +\psset{xMin=0,yMin=0,zMin=0,xMax=11,yMax=11,zMax=4,Alpha=135,Beta=20,Dx=1,Dy=1,Dz=1,arrowsize=.2,arrowinset=0.1,coorType=1,xThreeDunit=0.5,opacity=0.4,hideline=true}%\ +\pstThreeDPlaneGrid[planeGrid=xy,linewidth=0.3pt,linecolor=gray!70,xsubticks=7,ysubticks=7](0,0)(7,7)% +%-------------------------------------- +\multido{\i=0+1}{6}{% +\multido{\n=0+1}{6}{% +\multido{\r=0+1}{2}{% +\psboxTS(\i,\n,\r){1}{1}{1}{green}}}} +%-------------------------------------- +\multido{\i=1+1}{4}{% +\multido{\n=1+1}{4}{% +\multido{\r=2+1}{2}{% +\psboxTS(\i,\n,\r){1}{1}{1}{green}}}} +%-------------------------------------- +\multido{\i=2+1}{2}{% +\multido{\n=2+1}{2}{% +\multido{\r=4+1}{2}{% +\psboxTS(\i,\n,\r){1}{1}{1}{green}}}} +\end{pspicture} +} +\end{LTXexample} + +\newpage \pstVerb{/radiusT 2 22.5 cos mul def} \pstVerb{/deltaDach 10 2 22.5 sin mul sub def} |