We can find the appropriate options from this input:
Graphics3D[Cuboid[], ViewPoint -> {1, 1, 1}] // AbsoluteOptions
(*{AlignmentPoint -> Center, AspectRatio -> Automatic,
AutomaticImageSize -> False, Axes -> False, AxesEdge -> Automatic,
AxesLabel -> None, AxesOrigin -> Automatic, AxesStyle -> {},
Background -> None, BaselinePosition -> Automatic, BaseStyle -> {},
Boxed -> True, BoxRatios -> {1., 1., 1.}, BoxStyle -> {},
ClipPlanes -> None, ClipPlanesStyle -> Automatic,
ColorOutput -> Automatic, ContentSelectable -> Automatic,
ControllerLinking -> Automatic, ControllerMethod -> Automatic,
ControllerPath -> Automatic, CoordinatesToolOptions -> Automatic,
DisplayFunction -> Identity, Epilog -> {}, FaceGrids -> None,
FaceGridsStyle -> {}, FormatType -> TraditionalForm,
ImageMargins -> 0., ImagePadding -> All, ImageSize -> Automatic,
ImageSizeRaw -> Automatic, LabelStyle -> {}, Lighting -> Automatic,
Method -> Automatic, PlotLabel -> None,
PlotRange -> {{0., 1.}, {0., 1.}, {0., 1.}},
PlotRangePadding -> Automatic, PlotRegion -> Automatic,
PreserveImageOptions -> Automatic, Prolog -> {},
RotationAction -> "Fit", SphericalRegion -> False,
Ticks -> Automatic, TicksStyle -> {}, TouchscreenAutoZoom -> False,
ViewAngle -> Automatic, ViewCenter -> {0.5, 0.5, 0.5},
ViewMatrix -> Automatic, ViewPoint -> {1., 1., 1.},
ViewProjection -> Automatic, ViewRange -> All,
ViewVector -> Automatic, ViewVertical -> {0., 0., 1.}}*)
Then, the desired & appropriate parameters may be set:
Graphics3D[Cuboid[], ViewPoint -> {1, 1, 1},
ViewCenter -> {0.5`, 0.5`, 0.5`}, ViewVertical -> {0.`, 0.`, 1.`}]
Use AbsoluteOptions
to determine the definitive options for the current viewpoint you have outputted. From here, copy and paste these into your desired definition. What I mean by this is that you take your Cuboid
output, defined with the noted Viewpoint
, and then type //AbsoluteOptions
after the output. Evaluate this and use the output to be applied to your definition.
I have no experience with the answer of user @kglr, however, I can say with absolute certainty and confidence that if you find a viewpoint you like, perform the above procedure and you will have the desired output every time you evaluate it, just as you need/ask for here.
Hope this helps!
Output
cell with aGraphics
expression it tries to preserve the options that expression currently has. That's what you're running into. Just delete the cell if it's an issue. $\endgroup$ViewVertical
and (2) adding the optionPreserveImageOptions ->True
. E.g., try ifGraphics3D[Cuboid[], ViewPoint -> {1, 1, 1}, ViewVertical -> {-0.3, 0.6, 0.7}, PreserveImageOptions -> True]
works. $\endgroup$