1
$\begingroup$

I was wondering if anyone knew how to reset the viewing angle to what it was at the startup. I just want to reset it to that view, not reload startup file or load factory settings or anything. I want to have this viewpointenter image description here

but still have all the work that I did.

$\endgroup$
  • $\begingroup$ Can I reformulate this question : how to setup a camera so that it is placed at the exact same view as the 3D viewport view ? $\endgroup$ – lemon Jun 16 '16 at 19:32
  • $\begingroup$ Welcome to BSE, please edit your question to fit the new reformulated question $\endgroup$ – Georges Jun 16 '16 at 20:20
  • 1
    $\begingroup$ @lemon That's a good thought, but I'd wait for more information. The OP might not be wanting to move the camera object, just the viewport view. $\endgroup$ – Matt Jun 16 '16 at 21:03
  • $\begingroup$ @Matt, yes. This was a connected question but not the same. $\endgroup$ – lemon Jun 17 '16 at 6:56
2
$\begingroup$

If you want to reset the default viewport view and not the camera view,run this in text editor :

import bpy


vm = ((0.41, -0.4017, 0.8188, 0.0),(0.912, 0.1936, -0.3617, 0.0),(-0.0133, 0.8959, 0.4458, 0.0),(0.0, 0.0, -14.9892, 1.0))

for area in bpy.context.screen.areas:
    if area.type == 'VIEW_3D':
        v3d = area.spaces[0].region_3d
        if v3d :
            v3d.view_matrix = vm
            v3d.view_perspective = 'PERSP'

if you are wondering where those values are from , i simply started the default scene and used print(v3d.view_matrix) to get the default coordinates.

$\endgroup$
0
$\begingroup$

Start a new file, save it as camerapos.blend, then open your main blend file and append the camera from the camerapos.blend file into your main scene and make it the main camera.

$\endgroup$
0
$\begingroup$

As per your comment on your question, to set the camera to the same view:

Press Ctrl + Alt + Numpad 0

$\endgroup$
  • $\begingroup$ thanks. That move the cam at the good position. But is there a way to modify also the render size so that it fits the viewport ? But I will set that as a new question... $\endgroup$ – lemon Jun 17 '16 at 6:59
0
$\begingroup$

The following answer assumes that the object(s) to be displayed are at the center of the scene (that is, X = Y = Z = 0.), and make certain that the 3D cursor is positioned at the same place. To achieve the same point of view as if the camera were in a similar position for a scene, make certain the 3D viewport is in object mode, that the camera is the active object, and that the pivot point is defined to be the 3D cursor. Then open the tool shelf (N key). In the X, Y, and Z co-ordinates of the selected camera, and in the boxes for the rotation of the object, enter the values shown in the red box in the image below:

[enter image description here][1]

If the camera needs to be moved to a different location, in the X, Y, and Z boxes for the camera, multiply the values in each box by the same scalar number, so that, for example, if you needed the camera to be 4.3 times further away in order to see the whole object, you would multiply the values for X, Y, and Z each by 4.3. The boxes take numerical expressions, so you can do this by selecting each box in turn, selecting the value, and adding the string * 4 . 3 Enter. To keep the view the same, all three values will need to be multiplied by the same scalar value

If only part of the object is not visible, because some of it is cut off, change the value in the box next to the "end" button in the green box in the illustration. [NOTE: for purposes of economy, I have reordered the panels in the Properties shelf panel.] This will increase the depth of the field of view.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.