unreal.TimeManagementLibrary

class unreal.TimeManagementLibrary(outer=None, name='None')

Bases: unreal.BlueprintFunctionLibrary

Time Management Blueprint Library

C++ Source:

  • Module: TimeManagement

  • File: TimeManagementBlueprintLibrary.h

classmethod add_frame_number_frame_number(a, b)FrameNumber

Addition (FrameNumber A + FrameNumber B)

Parameters
Returns

Return type

FrameNumber

classmethod add_frame_number_integer(a, b)FrameNumber

Addition (FrameNumber A + int B)

Parameters
Returns

Return type

FrameNumber

classmethod conv_frame_rate_to_seconds(frame_rate)float

Converts an FrameRate to a float ie: 1/30 returns 0.0333333

Parameters

frame_rate (FrameRate) –

Returns

Return type

float

classmethod conv_qualified_frame_time_to_seconds(frame_time)float

Converts an QualifiedFrameTime to seconds.

Parameters

frame_time (QualifiedTime) –

Returns

Return type

float

classmethod conv_timecode_to_string(timecode, force_sign_display=False)str

Converts an Timecode to a string (hh:mm:ss:ff). If bForceSignDisplay then the number sign will always be prepended instead of just when expressing a negative time.

Parameters
Returns

Return type

str

classmethod divide_frame_number_integer(a, b)FrameNumber

Divide (FrameNumber A / B)

Parameters
Returns

Return type

FrameNumber

classmethod frame_number_to_integer(frame_number)int32

Converts a FrameNumber to an int32 for use in functions that take int32 frame counts for convenience.

Parameters

frame_number (FrameNumber) –

Returns

Return type

int32

classmethod get_timecode()Timecode

Get the current timecode of the engine.

Returns

Return type

Timecode

classmethod get_timecode_frame_rate()FrameRate

Gets the current timecode frame rate.

Returns

Return type

FrameRate

classmethod is_valid_framerate(frame_rate)bool

Verifies that this is a valid framerate with a non-zero denominator.

Parameters

frame_rate (FrameRate) –

Returns

Return type

bool

classmethod is_valid_multiple_of(frame_rate, other_framerate)bool

Checks if this framerate is an even multiple of another framerate, ie: 60 is a multiple of 30, but 59.94 is not.

Parameters
Returns

Return type

bool

classmethod multiply_frame_number_integer(a, b)FrameNumber

Multiply (FrameNumber A * B)

Parameters
Returns

Return type

FrameNumber

classmethod multiply_seconds_frame_rate(time_in_seconds, frame_rate)FrameTime

Multiplies a value in seconds against a FrameRate to get a new FrameTime.

Parameters
Returns

Return type

FrameTime

classmethod snap_frame_time_to_rate(source_time, source_rate, snap_to_rate)FrameTime

Snaps the given SourceTime to the nearest frame in the specified Destination Framerate. Useful for determining the nearest frame for another resolution. Returns the frame time in the destination frame rate.

Parameters
Returns

Return type

FrameTime

classmethod subtract_frame_number_frame_number(a, b)FrameNumber

Subtraction (FrameNumber A - FrameNumber B)

Parameters
Returns

Return type

FrameNumber

classmethod subtract_frame_number_integer(a, b)FrameNumber

Subtraction (FrameNumber A - int B)

Parameters
Returns

Return type

FrameNumber

classmethod transform_time(source_time, source_rate, destination_rate)FrameTime

Converts the specified time from one framerate to another framerate. This is useful for converting between tick resolution and display rate.

Parameters
Returns

Return type

FrameTime