I've been thinking of ways to handle placing my GUI interface in a 3D perspective projection, so that I can have 3D rotation effects on my "2D" interface elements. The problem I've been having is that it's been difficult positioning elements and making certain they all fit in view at once.
The idea I've had so far is to define a 2D quad in space to represent a "screen" surface, and layout the GUI on top of the quad in the same way I'd layout the gui in 2D. Then I'd move the camera to the center of the quad, point the camera at it and project the camera's position a certain distance along the quad's surface normal until the entire quad fits into the viewing frustum. The problem with that is I'm not sure how to find the minimum distance to project the camera position.
Anyone know an equation/algorithm for finding this?