engine
 
载入中...
搜索中...
未找到
Public 成员函数 | 静态 Public 成员函数 | Public 属性 | 所有成员列表
FTimecode结构体 参考

A timecode that stores time in HH:MM:SS format with the remainder of time represented by an integer frame count. 更多...

#include <Timecode.h>

Public 成员函数

 FTimecode ()
 Default construction for UObject purposes
 
 FTimecode (double InSeconds, const FFrameRate &InFrameRate, bool InbDropFrame, bool InbRollover)
 User construction from a time in seconds 更多...
 
 FTimecode (double InSeconds, const FFrameRate &InFrameRate, bool InbRollover)
 User construction from a time in seconds 更多...
 
 FTimecode (int32 InHours, int32 InMinutes, int32 InSeconds, int32 InFrames, bool InbDropFrame)
 User construction from a number of hours minutes seconds and frames. 更多...
 
FFrameNumber ToFrameNumber (const FFrameRate &InFrameRate) const
 Converts this Timecode back into a Frame Number at the given framerate, taking into account if this is a drop-frame format timecode.
 
FString ToString (bool bForceSignDisplay=false) const
 Get the Qualified Timecode formatted in HH:MM:SS:FF or HH:MM:SS;FF depending on if this represents drop-frame timecode or not. 更多...
 
FTimespan ToTimespan (const FFrameRate &InFrameRate) const
 Converts this Timecode back into a timespan at the given framerate, taking into account if this is a drop-frame format timecode.
 

静态 Public 成员函数

static FTimecode FromFrameNumber (const FFrameNumber &InFrameNumber, const FFrameRate &InFrameRate)
 Create a FTimecode from a specific frame number at the given frame rate. 更多...
 
static FTimecode FromFrameNumber (const FFrameNumber &InFrameNumber, const FFrameRate &InFrameRate, bool InbDropFrame)
 Create a FTimecode from a specific frame number at the given frame rate. 更多...
 
static FTimecode FromTimespan (const FTimespan &InTimespan, const FFrameRate &InFrameRate, bool InbDropFrame, bool InbRollover)
 Create a FTimecode from a timespan at the given frame rate. 更多...
 
static FTimecode FromTimespan (const FTimespan &InTimespan, const FFrameRate &InFrameRate, bool InbRollover)
 Create a FTimecode from a timespan at the given frame rate. 更多...
 
static bool IsDropFormatTimecodeSupported (const FFrameRate &InFrameRate)
 Drop frame is only support for frame rate of 29.97 or 59.94.
 
static bool UseDropFormatTimecode (const FFrameRate &InFrameRate)
 If the frame rate support drop frame format and the app wish to use drop frame format by default.
 
static CORE_API bool UseDropFormatTimecodeByDefaultWhenSupported ()
 By default, should we generate a timecode in drop frame format when the frame rate does support it.
 

Public 属性

bool bDropFrameFormat
 If true, this Timecode represents a Drop Frame timecode used to account for fractional frame rates in NTSC play rates.
 
int32 Frames
 How many frames does this timecode represent
 
int32 Hours
 How many hours does this timecode represent
 
int32 Minutes
 How many minutes does this timecode represent
 
int32 Seconds
 How many seconds does this timecode represent
 

详细描述

A timecode that stores time in HH:MM:SS format with the remainder of time represented by an integer frame count.

构造及析构函数说明

◆ FTimecode() [1/3]

FTimecode::FTimecode ( int32  InHours,
int32  InMinutes,
int32  InSeconds,
int32  InFrames,
bool  InbDropFrame 
)
inlineexplicit

User construction from a number of hours minutes seconds and frames.

参数
InbDropFrame- If true, this Timecode represents a "Drop Frame Timecode" format which skips the first frames of every minute (except those ending in multiples of 10) to account for drift when using a fractional NTSC framerate.

◆ FTimecode() [2/3]

FTimecode::FTimecode ( double  InSeconds,
const FFrameRate &  InFrameRate,
bool  InbDropFrame,
bool  InbRollover 
)
inlineexplicit

User construction from a time in seconds

参数
InbDropFrame- If true, this Timecode represents a "Drop Frame Timecode" format which skips the first frames of every minute (except those ending in multiples of 10) to account for drift when using a fractional NTSC framerate.
InbRollover- If true, the hours will be the modulo of 24.
注解
Be aware that the Cycles may not correspond to the System Time. See FDateTime and "leap seconds".

◆ FTimecode() [3/3]

FTimecode::FTimecode ( double  InSeconds,
const FFrameRate &  InFrameRate,
bool  InbRollover 
)
inlineexplicit

User construction from a time in seconds

参数
InbRollover- If true, the hours will be the modulo of 24.
注解
Be aware that the Cycles may not correspond to the System Time. See FDateTime and "leap seconds".

成员函数说明

◆ FromFrameNumber() [1/2]

static FTimecode FTimecode::FromFrameNumber ( const FFrameNumber &  InFrameNumber,
const FFrameRate &  InFrameRate 
)
inlinestatic

Create a FTimecode from a specific frame number at the given frame rate.

参数
InFrameNumber- The frame number to convert into a timecode. This should already be converted to InFrameRate's resolution.
InFrameRate- The framerate that this timecode is based in. This should be the playback framerate as it is used to determine when the Frame value wraps over.

◆ FromFrameNumber() [2/2]

static FTimecode FTimecode::FromFrameNumber ( const FFrameNumber &  InFrameNumber,
const FFrameRate &  InFrameRate,
bool  InbDropFrame 
)
inlinestatic

Create a FTimecode from a specific frame number at the given frame rate.

Optionally supports creating a drop frame timecode, which drops certain timecode display numbers to help account for NTSC frame rates which are fractional.

参数
InFrameNumber- The frame number to convert into a timecode. This should already be converted to InFrameRate's resolution.
InFrameRate- The framerate that this timecode is based in. This should be the playback framerate as it is used to determine when the Frame value wraps over.
InbDropFrame- If true, the returned timecode will drop the first two frames on every minute (except when Minute % 10 == 0) This is only valid for NTSC framerates (29.97, 59.94) and will assert if you try to create a drop-frame format from a non-valid framerate. All framerates can be represented when in non-drop frame format.

◆ FromTimespan() [1/2]

static FTimecode FTimecode::FromTimespan ( const FTimespan &  InTimespan,
const FFrameRate &  InFrameRate,
bool  InbDropFrame,
bool  InbRollover 
)
inlinestatic

Create a FTimecode from a timespan at the given frame rate.

Optionally supports creating a drop frame timecode, which drops certain timecode display numbers to help account for NTSC frame rates which are fractional.

参数
InFrameNumber- The timespan to convert into a timecode.
InFrameRate- The framerate that this timecode is based in. This should be the playback framerate as it is used to determine when the Frame value wraps over.
InbDropFrame- If true, the returned timecode will drop the first two frames on every minute (except when Minute % 10 == 0) This is only valid for NTSC framerates (29.97, 59.94) and will assert if you try to create a drop-frame format from a non-valid framerate. All framerates can be represented when in non-drop frame format.
InbRollover- If true, the hours will be the modulo of 24.

◆ FromTimespan() [2/2]

static FTimecode FTimecode::FromTimespan ( const FTimespan &  InTimespan,
const FFrameRate &  InFrameRate,
bool  InbRollover 
)
inlinestatic

Create a FTimecode from a timespan at the given frame rate.

参数
InFrameNumber- The timespan to convert into a timecode.
InFrameRate- The framerate that this timecode is based in. This should be the playback framerate as it is used to determine when the Frame value wraps over.
InbRollover- If true, the hours will be the modulo of 24.

◆ ToString()

FString FTimecode::ToString ( bool  bForceSignDisplay = false) const
inline

Get the Qualified Timecode formatted in HH:MM:SS:FF or HH:MM:SS;FF depending on if this represents drop-frame timecode or not.

参数
bForceSignDisplay- Forces the timecode to be prepended with a positive or negative sign. Standard behavior is to only show the sign when the value is negative.

该结构体的文档由以下文件生成: