wiki:CameraObjects

Version 1 (modified by Jonathan, 13 years ago) ( diff )

BackLinksMenu()

Camera Objects

Camera Objects can be created within the ProblemModuleInit routine in problem.f90. To create Cameras you first need to add two USE statements to your problem.f90

  USE Cameras
  USE Fields

Then in ProblemModuleInit declare a variable pointer of type CameraDef

  TYPE(CameraDef), POINTER :: Camera

Then create the Camera and set the various parameters as in the following example

    CALL CreateCamera(Camera)
    Camera%pos = (/4d0,-10d0,4d0/)
    Camera%UpVector = (/0d0,0d0,1d0/)
    Camera%Focus = (/4d0,4d0,4d0/)
    Camera%FOV = (/30d0,3d0/)

Here is a full list of the various Camera parameters with the default values in brackets:

  
  REAL(KIND=qPREC), DIMENSION(3) :: pos = DEFAULTCAMERAPOS ! Will choose a point at a distance in -y to see the entire domain.
  REAL(KIND=qPREC), DIMENSION(3) :: UpVector=(/0d0,0d0,1d0/)
  REAL(KIND=qPREC), DIMENSION(3) :: Focus = CENTER  !Will select the center of the simulation domain
  REAL(KIND=qPREC) :: FOV= (/30d0, 30d0/)

Attachments (11)

Note: See TracWiki for help on using the wiki.