mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
Renderer: Threaded frame dumping.
This commit is contained in:
@ -14,9 +14,11 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <condition_variable>
|
||||
#include <memory>
|
||||
#include <mutex>
|
||||
#include <string>
|
||||
#include <thread>
|
||||
#include <vector>
|
||||
|
||||
#include "Common/CommonTypes.h"
|
||||
@ -181,16 +183,30 @@ protected:
|
||||
static void* s_new_surface_handle;
|
||||
|
||||
private:
|
||||
void RunFrameDumps();
|
||||
void ShutdownFrameDumping();
|
||||
|
||||
static PEControl::PixelFormat prev_efb_format;
|
||||
static unsigned int efb_scale_numeratorX;
|
||||
static unsigned int efb_scale_numeratorY;
|
||||
static unsigned int efb_scale_denominatorX;
|
||||
static unsigned int efb_scale_denominatorY;
|
||||
|
||||
// framedumping
|
||||
std::vector<u8> m_frame_data;
|
||||
bool m_AVI_dumping = false;
|
||||
bool m_last_frame_dumped = false;
|
||||
// frame dumping
|
||||
std::thread m_frame_dump_thread;
|
||||
Common::Event m_frame_dump_start;
|
||||
Common::Event m_frame_dump_done;
|
||||
Common::Flag m_frame_dump_thread_running;
|
||||
bool m_frame_dump_frame_running = false;
|
||||
struct FrameDumpConfig
|
||||
{
|
||||
const u8* data;
|
||||
int width;
|
||||
int height;
|
||||
int stride;
|
||||
bool upside_down;
|
||||
AVIDump::Frame state;
|
||||
} m_frame_dump_config;
|
||||
};
|
||||
|
||||
extern std::unique_ptr<Renderer> g_renderer;
|
||||
|
Reference in New Issue
Block a user