\newcommand{\gezi}{1.5} % 设置格子的大小,单位 cm \pgfmathparse{\gezi * 5} \let\imgwd\pgfmathresult %定义背景图填充的宽度 % 重复铺满背景中间的图片 \foreach \y in {-1,0, 1, ..., 15} { % 根据需要调整数字 \node[anchor=north west] at (\mymid - \imgwd, -\y*2) { \includegraphics[width=\imgwd cm]{\bggezi} }; \node[anchor=north west] at (\mymid, -\y*2) { \includegraphics[width=\imgwd cm]{\bggezi} }; }