\documentclass{article}
\usepackage{pst-solides3d,pst-node,multido}
\usepackage[latin1]{inputenc}
\usepackage[T1]{fontenc}

\makeatletter
\def\psPoint{\def\pst@par{}\pst@object{psPoint}}
\def\psPoint@i(#1)#2{{% coordonnées cartésiennes
  \begin@ClosedObj
\pnode(!
    \tx@optionssolides
    SolidesDict begin
    #1
   3dto2d cm_1 exch cm_1 exch
   end){#2}%
   \end@ClosedObj
  }\ignorespaces%
}
\makeatother
\def\grille{% quadrillage du plan Oxy
\multido{\ix=-5+1}{11}{%
    \psPoint(\ix\space -5 0){A}
    \psPoint(\ix\space 5 0){B}
    \psline(A)(B)}
\multido{\iy=-5+1}{11}{%
    \psPoint(-5 \iy\space 0){A}
    \psPoint(5 \iy\space 0){B}
    \psline(A)(B)}
    \psPoint(0 0 0){O}
    \psPoint(5 0 0){X}
    \psPoint(0 5 0){Y}
    \psPoint(0 0 8){Z}
    \psline[arrowsize=0.3,arrowinset=0.2,linecolor=blue]{->}(O)(X)
    \psline[arrowsize=0.3,arrowinset=0.2,linecolor=blue]{->}(O)(Y)
    \psline[arrowsize=0.3,arrowinset=0.2,linecolor=blue]{->}(O)(Z)
    \uput[r](X){\textcolor{blue}{$x$}}\uput[u](Y){\textcolor{blue}{$y$}}%
    \uput[r](Z){\textcolor{blue}{$z$}}\uput[u](O){\textcolor{blue}{$O$}}}
\pagestyle{empty}
\date{8 octobre 2\,006}
\author{JPV \& ML}
\title{tests}

\begin{document}
\maketitle


\begin{center}

\psset{lightsrc=1e3 5 20,SphericalCoor=true,viewpoint=50 20 10,Decran=50}
\begin{pspicture}(-6,-2)(6,8)
\psframe(-6,-2)(6,8)
\grille
\codejps{
% solide 1
    0 1.5 6 newcylindre
    dup (jaune) outputcolors
% solide 2
    4 3 2 newcylindricalring
   {0 0 1 translatepoint3d} solidtransform
    dup (orange) outputcolors
% fusion
    solidfuz
    drawsolid**}
\psSolid[object=cube,a=1,color=cyan](0,3.5,2.5)
\end{pspicture}
\end{center}


\end{document}
