![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <FrameTime.h>
Public Member Functions | |
| FFrameTime () | |
| template<typename T , typename = typename TEnableIf<std::is_same_v<T, int32>>::Type> | |
| FFrameTime (T InFrameNumber) | |
| FFrameTime (FFrameNumber InFrameNumber) | |
| FFrameTime (FFrameNumber InFrameNumber, float InSubFrame) | |
| FFrameTime & | operator= (FFrameNumber InFrameNumber) |
| bool | Serialize (FArchive &Ar) |
| UE_FORCEINLINE_HINT FFrameNumber | GetFrame () const |
| UE_FORCEINLINE_HINT float | GetSubFrame () const |
| FFrameNumber | FloorToFrame () const |
| FFrameNumber | CeilToFrame () const |
| FFrameNumber | RoundToFrame () const |
| double | AsDecimal () const |
Static Public Member Functions | |
| static FFrameTime | FromDecimal (double InDecimalFrame) |
Public Attributes | |
| FFrameNumber | FrameNumber |
Static Public Attributes | |
| static CORE_API const float | MaxSubframe = 0.99999994f |
Structure representing a time by a context-free frame number, plus a sub frame value in the range [0:1) Conversion to and from time in seconds is achieved in combination with FFrameRate. Only the frame number part of this representation can be negative, sub frames are always a positive value between the frame number and its next logical frame
|
inline |
Default constructor initializing to zero
Implicit construction from a single integer, while disallowing implicit conversion from any other numeric type
|
inline |
Implicit construction from a type-safe frame number
|
inline |
Construction from a frame number and a sub frame
| UE_FORCEINLINE_HINT double FFrameTime::AsDecimal | ( | ) | const |
Retrieve a decimal representation of this frame time Sub frames are always added to the current frame number, so for negative frame times, a time of -10 [sub frame 0.25] will yield a decimal value of -9.75.
| UE_FORCEINLINE_HINT FFrameNumber FFrameTime::CeilToFrame | ( | ) | const |
Return the next frame number greater than or equal to this frame time
| UE_FORCEINLINE_HINT FFrameNumber FFrameTime::FloorToFrame | ( | ) | const |
Return the first frame number less than or equal to this frame time
|
inlinestatic |
Convert a decimal representation to a frame time Note that sub frames are always positive, so negative decimal representations result in an inverted sub frame and floored frame number
|
inline |
Access this time's frame number
|
inline |
Access this time's sub frame
|
inline |
Assignment from a type-safe frame number
| UE_FORCEINLINE_HINT FFrameNumber FFrameTime::RoundToFrame | ( | ) | const |
Round to the nearest frame number
Serializes the given FrameTime from or into the specified archive
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
Serializes the given FrameTime from or into the specified archive.
| Ar | The archive to serialize from or into. |
| FrameTime | The frame time to serialize. |
|
friend |
|
friend |
|
friend |
|
friend |
| FFrameNumber FFrameTime::FrameNumber |
IMPORTANT: If you change the struct data, ensure that you also update the version in NoExportTypes.h
|
static |