Blender V5.3
blender::ScreenFrameRateInfo Struct Reference

Public Attributes

bool fps_target_is_fractional
float fps_target
float fps_average
int times_index
int times_num
int times_num_set
double times [0]

Detailed Description

Ring buffer of recent frame timestamps; FPS is (samples - 1) / (newest - oldest).

Note
Stores timestamps rather than per-sample rates on purpose: averaging 1/interval is biased by short intervals and spikes during uneven timer cadence.

Definition at line 30 of file scene_fps.cc.

Member Data Documentation

◆ fps_average

float blender::ScreenFrameRateInfo::fps_average

Final result, ignore when -1.0.

Definition at line 37 of file scene_fps.cc.

Referenced by blender::ED_scene_fps_average_accumulate(), and blender::ED_scene_fps_average_calc().

◆ fps_target

float blender::ScreenFrameRateInfo::fps_target

The target FPS, use to reset on change.

Definition at line 35 of file scene_fps.cc.

Referenced by blender::ED_scene_fps_average_accumulate(), and blender::ED_scene_fps_average_calc().

◆ fps_target_is_fractional

bool blender::ScreenFrameRateInfo::fps_target_is_fractional

When the target FPS is not a whole number.

Definition at line 32 of file scene_fps.cc.

Referenced by blender::ED_scene_fps_average_accumulate(), and blender::ED_scene_fps_average_calc().

◆ times

double blender::ScreenFrameRateInfo::times[0]

Over-allocated, containing times_num elements.

Definition at line 45 of file scene_fps.cc.

Referenced by blender::ED_scene_fps_average_accumulate(), and blender::ED_scene_fps_average_calc().

◆ times_index

int blender::ScreenFrameRateInfo::times_index

◆ times_num

int blender::ScreenFrameRateInfo::times_num

◆ times_num_set

int blender::ScreenFrameRateInfo::times_num_set

Number of times set, never exceeds times_num.

Definition at line 42 of file scene_fps.cc.

Referenced by blender::ED_scene_fps_average_accumulate(), and blender::ED_scene_fps_average_calc().


The documentation for this struct was generated from the following file: