[pstricks] Drawing in 3D

Herbert Voss Herbert.Voss at alumni.TU-Berlin.DE
Thu Sep 30 14:36:39 CEST 2004


Alan Ristow wrote:

> In the code example below, I have drawn two diagrams of an annular blade
> slicing through a cylindrical object (an annular blade is shaped like an
> "O" and has its sharp edge on the inside of the "O"). I need to fill the
> area between the circles so it actually looks like a blade. In the
> second diagram, I have used two cylinder primitives to make it appear as
> though the blade is cutting through the cylinder.
> 
> Is this the most appropriate way to make a drawing such as this? I get
> the impression that I am stretching the limits of 3D drawing with
> PSTricks here....

I do not know if I understand your problem well ...


Herbert



\documentclass{article}%
\usepackage{pstricks}%  >= version 1.04
\usepackage{pst-vue3d}%
\pagestyle{empty}%

\begin{document}
   \psset{THETA=30,PHI=0,normaleLongitude=0,normaleLatitude=0,RotY=90}%

% In this pspicture, the cylinder is centered inside the "blade".

\begin{pspicture}(0,0)(10,5)
 
\CylindreThreeD[fillstyle=solid,fillcolor=gray,linestyle=none](0,0,0){5}{20}%
   \pscustom[fillstyle=eofill,fillcolor=lightgray]{%
     \CircleThreeD(19,0,0){7}%
     \CircleThreeD(19,0,0){12}%
   }
\end{pspicture}

% In this pspicture, the "blade" should look like it is cutting into
% the cylinder.

\begin{pspicture}(0,0)(10,5)
 
\CylindreThreeD[fillstyle=solid,fillcolor=gray,linestyle=none](0,0,0){5}{19}%
   \pscustom[fillstyle=eofill,fillcolor=lightgray]{%
     \CircleThreeD(19,0,-4){7}%
     \CircleThreeD(19,0,-4){12}%
   }
 
\CylindreThreeD[fillstyle=solid,fillcolor=gray,linestyle=none](19,0,0){5}{1}%
\end{pspicture}
\end{document}



-- 
http://TeXnik.de/
http://PSTricks.de/
ftp://ftp.dante.de/tex-archive/info/math/voss/Voss-Mathmode.pdf
http://www.dante.de/faq/de-tex-faq/
http://www.tex.ac.uk/cgi-bin/texfaq2html?introduction=yes




More information about the PSTricks mailing list