[pstricks] colors

Manuel Luque mluque5130 at aol.com
Fri Sep 19 20:49:52 CEST 2014


 

 

Dear Cyrille, 

the explanation is in the documentation : 7.6. Construction from scratch

The object new constructs a solid. Two parameters are used: sommets which indicates the list of
coordinates of the different vertices, and faces which gives the list of faces of the solid; a face is
characterized by a list of the indices of its vertices, listed in counterclockwise order when the face is
viewed from the exterior of the solid.

\begin{center}
\begin{pspicture}(-3,-3)(3,3)
\psset{unit=1cm,viewpoint=100 -30 20 rtp2xyz,Decran=200}
\axesIIID[axisnames={x_1,x_2,x_3}](1,1,1)(2.5,2.5,2.5)
\psSolid[object=new, action=draw*,fillcolor=cyan,
  incolor=red,show=all,num=all,linecolor=blue,
sommets=
0 0 0
0 0 2
0 2 0
2 0 0
0 2 2
2 0 2
2 2 0
2 2 2,
faces={
[0 1 4 2]
[0 3 5 1]
[3 0 2 6]
%[3 5 7 6]
[3 6 7 5]
%[6 7 4 2]
[2 4 7 6]
%[1 4 7 5]
[1 5 7 4]
}]%
\end{pspicture}
\end{center}

Best regards,

Manuel

 

-----E-mail d'origine-----
De : cyrille piatecki <cyrille.piatecki at univ-orleans.fr>
A: pstricks <pstricks at tug.org>
Envoyé le : Ve, 19 Sep 2014 16:28
Sujet : [pstricks] colors


What is my mistake since I have no color for my cube

%&latex
\documentclass[12pt]{extarticle}
\usepackage{pstricks,pst-solides3d,pstricks-add}

\begin{document}

\mbox{}
\vspace{5cm}

\begin{center}
\begin{pspicture}(-3,-3)(3,3)
%\psgrid
\psset{unit=1cm,viewpoint=90 60 40,Decran=200,fillcolor=cyan}
\axesIIID[axisnames={x_1,x_2,x_3}](1,1,1)(2.5,2.5,2.5)
\psSolid[object=new, action=draw,fillcolor=cyan,
  incolor=red,show=all,num=all,mode=1,linecolor=blue,
sommets=
0 0 0
0 0 2
0 2 0
2 0 0
0 2 2
2 0 2
2 2 0
2 2 2,
faces={
[0 1 4 2]
[0 3 5 1]
[3 0 2 6]
[3 5 7 6]
[6 7 4 2]
[1 4 7 5]
}]%
\end{pspicture}
\end{center}

\end{document}


Thanks
_______________________________________________
PSTricks mailing list
PSTricks at tug.org
http://tug.org/mailman/listinfo/pstricks
archive: http://www.tug.org/pipermail/pstricks/

 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/pstricks/attachments/20140919/0fa97f75/attachment.html>


More information about the PSTricks mailing list