source files: [xc]tfm.[ch]
(SEND <tfm> :FRAME-THINGS [:THINGS <thingList>] [:FRAME-TIGHTLY t])
Set the matrix so that (if the matrix controlled a camera) all things in <thingList> would be in the field of view. The algorithm used changes only the :LOCATION and :UP of the <tfm>.
(:UP is changed only because a sufficiently large change in :LOCATION used to flip the camera over, due to the :LOCATION being suddenly above :UP -- so now we apply the same change to :UP that we apply to location. In hindsight, this probably means that :UP should have been a direction vector instead of a point, but I wanted to uniformly use points everywhere, in anticipation of later using cubics to animate points, and having the position and orientation of cameras controlled by these animated points.)
See the CAMERA class documents for an explanation of <thingList> format.
After the :FRAME-THINGS call, the clipping planes will be set fairly close to given things. If you have background stuff you want visible, or if you intend to fly through the things, you may want to expand the <tfm> :DIAMETER considerably after doing a :FRAME-THINGS.
If :FRAME-TIGHTLY is non-nil, the things will be made to very nearly fill the viewport, otherwise enough room will be left that they can rotate without leaving the viewport.
If :THINGS is not provided explicitly, it should be a property on the <tfm> propertylist.