Project

General

Profile

SO3Engine
Camera

Functions

int SO3CameraCreate (mmachine m)
 main include
 
int SO3CameraLookAt (mmachine m)
 SO3CameraLookAt : Set a "look at" on the camera.
 
int SO3CameraGetDirection (mmachine m)
 SO3CameraGetDirection : Get the direction of a camera.
 
int SO3CameraGetDerivedDirection (mmachine m)
 SO3CameraGetDerivedDirection : Get the derivated direction of a camera.
 
int SO3CameraGetDerivedUp (mmachine m)
 SO3CameraGetDerivedUp : Gets the derived up vector of the camera, including any rotation inherited from a node attachment and reflection matrix.
 
int SO3CameraGetTriangleCount (mmachine m)
 SO3CameraGetTriangleCount : get the number of triangles rendered in last update.
 
int SO3CameraGetBatchCount (mmachine m)
 SO3CameraGetBatchCount : get the number of batch rendered in last update.
 
int SO3CameraSetViewport (mmachine m)
 SO3CameraSetViewport : Attach a camera to a viewport.
 
int SO3CameraSetFocalLength (mmachine m)
 SO3CameraSetFocalLength : defines focal length of a camera.
 
int SO3CameraGetFocalLength (mmachine m)
 SO3CameraGetFocalLength : Get the focal length of a camera.
 
int SO3CameraSetFOVy (mmachine m)
 SO3CameraSetFOVy : defines FOVy of a camera.
 
int SO3CameraSetLODbias (mmachine m)
 SO3CameraSetLODbias : defines a camera LOD bias.
 
int SO3CameraSetAspectRatio (mmachine m)
 SO3CameraSetAspectRatio : defines the aspect ratio of a camera.
 
int SO3CameraGetAspectRatio (mmachine m)
 SO3CameraGetAspectRatio : get the aspect ratio of a camera.
 
int SO3CameraSetAutoAspectRatio (mmachine m)
 SO3CameraSetAutoAspectRatio : set a camera aspect ratio to automatic.
 
int SO3CameraSetFrustumOffset (mmachine m)
 SO3CameraSetFrustumOffset : defines the frustum offset of a camera.
 
int SO3CameraGetFrustumOffset (mmachine m)
 SO3CameraGetFrustumOffset : get the frustum offset of a camera.
 
int SO3CameraGetFOVy (mmachine m)
 SO3CameraGetFOVy : Get the FOVy of a camera.
 
int SO3CameraGetLODbias (mmachine m)
 SO3CameraGetLODbias : Get the a camera LOD bias.
 
int SO3CameraSetPolygonMode (mmachine m)
 SO3CameraSetPolygonMode : Set the polygon Mode for a given camera.
 
int SO3CameraGetPolygonMode (mmachine m)
 SO3CameraGetPolygonMode : Get the Polygon mode of a camera.
 
int SO3CameraSetProjectionType (mmachine m)
 SO3CameraSetProjectionType : Sets the type of projection to use (orthographic or perspective). Default is perspective.
 
int SO3CameraGetProjectionType (mmachine m)
 SO3CameraGetProjectionType : Get the camera projection type.
 
int SO3CameraSetOrthoWindow (mmachine m)
 SO3CameraSetOrthoWindow : Sets the orthographic window settings, for use with orthographic rendering only.
 
int SO3CameraGetOrthoWindow (mmachine m)
 SO3CameraGetOrthoWindow : Gets the orthographic window settings, for use with orthographic rendering only.
 
int SO3CameraSetNearClipDistance (mmachine m)
 SO3CameraSetNearClipDistance : defines near clip distance of a camera.
 
int SO3CameraGetNearClipDistance (mmachine m)
 SO3CameraGetNearClipDistance : Get the near clip distance of a camera.
 
int SO3CameraSetFarClipDistance (mmachine m)
 SO3CameraSetFarClipDistance : defines far clip distance of a camera.
 
int SO3CameraGetFarClipDistance (mmachine m)
 SO3CameraGetFarClipDistance : Get the far clip distance of a camera.
 
int SO3CameraGetViewport (mmachine m)
 SO3CameraGetViewport : Get the current viewport attached to a camera.
 
int SO3CameraGetNumRenderedFaces (mmachine m)
 SO3CameraGetNumRenderedFaces : Get the numbered of rendered faces for a camera.
 
int SO3CameraSetProjectionMatrix (mmachine m)
 SO3CameraSetProjectionMatrix : Set the camera projection matrix.
 

Detailed Description

Scol functions definition

Function Documentation

◆ SO3CameraCreate()

int SO3CameraCreate ( mmachine  m)

main include

SO3CameraCreate : Create a new camera

Prototype: fun [SO3_SCENE S] SO3_OBJECT

Parameters
SO3_SCENE: current scene
S: given name for the new camera
Returns
SO3_OBJECT : Created camera if success , NIL otherwise

Definition at line 56 of file SCOLCamera.cpp.

◆ SO3CameraGetAspectRatio()

int SO3CameraGetAspectRatio ( mmachine  m)

SO3CameraGetAspectRatio : get the aspect ratio of a camera.

Prototype: fun [SO3_OBJECT] F

Parameters
SO3_OBJECT: current camera
Returns
F : ratio if success , NIL otherwise

Definition at line 685 of file SCOLCamera.cpp.

◆ SO3CameraGetBatchCount()

int SO3CameraGetBatchCount ( mmachine  m)

SO3CameraGetBatchCount : get the number of batch rendered in last update.

Prototype: fun [SO3_OBJECT] I

Parameters
SO3_OBJECT: current camera
Returns
I : number of batch if success , NIL otherwise

Definition at line 360 of file SCOLCamera.cpp.

◆ SO3CameraGetDerivedDirection()

int SO3CameraGetDerivedDirection ( mmachine  m)

SO3CameraGetDerivedDirection : Get the derivated direction of a camera.

Prototype: fun [SO3_OBJECT] [F F F]

Parameters
SO3_OBJECT: current camera
Returns
[F F F] : Derivated direction vector if success , NIL otherwise

Definition at line 214 of file SCOLCamera.cpp.

◆ SO3CameraGetDerivedUp()

int SO3CameraGetDerivedUp ( mmachine  m)

SO3CameraGetDerivedUp : Gets the derived up vector of the camera, including any rotation inherited from a node attachment and reflection matrix.

Prototype: fun [SO3_OBJECT] [F F F]

Parameters
SO3_OBJECT: current camera
Returns
[F F F] : Derivated up vector if success , NIL otherwise

Definition at line 267 of file SCOLCamera.cpp.

◆ SO3CameraGetDirection()

int SO3CameraGetDirection ( mmachine  m)

SO3CameraGetDirection : Get the direction of a camera.

Prototype: fun [SO3_OBJECT] [F F F]

Parameters
SO3_OBJECT: current camera
Returns
(F F F] : Direction vector if success , NIL otherwise

Definition at line 160 of file SCOLCamera.cpp.

◆ SO3CameraGetFarClipDistance()

int SO3CameraGetFarClipDistance ( mmachine  m)

SO3CameraGetFarClipDistance : Get the far clip distance of a camera.

Prototype: fun [SO3_OBJECT] F

Parameters
SO3_OBJECT: current camera
Returns
F : Far clip distance if success , NIL otherwise

Definition at line 1410 of file SCOLCamera.cpp.

◆ SO3CameraGetFocalLength()

int SO3CameraGetFocalLength ( mmachine  m)

SO3CameraGetFocalLength : Get the focal length of a camera.

Prototype: fun [SO3_OBJECT] F

Parameters
SO3_OBJECT: current camera
Returns
F : focal length if success , NIL otherwise

Definition at line 505 of file SCOLCamera.cpp.

◆ SO3CameraGetFOVy()

int SO3CameraGetFOVy ( mmachine  m)

SO3CameraGetFOVy : Get the FOVy of a camera.

Prototype: fun [SO3_OBJECT] F

Parameters
SO3_OBJECT: current camera
Returns
F : FOVy if success , NIL otherwise

Definition at line 875 of file SCOLCamera.cpp.

◆ SO3CameraGetFrustumOffset()

int SO3CameraGetFrustumOffset ( mmachine  m)

SO3CameraGetFrustumOffset : get the frustum offset of a camera.

Prototype: fun [SO3_OBJECT] [F F]

Parameters
SO3_OBJECT: current camera
Returns
[F F] : x and y offset if success , NIL otherwise

Definition at line 824 of file SCOLCamera.cpp.

◆ SO3CameraGetLODbias()

int SO3CameraGetLODbias ( mmachine  m)

SO3CameraGetLODbias : Get the a camera LOD bias.

Prototype: fun [SO3_OBJECT] F

Parameters
SO3_OBJECT: current camera
Returns
F : LOD bias value if success , NIL otherwise

Definition at line 916 of file SCOLCamera.cpp.

◆ SO3CameraGetNearClipDistance()

int SO3CameraGetNearClipDistance ( mmachine  m)

SO3CameraGetNearClipDistance : Get the near clip distance of a camera.

Prototype: fun [SO3_OBJECT] F

Parameters
SO3_OBJECT: current camera
Returns
F : Near clip distance if success , NIL otherwise

Definition at line 1324 of file SCOLCamera.cpp.

◆ SO3CameraGetNumRenderedFaces()

int SO3CameraGetNumRenderedFaces ( mmachine  m)

SO3CameraGetNumRenderedFaces : Get the numbered of rendered faces for a camera.

Prototype: fun [SO3_OBJECT] I

Parameters
SO3_OBJECT: current camera
Returns
I : numbered of rendered faces if success , NIL otherwise

Definition at line 1504 of file SCOLCamera.cpp.

◆ SO3CameraGetOrthoWindow()

int SO3CameraGetOrthoWindow ( mmachine  m)

SO3CameraGetOrthoWindow : Gets the orthographic window settings, for use with orthographic rendering only.

Prototype: fun [SO3_OBJECT] [F F]

Parameters
SO3_OBJECT: current camera
Returns
[F F]: Width and height of the orthographic window, in world unit, if success , NIL otherwise

Definition at line 1221 of file SCOLCamera.cpp.

◆ SO3CameraGetPolygonMode()

int SO3CameraGetPolygonMode ( mmachine  m)

SO3CameraGetPolygonMode : Get the Polygon mode of a camera.

Prototype: fun [SO3_OBJECT] I

Parameters
SO3_OBJECT: current camera
Returns
I : Polygon Mode if success , NIL otherwise

For polygon mode, values are :

  • SO3_POLY_POINTS
  • SO3_POLY_SOLID
  • SO3_POLY_WIREFRAME

Definition at line 1019 of file SCOLCamera.cpp.

◆ SO3CameraGetProjectionType()

int SO3CameraGetProjectionType ( mmachine  m)

SO3CameraGetProjectionType : Get the camera projection type.

Prototype: fun [SO3_OBJECT] I

Parameters
SO3_OBJECT: current camera
Returns
I : Projection type if success , NIL otherwise

For projection type, values are :

  • SO3_PROJECTION_PERSPECTIVE
  • SO3_PROJECTION_ORTHOGRAPHIC

Definition at line 1126 of file SCOLCamera.cpp.

◆ SO3CameraGetTriangleCount()

int SO3CameraGetTriangleCount ( mmachine  m)

SO3CameraGetTriangleCount : get the number of triangles rendered in last update.

Prototype: fun [SO3_OBJECT] I

Parameters
SO3_OBJECT: current camera
Returns
I : number of triangles if success , NIL otherwise

Definition at line 320 of file SCOLCamera.cpp.

◆ SO3CameraGetViewport()

int SO3CameraGetViewport ( mmachine  m)

SO3CameraGetViewport : Get the current viewport attached to a camera.

Prototype: fun [SO3_OBJECT] SO3_VIEWPORT

Parameters
SO3_OBJECT: current camera
Returns
SO3_VIEWPORT : Attached viewport if success , NIL otherwise

Definition at line 1452 of file SCOLCamera.cpp.

◆ SO3CameraLookAt()

int SO3CameraLookAt ( mmachine  m)

SO3CameraLookAt : Set a "look at" on the camera.

Prototype: fun [SO3_OBJECT [F F F]] I

Parameters
SO3_OBJECT: current camera
[FF F] : The "look at" vector
Returns
I : 1 if success , NIL otherwise

Definition at line 105 of file SCOLCamera.cpp.

◆ SO3CameraSetAspectRatio()

int SO3CameraSetAspectRatio ( mmachine  m)

SO3CameraSetAspectRatio : defines the aspect ratio of a camera.

Prototype: fun [SO3_OBJECT F] I

Parameters
SO3_OBJECT: current camera
F: ratio
Returns
I : 1 if success , NIL otherwise

Definition at line 644 of file SCOLCamera.cpp.

◆ SO3CameraSetAutoAspectRatio()

int SO3CameraSetAutoAspectRatio ( mmachine  m)

SO3CameraSetAutoAspectRatio : set a camera aspect ratio to automatic.

Prototype: fun [SO3_OBJECT I] I

Parameters
SO3_OBJECT: current camera
I: state
Returns
I : 1 if success , NIL otherwise

Definition at line 725 of file SCOLCamera.cpp.

◆ SO3CameraSetFarClipDistance()

int SO3CameraSetFarClipDistance ( mmachine  m)

SO3CameraSetFarClipDistance : defines far clip distance of a camera.

Prototype: fun [SO3_OBJECT F] I

Parameters
SO3_OBJECT: current camera
F: Far clip distance
Returns
I : 1 if success , NIL otherwise

Definition at line 1367 of file SCOLCamera.cpp.

◆ SO3CameraSetFocalLength()

int SO3CameraSetFocalLength ( mmachine  m)

SO3CameraSetFocalLength : defines focal length of a camera.

Prototype: fun [SO3_OBJECT F] I

Parameters
SO3_OBJECT: current camera
F: focal length
Returns
I : 1 if success , NIL otherwise

Definition at line 456 of file SCOLCamera.cpp.

◆ SO3CameraSetFOVy()

int SO3CameraSetFOVy ( mmachine  m)

SO3CameraSetFOVy : defines FOVy of a camera.

Prototype: fun [SO3_OBJECT F] I

Parameters
SO3_OBJECT: current camera
F: given FOVy
Returns
I : 1 if success , NIL otherwise

Definition at line 547 of file SCOLCamera.cpp.

◆ SO3CameraSetFrustumOffset()

int SO3CameraSetFrustumOffset ( mmachine  m)

SO3CameraSetFrustumOffset : defines the frustum offset of a camera.

Prototype: fun [SO3_OBJECT F F] I

Parameters
SO3_OBJECT: current camera
F: X offset
F: Y offset
Returns
I : 1 if success , NIL otherwise

Definition at line 774 of file SCOLCamera.cpp.

◆ SO3CameraSetLODbias()

int SO3CameraSetLODbias ( mmachine  m)

SO3CameraSetLODbias : defines a camera LOD bias.

Prototype: fun [SO3_OBJECT F] I

Parameters
SO3_OBJECT: current camera
F: LOD bias value, must be > 0.0
Returns
I : 1 if success , NIL otherwise

Definition at line 590 of file SCOLCamera.cpp.

◆ SO3CameraSetNearClipDistance()

int SO3CameraSetNearClipDistance ( mmachine  m)

SO3CameraSetNearClipDistance : defines near clip distance of a camera.

Prototype: fun [SO3_OBJECT F] I

Parameters
SO3_OBJECT: current camera
F: Near clip distance
Returns
I : 1 if success , NIL otherwise

Definition at line 1274 of file SCOLCamera.cpp.

◆ SO3CameraSetOrthoWindow()

int SO3CameraSetOrthoWindow ( mmachine  m)

SO3CameraSetOrthoWindow : Sets the orthographic window settings, for use with orthographic rendering only.

Prototype: fun [SO3_OBJECT F F] I

Parameters
SO3_OBJECT: current camera
F: width in world unit
F: height in world unit
Returns
I : 1 if success , NIL otherwise

Definition at line 1176 of file SCOLCamera.cpp.

◆ SO3CameraSetPolygonMode()

int SO3CameraSetPolygonMode ( mmachine  m)

SO3CameraSetPolygonMode : Set the polygon Mode for a given camera.

Prototype: fun [SO3_OBJECT I] I

Parameters
SO3_OBJECT: current camera
I: Polygon Mode

For polygon mode, values are :

  • SO3_POLY_POINTS
  • SO3_POLY_SOLID
  • SO3_POLY_WIREFRAME
Returns
I : 1 if success , NIL otherwise

Definition at line 964 of file SCOLCamera.cpp.

◆ SO3CameraSetProjectionMatrix()

int SO3CameraSetProjectionMatrix ( mmachine  m)

SO3CameraSetProjectionMatrix : Set the camera projection matrix.

Prototype: fun [SO3_OBJECT [[F F F F] [F F F F] [F F F F] [F F F F]]] I

Parameters
SO3_OBJECT: current camera
[[FF F F] [F F F F] [F F F F] [F F F F]] : projection matrix
Returns
I : 1 if success, NIL otherwise

Definition at line 1548 of file SCOLCamera.cpp.

◆ SO3CameraSetProjectionType()

int SO3CameraSetProjectionType ( mmachine  m)

SO3CameraSetProjectionType : Sets the type of projection to use (orthographic or perspective). Default is perspective.

Prototype: fun [SO3_OBJECT I] I

Parameters
SO3_OBJECT: current camera
I: Projection Type Mode

For polygon mode, values are :

  • SO3_PROJECTION_ORTHOGRAPHIC
  • SO3_PROJECTION_PERSPECTIVE
Returns
I : 1 if success , NIL otherwise

Definition at line 1074 of file SCOLCamera.cpp.

◆ SO3CameraSetViewport()

int SO3CameraSetViewport ( mmachine  m)

SO3CameraSetViewport : Attach a camera to a viewport.

Prototype: fun [SO3_VIEWPORT SO3_OBJECT] I

Parameters
SO3_VIEWPORT: current viewport
SO3_OBJECT: current camera
Returns
1 : 1 if success , NIL otherwise

Definition at line 401 of file SCOLCamera.cpp.