v10.50 v10.55 Alpha v10.54 Alpha v10.53 Alpha v10.52 Alpha v10.51 Alpha
v10.50 v10.55 Alpha v10.54 Alpha v10.53 Alpha v10.52 Alpha v10.51 Alpha

Time Calculation Functions

This group of functions covers VSE capability to work with "time", the VSE time objects.

AddTime()

Adds two VSE time objects.

AddTime(time1, time2)

Parameters

time_1

VSE time object representing the first time interval

time_2

VSE time object representing the second time interval

Return values

Returns a VSE time object representing a time interval equal to the sum of time_1 and time_2

Example

t1 = Time(100);
t2 = Time(2, 200);
t3 = AddTime(t1, t2)  # Returns VSE time object = 2 sec 300 ns.

SubtractTime()

Subtracts two VSE time objects.

SubtractTime (time1, time2)

Parameters

time_1

VSE time object representing the first time interval

time_2

VSE time object representing the second time interval

Return values

Returns a VSE time object representing a time interval equal to the subtraction of time_1 and time_2

Example

t1 = Time(100);
t2 = Time(2, 200);
t3 = SubtractTime (t2, t1)  # Returns VSE time object = 2 sec 100 ns.

MulTimeByInt()

Multiplies a VSE time object by an integer value.

MulTimeByInt (time, mult)

Parameters

time

VSE time object

mult

Multiplier, integer value

Return values

Returns a VSE time object representing a time interval equal to time * mult.

Example

t   = Time(2, 200);
t1 = MulTimeByInt (t, 2)  # Returns VSE time object = 4 sec 400 ns.

DivTimeByInt()

Divides a VSE time object by an integer value.

DivTimeByInt (time, div)

Parameters

time

VSE time object

div

Divider, integer value

Return values

Returns a VSE time object representing time interval equal to time / div.

Example

t   = Time(2, 200);
t1 = DivTimeByInt (t, 2)  # Returns VSE time object = 1 sec 100 ns.