Package esys :: Package lsm :: Package vis :: Package core :: Module camera :: Class Camera
[hide private]
[frames] | no frames]

Class Camera

object --+
         |
        Camera
Known Subclasses:

Objects of this class represent a camera.

Instance Methods [hide private]
 
__init__(self)
Initialises camera object.
 
getLookAt(self)
Returns the coordinate at which this camera is looking.
 
getPosn(self)
Returns the position coordinate of this camera.
float
getZoom(self)
Returns the zoom factor.
 
rotate(self, axis, axisPt)
Rotates the camera position and look-at coordinate about the specified axis.
 
rotatePosn(self, axis, axisPt)
Rotates the camera position about the specified axis.
 
setLookAt(self, coord)
Sets the coordinate at which this camera is looking.
 
setPosn(self, coord)
Sets the position coordinate of this camera.
 
setZoom(self, factor)
Decrease the scale of the projection area by the specified factor.

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self)
(Constructor)

 

Initialises camera object.

Overrides: object.__init__

getLookAt(self)

 

Returns the coordinate at which this camera is looking.

Returns:
The coordinate being looked-at by this camera.

getPosn(self)

 

Returns the position coordinate of this camera.

Returns:
Position coordinate of this camera.

getZoom(self)

 

Returns the zoom factor.

Returns: float
The zoom factor.

See Also: setZoom

rotate(self, axis, axisPt)

 

Rotates the camera position and look-at coordinate about the specified axis.

Parameters:
  • axis (iterable of 3 float elements) - Axis of rotation and angle of rotation ( = axis.norm() radians).
  • axisPt (iterable of 3 float elements) - Axis of rotation is assumed to pass through this point.

rotatePosn(self, axis, axisPt)

 

Rotates the camera position about the specified axis.

Parameters:
  • axis (iterable of 3 float elements) - Axis of rotation and angle of rotation ( = axis.norm() radians).
  • axisPt (iterable of 3 float elements) - Axis of rotation is assumed to pass through this point.

setLookAt(self, coord)

 

Sets the coordinate at which this camera is looking.

Parameters:
  • coord (iterable of 3 float elements) - New coordinate to be looked-at by this camera.

setPosn(self, coord)

 

Sets the position coordinate of this camera.

Parameters:
  • coord (iterable of 3 float elements) - New position of this camera.

setZoom(self, factor)

 

Decrease the scale of the projection area by the specified factor. A value greater than 1 is a zoom-in, a value less than 1 is a zoom-out.

Parameters:
  • factor (float) - Zoom multiplier factor > 0.0.