Lint fixes

This commit is contained in:
Scott Mansell
2023-01-31 17:29:16 +13:00
parent 11de923dcb
commit 31cfe8250d
39 changed files with 219 additions and 235 deletions

View File

@ -6,7 +6,6 @@
#include "Common/CommonTypes.h"
#include "Common/EventHook.h"
// Called when certain video config setting are changed
using ConfigChangedEvent = Event<"ConfigChanged", u32>;
@ -21,60 +20,60 @@ using AfterFrameEvent = Event<"AfterFrame">;
struct PresentInfo
{
enum class PresentReason
{
Immediate, // FIFO is Presenting the XFB immediately, straight after the XFB copy
VideoInterface, // VideoInterface has triggered a present with a new frame
VideoInterfaceDuplicate, // VideoInterface has triggered a present with a duplicate frame
};
enum class PresentReason
{
Immediate, // FIFO is Presenting the XFB immediately, straight after the XFB copy
VideoInterface, // VideoInterface has triggered a present with a new frame
VideoInterfaceDuplicate, // VideoInterface has triggered a present with a duplicate frame
};
// The number of (unique) frames since the emulated console booted
u64 frame_count;
// The number of (unique) frames since the emulated console booted
u64 frame_count;
// The number of presents since the video backend was initialized.
// never goes backwards.
u64 present_count;
// The number of presents since the video backend was initialized.
// never goes backwards.
u64 present_count;
// The frame is identical to the previous frame
PresentReason reason;
// The frame is identical to the previous frame
PresentReason reason;
// The exact emulated time of the when real hardware would have presented this frame
// FIXME: Immediate should predict the timestamp of this present
u64 emulated_timestamp;
// The exact emulated time of the when real hardware would have presented this frame
// FIXME: Immediate should predict the timestamp of this present
u64 emulated_timestamp;
// TODO:
// u64 intended_present_time;
// TODO:
// u64 intended_present_time;
// AfterPresent only: The actual time the frame was presented
u64 actual_present_time = 0;
// AfterPresent only: The actual time the frame was presented
u64 actual_present_time = 0;
enum class PresentTimeAccuracy
{
// The Driver/OS has given us an exact timestamp of when the first line of the frame started
// scanning out to the monitor
PresentOnScreenExact,
enum class PresentTimeAccuracy
{
// The Driver/OS has given us an exact timestamp of when the first line of the frame started
// scanning out to the monitor
PresentOnScreenExact,
// An approximate timestamp of scanout.
PresentOnScreen,
// An approximate timestamp of scanout.
PresentOnScreen,
// Dolphin doesn't have visibility of the present time. But the present operation has
// been queued with the GPU driver and will happen in the near future.
PresentInProgress,
// Dolphin doesn't have visibility of the present time. But the present operation has
// been queued with the GPU driver and will happen in the near future.
PresentInProgress,
// Not implemented
Unimplemented,
};
// Not implemented
Unimplemented,
};
// Accuracy of actual_present_time
PresentTimeAccuracy present_time_accuracy = PresentTimeAccuracy::Unimplemented;
// Accuracy of actual_present_time
PresentTimeAccuracy present_time_accuracy = PresentTimeAccuracy::Unimplemented;
};
// An event called just as a frame is queued for presentation.
// The exact timing of this event depends on the "Immediately Present XFB" option.
//
// If enabled, this event will trigger immediately after AfterFrame
// If disabled, this event won't trigger until the emulated interface starts drawing out a new frame.
// If disabled, this event won't trigger until the emulated interface starts drawing out a new
// frame.
//
// frame_count: The number of frames
using BeforePresentEvent = Event<"BeforePresent", PresentInfo&>;