Program Listing for File d3d12-rootsignature.h

Return to documentation for file (include\d3d12-state-tracking\d3d12-rootsignature.h)

/******************************************************************************
© Intel Corporation.

This software and the related documents are Intel copyrighted materials,
and your use of them is governed by the express license under which they
were provided to you ("License"). Unless the License provides otherwise,
you may not use, modify, copy, publish, distribute, disclose or transmit
this software or the related documents without Intel's prior written
permission.


 This software and the related documents are provided as is, with no express
or implied warranties, other than those that are expressly stated in the
License.

******************************************************************************/

#pragma once
#include "d3d12-object.h"
#include "reflection/struct-data-manager.h"
#include <d3d12.h>
#include <memory>

namespace gpa {
namespace d3d12_state_tracker {

class D3D12RootSignatureState : public D3D12ObjectState
{
private:
    D3D12_VERSIONED_ROOT_SIGNATURE_DESC mDesc{};
    std::vector<uint8_t> mBlob;
    std::unique_ptr<serialization::StructDataManager> mRootSignatureDescDataManager;

public:
    static constexpr GUID sGUID = {0xedbfb6b, 0x6e67, 0x4ad7, {0x97, 0xbd, 0x76, 0x30, 0x34, 0x4b, 0xb5, 0xc3}};

public:
    D3D12RootSignatureState(ID3D12RootSignature* runtimeObj, void const* pBlobWithRootSignature, size_t blobLengthInBytes);
    virtual ~D3D12RootSignatureState();

    GUID GetGUID() override;

    D3D12_VERSIONED_ROOT_SIGNATURE_DESC const* GetRootSignatureDesc() const;
    std::vector<uint8_t> GetRootSignatureBlob() const;
};

}  // namespace d3d12_state_tracker
}  // namespace gpa