\documentclass[12pt,a4paper]{article} 
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage{lmodern} 
\usepackage{fancyvrb} 
\usepackage{multido} 
\usepackage{pstricks} 
\usepackage{pst-grad} 
\usepackage{pst-light3d}
\let\pstlightVersion\FileVersion 
%
\usepackage{pst-plot} 
\usepackage{pst-tree} 
\usepackage{pst-example} 
\usepackage{url} 
\def\PstLightThreeDPackage{\texttt{pst-light3d}}
\definecolor{DarkGreen}{cmyk}{1,0,1,0.8}
\definecolor{LightGreen}{cmyk}{1,0,1,0.2}
\definecolor{Gold}{rgb}{1,0.84,0}
\definecolor{Violet}{cmyk}{0.79,0.88,0,0}
\hbadness=7000   % Over and under full box warnings
\hfuzz=3pt 
\errorcontextlines100

\newenvironment{optlist}{\begin{description}%
    \renewcommand\makelabel[1]{% 
      \descriptionlabel{\mdseries\textsf{##1}}}% 
    \itemsep0.25\itemsep}% 
 {\end{description}}
%
\def\cs#1{\texttt{#1}}
 \title{The \PstLightThreeDPackage{} package\\
 {\footnotesize version \pstlightVersion}\\
     A PSTricks package for three dimensional\\ 
    lighten effect on characters and PSTricks graphics\thanks{%
Documentation revised by Herbert Voß}}
 \author{Denis \textsc{Girou}
 and Peter \textsc{Kleiweg} }
 \date{\today}

\begin{document}
%
 \maketitle 
% 
 \begin{abstract}
 This package allow to add a three dimensional lighten 
 effect on characters (PostScript fonts), using the 
 \cs{PstLightThreeDText} macro, and curves (opened or closed), 
 using the \cs{PstLightThreeDGraphic} macro, with various customization parameters.
 \end{abstract} 
% 
\tableofcontents 

\clearpage 
\section{Examples} 

\begin{Beispiel}[colwidth=5.5cm]
\DeclareFixedFont{\Bf}{T1}{ptm}{b}{n}{3cm} 
\PstLightThreeDText[fillstyle=solid,fillcolor=white]{\Bf Test}
\end{Beispiel}


\begin{Beispiel}[colwidth=5.5cm]
\DeclareFixedFont{\Bf}{T1}{ptm}{b}{n}{3cm} 
\PstLightThreeDText[linestyle=none,fillstyle=solid, fillcolor=darkgray]{\Bf Test}
\end{Beispiel}
 
\begin{Beispiel}[colwidth=5.5cm]
\psset{linestyle=none,fillstyle=solid,fillcolor=LightGreen}% 
\PstLightThreeDText[LightThreeDAngle=0]{\Bf Test}\\[0.5cm]
\PstLightThreeDText[LightThreeDAngle=90]{\Bf Test}
\end{Beispiel}

\begin{Beispiel}[colwidth=5.5cm]
\psset{linestyle=none,fillstyle=solid,fillcolor=magenta,}% 
\PstLightThreeDText[LightThreeDXLength=0.5, LightThreeDYLength=-1]{\Bf Test}\\[1cm]
\PstLightThreeDText[LightThreeDXLength=-1, LightThreeDYLength=0.5]{\Bf Test}
\end{Beispiel}

\begin{Beispiel}[colwidth=5.5cm]
\DeclareFixedFont{\Sf}{T1}{phv}{b}{n}{3cm} 
\psset{linestyle=none,fillstyle=solid,fillcolor=cyan}% 
\PstLightThreeDText[LightThreeDColorPsCommand=1.2 div setgray]{\Sf 123}\\[1cm] 
\PstLightThreeDText[LightThreeDColorPsCommand=2.5 div setgray]{\Sf 123}
\end{Beispiel}

\begin{Beispiel}[colwidth=5.5cm]
\DeclareFixedFont{\Rm}{T1}{ptm}{m}{n}{3cm} 
\psset{linestyle=none,fillstyle=solid}% 
\PstLightThreeDText[fillcolor=Violet, LightThreeDColorPsCommand=% 
  2.5 div 0.7 exch 0.8 sethsbcolor]{\Rm 987}\\[1cm]
\PstLightThreeDText[fillcolor=DarkGreen, LightThreeDColorPsCommand=% 
  2 div 0.5 exch 0.2 exch sethsbcolor]{\Rm 987}
\end{Beispiel}

\begin{Beispiel}
\DeclareFixedFont{\Rmb}{T1}{ptm}{m}{n}{4cm} 
\PstLightThreeDText[linestyle=none,fillstyle=solid,fillcolor=Gold, LightThreeDColorPsCommand=% 
  1.2 div 0.15 exch 0.7 exch sethsbcolor]{\Rmb PSTricks}
\end{Beispiel}

\begin{Beispiel}[colwidth=4cm]
\psset{unit=0.5cm,linestyle=solid,fillstyle=none}% 
\pspicture(-0.1,-3.5)(7.2,3)
\PstLightThreeDGraphic[LightThreeDXLength=0.4, LightThreeDColorPsCommand=% 
  1.2 div 0.15 exch 0.7 exch sethsbcolor]{% 
    \pscurve(0,2)(1,-3)(2,2)(4,3)(7,0)} 
\endpspicture 
\end{Beispiel}


\begin{Beispiel}[colwidth=4cm]
\psset{unit=0.5cm,linestyle=solid,fillstyle=none}% 
\pspicture(0,-3.5)(7.7,3) 
\PstLightThreeDGraphic[LightThreeDXLength=0.8, LightThreeDColorPsCommand=% 
  2 div 0.35 exch 0.9 exch sethsbcolor]{\pspolygon(0,2)(1,-3)(2,0)(4,1)(6,1)(7,3)} 
\endpspicture 
\end{Beispiel}
 
\begin{Beispiel}[colwidth=4cm]
\psset{unit=0.5cm,linestyle=solid,fillstyle=none}% 
\pspicture(0.5,-3.6)(3.8,3) 
\PstLightThreeDGraphic[LightThreeDColorPsCommand=% 
  2.6 div 0.12 exch 0.7 exch sethsbcolor]{\psellipse(2,0)(1.5,3)} 
\endpspicture
\end{Beispiel}

\begin{Beispiel}[colwidth=4cm]
\SpecialCoor 
\def\PstCoordinates{}% 
\Multido{\nDistance=0.00+0.02,\iAngle=0+20}{200}{% 
  \edef\PstCoordinates{\PstCoordinates(\nDistance;\iAngle)}} 
\psset{unit=0.5cm}% 
\pspicture(-3.8,-4)(4.1,3.7) 
\PstLightThreeDGraphic[LightThreeDLength=0.2, LightThreeDColorPsCommand=% 
  1.2 div 0.3 exch 0.7 exch sethsbcolor]{\expandafter\pscurve\PstCoordinates} 
\endpspicture
\end{Beispiel}

\begin{Beispiel}[colwidth=4cm]
\SpecialCoor 
\def\PstCoordinates{}% 
\Multido{\nDistance=0.00+0.02,\iAngle=0+20}{200}{% 
  \edef\PstCoordinates{\PstCoordinates(\nDistance;\iAngle)}} 
\psset{unit=0.5cm}% 
\pspicture(-3.8,-4)(4.1,3.7) 
\PstLightThreeDGraphic[LightThreeDLength=0.2, LightThreeDAngle=30,LightThreeDColorPsCommand=% 
  /Counter Counter 0.00005 add def 2 mul Counter exch 0.7 exch sethsbcolor]{% 
  \pstVerb{ /Counter 0 def }% 
  \expandafter\pscurve\PstCoordinates} 
\endpspicture
\end{Beispiel}

\begin{Beispiel}
\PstLightThreeDGraphic[LightThreeDXLength=0.2, LightThreeDYLength=-0.2, LightThreeDColorPsCommand=% 
  1.2 div 0.65 exch 0.9 sethsbcolor]{% 
    \large \let\TovalORIG\Toval \def\Toval#1{\TovalORIG{\raise2mm\hbox{\hskip2mm#1}}}% 
    \let\TtriORIG\Ttri \def\Ttri#1{\TtriORIG{\raise3mm\hbox{#1}}}% 
    \psset{framesep=0.15,fillstyle=gradient,gradmidpoint=0, gradbegin=cyan,gradend=blue}% 
    \pstree[treesep=0.5]{\Ttri{Jane}} {\psset{framesep=0.25}% 
    \pstree{\Toval{Marc}} {\Toval{Bob}\Toval{Ann}\Toval{Peter}}}}
\end{Beispiel}

\begin{Beispiel}
\psset{xunit=8cm,yunit=3cm}% 
\pspicture(-0.45,-1.6)(1,1.3)%
\psaxes[Dx=0.2,Oy=-1.2,Dy=0.2,tickstyle=top, axesstyle=frame](0,-1.2)(1,1.2)%
\psset{plotpoints=500,LightThreeDXLength=0.3, LightThreeDYLength=-0.3}%
\PstLightThreeDGraphic[LightThreeDColorPsCommand=1.5 div 0.05 exch 0.8 sethsbcolor]{%
  \psplot{0}{0.95}{x 10 mul 57.296 mul sin}}%
\PstLightThreeDGraphic[LightThreeDColorPsCommand=1.5 div 0.6 exch 0.8 sethsbcolor]{%
  \psplot{0}{0.95}{x 40 mul 57.296 mul cos 2 div}}%
\rput(-0.3,0.1){\textcolor{red}{$\sin (10 \times x)$}}%
\rput(-0.3,-0.1){\textcolor{blue}{$\cos (40 \times x) / 2$}}%
\rput(0.5,-1.5){$x$}%
\endpspicture
\end{Beispiel}
%

\end{document} 
