Camera

The camera is used to render a scene from a specific viewpoint, and has parameters including position, orientation, field of view, and projection mode[1][2] (orthographic or perspective). Engine De...

Updated about 5 years ago

The camera is used to render a scene from a specific viewpoint, and has parameters including position, orientation, field of view, and projection mode[1][2] (orthographic or perspective).

Engine Details

The calling sequence the engine uses to determine the camera position for each viewport are[3]:

  1. UGameViewportClient::Draw
    
  2. ULocalPlayer::CalcSceneView
    
  3. [https://api.unrealengine.com/INT/API/Runtime/Engine/Engine/ULocalPlayer/GetViewPoint/index.html ULocalPlayer::GetViewPoint]
    
  4. [https://api.unrealengine.com/INT/API/Runtime/Engine/GameFramework/APlayerController/GetPlayerViewPoint/index.html APlayerController::GetPlayerViewPoint]
    

    to determine position

    APlayerCameraManager::GetFOVAngle
    

    to determine the field of view.

  5. APlayerController::GetViewTarget
    
  6. APlayerCameraManager::GetViewTarget
    

    to determine the camera position and orientation.

Further Reading

Documentation

API

References

  1. 3D Projection | Wikipedia
  2. Camera matrix | Wikipedia
  3. | UE4Examples