\documentclass[border=15pt,pstricks,12pt]{standalone}
\usepackage{pst-intersect}
\begin{document}
\begin{pspicture}[showgrid](3,2)
{\psset{linestyle=dashed}
\pssavepath{MyPath}{\pscurve(0,2)(0,0.5)(3,1)}
\pssavebezier{MyBez}(0,0)(0,1)(1,2)(3,2)(1,0)(3,0)
\psintersect[showpoints]{MyPath}{MyBez}}
\psclip{\pscurve(0,2)(0,0.5)(3,1)}{
\pscustom[fillstyle=vlines]{\pssavebezier{hi}(0,0)(0,1)(1,2)(3,2)(1,0)(3,0)
\gsave \grestore}}
\endpsclip
\end{pspicture}
\end{document}
两个数字不一致。为什么呢?
答案1
你有很多尾随空格:
\documentclass[border=15pt,pstricks,12pt]{standalone}
\usepackage{pst-intersect}
\begin{document}
\begin{pspicture}[showgrid](3,2)
{\psset{linestyle=dashed}
\pssavepath{MyPath}{\pscurve(0,2)(0,0.5)(3,1)}%%%
\pssavebezier{MyBez}(0,0)(0,1)(1,2)(3,2)(1,0)(3,0)%%%%
\psintersect[showpoints]{MyPath}{MyBez}}%%%%%
\psclip{\pscurve(0,2)(0,0.5)(3,1)}{%
\pscustom[fillstyle=vlines]{%
\pssavebezier{hi}(0,0)(0,1)(1,2)(3,2)(1,0)(3,0)}}
\endpsclip
\end{pspicture}
\end{document}