c4d.modules.motiontracker.MtData

class c4d.modules.motiontracker.MtData

New in version R18.020.

Methods Signatures

MtData.GetNormalisedPosition()

Retrieves the track position in normalized coordinates.

MtData.GetPixelPosition()

Retrieves the track position in pixel coordinates.

MtData.GetCameraSpaceDirection()

Retrieves the camera space ray corresponding to track position.

Methods Documentation

MtData.GetNormalisedPosition(self)

Retrieves the track position in normalized coordinates.

Note

x is in range -0.5 to +0.5 from left to right of image.
y is in range -0.5/aspect to +0.5/aspect from top to bottom of image, where aspect is the image aspect ratio.
Return type

c4d.Vector

Returns

The track position in normalized coordinates.

MtData.GetPixelPosition(self, footageData, originalRes)

Retrieves the track position in pixel coordinates.

Parameters
  • footageData (c4d.modules.motiontracker.MtFootageData) – The footage object (used to define resolution and aspect ratio).

  • originalRes (int) –

    If True, returns pixel coordinates for the original footage.
    If False, returns pixel coordinates for the downsampled footage.

Return type

c4d.Vector

Returns

The track position in pixel coordinates.

MtData.GetCameraSpaceDirection(self, focalLength, sensorWidth)

Retrieves the camera space ray corresponding to track position.

Parameters
  • focalLength (float) – The focal length to use for the camera (mm).

  • sensorWidth (float) – The sensor width to use for the camera (mm).

Return type

c4d.Vector

Returns

The ray in camera space corresponding to the position of the track.