We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

Camera target is off

Home Forums Graphics / Blender Camera target is off

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #70685
    hamza3d
    Participant

    My camera in my scene is always off in verge3d viewport. Even if I select my target under verge3d settings/target object or do it manually, it is always off. It’s as if there is a bug. In Blender I can see the true view of the viewport if I select ‘From Cursor’. How can I correct it?

    #70686
    xeon
    Customer

    Well…without seeing your blender file and your puzzles I can only provide you generic advice.

    1. Dont use From Cursor.
    2. In Blender select your camera, then from the View Menu (top menu of blender), select Cameras, then select Active Camera. If you only have one camera in your scene you can just press 0 on the number pad. This will show you what your camera is going to see when V3D starts unless you have animation or puzzles affecting it on load.
    3. Recommendations: Place an empty at the position you want your camera to start, rename the empty. CAM_Start_Location. Create another empty at the location you want your camera to look at and name it CAM_Start_Target_Location.

    In you initializing puzzles (the first few to execute), set an Set ActiveCamera puzzle and place your active camera object in it. Then place a TweenCamera to puzzle immediately following the SetActiveCamera Puzzle. Set the position of to CAM_Start_Location and the LookAt to CAM_Start_Target_Location, set the move to linear and the seconds to 0. This will ensure your camera in Blender is positioned precisely in V3D.

    Xeon
    Route 66 Digital
    Interactive Solutions - https://www.r66d.com
    Tutorials - https://www.xeons3dlab.com

    #70704
    hamza3d
    Participant

    Thanks the puzzle ‘Set ActiveCamera puzzle’ seems to have fixed it. Another problem which has started this all, is camera animation with puzzles. I watched one of your video the other about camera’s. When I want to move the camera between the two points it goes in reverse motion. Second I can not seem to get the position right. It is not intuitive to control the targets within tween camera puzzle.

    I’ve attached an example. What I want to achieve is whenever the user clicks on the eyes. I want the camera to get closer (close-up of the eyes/subject).

    #70705
    hamza3d
    Participant

    The zip file was too big I’ll try again with this post.

    Also here is a screenshot of the puzzles.

    Attachments:
    You must be logged in to view attached files.
    #70707
    hamza3d
    Participant

    Sorry for the multiple posts but I get an error when I want to upload the files other than images.
    I have also included a screenshot of the blender scene.

    Attachments:
    You must be logged in to view attached files.
    #70724
    xeon
    Customer

    It appears you have four camera location empties.
    This is what I believe is happening.

    You start your scene at camera_initialize_start and looking at camera_initialize end.

    For the sake of simplicity I am going to assign the z values to explain whats happening. They do not match what you have going on precisely.
    Camera_initialize start is at z=5
    Camera_initialize end is at z=.2
    This sets the initial position of the camera and has a time value of 0.

    When the user clicks on the eyes
    The camera Jumps to (because the tween time is 0),
    The camera moves from Camera initialize start to camera_tween_start.
    Camera_tween_start is further away from the monkey…so we will say Z=6
    The camera target changes too … its now camera_tween_end and its located closer to the monkey…lets just say z=.1

    So you moved the camera further away from the monkey… the camera is moving backwards.
    You also moved the target closer to the monkey which also adds to the effect of the camera moving backwards.

    If you want the camera to move forward…. move the camera_tween_start somewhere closer to the monkey.

    Recommendation: You named your initial empties correctly. But your other names may make the understanding of how this works more difficult.

    You may want to rename Camera Tween Start to Camera Tween End. Its the location where the camera will end up when the tween is completed. You can leave the When clicked Tween camera look at to be the same as the initial Camera_initialize_end.

    But again the naming is odd.

    I would suggest renaming your emtpies:
    Camera_initialize_start. >>> Camera_Start_Location
    Camera_initialize_end >>> Camera Start_LookAt
    Camera_Tween_Start >>> Camera_Tween_Location
    Camera_Tween_End >>> Camera_Tween_LookAt

    In the tween puzzle…the first object is the “position of” you want the camera to move to. The second position is the look at. This is where the camera is pointed to. The tween puzzle moves the camera from its current position to the position specified in the “position of” within the tween puzzle.

    I think you may be confusing that the tween puzzle specifies where to start and where to end up. But its really move the camera from where its at…and. move it to the new location and look at the specified location. The seconds is the time that this will ocurr in…longer durations make the camera move smoothly.

    Hope this helps.

    Xeon
    Route 66 Digital
    Interactive Solutions - https://www.r66d.com
    Tutorials - https://www.xeons3dlab.com

    #70767
    hamza3d
    Participant

    Thanks a lot man. Yeah I misunderstood the camera tween puzzle. I assumed that I needed a starting and end point. Which may also explain when I move the second ‘location’ empty on the y or x axis that the rotation is all messed up. I’ll implement your solution and hopefully things get sorted out. Thanks!

    #70817
    hamza3d
    Participant

    Unfortunately it is not running perfectly. When empties are aligned on z axis (x and y have default values) it works as you have described but when I move the second (even a little bit) ‘look at’ empty on x and y axis OR the location empty then it rotates on z-axis? I have looked at the ‘global illumination’ project and I don’t see the issue there even when I change the empties around. What I want should be (theoretically) simple: first we see the whole object as wide shot. Then zoom in on a piece of the object, centered in frame (so the camera has to move on x-y axis).

    • This reply was modified 9 months ago by hamza3d.
    • This reply was modified 9 months ago by hamza3d.
    Attachments:
    You must be logged in to view attached files.
    #70854
    xeon
    Customer

    Is this what you are trying to do? click on the cube to start camera movement.

    https://v3d.net/t7t

    V3D project and blend file here: https://v3d.net/t7u

    • This reply was modified 9 months ago by xeon.

    Xeon
    Route 66 Digital
    Interactive Solutions - https://www.r66d.com
    Tutorials - https://www.xeons3dlab.com

    #70870
    hamza3d
    Participant

    Kind of. Before we click anything the object is positioned as expected. But if I want to focus in on object, let’s say upper right corner, the camera rotates on the z-axis. For example if you move this empty ‘CAM_Target_2’ more to the upper right corner for: x-axis = 0.7 m, y-axis = 0.7 m and z-axis = 5.07679 m (value stays the same), you’ll see that the camera rotates.

    #71128
    xeon
    Customer

    I believe and someone with a deeper knowledge of why V3D does this on the Z-axis can chime in. I have not found a good for solution for this other than not have my camera tweening from in a dominant Z axis. It works fine any other axis.

    You can do other things to avoid using the tween such as camera zoom or you can animate you camera in Blender and just animate the camera for that sequence. You can use puzzles to move it too but tween…not great in Z.

    Xeon
    Route 66 Digital
    Interactive Solutions - https://www.r66d.com
    Tutorials - https://www.xeons3dlab.com

    #71133
    kdv
    Participant

    just a little advice: never rotate cameras around its local Z axis. otherwize you will get the effect of a tilted head.

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #71141
    hamza3d
    Participant

    Thanks. I lost a lot of time because of this issue but it works now as expected. I have changed the orientation of my objects so that it on x & y axis.

Viewing 13 posts - 1 through 13 (of 13 total)
  • You must be logged in to reply to this topic.