Retour

cylindre_08.tex

Télécharger le fichier Fichier PDF
Image PNG
\documentclass{article}
\usepackage[dvipsnames,svgnames]{pstricks}
\usepackage{pst-solides3d}
\begin{document}
\pagestyle{empty}
 
%% Auteur : Manuel Luque
%%
%% ATTENTION : nécessite DEUX VISUALISATIONS du fichier .ps
%% soit : 
%% 1 compilation LaTeX, 1 visualisation du .ps, une compilation LaTeX 
%% puis une nouvelle visualisation
\psset{unit=2}
\begin{pspicture}(-4,-3)(4,3)
\psframe(-4,-3)(4,3)
\psset{lightsrc=viewpoint,SphericalCoor,viewpoint=100 -13 10,Decran=50}
\psset{solidmemory}
\IfFileExists{crosshollow2-sommets.dat}{%
\psSolid[object=datfile,deactivatecolor,
        file=crosshollow2]%
}{
\psSolid[object=datfile,
        file=cylindrebiseau,rm=0 68,hollow,
        incolor=yellow!50,fillcolor=green!50,
        action=none,name=cylindrebiseau1]
\psSolid[object=datfile,RotZ=90,rm=0 68,hollow,
        incolor=yellow!50,fillcolor=green!50,
        file=cylindrebiseau,name=cylindrebiseau2,action=none]
\psSolid[object=datfile,RotZ=180,rm=0 68,hollow,
        incolor=yellow!50,fillcolor=green!50,
        file=cylindrebiseau,name=cylindrebiseau3,action=none]
\psSolid[object=datfile,RotZ=270,rm=0 68,hollow,
        incolor=yellow!50,fillcolor=green!50,
        file=cylindrebiseau,name=cylindrebiseau4,action=none]
\psSolid[object=fusion,
        base=cylindrebiseau1 cylindrebiseau2
        cylindrebiseau3 cylindrebiseau4,
        action=writesolid,file=crosshollow2]
\psSolid[object=datfile,deactivatecolor,
        file=crosshollow2]
}
\composeSolid
\end{pspicture}
\end{document}