Main Page Modules Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages

# IdeCamera Class Reference

`#include <deCamera.hpp>`

Inheritance diagram for IdeCamera:

[legend]
List of all members.

## Public Member Functions
virtual long | Release ()=0
| deletes the object
virtual void | SetWindow (HWND window)=0
| Match the camera with a window handle. Multiple cameras may share a window handle.
virtual void | SetRect (deRect rect)=0
| Set the client rect of the camera's viewport, which the scene will be rendered into.
virtual void | SetFOV (deDouble Degrees)=0
| Set the horizontal Field-of-View of the camera, in degrees.
virtual void | SetScreenAspect (long PixelWidth, long PixelHeight, deDouble AspectRatio)=0
| Set the screen aspect ratio (AspectRatio = 4/3 or 16/9, defaults to 4/3).
virtual void | SetClip (deDouble Near, deDouble Far)=0
| Set the near and far clip planes of the camera's viewport.
virtual void | FogEnable (deBoolean Enable)=0
virtual void | SetFog (deFloat Near, deFloat Far, deARGB Color, deBoolean RangeFog=(DE_FALSE))=0
virtual void | SetOrthoWidth (deDouble Width)=0
| Set the width of the camera, if it will be an orthographic projection.
virtual void | EnableOrtho (deBoolean OrthoEnable)=0
| Enable or disable an orthographic (parallel) projection mode.
virtual deBoolean | BuildRootFrustum (IdePlaneFrustum *pFrustum)=0
| Build a frustum from this camera based on its rect and transform.
virtual deVec3d | ScreenPointToWorldVec (int x, int y, deVec3d *StartPosition)=0
virtual deBoolean | WorldPosToScreenPos (const deVec3d &pos, int &x, int &y)=0
| Transforms a 3D world position into an (x,y) pair on the screen.
virtual deBoolean | FrustumRect (const IdePlaneFrustum *pFrustum, deRect &ScreenRect)=0
virtual HWND | GetWindow ()=0
| Retrieve the associated window handle.
virtual deRect | GetRect ()=0
| Retrieve the screenrect the camera is using.
virtual deDouble | GetFOV ()=0
| Retrieve the horizontal Field-of-View of the camera, in degrees.
virtual deDouble | GetFOVy (deDouble &Aspect)=0
virtual deDouble | GetNearClip ()=0
| Retrieve the near clip plane distance.
virtual deDouble | GetFarClip ()=0
| Retrieve the far clip plane distance.
virtual deDouble | GetOrthoWidth ()=0
| Retrieve the orthogrpahic width of the camera.
virtual deBoolean | IsOrtho ()=0
virtual deBoolean | GetFog (deFloat &Near, deFloat &Far, deARGB &Color, deBoolean &RangeFog)=0
virtual void | LockAspect (deDouble Aspect)=0
virtual deTransformInfo & | Position ()=0
## Protected Member Functions
virtual | ~IdeCamera (void)

## Detailed Description

Essentially a storage class to interface deRender & deScene - stores things related to the screen view. Related functions: IdeCamera_CreateCamera

## Constructor & Destructor Documentation

virtual IdeCamera::~IdeCamera | ( | void |  | ) | `[inline, protected, virtual]`

## Member Function Documentation

virtual deBoolean IdeCamera::BuildRootFrustum | ( | IdePlaneFrustum * | pFrustum | ) | `[pure virtual]`

| Build a frustum from this camera based on its rect and transform. Implemented in deCamera.

virtual void IdeCamera::EnableOrtho | ( | deBoolean | OrthoEnable | ) | `[pure virtual]`

| Enable or disable an orthographic (parallel) projection mode. Implemented in deCamera.

virtual void IdeCamera::FogEnable | ( | deBoolean | Enable | ) | `[pure virtual]`

| Implemented in deCamera.

virtual deBoolean IdeCamera::FrustumRect | ( | const IdePlaneFrustum * | pFrustum,
|  | deRect & | ScreenRect
| ) | `[pure virtual]`

  | Clips a screen rect to the input frustum Returns: deTrue if successful, deFalse otherwise Parameters:
  Frustum | a valid deFrustum object to be used in clipping a screen-rect
  ScreenRect | a deRect filled with valid screen positions, to be clipped down to the screen-size of Frustum
Implemented in deCamera.

virtual deDouble IdeCamera::GetFarClip | ( |  | ) | `[pure virtual]`

| Retrieve the far clip plane distance. Implemented in deCamera.

virtual deBoolean IdeCamera::GetFog | ( | deFloat & | Near,
|  | deFloat & | Far,
|  | deARGB & | Color,
|  | deBoolean & | RangeFog
| ) | `[pure virtual]`

| Implemented in deCamera.

virtual deDouble IdeCamera::GetFOV | ( |  | ) | `[pure virtual]`

| Retrieve the horizontal Field-of-View of the camera, in degrees. Implemented in deCamera.

virtual deDouble IdeCamera::GetFOVy | ( | deDouble & | Aspect | ) | `[pure virtual]`

  | Retrieve the vertical Field-of-View of the camera, in radians Parameters:
  Aspect | the aspect ratio of the viewport being used. (Aspect = Width/Height). This will be filled with the current "Locked" Aspect if one is set
Implemented in deCamera.

virtual deDouble IdeCamera::GetNearClip | ( |  | ) | `[pure virtual]`

| Retrieve the near clip plane distance. Implemented in deCamera.

virtual deDouble IdeCamera::GetOrthoWidth | ( |  | ) | `[pure virtual]`

| Retrieve the orthogrpahic width of the camera. Implemented in deCamera.

virtual deRect IdeCamera::GetRect | ( |  | ) | `[pure virtual]`

| Retrieve the screenrect the camera is using. Implemented in deCamera.

virtual HWND IdeCamera::GetWindow | ( |  | ) | `[pure virtual]`

| Retrieve the associated window handle. Implemented in deCamera.

virtual deBoolean IdeCamera::IsOrtho | ( |  | ) | `[pure virtual]`

| Tell whether the camera is using an orthographic projection or not Returns: deTrue if an orthographic projection is in use Implemented in deCamera.

virtual void IdeCamera::LockAspect | ( | deDouble | Aspect | ) | `[pure virtual]`

  | Used to lock the aspect of a camera in order to cause a distorted image to render. The return value from GetFOVy will be unaffected by the Aspect actually fed to it. Parameters:
  Aspect | An aspect ratio to lock the camera into using. Use a negative value to unlock.
Implemented in deCamera.

virtual deTransformInfo& IdeCamera::Position | ( |  | ) | `[pure virtual]`

| The current transformation of the camera Returns: a reference to the camera's internal transform, instead of a Get/Set pair. Implemented in deCamera.

virtual long IdeCamera::Release | ( |  | ) | `[pure virtual]`

| deletes the object Implemented in deCamera.

virtual deVec3d IdeCamera::ScreenPointToWorldVec | ( | int | x,
|  | int | y,
|  | deVec3d * | StartPosition
| ) | `[pure virtual]`

  | Retrieve a vector in world-space corresponding to a screen position. Returns: a vector (with Z=1) pointing from the camera's translation along the ray that coincides with the point selected on the near clip plane Parameters:
  a | pointer to a vector in which to store the start point of the ray
Implemented in deCamera.

virtual void IdeCamera::SetClip | ( | deDouble | Near,
|  | deDouble | Far
| ) | `[pure virtual]`

| Set the near and far clip planes of the camera's viewport. Implemented in deCamera.

virtual void IdeCamera::SetFog | ( | deFloat | Near,
|  | deFloat | Far,
|  | deARGB | Color,
|  | deBoolean | RangeFog = (DE_FALSE)
| ) | `[pure virtual]`

| Implemented in deCamera.

virtual void IdeCamera::SetFOV | ( | deDouble | Degrees | ) | `[pure virtual]`

| Set the horizontal Field-of-View of the camera, in degrees. Implemented in deCamera.

virtual void IdeCamera::SetOrthoWidth | ( | deDouble | Width | ) | `[pure virtual]`

| Set the width of the camera, if it will be an orthographic projection. Implemented in deCamera.

virtual void IdeCamera::SetRect | ( | deRect | rect | ) | `[pure virtual]`

| Set the client rect of the camera's viewport, which the scene will be rendered into. Implemented in deCamera.

virtual void IdeCamera::SetScreenAspect | ( | long | PixelWidth,
|  | long | PixelHeight,
|  | deDouble | AspectRatio
| ) | `[pure virtual]`

| Set the screen aspect ratio (AspectRatio = 4/3 or 16/9, defaults to 4/3). Implemented in deCamera.

virtual void IdeCamera::SetWindow | ( | HWND | window | ) | `[pure virtual]`

| Match the camera with a window handle. Multiple cameras may share a window handle. Implemented in deCamera.

virtual deBoolean IdeCamera::WorldPosToScreenPos | ( | const deVec3d & | pos,
|  | int & | x,
|  | int & | y
| ) | `[pure virtual]`

| Transforms a 3D world position into an (x,y) pair on the screen. Implemented in deCamera.

The documentation for this class was generated from the following file:

- deCamera.hpp