Merge branch 'master' of https://github.com/xenia-project/xenia into canary_experimental

This commit is contained in:
Gliniak
2025-08-15 15:37:50 +02:00
78 changed files with 3438 additions and 2888 deletions

View File

@@ -10,26 +10,39 @@
#ifndef XENIA_UI_RENDERDOC_API_H_
#define XENIA_UI_RENDERDOC_API_H_
#include <memory>
#include "third_party/renderdoc/renderdoc_app.h"
#include "xenia/base/platform.h"
#if XE_PLATFORM_WIN32
#include "xenia/base/platform_win.h"
#endif
namespace xe {
namespace ui {
class RenderdocApi {
class RenderDocAPI {
public:
RenderdocApi() = default;
RenderdocApi(const RenderdocApi& renderdoc_api) = delete;
RenderdocApi& operator=(const RenderdocApi& renderdoc_api) = delete;
~RenderdocApi() { Shutdown(); }
static std::unique_ptr<RenderDocAPI> CreateIfConnected();
bool Initialize();
void Shutdown();
RenderDocAPI(const RenderDocAPI&) = delete;
RenderDocAPI& operator=(const RenderDocAPI&) = delete;
// nullptr if not attached.
~RenderDocAPI();
// Always present if this object exists.
const RENDERDOC_API_1_0_0* api_1_0_0() const { return api_1_0_0_; }
private:
explicit RenderDocAPI() = default;
#if XE_PLATFORM_LINUX
void* library_ = nullptr;
#elif XE_PLATFORM_WIN32
HMODULE library_ = nullptr;
#endif
const RENDERDOC_API_1_0_0* api_1_0_0_ = nullptr;
};