mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-10-02 02:18:16 +00:00
Start moving towards C++ only UI code. Assume C++ for the replay API
* The C# P/Invoke stuff doesn't directly use the header, and we are soon going to deprecate the C interface entirely.
This commit is contained in:
@@ -62,7 +62,7 @@ void RemoteHost::CheckStatus()
|
||||
return;
|
||||
}
|
||||
|
||||
RemoteServer *rend = NULL;
|
||||
IRemoteServer *rend = NULL;
|
||||
ReplayCreateStatus status =
|
||||
RENDERDOC_CreateRemoteServerConnection(Hostname.toUtf8().data(), 0, &rend);
|
||||
|
||||
|
||||
@@ -235,7 +235,7 @@ void RemoteManager::refreshHost(QTreeWidgetItem *node)
|
||||
if(nextIdent == ~0U || prevIdent >= nextIdent)
|
||||
break;
|
||||
|
||||
TargetControl *conn =
|
||||
ITargetControl *conn =
|
||||
RENDERDOC_CreateTargetControl(hostnameBytes.data(), nextIdent, username.data(), false);
|
||||
|
||||
if(conn)
|
||||
@@ -603,7 +603,7 @@ void RemoteManager::on_connect_clicked()
|
||||
}
|
||||
else
|
||||
{
|
||||
RemoteServer *server = NULL;
|
||||
IRemoteServer *server = NULL;
|
||||
ReplayCreateStatus status =
|
||||
RENDERDOC_CreateRemoteServerConnection(host->Hostname.toUtf8().data(), 0, &server);
|
||||
if(server)
|
||||
|
||||
@@ -317,7 +317,6 @@ struct FetchFrameInfo
|
||||
|
||||
struct EventUsage
|
||||
{
|
||||
#ifdef __cplusplus
|
||||
EventUsage() : eventID(0), usage(eUsage_None) {}
|
||||
EventUsage(uint32_t e, ResourceUsage u) : eventID(e), usage(u) {}
|
||||
EventUsage(uint32_t e, ResourceUsage u, ResourceId v) : eventID(e), usage(u), view(v) {}
|
||||
@@ -329,8 +328,6 @@ struct EventUsage
|
||||
}
|
||||
|
||||
bool operator==(const EventUsage &o) const { return eventID == o.eventID && usage == o.usage; }
|
||||
#endif
|
||||
|
||||
uint32_t eventID;
|
||||
ResourceUsage usage;
|
||||
ResourceId view;
|
||||
|
||||
@@ -125,13 +125,11 @@ struct ResourceId
|
||||
{
|
||||
uint64_t id;
|
||||
|
||||
#ifdef __cplusplus
|
||||
ResourceId() : id() {}
|
||||
ResourceId(uint64_t val, bool) { id = val; }
|
||||
bool operator==(const ResourceId u) const { return id == u.id; }
|
||||
bool operator!=(const ResourceId u) const { return id != u.id; }
|
||||
bool operator<(const ResourceId u) const { return id < u.id; }
|
||||
#endif
|
||||
};
|
||||
|
||||
#include "capture_options.h"
|
||||
@@ -144,9 +142,6 @@ struct ResourceId
|
||||
#include "shader_types.h"
|
||||
#include "vk_pipestate.h"
|
||||
|
||||
// for C++ expose the interface as a virtual interface
|
||||
#ifdef __cplusplus
|
||||
|
||||
struct IReplayOutput
|
||||
{
|
||||
virtual bool SetOutputConfig(const OutputConfig &o) = 0;
|
||||
@@ -173,72 +168,56 @@ struct IReplayOutput
|
||||
virtual uint32_t PickVertex(uint32_t eventID, uint32_t x, uint32_t y, uint32_t *pickedInstance) = 0;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef RENDERDOC_EXPORTS
|
||||
struct ReplayOutput;
|
||||
#else
|
||||
#ifdef __cplusplus
|
||||
typedef IReplayOutput ReplayOutput;
|
||||
#else
|
||||
struct ReplayOutput
|
||||
{
|
||||
};
|
||||
#endif
|
||||
#endif
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetOutputConfig(ReplayOutput *output,
|
||||
// deprecated C interface, for renderdocui only
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetOutputConfig(IReplayOutput *output,
|
||||
const OutputConfig &o);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetTextureDisplay(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetTextureDisplay(IReplayOutput *output,
|
||||
const TextureDisplay &o);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetMeshDisplay(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetMeshDisplay(IReplayOutput *output,
|
||||
const MeshDisplay &o);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_ClearThumbnails(ReplayOutput *output);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_AddThumbnail(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_ClearThumbnails(IReplayOutput *output);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_AddThumbnail(IReplayOutput *output,
|
||||
WindowingSystem system,
|
||||
void *data, ResourceId texID,
|
||||
FormatComponentType typeHint);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_Display(ReplayOutput *output);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_Display(IReplayOutput *output);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetPixelContext(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetPixelContext(IReplayOutput *output,
|
||||
WindowingSystem system,
|
||||
void *data);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayOutput_SetPixelContextLocation(ReplayOutput *output, uint32_t x, uint32_t y);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_DisablePixelContext(ReplayOutput *output);
|
||||
ReplayOutput_SetPixelContextLocation(IReplayOutput *output, uint32_t x, uint32_t y);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_DisablePixelContext(IReplayOutput *output);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_GetCustomShaderTexID(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_GetCustomShaderTexID(IReplayOutput *output,
|
||||
ResourceId *id);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_GetMinMax(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_GetMinMax(IReplayOutput *output,
|
||||
PixelValue *minval,
|
||||
PixelValue *maxval);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayOutput_GetHistogram(ReplayOutput *output, float minval, float maxval, bool32 channels[4],
|
||||
ReplayOutput_GetHistogram(IReplayOutput *output, float minval, float maxval, bool32 channels[4],
|
||||
rdctype::array<uint32_t> *histogram);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_PickPixel(
|
||||
ReplayOutput *output, ResourceId texID, bool32 customShader, uint32_t x, uint32_t y,
|
||||
IReplayOutput *output, ResourceId texID, bool32 customShader, uint32_t x, uint32_t y,
|
||||
uint32_t sliceFace, uint32_t mip, uint32_t sample, PixelValue *val);
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC ReplayOutput_PickVertex(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC ReplayOutput_PickVertex(IReplayOutput *output,
|
||||
uint32_t eventID, uint32_t x,
|
||||
uint32_t y,
|
||||
uint32_t *pickedInstance);
|
||||
|
||||
// for C++ expose the interface as a virtual interface
|
||||
#ifdef __cplusplus
|
||||
|
||||
struct IReplayRenderer
|
||||
{
|
||||
virtual APIProperties GetAPIProperties() = 0;
|
||||
|
||||
virtual void GetSupportedWindowSystems(rdctype::array<WindowingSystem> *systems) = 0;
|
||||
|
||||
virtual ReplayOutput *CreateOutput(WindowingSystem system, void *data, OutputType type) = 0;
|
||||
virtual IReplayOutput *CreateOutput(WindowingSystem system, void *data, OutputType type) = 0;
|
||||
virtual void Shutdown() = 0;
|
||||
virtual void ShutdownOutput(ReplayOutput *output) = 0;
|
||||
virtual void ShutdownOutput(IReplayOutput *output) = 0;
|
||||
|
||||
virtual void FileChanged() = 0;
|
||||
|
||||
@@ -300,128 +279,113 @@ struct IReplayRenderer
|
||||
rdctype::array<byte> *data) = 0;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef RENDERDOC_EXPORTS
|
||||
struct ReplayRenderer;
|
||||
#else
|
||||
#ifdef __cplusplus
|
||||
typedef IReplayRenderer ReplayRenderer;
|
||||
#else
|
||||
struct ReplayRenderer
|
||||
{
|
||||
};
|
||||
#endif
|
||||
#endif
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_GetAPIProperties(ReplayRenderer *rend,
|
||||
// deprecated C interface, for renderdocui only
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_GetAPIProperties(IReplayRenderer *rend,
|
||||
APIProperties *props);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_GetSupportedWindowSystems(
|
||||
ReplayRenderer *rend, rdctype::array<WindowingSystem> *systems);
|
||||
IReplayRenderer *rend, rdctype::array<WindowingSystem> *systems);
|
||||
|
||||
extern "C" RENDERDOC_API ReplayOutput *RENDERDOC_CC ReplayRenderer_CreateOutput(
|
||||
ReplayRenderer *rend, WindowingSystem system, void *data, OutputType type);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_Shutdown(ReplayRenderer *rend);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_ShutdownOutput(ReplayRenderer *rend,
|
||||
ReplayOutput *output);
|
||||
extern "C" RENDERDOC_API IReplayOutput *RENDERDOC_CC ReplayRenderer_CreateOutput(
|
||||
IReplayRenderer *rend, WindowingSystem system, void *data, OutputType type);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_Shutdown(IReplayRenderer *rend);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_ShutdownOutput(IReplayRenderer *rend,
|
||||
IReplayOutput *output);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_FileChanged(ReplayRenderer *rend);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_FileChanged(IReplayRenderer *rend);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_HasCallstacks(ReplayRenderer *rend);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_InitResolver(ReplayRenderer *rend);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_HasCallstacks(IReplayRenderer *rend);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_InitResolver(IReplayRenderer *rend);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SetFrameEvent(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SetFrameEvent(IReplayRenderer *rend,
|
||||
uint32_t eventID,
|
||||
bool32 force);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetD3D11PipelineState(ReplayRenderer *rend, D3D11PipelineState *state);
|
||||
ReplayRenderer_GetD3D11PipelineState(IReplayRenderer *rend, D3D11PipelineState *state);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetD3D12PipelineState(ReplayRenderer *rend, D3D12PipelineState *state);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetGLPipelineState(ReplayRenderer *rend,
|
||||
ReplayRenderer_GetD3D12PipelineState(IReplayRenderer *rend, D3D12PipelineState *state);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetGLPipelineState(IReplayRenderer *rend,
|
||||
GLPipelineState *state);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetVulkanPipelineState(ReplayRenderer *rend, VulkanPipelineState *state);
|
||||
ReplayRenderer_GetVulkanPipelineState(IReplayRenderer *rend, VulkanPipelineState *state);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_BuildCustomShader(
|
||||
ReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
IReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
ShaderStageType type, ResourceId *shaderID, rdctype::str *errors);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeCustomShader(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeCustomShader(IReplayRenderer *rend,
|
||||
ResourceId id);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_BuildTargetShader(
|
||||
ReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
IReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
ShaderStageType type, ResourceId *shaderID, rdctype::str *errors);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_ReplaceResource(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_ReplaceResource(IReplayRenderer *rend,
|
||||
ResourceId from,
|
||||
ResourceId to);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_RemoveReplacement(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_RemoveReplacement(IReplayRenderer *rend,
|
||||
ResourceId id);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeTargetResource(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeTargetResource(IReplayRenderer *rend,
|
||||
ResourceId id);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetFrameInfo(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetFrameInfo(IReplayRenderer *rend,
|
||||
FetchFrameInfo *frame);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetDrawcalls(ReplayRenderer *rend, rdctype::array<FetchDrawcall> *draws);
|
||||
ReplayRenderer_GetDrawcalls(IReplayRenderer *rend, rdctype::array<FetchDrawcall> *draws);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_FetchCounters(ReplayRenderer *rend, uint32_t *counters, uint32_t numCounters,
|
||||
ReplayRenderer_FetchCounters(IReplayRenderer *rend, uint32_t *counters, uint32_t numCounters,
|
||||
rdctype::array<CounterResult> *results);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_EnumerateCounters(ReplayRenderer *rend, rdctype::array<uint32_t> *counters);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DescribeCounter(ReplayRenderer *rend,
|
||||
ReplayRenderer_EnumerateCounters(IReplayRenderer *rend, rdctype::array<uint32_t> *counters);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DescribeCounter(IReplayRenderer *rend,
|
||||
uint32_t counterID,
|
||||
CounterDescription *desc);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetTextures(ReplayRenderer *rend, rdctype::array<FetchTexture> *texs);
|
||||
ReplayRenderer_GetTextures(IReplayRenderer *rend, rdctype::array<FetchTexture> *texs);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetBuffers(ReplayRenderer *rend, rdctype::array<FetchBuffer> *bufs);
|
||||
ReplayRenderer_GetBuffers(IReplayRenderer *rend, rdctype::array<FetchBuffer> *bufs);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetResolve(ReplayRenderer *rend, uint64_t *callstack, uint32_t callstackLen,
|
||||
ReplayRenderer_GetResolve(IReplayRenderer *rend, uint64_t *callstack, uint32_t callstackLen,
|
||||
rdctype::array<rdctype::str> *trace);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetDebugMessages(ReplayRenderer *rend, rdctype::array<DebugMessage> *msgs);
|
||||
ReplayRenderer_GetDebugMessages(IReplayRenderer *rend, rdctype::array<DebugMessage> *msgs);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_PixelHistory(
|
||||
ReplayRenderer *rend, ResourceId target, uint32_t x, uint32_t y, uint32_t slice, uint32_t mip,
|
||||
IReplayRenderer *rend, ResourceId target, uint32_t x, uint32_t y, uint32_t slice, uint32_t mip,
|
||||
uint32_t sampleIdx, FormatComponentType typeHint, rdctype::array<PixelModification> *history);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_DebugVertex(ReplayRenderer *rend, uint32_t vertid, uint32_t instid, uint32_t idx,
|
||||
ReplayRenderer_DebugVertex(IReplayRenderer *rend, uint32_t vertid, uint32_t instid, uint32_t idx,
|
||||
uint32_t instOffset, uint32_t vertOffset, ShaderDebugTrace *trace);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugPixel(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugPixel(IReplayRenderer *rend,
|
||||
uint32_t x, uint32_t y,
|
||||
uint32_t sample,
|
||||
uint32_t primitive,
|
||||
ShaderDebugTrace *trace);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugThread(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugThread(IReplayRenderer *rend,
|
||||
uint32_t groupid[3],
|
||||
uint32_t threadid[3],
|
||||
ShaderDebugTrace *trace);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetUsage(ReplayRenderer *rend, ResourceId id, rdctype::array<EventUsage> *usage);
|
||||
ReplayRenderer_GetUsage(IReplayRenderer *rend, ResourceId id, rdctype::array<EventUsage> *usage);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetCBufferVariableContents(
|
||||
ReplayRenderer *rend, ResourceId shader, const char *entryPoint, uint32_t cbufslot,
|
||||
IReplayRenderer *rend, ResourceId shader, const char *entryPoint, uint32_t cbufslot,
|
||||
ResourceId buffer, uint64_t offs, rdctype::array<ShaderVariable> *vars);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SaveTexture(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SaveTexture(IReplayRenderer *rend,
|
||||
const TextureSave &saveData,
|
||||
const char *path);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetPostVSData(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetPostVSData(IReplayRenderer *rend,
|
||||
uint32_t instID,
|
||||
MeshDataStage stage,
|
||||
MeshFormat *data);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetBufferData(
|
||||
ReplayRenderer *rend, ResourceId buff, uint64_t offset, uint64_t len, rdctype::array<byte> *data);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetTextureData(ReplayRenderer *rend, ResourceId tex, uint32_t arrayIdx, uint32_t mip,
|
||||
rdctype::array<byte> *data);
|
||||
|
||||
// for C++ expose the interface as a virtual interface
|
||||
#ifdef __cplusplus
|
||||
ReplayRenderer_GetBufferData(IReplayRenderer *rend, ResourceId buff, uint64_t offset, uint64_t len,
|
||||
rdctype::array<byte> *data);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetTextureData(IReplayRenderer *rend, ResourceId tex, uint32_t arrayIdx,
|
||||
uint32_t mip, rdctype::array<byte> *data);
|
||||
|
||||
struct ITargetControl
|
||||
{
|
||||
@@ -442,43 +406,27 @@ struct ITargetControl
|
||||
virtual void ReceiveMessage(TargetControlMessage *msg) = 0;
|
||||
};
|
||||
|
||||
#endif
|
||||
// deprecated C interface, for renderdocui only
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_Shutdown(ITargetControl *control);
|
||||
|
||||
#ifdef RENDERDOC_EXPORTS
|
||||
struct TargetControl;
|
||||
#else
|
||||
#ifdef __cplusplus
|
||||
typedef ITargetControl TargetControl;
|
||||
#else
|
||||
struct TargetControl
|
||||
{
|
||||
};
|
||||
#endif
|
||||
#endif
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetTarget(ITargetControl *control);
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetAPI(ITargetControl *control);
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC TargetControl_GetPID(ITargetControl *control);
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetBusyClient(ITargetControl *control);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_Shutdown(TargetControl *control);
|
||||
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetTarget(TargetControl *control);
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetAPI(TargetControl *control);
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC TargetControl_GetPID(TargetControl *control);
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetBusyClient(TargetControl *control);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_TriggerCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_TriggerCapture(ITargetControl *control,
|
||||
uint32_t numFrames);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_QueueCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_QueueCapture(ITargetControl *control,
|
||||
uint32_t frameNumber);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_CopyCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_CopyCapture(ITargetControl *control,
|
||||
uint32_t remoteID,
|
||||
const char *localpath);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_DeleteCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_DeleteCapture(ITargetControl *control,
|
||||
uint32_t remoteID);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_ReceiveMessage(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_ReceiveMessage(ITargetControl *control,
|
||||
TargetControlMessage *msg);
|
||||
|
||||
// for C++ expose the interface as a virtual interface
|
||||
#ifdef __cplusplus
|
||||
|
||||
struct IRemoteServer
|
||||
{
|
||||
virtual void ShutdownConnection() = 0;
|
||||
@@ -502,70 +450,51 @@ struct IRemoteServer
|
||||
float *progress) = 0;
|
||||
|
||||
virtual ReplayCreateStatus OpenCapture(uint32_t proxyid, const char *logfile, float *progress,
|
||||
ReplayRenderer **rend) = 0;
|
||||
virtual void CloseCapture(ReplayRenderer *rend) = 0;
|
||||
IReplayRenderer **rend) = 0;
|
||||
virtual void CloseCapture(IReplayRenderer *rend) = 0;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef RENDERDOC_EXPORTS
|
||||
struct RemoteServer;
|
||||
#else
|
||||
#ifdef __cplusplus
|
||||
typedef IRemoteServer RemoteServer;
|
||||
#else
|
||||
struct RemoteServer
|
||||
{
|
||||
};
|
||||
#endif
|
||||
#endif
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ShutdownConnection(RemoteServer *remote);
|
||||
// deprecated C interface, for renderdocui only
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ShutdownConnection(IRemoteServer *remote);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC
|
||||
RemoteServer_ShutdownServerAndConnection(RemoteServer *remote);
|
||||
RemoteServer_ShutdownServerAndConnection(IRemoteServer *remote);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC RemoteServer_Ping(RemoteServer *remote);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC RemoteServer_Ping(IRemoteServer *remote);
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
RemoteServer_LocalProxies(RemoteServer *remote, rdctype::array<rdctype::str> *out);
|
||||
RemoteServer_LocalProxies(IRemoteServer *remote, rdctype::array<rdctype::str> *out);
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
RemoteServer_RemoteSupportedReplays(RemoteServer *remote, rdctype::array<rdctype::str> *out);
|
||||
RemoteServer_RemoteSupportedReplays(IRemoteServer *remote, rdctype::array<rdctype::str> *out);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_GetHomeFolder(RemoteServer *remote,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_GetHomeFolder(IRemoteServer *remote,
|
||||
rdctype::str *home);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ListFolder(
|
||||
RemoteServer *remote, const char *path, rdctype::array<DirectoryFile> *dirlist);
|
||||
IRemoteServer *remote, const char *path, rdctype::array<DirectoryFile> *dirlist);
|
||||
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC
|
||||
RemoteServer_ExecuteAndInject(RemoteServer *remote, const char *app, const char *workingDir,
|
||||
RemoteServer_ExecuteAndInject(IRemoteServer *remote, const char *app, const char *workingDir,
|
||||
const char *cmdLine, void *env, const CaptureOptions *opts);
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_TakeOwnershipCapture(RemoteServer *remote,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_TakeOwnershipCapture(IRemoteServer *remote,
|
||||
const char *filename);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureToRemote(
|
||||
RemoteServer *remote, const char *filename, float *progress, rdctype::str *remotepath);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureFromRemote(RemoteServer *remote,
|
||||
IRemoteServer *remote, const char *filename, float *progress, rdctype::str *remotepath);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureFromRemote(IRemoteServer *remote,
|
||||
const char *remotepath,
|
||||
const char *localpath,
|
||||
float *progress);
|
||||
|
||||
extern "C" RENDERDOC_API ReplayCreateStatus RENDERDOC_CC
|
||||
RemoteServer_OpenCapture(RemoteServer *remote, uint32_t proxyid, const char *logfile,
|
||||
float *progress, ReplayRenderer **rend);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CloseCapture(RemoteServer *remote,
|
||||
ReplayRenderer *rend);
|
||||
RemoteServer_OpenCapture(IRemoteServer *remote, uint32_t proxyid, const char *logfile,
|
||||
float *progress, IReplayRenderer **rend);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CloseCapture(IRemoteServer *remote,
|
||||
IReplayRenderer *rend);
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
// camera
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifdef RENDERDOC_EXPORTS
|
||||
class Camera;
|
||||
#else
|
||||
class Camera
|
||||
{
|
||||
};
|
||||
#endif
|
||||
|
||||
extern "C" RENDERDOC_API Camera *RENDERDOC_CC Camera_InitArcball();
|
||||
extern "C" RENDERDOC_API Camera *RENDERDOC_CC Camera_InitFPSLook();
|
||||
@@ -606,13 +535,13 @@ extern "C" RENDERDOC_API uint32_t RENDERDOC_CC Topology_VertexOffset(PrimitiveTo
|
||||
extern "C" RENDERDOC_API ReplaySupport RENDERDOC_CC RENDERDOC_SupportLocalReplay(
|
||||
const char *logfile, rdctype::str *driverName, rdctype::str *recordMachineIdent);
|
||||
extern "C" RENDERDOC_API ReplayCreateStatus RENDERDOC_CC
|
||||
RENDERDOC_CreateReplayRenderer(const char *logfile, float *progress, ReplayRenderer **rend);
|
||||
RENDERDOC_CreateReplayRenderer(const char *logfile, float *progress, IReplayRenderer **rend);
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
// Target Control
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
extern "C" RENDERDOC_API TargetControl *RENDERDOC_CC RENDERDOC_CreateTargetControl(
|
||||
extern "C" RENDERDOC_API ITargetControl *RENDERDOC_CC RENDERDOC_CreateTargetControl(
|
||||
const char *host, uint32_t ident, const char *clientName, bool32 forceConnection);
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC RENDERDOC_EnumerateRemoteTargets(const char *host,
|
||||
uint32_t nextIdent);
|
||||
@@ -623,7 +552,7 @@ extern "C" RENDERDOC_API uint32_t RENDERDOC_CC RENDERDOC_EnumerateRemoteTargets(
|
||||
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC RENDERDOC_GetDefaultRemoteServerPort();
|
||||
extern "C" RENDERDOC_API ReplayCreateStatus RENDERDOC_CC
|
||||
RENDERDOC_CreateRemoteServerConnection(const char *host, uint32_t port, RemoteServer **rend);
|
||||
RENDERDOC_CreateRemoteServerConnection(const char *host, uint32_t port, IRemoteServer **rend);
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RENDERDOC_BecomeRemoteServer(const char *listenhost,
|
||||
uint32_t port,
|
||||
volatile bool32 *killReplay);
|
||||
|
||||
@@ -267,7 +267,6 @@ struct ShaderReflection
|
||||
|
||||
struct BindpointMap
|
||||
{
|
||||
#ifdef __cplusplus
|
||||
BindpointMap()
|
||||
{
|
||||
bindset = 0;
|
||||
@@ -290,7 +289,6 @@ struct BindpointMap
|
||||
return bindset < o.bindset;
|
||||
return bind < o.bind;
|
||||
}
|
||||
#endif
|
||||
|
||||
int32_t bindset;
|
||||
int32_t bind;
|
||||
|
||||
@@ -1016,7 +1016,7 @@ public:
|
||||
}
|
||||
|
||||
ReplayCreateStatus OpenCapture(uint32_t proxyid, const char *filename, float *progress,
|
||||
ReplayRenderer **rend)
|
||||
IReplayRenderer **rend)
|
||||
{
|
||||
if(rend == NULL)
|
||||
return eReplayCreate_InternalError;
|
||||
@@ -1101,7 +1101,7 @@ public:
|
||||
return eReplayCreate_Success;
|
||||
}
|
||||
|
||||
void CloseCapture(ReplayRenderer *rend)
|
||||
void CloseCapture(IReplayRenderer *rend)
|
||||
{
|
||||
Serialiser sendData("", Serialiser::WRITING, false);
|
||||
Send(eRemoteServer_CloseLog, sendData);
|
||||
@@ -1133,28 +1133,28 @@ private:
|
||||
vector<pair<RDCDriver, string> > m_Proxies;
|
||||
};
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ShutdownConnection(RemoteServer *remote)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ShutdownConnection(IRemoteServer *remote)
|
||||
{
|
||||
remote->ShutdownConnection();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ShutdownServerAndConnection(RemoteServer *remote)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ShutdownServerAndConnection(IRemoteServer *remote)
|
||||
{
|
||||
remote->ShutdownServerAndConnection();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC RemoteServer_Ping(RemoteServer *remote)
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC RemoteServer_Ping(IRemoteServer *remote)
|
||||
{
|
||||
return remote->Ping();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
RemoteServer_LocalProxies(RemoteServer *remote, rdctype::array<rdctype::str> *out)
|
||||
RemoteServer_LocalProxies(IRemoteServer *remote, rdctype::array<rdctype::str> *out)
|
||||
{
|
||||
return remote->LocalProxies(out);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_GetHomeFolder(RemoteServer *remote,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_GetHomeFolder(IRemoteServer *remote,
|
||||
rdctype::str *home)
|
||||
{
|
||||
rdctype::str path = remote->GetHomeFolder();
|
||||
@@ -1163,7 +1163,7 @@ extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_GetHomeFolder(RemoteServ
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ListFolder(
|
||||
RemoteServer *remote, const char *path, rdctype::array<DirectoryFile> *dirlist)
|
||||
IRemoteServer *remote, const char *path, rdctype::array<DirectoryFile> *dirlist)
|
||||
{
|
||||
rdctype::array<DirectoryFile> files = remote->ListFolder(path);
|
||||
if(dirlist)
|
||||
@@ -1171,25 +1171,25 @@ extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_ListFolder(
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
RemoteServer_RemoteSupportedReplays(RemoteServer *remote, rdctype::array<rdctype::str> *out)
|
||||
RemoteServer_RemoteSupportedReplays(IRemoteServer *remote, rdctype::array<rdctype::str> *out)
|
||||
{
|
||||
return remote->RemoteSupportedReplays(out);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC
|
||||
RemoteServer_ExecuteAndInject(RemoteServer *remote, const char *app, const char *workingDir,
|
||||
RemoteServer_ExecuteAndInject(IRemoteServer *remote, const char *app, const char *workingDir,
|
||||
const char *cmdLine, void *env, const CaptureOptions *opts)
|
||||
{
|
||||
return remote->ExecuteAndInject(app, workingDir, cmdLine, env, opts);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_TakeOwnershipCapture(RemoteServer *remote,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_TakeOwnershipCapture(IRemoteServer *remote,
|
||||
const char *filename)
|
||||
{
|
||||
remote->TakeOwnershipCapture(filename);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureToRemote(RemoteServer *remote,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureToRemote(IRemoteServer *remote,
|
||||
const char *filename,
|
||||
float *progress,
|
||||
rdctype::str *remotepath)
|
||||
@@ -1199,7 +1199,7 @@ extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureToRemote(Remo
|
||||
*remotepath = path;
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureFromRemote(RemoteServer *remote,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureFromRemote(IRemoteServer *remote,
|
||||
const char *remotepath,
|
||||
const char *localpath,
|
||||
float *progress)
|
||||
@@ -1208,20 +1208,20 @@ extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CopyCaptureFromRemote(Re
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API ReplayCreateStatus RENDERDOC_CC
|
||||
RemoteServer_OpenCapture(RemoteServer *remote, uint32_t proxyid, const char *logfile,
|
||||
float *progress, ReplayRenderer **rend)
|
||||
RemoteServer_OpenCapture(IRemoteServer *remote, uint32_t proxyid, const char *logfile,
|
||||
float *progress, IReplayRenderer **rend)
|
||||
{
|
||||
return remote->OpenCapture(proxyid, logfile, progress, rend);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CloseCapture(RemoteServer *remote,
|
||||
ReplayRenderer *rend)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC RemoteServer_CloseCapture(IRemoteServer *remote,
|
||||
IReplayRenderer *rend)
|
||||
{
|
||||
return remote->CloseCapture(rend);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API ReplayCreateStatus RENDERDOC_CC
|
||||
RENDERDOC_CreateRemoteServerConnection(const char *host, uint32_t port, RemoteServer **rend)
|
||||
RENDERDOC_CreateRemoteServerConnection(const char *host, uint32_t port, IRemoteServer **rend)
|
||||
{
|
||||
if(rend == NULL)
|
||||
return eReplayCreate_InternalError;
|
||||
|
||||
@@ -644,58 +644,58 @@ private:
|
||||
}
|
||||
};
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_Shutdown(TargetControl *control)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_Shutdown(ITargetControl *control)
|
||||
{
|
||||
control->Shutdown();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetTarget(TargetControl *control)
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetTarget(ITargetControl *control)
|
||||
{
|
||||
return control->GetTarget();
|
||||
}
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetAPI(TargetControl *control)
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetAPI(ITargetControl *control)
|
||||
{
|
||||
return control->GetAPI();
|
||||
}
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC TargetControl_GetPID(TargetControl *control)
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC TargetControl_GetPID(ITargetControl *control)
|
||||
{
|
||||
return control->GetPID();
|
||||
}
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetBusyClient(TargetControl *control)
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC TargetControl_GetBusyClient(ITargetControl *control)
|
||||
{
|
||||
return control->GetBusyClient();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_TriggerCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_TriggerCapture(ITargetControl *control,
|
||||
uint32_t numFrames)
|
||||
{
|
||||
control->TriggerCapture(numFrames);
|
||||
}
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_QueueCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_QueueCapture(ITargetControl *control,
|
||||
uint32_t frameNumber)
|
||||
{
|
||||
control->QueueCapture(frameNumber);
|
||||
}
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_CopyCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_CopyCapture(ITargetControl *control,
|
||||
uint32_t remoteID,
|
||||
const char *localpath)
|
||||
{
|
||||
control->CopyCapture(remoteID, localpath);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_DeleteCapture(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_DeleteCapture(ITargetControl *control,
|
||||
uint32_t remoteID)
|
||||
{
|
||||
control->DeleteCapture(remoteID);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_ReceiveMessage(TargetControl *control,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC TargetControl_ReceiveMessage(ITargetControl *control,
|
||||
TargetControlMessage *msg)
|
||||
{
|
||||
control->ReceiveMessage(msg);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API TargetControl *RENDERDOC_CC RENDERDOC_CreateTargetControl(
|
||||
extern "C" RENDERDOC_API ITargetControl *RENDERDOC_CC RENDERDOC_CreateTargetControl(
|
||||
const char *host, uint32_t ident, const char *clientName, bool32 forceConnection)
|
||||
{
|
||||
string s = "localhost";
|
||||
|
||||
@@ -380,7 +380,7 @@ extern "C" RENDERDOC_API ReplaySupport RENDERDOC_CC RENDERDOC_SupportLocalReplay
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API ReplayCreateStatus RENDERDOC_CC
|
||||
RENDERDOC_CreateReplayRenderer(const char *logfile, float *progress, ReplayRenderer **rend)
|
||||
RENDERDOC_CreateReplayRenderer(const char *logfile, float *progress, IReplayRenderer **rend)
|
||||
{
|
||||
if(rend == NULL)
|
||||
return eReplayCreate_InternalError;
|
||||
@@ -744,7 +744,7 @@ uint32_t StartAndroidPackageForCapture(const char *host, const char *package)
|
||||
while(elapsed < timeout)
|
||||
{
|
||||
// Check if the target app has started yet and we can connect to it.
|
||||
TargetControl *control = RENDERDOC_CreateTargetControl(host, ret, "testConnection", false);
|
||||
ITargetControl *control = RENDERDOC_CreateTargetControl(host, ret, "testConnection", false);
|
||||
if(control)
|
||||
{
|
||||
TargetControl_Shutdown(control);
|
||||
|
||||
@@ -867,27 +867,27 @@ void ReplayOutput::DisplayMesh()
|
||||
m_pDevice->RenderMesh(m_EventID, secondaryDraws, mesh);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetOutputConfig(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetOutputConfig(IReplayOutput *output,
|
||||
const OutputConfig &o)
|
||||
{
|
||||
return output->SetOutputConfig(o);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetTextureDisplay(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetTextureDisplay(IReplayOutput *output,
|
||||
const TextureDisplay &o)
|
||||
{
|
||||
return output->SetTextureDisplay(o);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetMeshDisplay(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetMeshDisplay(IReplayOutput *output,
|
||||
const MeshDisplay &o)
|
||||
{
|
||||
return output->SetMeshDisplay(o);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_ClearThumbnails(ReplayOutput *output)
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_ClearThumbnails(IReplayOutput *output)
|
||||
{
|
||||
return output->ClearThumbnails();
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_AddThumbnail(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_AddThumbnail(IReplayOutput *output,
|
||||
WindowingSystem system,
|
||||
void *data, ResourceId texID,
|
||||
FormatComponentType typeHint)
|
||||
@@ -895,42 +895,42 @@ extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_AddThumbnail(ReplayOut
|
||||
return output->AddThumbnail(system, data, texID, typeHint);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_Display(ReplayOutput *output)
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_Display(IReplayOutput *output)
|
||||
{
|
||||
return output->Display();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetPixelContext(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_SetPixelContext(IReplayOutput *output,
|
||||
WindowingSystem system,
|
||||
void *data)
|
||||
{
|
||||
return output->SetPixelContext(system, data);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayOutput_SetPixelContextLocation(ReplayOutput *output, uint32_t x, uint32_t y)
|
||||
ReplayOutput_SetPixelContextLocation(IReplayOutput *output, uint32_t x, uint32_t y)
|
||||
{
|
||||
return output->SetPixelContextLocation(x, y);
|
||||
}
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_DisablePixelContext(ReplayOutput *output)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_DisablePixelContext(IReplayOutput *output)
|
||||
{
|
||||
output->DisablePixelContext();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_GetCustomShaderTexID(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayOutput_GetCustomShaderTexID(IReplayOutput *output,
|
||||
ResourceId *id)
|
||||
{
|
||||
if(id)
|
||||
*id = output->GetCustomShaderTexID();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_GetMinMax(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_GetMinMax(IReplayOutput *output,
|
||||
PixelValue *minval,
|
||||
PixelValue *maxval)
|
||||
{
|
||||
return output->GetMinMax(minval, maxval);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayOutput_GetHistogram(ReplayOutput *output, float minval, float maxval, bool32 channels[4],
|
||||
ReplayOutput_GetHistogram(IReplayOutput *output, float minval, float maxval, bool32 channels[4],
|
||||
rdctype::array<uint32_t> *histogram)
|
||||
{
|
||||
bool chans[4] = {channels[0] != 0, channels[1] != 0, channels[2] != 0, channels[3] != 0};
|
||||
@@ -938,13 +938,13 @@ ReplayOutput_GetHistogram(ReplayOutput *output, float minval, float maxval, bool
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayOutput_PickPixel(
|
||||
ReplayOutput *output, ResourceId texID, bool32 customShader, uint32_t x, uint32_t y,
|
||||
IReplayOutput *output, ResourceId texID, bool32 customShader, uint32_t x, uint32_t y,
|
||||
uint32_t sliceFace, uint32_t mip, uint32_t sample, PixelValue *val)
|
||||
{
|
||||
return output->PickPixel(texID, customShader != 0, x, y, sliceFace, mip, sample, val);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC ReplayOutput_PickVertex(ReplayOutput *output,
|
||||
extern "C" RENDERDOC_API uint32_t RENDERDOC_CC ReplayOutput_PickVertex(IReplayOutput *output,
|
||||
uint32_t eventID, uint32_t x,
|
||||
uint32_t y,
|
||||
uint32_t *pickedInstance)
|
||||
|
||||
@@ -1425,7 +1425,7 @@ ReplayOutput *ReplayRenderer::CreateOutput(WindowingSystem system, void *data, O
|
||||
return out;
|
||||
}
|
||||
|
||||
void ReplayRenderer::ShutdownOutput(ReplayOutput *output)
|
||||
void ReplayRenderer::ShutdownOutput(IReplayOutput *output)
|
||||
{
|
||||
RDCUNIMPLEMENTED("Shutting down individual outputs");
|
||||
}
|
||||
@@ -1669,7 +1669,7 @@ void ReplayRenderer::FetchPipelineState()
|
||||
}
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_GetAPIProperties(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_GetAPIProperties(IReplayRenderer *rend,
|
||||
APIProperties *props)
|
||||
{
|
||||
if(props)
|
||||
@@ -1677,69 +1677,69 @@ extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_GetAPIProperties(Repla
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_GetSupportedWindowSystems(
|
||||
ReplayRenderer *rend, rdctype::array<WindowingSystem> *systems)
|
||||
IReplayRenderer *rend, rdctype::array<WindowingSystem> *systems)
|
||||
{
|
||||
rend->GetSupportedWindowSystems(systems);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API ReplayOutput *RENDERDOC_CC ReplayRenderer_CreateOutput(
|
||||
ReplayRenderer *rend, WindowingSystem system, void *data, OutputType type)
|
||||
extern "C" RENDERDOC_API IReplayOutput *RENDERDOC_CC ReplayRenderer_CreateOutput(
|
||||
IReplayRenderer *rend, WindowingSystem system, void *data, OutputType type)
|
||||
{
|
||||
return rend->CreateOutput(system, data, type);
|
||||
}
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_Shutdown(ReplayRenderer *rend)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_Shutdown(IReplayRenderer *rend)
|
||||
{
|
||||
rend->Shutdown();
|
||||
}
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_ShutdownOutput(ReplayRenderer *rend,
|
||||
ReplayOutput *output)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_ShutdownOutput(IReplayRenderer *rend,
|
||||
IReplayOutput *output)
|
||||
{
|
||||
rend->ShutdownOutput(output);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_FileChanged(ReplayRenderer *rend)
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_FileChanged(IReplayRenderer *rend)
|
||||
{
|
||||
rend->FileChanged();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_HasCallstacks(ReplayRenderer *rend)
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_HasCallstacks(IReplayRenderer *rend)
|
||||
{
|
||||
return rend->HasCallstacks();
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_InitResolver(ReplayRenderer *rend)
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_InitResolver(IReplayRenderer *rend)
|
||||
{
|
||||
return rend->InitResolver();
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SetFrameEvent(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SetFrameEvent(IReplayRenderer *rend,
|
||||
uint32_t eventID,
|
||||
bool32 force)
|
||||
{
|
||||
return rend->SetFrameEvent(eventID, force != 0);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetD3D11PipelineState(ReplayRenderer *rend, D3D11PipelineState *state)
|
||||
ReplayRenderer_GetD3D11PipelineState(IReplayRenderer *rend, D3D11PipelineState *state)
|
||||
{
|
||||
return rend->GetD3D11PipelineState(state);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetD3D12PipelineState(ReplayRenderer *rend, D3D12PipelineState *state)
|
||||
ReplayRenderer_GetD3D12PipelineState(IReplayRenderer *rend, D3D12PipelineState *state)
|
||||
{
|
||||
return rend->GetD3D12PipelineState(state);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetGLPipelineState(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetGLPipelineState(IReplayRenderer *rend,
|
||||
GLPipelineState *state)
|
||||
{
|
||||
return rend->GetGLPipelineState(state);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetVulkanPipelineState(ReplayRenderer *rend, VulkanPipelineState *state)
|
||||
ReplayRenderer_GetVulkanPipelineState(IReplayRenderer *rend, VulkanPipelineState *state)
|
||||
{
|
||||
return rend->GetVulkanPipelineState(state);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_BuildCustomShader(
|
||||
ReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
IReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
ShaderStageType type, ResourceId *shaderID, rdctype::str *errors)
|
||||
{
|
||||
if(shaderID == NULL)
|
||||
@@ -1747,14 +1747,14 @@ extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_BuildCustomShader(
|
||||
|
||||
*shaderID = rend->BuildCustomShader(entry, source, compileFlags, type, errors);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeCustomShader(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeCustomShader(IReplayRenderer *rend,
|
||||
ResourceId id)
|
||||
{
|
||||
return rend->FreeCustomShader(id);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_BuildTargetShader(
|
||||
ReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
IReplayRenderer *rend, const char *entry, const char *source, const uint32_t compileFlags,
|
||||
ShaderStageType type, ResourceId *shaderID, rdctype::str *errors)
|
||||
{
|
||||
if(shaderID == NULL)
|
||||
@@ -1762,85 +1762,85 @@ extern "C" RENDERDOC_API void RENDERDOC_CC ReplayRenderer_BuildTargetShader(
|
||||
|
||||
*shaderID = rend->BuildTargetShader(entry, source, compileFlags, type, errors);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_ReplaceResource(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_ReplaceResource(IReplayRenderer *rend,
|
||||
ResourceId from,
|
||||
ResourceId to)
|
||||
{
|
||||
return rend->ReplaceResource(from, to);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_RemoveReplacement(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_RemoveReplacement(IReplayRenderer *rend,
|
||||
ResourceId id)
|
||||
{
|
||||
return rend->RemoveReplacement(id);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeTargetResource(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_FreeTargetResource(IReplayRenderer *rend,
|
||||
ResourceId id)
|
||||
{
|
||||
return rend->FreeTargetResource(id);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetFrameInfo(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetFrameInfo(IReplayRenderer *rend,
|
||||
FetchFrameInfo *frame)
|
||||
{
|
||||
return rend->GetFrameInfo(frame);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetDrawcalls(ReplayRenderer *rend, rdctype::array<FetchDrawcall> *draws)
|
||||
ReplayRenderer_GetDrawcalls(IReplayRenderer *rend, rdctype::array<FetchDrawcall> *draws)
|
||||
{
|
||||
return rend->GetDrawcalls(draws);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_FetchCounters(ReplayRenderer *rend, uint32_t *counters, uint32_t numCounters,
|
||||
ReplayRenderer_FetchCounters(IReplayRenderer *rend, uint32_t *counters, uint32_t numCounters,
|
||||
rdctype::array<CounterResult> *results)
|
||||
{
|
||||
return rend->FetchCounters(counters, numCounters, results);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_EnumerateCounters(ReplayRenderer *rend, rdctype::array<uint32_t> *counters)
|
||||
ReplayRenderer_EnumerateCounters(IReplayRenderer *rend, rdctype::array<uint32_t> *counters)
|
||||
{
|
||||
return rend->EnumerateCounters(counters);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DescribeCounter(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DescribeCounter(IReplayRenderer *rend,
|
||||
uint32_t counterID,
|
||||
CounterDescription *desc)
|
||||
{
|
||||
return rend->DescribeCounter(counterID, desc);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetTextures(ReplayRenderer *rend, rdctype::array<FetchTexture> *texs)
|
||||
ReplayRenderer_GetTextures(IReplayRenderer *rend, rdctype::array<FetchTexture> *texs)
|
||||
{
|
||||
return rend->GetTextures(texs);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetBuffers(ReplayRenderer *rend, rdctype::array<FetchBuffer> *bufs)
|
||||
ReplayRenderer_GetBuffers(IReplayRenderer *rend, rdctype::array<FetchBuffer> *bufs)
|
||||
{
|
||||
return rend->GetBuffers(bufs);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetResolve(ReplayRenderer *rend, uint64_t *callstack, uint32_t callstackLen,
|
||||
ReplayRenderer_GetResolve(IReplayRenderer *rend, uint64_t *callstack, uint32_t callstackLen,
|
||||
rdctype::array<rdctype::str> *trace)
|
||||
{
|
||||
return rend->GetResolve(callstack, callstackLen, trace);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetDebugMessages(ReplayRenderer *rend, rdctype::array<DebugMessage> *msgs)
|
||||
ReplayRenderer_GetDebugMessages(IReplayRenderer *rend, rdctype::array<DebugMessage> *msgs)
|
||||
{
|
||||
return rend->GetDebugMessages(msgs);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_PixelHistory(
|
||||
ReplayRenderer *rend, ResourceId target, uint32_t x, uint32_t y, uint32_t slice, uint32_t mip,
|
||||
IReplayRenderer *rend, ResourceId target, uint32_t x, uint32_t y, uint32_t slice, uint32_t mip,
|
||||
uint32_t sampleIdx, FormatComponentType typeHint, rdctype::array<PixelModification> *history)
|
||||
{
|
||||
return rend->PixelHistory(target, x, y, slice, mip, sampleIdx, typeHint, history);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_DebugVertex(ReplayRenderer *rend, uint32_t vertid, uint32_t instid, uint32_t idx,
|
||||
ReplayRenderer_DebugVertex(IReplayRenderer *rend, uint32_t vertid, uint32_t instid, uint32_t idx,
|
||||
uint32_t instOffset, uint32_t vertOffset, ShaderDebugTrace *trace)
|
||||
{
|
||||
return rend->DebugVertex(vertid, instid, idx, instOffset, vertOffset, trace);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugPixel(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugPixel(IReplayRenderer *rend,
|
||||
uint32_t x, uint32_t y,
|
||||
uint32_t sample,
|
||||
uint32_t primitive,
|
||||
@@ -1848,7 +1848,7 @@ extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugPixel(ReplayRen
|
||||
{
|
||||
return rend->DebugPixel(x, y, sample, primitive, trace);
|
||||
}
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugThread(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugThread(IReplayRenderer *rend,
|
||||
uint32_t groupid[3],
|
||||
uint32_t threadid[3],
|
||||
ShaderDebugTrace *trace)
|
||||
@@ -1857,26 +1857,26 @@ extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_DebugThread(ReplayRe
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetUsage(ReplayRenderer *rend, ResourceId id, rdctype::array<EventUsage> *usage)
|
||||
ReplayRenderer_GetUsage(IReplayRenderer *rend, ResourceId id, rdctype::array<EventUsage> *usage)
|
||||
{
|
||||
return rend->GetUsage(id, usage);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetCBufferVariableContents(
|
||||
ReplayRenderer *rend, ResourceId shader, const char *entryPoint, uint32_t cbufslot,
|
||||
IReplayRenderer *rend, ResourceId shader, const char *entryPoint, uint32_t cbufslot,
|
||||
ResourceId buffer, uint64_t offs, rdctype::array<ShaderVariable> *vars)
|
||||
{
|
||||
return rend->GetCBufferVariableContents(shader, entryPoint, cbufslot, buffer, offs, vars);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SaveTexture(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_SaveTexture(IReplayRenderer *rend,
|
||||
const TextureSave &saveData,
|
||||
const char *path)
|
||||
{
|
||||
return rend->SaveTexture(saveData, path);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetPostVSData(ReplayRenderer *rend,
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetPostVSData(IReplayRenderer *rend,
|
||||
uint32_t instID,
|
||||
MeshDataStage stage,
|
||||
MeshFormat *data)
|
||||
@@ -1885,13 +1885,14 @@ extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetPostVSData(Replay
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetBufferData(
|
||||
ReplayRenderer *rend, ResourceId buff, uint64_t offset, uint64_t len, rdctype::array<byte> *data)
|
||||
IReplayRenderer *rend, ResourceId buff, uint64_t offset, uint64_t len, rdctype::array<byte> *data)
|
||||
{
|
||||
return rend->GetBufferData(buff, offset, len, data);
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC ReplayRenderer_GetTextureData(
|
||||
ReplayRenderer *rend, ResourceId tex, uint32_t arrayIdx, uint32_t mip, rdctype::array<byte> *data)
|
||||
extern "C" RENDERDOC_API bool32 RENDERDOC_CC
|
||||
ReplayRenderer_GetTextureData(IReplayRenderer *rend, ResourceId tex, uint32_t arrayIdx,
|
||||
uint32_t mip, rdctype::array<byte> *data)
|
||||
{
|
||||
return rend->GetTextureData(tex, arrayIdx, mip, data);
|
||||
}
|
||||
|
||||
@@ -191,7 +191,7 @@ public:
|
||||
|
||||
ReplayOutput *CreateOutput(WindowingSystem, void *data, OutputType type);
|
||||
|
||||
void ShutdownOutput(ReplayOutput *output);
|
||||
void ShutdownOutput(IReplayOutput *output);
|
||||
void Shutdown();
|
||||
|
||||
private:
|
||||
|
||||
@@ -45,7 +45,7 @@ void readCapOpts(const std::string &str, CaptureOptions *opts)
|
||||
*(b++) = (byte(str[i * 2 + 0] - 'a') << 4) | byte(str[i * 2 + 1] - 'a');
|
||||
}
|
||||
|
||||
void DisplayRendererPreview(ReplayRenderer *renderer, uint32_t width, uint32_t height)
|
||||
void DisplayRendererPreview(IReplayRenderer *renderer, uint32_t width, uint32_t height)
|
||||
{
|
||||
if(renderer == NULL)
|
||||
return;
|
||||
@@ -482,7 +482,7 @@ struct ReplayCommand : public Command
|
||||
std::cout << "Replaying '" << filename << "' on " << parser.get<string>("remote-host") << ":"
|
||||
<< parser.get<uint32_t>("remote-port") << "." << std::endl;
|
||||
|
||||
RemoteServer *remote = NULL;
|
||||
IRemoteServer *remote = NULL;
|
||||
ReplayCreateStatus status = RENDERDOC_CreateRemoteServerConnection(
|
||||
parser.get<string>("remote-host").c_str(), parser.get<uint32_t>("remote-port"), &remote);
|
||||
|
||||
|
||||
@@ -28,13 +28,7 @@
|
||||
|
||||
struct CaptureOptions;
|
||||
struct TextureDisplay;
|
||||
|
||||
#ifdef __cplusplus
|
||||
struct IReplayRenderer;
|
||||
typedef IReplayRenderer ReplayRenderer;
|
||||
#else
|
||||
struct ReplayRenderer
|
||||
#endif
|
||||
|
||||
struct Command
|
||||
{
|
||||
@@ -61,6 +55,6 @@ int renderdoccmd(std::vector<std::string> &argv);
|
||||
void readCapOpts(const std::string &str, CaptureOptions *opts);
|
||||
|
||||
// these must be defined in platform .cpps
|
||||
void DisplayRendererPreview(ReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
void DisplayRendererPreview(IReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
uint32_t height);
|
||||
void Daemonise();
|
||||
|
||||
@@ -48,13 +48,13 @@ void Daemonise()
|
||||
{
|
||||
}
|
||||
|
||||
void DisplayRendererPreview(ReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
void DisplayRendererPreview(IReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
uint32_t height)
|
||||
{
|
||||
ANativeWindow *connectionScreenWindow = android_state->window;
|
||||
|
||||
ReplayOutput *out = ReplayRenderer_CreateOutput(renderer, eWindowingSystem_Android,
|
||||
connectionScreenWindow, eOutputType_TexDisplay);
|
||||
IReplayOutput *out = ReplayRenderer_CreateOutput(renderer, eWindowingSystem_Android,
|
||||
connectionScreenWindow, eOutputType_TexDisplay);
|
||||
|
||||
OutputConfig c = {eOutputType_TexDisplay};
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@ void Daemonise()
|
||||
{
|
||||
}
|
||||
|
||||
void DisplayRendererPreview(ReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
void DisplayRendererPreview(IReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
uint32_t height)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -200,7 +200,7 @@ void VerifyVulkanLayer(int argc, char *argv[])
|
||||
add_command("vulkanregister", new VulkanRegisterCommand());
|
||||
}
|
||||
|
||||
void DisplayRendererPreview(ReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
void DisplayRendererPreview(IReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
uint32_t height)
|
||||
{
|
||||
// we only have the preview implemented for platforms that have xlib & xcb. It's unlikely
|
||||
@@ -279,7 +279,7 @@ void DisplayRendererPreview(ReplayRenderer *renderer, TextureDisplay &displayCfg
|
||||
xcb = true;
|
||||
}
|
||||
|
||||
ReplayOutput *out = NULL;
|
||||
IReplayOutput *out = NULL;
|
||||
|
||||
// prefer xcb
|
||||
if(xcb)
|
||||
|
||||
@@ -233,7 +233,7 @@ void Daemonise()
|
||||
// nothing really to do, windows version of renderdoccmd is already 'detached'
|
||||
}
|
||||
|
||||
void DisplayRendererPreview(ReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
void DisplayRendererPreview(IReplayRenderer *renderer, TextureDisplay &displayCfg, uint32_t width,
|
||||
uint32_t height)
|
||||
{
|
||||
RECT wr = {0, 0, (LONG)width, (LONG)height};
|
||||
@@ -249,7 +249,7 @@ void DisplayRendererPreview(ReplayRenderer *renderer, TextureDisplay &displayCfg
|
||||
ShowWindow(wnd, SW_SHOW);
|
||||
UpdateWindow(wnd);
|
||||
|
||||
ReplayOutput *out =
|
||||
IReplayOutput *out =
|
||||
ReplayRenderer_CreateOutput(renderer, eWindowingSystem_Win32, wnd, eOutputType_TexDisplay);
|
||||
|
||||
OutputConfig c = {eOutputType_TexDisplay};
|
||||
|
||||
Reference in New Issue
Block a user