[pstricks] overlays or similar methods

Herbert Voss LaTeX at zedat.fu-berlin.de
Thu Oct 27 19:46:46 CEST 2005


Christoph Bersch wrote:
> Hi!
> 
> As far as I know there is no real possiblity of making overlays with
> PSTricks. So maybe some of you has an alternativ idea to solve my problem:
> 
> For the moment in my package pst-optexp it's only possible to draw
> single beams:
> 
>            | (beam)
>            |
>            | /
>      -------/
>            / (mirror)
>           /
> 
> and I have to draw the beams before the components in order to have the
> beam placed behind the component lines. So far there is no problem.
> 
> But I'm thinking about allowing the use of larger beams:
> 
>          | | (beams)
>          | |
>          | | /
>     --------/
>          | /
>     ------/ (mirror)
>          /
> 
> Now I could define a parameter 'beamwidth' and create two additional
> \pnode within the component that can be used after the component was set
> to draw the two beams.
> But by this the nodes would be accessible only _after_ the component was
> drawn and thus for the moment I see no possibility to draw the beams
> _behind_ the components.

- you need the angle and one point of the mirror, then you have the
   equation for it y-a=m(x-b)
- one node is enough, then you can calculate on PS-side the
   intersection point or use one of the existing macros of pst-eucl,
   pst-optic or pstricks-add. With the linewidth you can
   calculate the other nodes and draw the line as a filled polygon

Herbert




More information about the PSTricks mailing list