\documentclass[border=.8cm,pstricks]{standalone}
\usepackage{pst-eucl}
\def\a{4}
\begin{document}
\begin{pspicture}(4,3.5)
\psset{linejoin=1,PointSymbol=none}
\pstGeonode[PosAngle={-90,90,90,-90}]%
(0,0){A}(+0,\a-.6){B}(+\a,\a-.6){C}(\a,0){D}
\pstMiddleAB[PosAngle=-90]{A}{D}{C_1}
\pstRotation[RotAngle=-90,PointName=none]{C_1}{B}[B']
\pstInterLL[PosAngle=0]{C_1}{B'}{C}{D}{K}
\pspolygon[fillstyle=crosshatch*,%
fillcolor=cyan!35,%
hatchcolor=blue!50,%
hatchangle=0,%
hatchwidth=.7pt,%
hatchsep=10.2pt](K)(D)(A)(B)
\pspolygon[fillstyle=crosshatch*,%
fillcolor=cyan!20,%
hatchcolor=blue!50,%
hatchangle=120,%
hatchwidth=.7pt,%
hatchsep=11pt](B)(C_1)(K)
\pstSegmentMark[Mark=pstslashh]{A}{C_1}
\pstSegmentMark[Mark=pstslashh]{C_1}{D}
\psline[linestyle=dashed](B)(C)(K)
\pstRightAngle[RightAngleSize=.2]{K}{C_1}{B}
\psdots[dotsize=.1](A)(B)(C)(D)(K)(C_1)
\end{pspicture}
\end{document}
问题:有人可以为我的图片添加“阴影”吗?
看到Red Cloud的回答后:
\documentclass[border=.8cm,pstricks]{standalone}
\usepackage{pst-eucl,pst-blur}
\def\a{4}
\begin{document}
\begin{pspicture}(4,3.5)
\psset{linejoin=1,PointSymbol=none}
\pstGeonode[PosAngle={-90,90,90,-90}]%
(0,0){A}(+0,\a-.6){B}(+\a,\a-.6){C}(\a,0){D}
\pstMiddleAB[PosAngle=-90]{A}{D}{C_1}
\pstRotation[RotAngle=-90,PointName=none]{C_1}{B}[B']
\pstInterLL[PosAngle=0]{C_1}{B'}{C}{D}{K}
\pspolygon[fillstyle=crosshatch*,fillcolor=cyan!35,%
hatchcolor=blue!50, hatchangle=0,%
hatchwidth=.7pt,hatchsep=10.2pt](K)(D)(A)(B)
\psclip{\psframe[linestyle=none](B)(D)}
\pspolygon[fillstyle=crosshatch*,fillcolor=cyan!20,%
hatchcolor=blue!50, hatchangle=120,%
hatchwidth=.7pt,hatchsep=11pt,
shadow=true,blur=true,shadowangle=-100,blursteps=80,
blurbg=black!8,blurradius=2.2pt](B)(C_1)(K)
\endpsclip
\pstSegmentMark[Mark=pstslashh]{A}{C_1}
\pstSegmentMark[Mark=pstslashh]{C_1}{D}
\psline(A)(B)
\psline(K)(D)
\psline[linestyle=dashed](B)(C)(K)
\pstRightAngle[RightAngleSize=.2]{K}{C_1}{B}
\psdots[dotsize=.1](A)(B)(C)(D)(K)(C_1)
\end{pspicture}
\end{document}
看到@ArtificialOdorlessArmpit 的回答后:
\documentclass[border=.8cm,pstricks]{standalone}
\usepackage{pst-eucl}
\def\a{4}
\begin{document}
\begin{pspicture}[saveNodeCoors](4,3.5)
\psset{linejoin=1,PointSymbol=none}
\pstGeonode[PosAngle={-90,90,90,-90}]%
(0,0){A}(+0,\a-.6){B}(+\a,\a-.6){C}(\a,0){D}
\pstMiddleAB[PosAngle=-90]{A}{D}{C_1}
\pstRotation[RotAngle=-90,PointName=none]{C_1}{B}[B']
\pstInterLL[PosAngle=0]{C_1}{B'}{C}{D}{K}
\pspolygon[fillstyle=crosshatch*,fillcolor=cyan!35,%
hatchcolor=blue!50, hatchangle=0,%
hatchwidth=.7pt,hatchsep=10.2pt](K)(D)(A)(B)
\psclip{\psframe[linestyle=none](B)(D)}
\psline[linecolor=gray,strokeopacity=.5,linewidth=3.5pt](B|!0 N-B.y .04 sub)(1.99,0|!0 N-C_1.y .03 sub)(K|!0 N-K.y .02 sub)
\endpsclip
\pspolygon[fillstyle=crosshatch*,fillcolor=cyan!20,%
hatchcolor=blue!50, hatchangle=120,%
hatchwidth=.7pt,hatchsep=11pt,](B)(C_1)(K)
\pspolygon(B)(C_1)(K)
\pstSegmentMark[Mark=pstslashh]{A}{C_1}
\pstSegmentMark[Mark=pstslashh]{C_1}{D}
\psline(A)(B)
\psline(K)(D)
\psline[linestyle=dashed](B)(C)(K)
\pstRightAngle[RightAngleSize=.2]{K}{C_1}{B}
\psdots[dotsize=.1](A)(B)(C)(D)(K)(C_1)
\end{pspicture}
\end{document}
答案1
答案2
PSTricks 解决方案仅用于好玩的目的。
\documentclass[border=.8cm,pstricks]{standalone}
\usepackage{pst-eucl}
\def\a{4}
\begin{document}
\begin{pspicture}[saveNodeCoors](4,3.5)
\psset{linejoin=1,PointSymbol=none}
\pstGeonode[PosAngle={-90,90,90,-90}]%
(0,0){A}(+0,\a-.6){B}(+\a,\a-.6){C}(\a,0){D}
\pstMiddleAB[PosAngle=-90]{A}{D}{C_1}
\pstRotation[RotAngle=-90,PointName=none]{C_1}{B}[B']
\pstInterLL[PosAngle=0]{C_1}{B'}{C}{D}{K}
\pspolygon[fillstyle=crosshatch*,fillcolor=cyan!35,%
hatchcolor=blue!50, hatchangle=0,%
hatchwidth=.7pt,hatchsep=10.2pt](K)(D)(A)(B)
\psclip{\psframe[linestyle=none](B)(D)}
\multido{\i=10+10}{11}{%
\pstVerb{/AA {\i\space 1000 div} bind def}%
\psline[linecolor=gray,strokeopacity=\pscalculate{0.2-\i*0.001}](B|!0 N-B.y AA sub)(C_1|!0 N-C_1.y AA sub)(K|!0 N-K.y AA sub)}
\endpsclip
\pspolygon(B)(C_1)(K)
\pstSegmentMark[Mark=pstslashh]{A}{C_1}
\pstSegmentMark[Mark=pstslashh]{C_1}{D}
\psline(A)(B)
\psline(K)(D)
\psline[linestyle=dashed](B)(C)(K)
\pstRightAngle[RightAngleSize=.2]{K}{C_1}{B}
\psdots[dotsize=.1](A)(B)(C)(D)(K)(C_1)
\end{pspicture}
\end{document}
编辑
回应您上次的编辑。
\documentclass[border=.8cm,pstricks]{standalone}
\usepackage{pst-eucl}
\def\a{4}
\begin{document}
\begin{pspicture}[saveNodeCoors](4,3.5)
\psset{linejoin=1,PointSymbol=none}
\pstGeonode[PosAngle={-90,90,90,-90}]%
(0,0){A}(+0,\a-.6){B}(+\a,\a-.6){C}(\a,0){D}
\pstMiddleAB[PosAngle=-90]{A}{D}{C_1}
\pnode(C_1){T}% buffering is necessary. I don't know why.
\pstRotation[RotAngle=-90,PointName=none]{C_1}{B}[B']
\pstInterLL[PosAngle=0]{C_1}{B'}{C}{D}{K}
\pspolygon[fillstyle=crosshatch*,fillcolor=cyan!35,%
hatchcolor=blue!50, hatchangle=0,%
hatchwidth=.7pt,hatchsep=10.2pt](K)(D)(A)(B)
\psclip{\psframe[linestyle=none](B)(D)}
\multido{\i=10+10}{11}{%
\pstVerb{/AA {\i\space 1000 div} bind def}%
\psline[linecolor=gray,strokeopacity=\pscalculate{0.2-\i*0.001}]%
(!N-B.x AA sub 0|!0 N-B.y AA sub)% your version
(!N-T.x AA sub N-T.y AA sub)% simplified version
(!N-K.x AA sub N-K.y AA sub)}% simplified version
\endpsclip
\pspolygon(B)(C_1)(K)
\pstSegmentMark[Mark=pstslashh]{A}{C_1}
\pstSegmentMark[Mark=pstslashh]{C_1}{D}
\psline(A)(B)
\psline(K)(D)
\psline[linestyle=dashed](B)(C)(K)
\pstRightAngle[RightAngleSize=.2]{K}{C_1}{B}
\psdots[dotsize=.1](A)(B)(C)(D)(K)(C_1)
\end{pspicture}
\end{document}