summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/dvips
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-10-28 21:07:41 +0000
committerKarl Berry <karl@freefriends.org>2018-10-28 21:07:41 +0000
commitbc9c08f557acfd4ea175640b453d93e803b6c73e (patch)
tree50722f01df24b0ffa1372662d26c9f39a379a54f /Master/texmf-dist/dvips
parentbf3f53c013740ce1d4544104167f312ec3ea11d9 (diff)
pst-moire (28oct18)
git-svn-id: svn://tug.org/texlive/trunk@49014 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/dvips')
-rw-r--r--Master/texmf-dist/dvips/pst-moire/pst-moire.pro259
1 files changed, 259 insertions, 0 deletions
diff --git a/Master/texmf-dist/dvips/pst-moire/pst-moire.pro b/Master/texmf-dist/dvips/pst-moire/pst-moire.pro
new file mode 100644
index 00000000000..59fd37da5e6
--- /dev/null
+++ b/Master/texmf-dist/dvips/pst-moire/pst-moire.pro
@@ -0,0 +1,259 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%% %%
+%% This is file `pst-moire.pro' %%
+%% %%
+%% IMPORTANT NOTICE: %%
+%% %%
+%% Package `pst-moire' %%
+%% %%
+%% Jürgen Gilg, Manuel Luque, Jean-Michel Sarlat %%
+%% %%
+%% Copyright (C) 2018 %%
+%% %%
+%% This program can redistributed and/or modified under %%
+%% the terms of the LaTeX Project Public License %%
+%% Distributed from CTAN archives in directory %%
+%% macros/latex/base/lppl.txt; either version 1.3c of %%
+%% the License, or (at your option) any later version. %%
+%% %%
+%% DESCRIPTION: %%
+%% `pst-moire' is a PSTricks package to draw moire patterns %%
+%% %%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+/moireDict 100 dict def
+moireDict begin
+/pst-Fresnel {
+gsave
+0 0 translate
+1 2 R R mul {%
+ /n_1 exch def
+ /n n_1 1 add def
+ /R_1 n_1 sqrt def
+ /R n sqrt def
+ /width R R_1 sub unit def
+ /radius R R_1 add 2 div unit def
+ width setlinewidth
+ linecolor % \pst@usecolor\pslinecolor
+ circle
+ stroke
+ } for
+grestore
+} def
+%
+/pst-radial {
+/secteur {
+gsave
+ newpath
+ 0 0 moveto
+ 0 0 Runit 0 1 arc
+ closepath
+ linecolor
+ fill
+grestore
+ }
+def
+gsave
+newpath
+Runit 0 moveto
+0 0 Runit 0 360 arc
+Runit 10 div 0 moveto
+0 0 Runit 10 div 360 0 arcn
+closepath
+clip
+1 1 120 { % les angles
+ secteur
+ 3 rotate
+ } for
+grestore
+} def
+%
+/pst-linear {
+Runit neg 0 translate
+/trait {
+ newpath
+ 0 Runit neg moveto
+ 0 Runit lineto
+ linecolor
+ linewidth
+ stroke
+ }
+def
+gsave
+0 1 NombreTraits 1 add{% 50 traits espacés de 2 mm
+ trait
+ mm 2 mul 0 translate
+ } for
+grestore
+} def
+%
+/pst-square {
+/Square {
+ newpath
+ Side neg Side neg moveto
+ Side Side neg lineto
+ Side Side lineto
+ Side neg Side lineto
+ closepath
+ linecolor
+ linewidth
+ stroke
+ }def
+gsave
+0 1 NombreTraits 2 div {% 50 carrés espacés de 2 mm
+ /Side exch mm 2 mul mul def
+ Square
+ } for
+grestore
+} def
+%
+/pst-Newton {
+/SquareNewton {
+ newpath
+ Side neg Side neg moveto
+ Side Side neg lineto
+ Side Side lineto
+ Side neg Side lineto
+ closepath
+ linecolor
+ width setlinewidth % Width mm
+ stroke
+ }
+def
+gsave
+1 2 R R mul {%
+ /n_1 exch def
+ /n n_1 1 add def
+ /R_1 n_1 sqrt def
+ /R n sqrt def
+ /width R R_1 sub unit def
+ /Side R R_1 add 2 div unit def
+ SquareNewton
+ } for
+grestore
+}def
+%
+/pst-circle {
+/Circle {
+ newpath
+ 0 0 Radius 0 360 arc
+ closepath
+ linecolor
+ linewidth
+ stroke
+ }def
+ gsave
+0 1 NombreTraits 2 div {% 50 carrés espacés de 2 mm
+ /Radius exch mm 2 mul mul def
+ Circle
+ } for
+grestore
+} def
+%
+/pst-Bouasse{
+/grille {
+0 1 51 { % 51 traits
+ /trait exch def
+ /xS 2 trait mul 0.01 trait dup mul mul add % en mm
+ mm mul
+ 64 mm mul sub % en pts
+ def
+gsave
+newpath
+ xS 183 neg moveto
+ xS 183 lineto
+ linewidth
+ linecolor
+ stroke
+ } for
+} def % dessin de la grille
+reduc reduc scale
+ grille
+grestore
+} def
+%
+/pst-Gauss1{% definition obsolete
+10 dict begin
+/a 0.5 def
+/yStart -10 def
+/yStop 10 def
+/TRAME {
+-15 0.5 15 { % le nombre de traits
+ /k exch def
+ /p 2.71828 0.5 k a mul dup mul mul neg exp m k a mul mul sub def
+ /xStart 10 neg p sub m div def
+ /xStop 10 p sub m div def
+ linecolor
+ linewidth
+ newpath
+ xStart unit yStart unit moveto
+ xStop unit yStop unit lineto
+ stroke
+} for
+} def
+/CIRCLE {0 0 Runit 0 360 arc } def
+gsave
+CIRCLE clip
+ 90 Alpha sub rotate
+ TRAME
+grestore
+end
+} def
+%
+/pst-Gauss {
+0 0 translate
+10 dict begin
+/A1 3 def
+/K1 0.5 def
+%/E1 0.25 def
+/TRAME {
+-40 E1 2 mul 40 {/n exch def
+gsave
+ n E1 mul unit % x
+ A1 unit 2.71828 K1 n E1 mul mul dup mul neg exp mul % y
+ translate
+ linecolor
+ linewidth
+ -6 unit -6 m mul unit moveto
+ 6 unit 6 m mul unit lineto
+ stroke
+grestore
+ } for
+} def
+Runit neg Runit neg moveto
+Runit neg Runit lineto
+Runit Runit lineto
+Runit Runit neg lineto
+Runit neg Runit neg lineto
+clip
+ TRAME
+end
+} def
+%
+/pst-dot {
+/DOT {DotSize DotStyle Dot} def
+/pas {DotSize DS 4 mul} bind def
+R unit neg pas R unit { /xPos exch def
+R unit neg pas R unit { /yPos exch def
+xPos yPos DOT
+ } for
+} for
+} def
+%
+/pst-chess {
+/DOT {DotSize DotStyle Dot} def
+/pas {DotSize DS 4 mul} bind def
+R unit neg pas R unit { /xPos exch def
+R unit neg pas R unit { /yPos exch def
+xPos yPos DOT
+ } for
+} for
+%
+R unit neg pas 2 div add pas R unit pas 2 div sub { /xPos exch def
+R unit neg pas 2 div add pas R unit pas 2 div sub{ /yPos exch def
+xPos yPos DOT
+ } for
+} for
+} def
+%
+end
+% END pst-moire.pro