Game Development Reference
In-Depth Information
iTween.MoveTo(gameObject, iTween.Hash("path",
iTweenPath.GetPath("Camera Fly") , "time", 4f, "easetype",
iTween.EaseType.easeInOutSine));
}
}
More information on iTween and its usage can be found online at
http://itween.pixelplacement.com/gettingstarted.php .
Summary
This chapter concentrated on many common tasks expected or needed of cameras.
Cameras are essential in Unity and in any game engine, because they represent
the perspective from which the scene is rendered to the screen. Most of the camera
functionality is commonly taken for granted in Unity, and as a result, much of the
flexibility and control that cameras offer us is lost and not discussed. Specifically,
here, we first considered gizmo rendering, that is, how to permanently render the
camera gizmo in the scene viewport even when the camera is deselected. Second,
we saw how to determine which objects are visible to the camera and which are
not. This included several kinds of important tests such as frustum presence and
occlusion testing. Third, we saw how to create and configure orthographic cameras
that render 2D elements without perspective distortion. Fourth, we saw how to edit
and enhance a camera render through render textures. This involved overriding a
series of camera-critical events and blending renders from other cameras to create
a camera cross-fade effect. Fifth, we saw how to create more advanced camera
motions, such as camera shake. Finally, you learned about camera paths, that is, the
ability for a camera to follow a specified path, whether this path was defined by a
series of game object waypoints or was simply an object to follow. Next up, we'll
explore the Mono Framework further.
 
Search WWH ::




Custom Search