diff --git a/framework/decode/metadata_json_consumer.h b/framework/decode/metadata_json_consumer.h index 6d36737acf..587d4ed0bd 100644 --- a/framework/decode/metadata_json_consumer.h +++ b/framework/decode/metadata_json_consumer.h @@ -25,6 +25,7 @@ #define GFXRECON_DECODE_METADATA_JSON_CONSUMER_H #include "util/defines.h" +#include "util/file_path.h" #include "format/format_json.h" GFXRECON_BEGIN_NAMESPACE(gfxrecon) @@ -78,6 +79,22 @@ class MetadataJsonConsumer : public Base WriteBlockEnd(); } + virtual void Process_ExeFileInfo(gfxrecon::util::filepath::FileInfo& info) override + { + const util::JsonOptions& json_options = GetOptions(); + auto& jdata = WriteMetaCommandStart("ExeFileInfo"); + FieldToJson(jdata["product_version"], info.ProductVersion, json_options); + FieldToJson(jdata["file_version"], info.FileVersion, json_options); + FieldToJson(jdata["app_version"], info.AppVersion, json_options); + FieldToJson(jdata["app_name"], info.AppName, json_options); + FieldToJson(jdata["company_name"], info.CompanyName, json_options); + FieldToJson(jdata["file_description"], info.FileDescription, json_options); + FieldToJson(jdata["internal_name"], info.InternalName, json_options); + FieldToJson(jdata["original_filename"], info.OriginalFilename, json_options); + FieldToJson(jdata["product_name"], info.ProductName, json_options); + WriteBlockEnd(); + } + virtual void ProcessResizeWindowCommand(format::HandleId surface_id, uint32_t width, uint32_t height) override { using namespace util; diff --git a/framework/decode/vulkan_decoder_base.cpp b/framework/decode/vulkan_decoder_base.cpp index 84534cf4cc..fd1667edbd 100644 --- a/framework/decode/vulkan_decoder_base.cpp +++ b/framework/decode/vulkan_decoder_base.cpp @@ -83,6 +83,13 @@ void VulkanDecoderBase::DispatchFillMemoryCommand( } } +void VulkanDecoderBase::DispatchExeFileInfo(format::ThreadId thread_id, format::ExeFileInfoBlock& info) +{ + for (auto consumer: consumers_) { + consumer->Process_ExeFileInfo(info.info_record); + } +} + void VulkanDecoderBase::DispatchFillMemoryResourceValueCommand( const format::FillMemoryResourceValueCommandHeader& command_header, const uint8_t* data) { diff --git a/framework/decode/vulkan_decoder_base.h b/framework/decode/vulkan_decoder_base.h index b488dc0ecc..6f371e8f09 100644 --- a/framework/decode/vulkan_decoder_base.h +++ b/framework/decode/vulkan_decoder_base.h @@ -193,7 +193,7 @@ class VulkanDecoderBase : public ApiDecoder virtual void DispatchDriverInfo(format::ThreadId thread_id, format::DriverInfoBlock& info) override {} - virtual void DispatchExeFileInfo(format::ThreadId thread_id, format::ExeFileInfoBlock& info) override {} + virtual void DispatchExeFileInfo(format::ThreadId thread_id, format::ExeFileInfoBlock& info) override; virtual void SetCurrentBlockIndex(uint64_t block_index) override;