Não tenho certeza de como proceder ao preencher o interior de um caminho gerado aleatoriamente (por meio de uma decoração aleatória).
Comecei com o código fornecido na resposta a esteperguntae trabalhei nisso já que o propósito básico estava relacionado.
O preenchimento e a linha desenhada não são exatamente iguais, pois há uma decoração aleatória aplicada a cada um.
PERGUNTA)
Como aplico o preenchimento no interior delimitado pela linha desenhada?
(Além disso, neste caso, como faço para aumentar as setas de decoração? Posso aplicar setas de decoração também no caminho desenhado sem quebrar a outra decoração?)
\documentclass[border=0pt]{standalone}\usepackage{mathtools,tikz,tkz-euclide}\usetikzlibrary{decorations.markings,arrows,decorations.pathmorphing}\usetkzobj{all}\begin{document}\begin{tikzpicture}[label]\tkzInit[xmin=-0.8,xmax=10,ymin=-0.4,ymax=8.4] \tkzClip
\tikzset{every node}=[font=\normalsize]
%here_we_make_such_a_dashing
\tikzstyle{finelydashed}=[dash pattern=on 4pt off 7pt]
\tikzstyle{coarselydashed}=[dash pattern=on 7pt off 8pt]
%here_we_make_such_a_shading
\pgfdeclarepatternformonly{ltrdiagonals}%
{\pgfqpoint{-1pt}{-1pt}}{\pgfqpoint{10pt}{10pt}}%
{\pgfqpoint{9pt}{9pt}}{\pgfsetlinewidth{0.4pt}\pgfpathmoveto{\pgfqpoint{0pt}{0pt}}%
\pgfpathlineto{\pgfqpoint{9.1pt}{9.1pt}}%
\pgfusepath{stroke}}%
%here_we_make_such_a_grid
\draw[help lines,color=black!90](0,0)grid(8,8);
%here_we_define_our_several_points
\tkzDefPoint(1,2){v}\tkzDefPoint(7,2){w}
\tkzDefPointBy[rotation=center w angle -42](v)
\tkzGetPoint{C}
\tkzDefPointBy[rotation=center v angle 63](w)
\tkzGetPoint{D}
\tkzInterLL(v,D)(C,w)\tkzGetPoint{x}
\tkzDefMidPoint(v,x)\tkzGetPoint{M}
\draw[shade,top color=black!96,bottom color=black!16,fill opacity=0.64,decoration= {random steps,segment length=22pt,amplitude=11pt},decorate,line width=2pt,rounded corners=8pt](v)--(1.7,3.2)--(4,4)--(6,3)--(w)--(7.4,1)--(0.4,0.4)--(v);
\fill[even odd rule,pattern=ltrdiagonals,pattern color=black!84,decoration={random steps,segment length=24pt,amplitude=0.24cm},decorate,line width=2pt,rounded corners=8pt](v)--(1.7,3.2)--(4,4)--(6,3)--(w)--(7.4,1)--(0.4,0.4)--(v);
%here_we_label_each_node_so
\tkzLabelPoint[above left](v){\LARGE $\boldsymbol{\mathbf{H}_{\;n\;v}}\,$}
\tkzLabelPoint[above left](x){\LARGE $\mathbf{x_{\;n}}$}
\tkzLabelPoint[right](w){\LARGE $\;\boldsymbol{\mathbf{H}_{\;n\;w}}$}
\tkzLabelAngle[pos=0.64](v,x,w){\large $\boldsymbol{\varphi}$}
\tkzLabelAngle[pos=0.64](w,v,x){\large $\boldsymbol{\rho}$}
\tkzLabelPoint[left](M){$\boldsymbol{2\cdot\mu}\;$}
%here_we_construct_each_line_so
\begin{scope}[decoration={markings,mark=at position 0.5 with {\LARGE\arrow{triangle 45},color=black!96}}]
\draw[-,decorate](v)--(x);
\draw[-,decorate](v)--(w);
\draw[-,decorate](x)--(w);
\end{scope}
\draw[-,line width=1.2pt,coarselydashed,color=black!96](v)--(x);
\draw[-,line width=1.2pt,coarselydashed,color=black!96](v)--(w);
\draw[-,line width=1.2pt,coarselydashed,color=black!96](x)--(w);
\tkzDrawPoints[color=black,shape=circle,fill=black!64,size=16pt](v,x,w)
\tkzMarkAngle[scale=1,line width=1.2pt,finelydashed,color=black!96](v,x,w)
\tkzMarkAngle[scale=1,line width=1.2pt,finelydashed,color=black!96](w,v,x)
\end{tikzpicture}\end{document}
Responder1
Você precisa reutilizar o mesmo caminho com postaction,preaction
chaves.
\documentclass[border=0pt]{standalone}
\usepackage{mathtools,tikz,tkz-euclide}\usetikzlibrary{decorations.markings,arrows,decorations.pathmorphing}
\usetkzobj{all}
\begin{document}
\begin{tikzpicture}[label]
\tkzInit[xmin=-0.8,xmax=10,ymin=-0.4,ymax=8.4]
\tkzClip
\tikzset{every node}=[font=\normalsize]
%here_we_make_such_a_dashing
\tikzstyle{finelydashed}=[dash pattern=on 4pt off 7pt]
\tikzstyle{coarselydashed}=[dash pattern=on 7pt off 8pt]
%here_we_make_such_a_shading
\pgfdeclarepatternformonly{ltrdiagonals}%
{\pgfqpoint{-1pt}{-1pt}}{\pgfqpoint{10pt}{10pt}}%
{\pgfqpoint{9pt}{9pt}}{\pgfsetlinewidth{0.4pt}\pgfpathmoveto{\pgfqpoint{0pt}{0pt}}%
\pgfpathlineto{\pgfqpoint{9.1pt}{9.1pt}}%
\pgfusepath{stroke}}%
%here_we_make_such_a_grid
\draw[help lines,color=black!90](0,0)grid(8,8);
%here_we_define_our_several_points
\tkzDefPoint(1,2){v}\tkzDefPoint(7,2){w}
\tkzDefPointBy[rotation=center w angle -42](v)
\tkzGetPoint{C}
\tkzDefPointBy[rotation=center v angle 63](w)
\tkzGetPoint{D}
\tkzInterLL(v,D)(C,w)\tkzGetPoint{x}
\tkzDefMidPoint(v,x)\tkzGetPoint{M}
\draw[%shade,
top color=black!96,
bottom color=black!16,
fill opacity=0.64,
decoration={random steps,segment length=22pt,amplitude=11pt},
decorate,
line width=2pt,
rounded corners=8pt,
postaction={fill,pattern=ltrdiagonals,pattern color=black!84}
](v)--(1.7,3.2)--(4,4)--(6,3)--(w)--(7.4,1)--(0.4,0.4)--(v);
%here_we_label_each_node_so
\tkzLabelPoint[above left](v){\LARGE $\boldsymbol{\mathbf{H}_{\;n\;v}}\,$}
\tkzLabelPoint[above left](x){\LARGE $\mathbf{x_{\;n}}$}
\tkzLabelPoint[right](w){\LARGE $\;\boldsymbol{\mathbf{H}_{\;n\;w}}$}
\tkzLabelAngle[pos=0.64](v,x,w){\large $\boldsymbol{\varphi}$}
\tkzLabelAngle[pos=0.64](w,v,x){\large $\boldsymbol{\rho}$}
\tkzLabelPoint[left](M){$\boldsymbol{2\cdot\mu}\;$}
%here_we_construct_each_line_so
\begin{scope}[decoration={markings,mark=at position 0.5 with {\LARGE\arrow{triangle 45},color=black!96}}]
\draw[-,decorate](v)--(x);
\draw[-,decorate](v)--(w);
\draw[-,decorate](x)--(w);
\end{scope}
\draw[-,line width=1.2pt,coarselydashed,color=black!96](v)--(x);
\draw[-,line width=1.2pt,coarselydashed,color=black!96](v)--(w);
\draw[-,line width=1.2pt,coarselydashed,color=black!96](x)--(w);
\tkzDrawPoints[color=black,shape=circle,fill=black!64,size=16pt](v,x,w)
\tkzMarkAngle[scale=1,line width=1.2pt,finelydashed,color=black!96](v,x,w)
\tkzMarkAngle[scale=1,line width=1.2pt,finelydashed,color=black!96](w,v,x)
\end{tikzpicture}
\end{document}
Como você pode ver, random steps
não jogue bem com a rounded corners
opção. Dê uma olhada tambémDeve \tikzset ou \tikzstyle ser usado para definir estilos TikZ?