mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-25 07:09:48 -06:00
AVIDump: Add a struct for the state.
So AddFrame use no global state and can be threaded well.
This commit is contained in:
@ -14,8 +14,21 @@ private:
|
||||
static void CheckResolution(int width, int height);
|
||||
|
||||
public:
|
||||
struct Frame
|
||||
{
|
||||
u64 ticks = 0;
|
||||
u32 ticks_per_second = 0;
|
||||
bool first_frame = false;
|
||||
};
|
||||
|
||||
static bool Start(int w, int h);
|
||||
static void AddFrame(const u8* data, int width, int height, int stride, u64 ticks);
|
||||
static void AddFrame(const u8* data, int width, int height, int stride, const Frame& state);
|
||||
static void Stop();
|
||||
static void DoState();
|
||||
|
||||
#if defined(HAVE_LIBAV) || defined(_WIN32)
|
||||
static Frame FetchState(u64 ticks);
|
||||
#else
|
||||
static Frame FetchState(u64 ticks) { return {}; }
|
||||
#endif
|
||||
};
|
||||
|
Reference in New Issue
Block a user