答案1
这可以使用 tikz 和 adjustbox 来完成:
\usepackage{adjustbox}
\usepackage{tikz}
\usepackage{graphicx}
\usetikzlibrary{decorations.pathmorphing}
\newcommand{\cutimage}[3]{
\adjustbox{max width=\textwidth}{
\tikz{
\node[inner sep=0pt] (A) {
\adjustbox{trim={0} {0} {#2\width} {0},clip}{\includegraphics{#1}}
};
\draw[decoration={zigzag, mirror,segment length=6mm,amplitude=1.1pt}, decorate](A.north east) -- (A.south east)
}
\tikz{
\node[inner sep=0pt] (A) {
\adjustbox{trim={#3\width} {0} {0} {0},clip}{\includegraphics{#1}}
};
\draw[decoration={zigzag, mirror,segment length=6mm,amplitude=1.1pt}, decorate](A.north west) -- (A.south west)
}
}
}
用法:
\cutimage{image.png}{.65}{.87}
感谢这些答案,我从中借鉴了部分内容: