tikz-3dplot を使用しながらスタンドアロン ページのサイズを均一に保つ

tikz-3dplot を使用しながらスタンドアロン ページのサイズを均一に保つ

の視点の角度を変えると、tikz-3dplotを使用しているときにさまざまなページが変わりますstandalone。そのサイズを均一に保つにはどうすればよいですか?

背景として長方形を追加してもうまくいかなかったので、より合理的な解決策は、回転不変のオブジェクトを追加することです。不透明度がゼロの球体で、どちらの角度からでも (どの角度からでも) サイズが変わらないようにします。しかし、そのような球体を描画することはできませんでした (ボール コマンドは 3D 用ではないですよね)。

\documentclass[tikz,border=2pt]{standalone}
\usepackage{tikz-3dplot}

\begin{document}

\tdplotsetmaincoords{60}{50}
\begin{tikzpicture}     [tdplot_main_coords]

\draw[-latex]  (-1,-1,-1) --  (1,1,1);

\end{tikzpicture}

% now arrow seen from other angle, but the page shrinks
\tdplotsetmaincoords{30}{90}
\begin{tikzpicture}     [tdplot_main_coords]

\draw[-latex]  (-1,-1,-1) --  (1,1,1);

\end{tikzpicture}


\end{document}

ここに画像の説明を入力してください

答え1

ミニページで tikzpicture を中央に配置できます。

\documentclass[multi={minipage},border=2pt]{standalone}
\usepackage{tikz}
\usepackage{tikz-3dplot}

\begin{document}

\begin{minipage}[c][3.47cm][c]{3.47cm}% sqrt(12)
\centering
\tdplotsetmaincoords{60}{50}
\begin{tikzpicture}     [tdplot_main_coords]

\draw[-latex]  (-1,-1,-1) --  (1,1,1);

\end{tikzpicture}
\end{minipage}

\begin{minipage}[c][3.47cm][c]{3.47cm}
\centering
% now arrow seen from other angle, but the page shrinks
\tdplotsetmaincoords{30}{90}
\begin{tikzpicture}     [tdplot_main_coords]

\draw[-latex]  (-1,-1,-1) --  (1,1,1);

\end{tikzpicture}
\end{minipage}

\end{document}

関連情報