[Bf-committers] Camera view navigation rant

Campbell Barton ideasman42 at gmail.com
Mon Apr 25 05:50:54 CEST 2011


On Sun, Apr 24, 2011 at 9:55 PM, Daniel Salazar - 3Developer.com
<zanqdo at gmail.com> wrote:
> So can we take a look at camera view navigation? It's like playing a
> space flight simulator every time I press Shift F, I just want to
> position and orient my camera, not to deal with inertia and atmosphere
> entering angle! (feels like that at least)
> http://chrome.atari.com/lunarlander/
>
> The flight mode panning (WASD keys) is of no use.. again calculating
> directions and inercia and keeping in mind how many presses I've done
> for each side so I can try and counter act when I want a stop! (which
> never works btw, the counter act seems to never be able to reach zero
> again) this could be a test for new NASA astronauts.
>
> Trackball is a "decent" tool for orienting the camera but it is about
> 10 times too sensitive, and somehow seems like it's going the wrong
> direction (inverted axis?)
>
> I have asked for simple game like controls in the past, you know those
> first person shooter controls? those are intuitive and precise but the
> answer was something like "naah fly simulator is cooler, we can fly
> like birds!", really that was an actual answer, supposedly for live
> recording the camera to keyframes.
>
> Also a lock camera to view option would be great so we can just move
> the camera like we move any other viewport
>
> am I the only one that doesn't get this?
>
> peace,
> Daniel Salazar
> 3Developer.com

Alternative view navigation modes would definitely be worth trying out
and can be scripted without doing anything really complicated.

See: Script Templates -> Operator Modal View3D, this is a very simple
operator that uses the mouse to move the view offset.
in execute() you can set rv3d.view_location and rv3d.view_rotation

API Ref: http://www.blender.org/documentation/blender_python_api_2_57_release/bpy.types.RegionView3D.html

Reading you're mail I remembered rv3d.view_matrix was readonly, just
committed support for assignment r36317.
This makes manipulating the view easier, so you can assign the
transform without worrying about the 'view_distance'.

Of course once the basics are done this can become more involved,
casting rays, smoother motion, mouse-look & strafe :-)


More information about the Bf-committers mailing list