![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <FrameRate.h>
Inheritance diagram for FFrameRate:Public Member Functions | |
| FFrameRate () | |
| FFrameRate (uint32 InNumerator, uint32 InDenominator) | |
| bool | IsValid () const |
| double | AsInterval () const |
| double | AsDecimal () const |
| double | AsSeconds (FFrameTime FrameNumber) const |
| FFrameTime | AsFrameTime (double InTimeSeconds) const |
| FFrameNumber | AsFrameNumber (double InTimeSeconds) const |
| bool | IsMultipleOf (FFrameRate Other) const |
| bool | IsFactorOf (FFrameRate Other) const |
| CORE_API FText | ToPrettyText () const |
| CORE_API bool | ComputeGridSpacing (const float PixelsPerSecond, double &OutMajorInterval, int32 &OutMinorDivisions, float MinTickPx=30.f, float DesiredMajorTickPx=120.f) const |
| CORE_API double | MaxSeconds () const |
| FFrameRate | Reciprocal () const |
| CORE_API bool | Serialize (FArchive &Ar) |
Static Public Member Functions | |
| static FFrameTime | TransformTime (FFrameTime SourceTime, FFrameRate SourceRate, FFrameRate DestinationRate) |
| static FFrameTime | Snap (FFrameTime SourceTime, FFrameRate SourceRate, FFrameRate SnapToRate) |
Public Attributes | |
| int32 | Numerator |
| int32 | Denominator |
Friends | |
| bool | operator== (const FFrameRate &A, const FFrameRate &B) |
| bool | operator!= (const FFrameRate &A, const FFrameRate &B) |
| FFrameRate | operator* (FFrameRate A, FFrameRate B) |
| FFrameRate | operator/ (FFrameRate A, FFrameRate B) |
| double | operator/ (FFrameNumber Frame, FFrameRate Rate) |
| TRange< double > | operator/ (const TRange< FFrameNumber > &FrameRange, FFrameRate Rate) |
| double | operator/ (FFrameTime FrameTime, FFrameRate Rate) |
| FFrameTime | operator* (double TimeInSeconds, FFrameRate Rate) |
| FFrameTime | operator* (float TimeInSeconds, FFrameRate Rate) |
| uint32 | GetTypeHash (const FFrameRate &Rate) |
| CORE_API FArchive & | operator<< (FArchive &Ar, FFrameRate &FrameRate) |
A frame rate represented as a fraction comprising 2 integers: a numerator (number of frames), and a denominator (per second)
|
inline |
Default construction to a frame rate of 60000 frames per second (0.0166 ms)
|
inline |
Get the decimal representation of this framerate
|
inline |
Convert the specified time in seconds to a frame number by rounding down to the nearest integer.
| InTimeSeconds | The time to convert in seconds |
|
inline |
Convert the specified time in seconds to a frame number by rounding down to the nearest integer.
| InTimeSeconds | The time to convert in seconds |
|
inline |
Get the decimal representation of this framerate's interval
|
inline |
Convert the specified frame number to a floating-point number of seconds based on this framerate
| FrameNumber | The frame number to convert |
| bool FFrameRate::ComputeGridSpacing | ( | const float | PixelsPerSecond, |
| double & | OutMajorInterval, | ||
| int32 & | OutMinorDivisions, | ||
| float | MinTickPx = 30.f, |
||
| float | DesiredMajorTickPx = 120.f |
||
| ) | const |
Compute a desirable grid spacing for the specified screen units
| PixelsPerSecond | The number of pixels representing a second of time |
| OutMajorInterval | (Out) The interval in seconds at which to draw major grid lines |
| OutMinorDivisions | (Out) The number of divisions to draw between major tick lines |
| MinTickPx | (Optional) The smallest size in pixels that is desirable between ticks |
| DesiredMajorTickPx | (Optional) The desired size to compute major tick lines from |
|
inline |
Check whether this frame rate is a factor of another
|
inline |
Check whether this frame rate is a multiple of another
|
inline |
Verify that this frame rate is valid to use
| double FFrameRate::MaxSeconds | ( | ) | const |
Get the maximum number of seconds representable with this framerate
|
inline |
Get the reciprocal of this frame rate
|
inlinestatic |
Snap a time specified in one framerate, to another
| SourceTime | The frame number to convert |
| SourceRate | The source frame rate |
| SnapToRate | The destination frame rate |
| FText FFrameRate::ToPrettyText | ( | ) | const |
Convert this frame rate to a prettified text string.
|
inlinestatic |
Convert the specified time from one framerate to another framerate
| SourceTime | The frame number to convert |
| SourceRate | The source frame rate |
| DestinationRate | The destination frame rate |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
| int32 FFrameRate::Denominator |
The denominator of the framerate represented as a number of frames per second (e.g. 1 for 60 fps)
| int32 FFrameRate::Numerator |
IMPORTANT: If you change the struct data, ensure that you also update the version in NoExportTypes.h
The numerator of the framerate represented as a number of frames per second (e.g. 60 for 60 fps)