diff options
author | Karl Berry <karl@freefriends.org> | 2009-01-14 00:42:36 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-01-14 00:42:36 +0000 |
commit | 646227dfa8135f57fbdaf259d889b55065bb763a (patch) | |
tree | 985c56dc267f654b7a84c83b774989a45d1257bc /Master/texmf-dist/dvips/pst-solides3d/solides.pro | |
parent | a1bced89d26fce38304a5f035d000839f561d258 (diff) |
pst-solides3d update (12jan09)
git-svn-id: svn://tug.org/texlive/trunk@11864 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/dvips/pst-solides3d/solides.pro')
-rw-r--r-- | Master/texmf-dist/dvips/pst-solides3d/solides.pro | 98 |
1 files changed, 76 insertions, 22 deletions
diff --git a/Master/texmf-dist/dvips/pst-solides3d/solides.pro b/Master/texmf-dist/dvips/pst-solides3d/solides.pro index 7e410935f83..a6c1c06c3e1 100644 --- a/Master/texmf-dist/dvips/pst-solides3d/solides.pro +++ b/Master/texmf-dist/dvips/pst-solides3d/solides.pro @@ -1,6 +1,6 @@ %! % PostScript prologue for pst-solides3d.tex. -% Version 4.09, 2008/07/23 +% Version 4.13, 2008/10/30 % %% COPYRIGHT 2008 by Jean-Paul Vignault %% @@ -3356,6 +3356,57 @@ end %%%% geometrie 3d (calculs) %%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%%%%% ### p3dtoplane ### +%% syntaxe : x y z P p3dtoplan --> X Y +/p3dtoplane { +5 dict begin + /leplan exch def + /M defpoint3d + leplan plangetbase 0 getp3d /U defpoint3d + leplan plangetbase 1 getp3d /V defpoint3d + leplan plangetorigine /I defpoint3d + I M vecteur3d U scalprod3d + I M vecteur3d V scalprod3d +end +} def + +%%%%% ### pplaneto3d ### +%% syntaxe : x y P pplaneto3d --> X Y Z +/pplaneto3d { +6 dict begin + /leplan exch def + /y exch def + /x exch def + leplan plangetbase 0 getp3d /U defpoint3d + leplan plangetbase 1 getp3d /V defpoint3d + leplan plangetorigine /I defpoint3d + U x mulv3d + V y mulv3d addv3d + I addv3d +end +} def + +%%%%% ### orthoprojplane3d ### +%% Projection orthogonale d'un point 3d sur un plan +%% Mx My Mz (=le point a projeter) +%% Ax Ay Az (=un point du plan) +%% Vx Vy Vz (un vecteur normal au plan) +/orthoprojplane3d { +4 dict begin + dup isplan { + /monplan exch def + monplan plangetorigine + monplan plangetbase aload pop vectprod3d + } if + /V defpoint3d + /A defpoint3d + /M defpoint3d + /VN {V unitaire3d} def + VN M A vecteur3d VN scalprod3d mulv3d + M addv3d +end +} def + %%%%% ### sortp3d ### /sortp3d { 6 dict begin @@ -6230,7 +6281,7 @@ end end } def -%% syntaxe : plantype getbase --> [u v w] +%% syntaxe : plantype getbase --> [u v] %% ou u, v et w vecteurs de R^3 /plangetbase { 1 dict begin @@ -8854,6 +8905,7 @@ end a b neg c neg %% 7 ] def S F generesolid +end } def %%%%% ### newcylindre ### @@ -10184,7 +10236,9 @@ end dup solidinhue solidputinhuecolors } if } ifelse - } if + } { + /activationgestioncouleurs true def + } ifelse 0 1 fcol length 2 idiv 1 sub { /i exch def @@ -10637,8 +10691,8 @@ gsave linecolor linestyle tx@Dict /solidname known { - texte args definition cvx exec - solidname cvlit exch defpoint3d + args definition cvx exec + solidname cvlit defpoint3d tx@Dict /solidname undef } if args definition cvx exec newvecteur @@ -10814,7 +10868,7 @@ gsave } if texte args definition cvx exec pos (text3d) append cvx exec tx@Dict /solidname known { - texte args definition cvx exec + args definition cvx exec solidname cvlit defpoint3d tx@Dict /solidname undef } if @@ -11046,14 +11100,14 @@ end proj-action (none) eqstring not { l@pl@n plangetrange aload pop setyrange setxrange - newpath - xmin ymin l@pl@n pointplan smoveto - xmin ymax l@pl@n pointplan slineto - xmax ymax l@pl@n pointplan slineto - xmax ymin l@pl@n pointplan slineto - xmin ymin l@pl@n pointplan slineto - planprojpst projpath - clip +%% newpath +%% xmin ymin l@pl@n pointplan smoveto +%% xmin ymax l@pl@n pointplan slineto +%% xmax ymax l@pl@n pointplan slineto +%% xmax ymin l@pl@n pointplan slineto +%% xmin ymin l@pl@n pointplan slineto +%% planprojpst projpath +%% clip solidlinewidth setlinewidth linestyle linecolor @@ -11068,14 +11122,14 @@ end proj-action (none) eqstring not { l@pl@n plangetrange aload pop setyrange setxrange - newpath - xmin ymin l@pl@n pointplan smoveto - xmin ymax l@pl@n pointplan slineto - xmax ymax l@pl@n pointplan slineto - xmax ymin l@pl@n pointplan slineto - xmin ymin l@pl@n pointplan slineto - planprojpst projpath - clip +%% newpath +%% xmin ymin l@pl@n pointplan smoveto +%% xmin ymax l@pl@n pointplan slineto +%% xmax ymax l@pl@n pointplan slineto +%% xmax ymin l@pl@n pointplan slineto +%% xmin ymin l@pl@n pointplan slineto +%% planprojpst projpath +%% clip planprojpst bprojscene solidlinewidth setlinewidth linestyle |