1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-31 14:52:11 +01:00

[dxbc] Parse patch constant signature

This commit is contained in:
Philip Rebohle 2019-01-26 14:52:29 +01:00
parent 3960355d47
commit 0b5cffb0bb
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
6 changed files with 15 additions and 3 deletions

View File

@ -7,9 +7,11 @@ namespace dxvk {
const DxbcProgramInfo& programInfo, const DxbcProgramInfo& programInfo,
const Rc<DxbcIsgn>& isgn, const Rc<DxbcIsgn>& isgn,
const Rc<DxbcIsgn>& osgn, const Rc<DxbcIsgn>& osgn,
const Rc<DxbcIsgn>& psgn,
DxbcAnalysisInfo& analysis) DxbcAnalysisInfo& analysis)
: m_isgn (isgn), : m_isgn (isgn),
m_osgn (osgn), m_osgn (osgn),
m_psgn (psgn),
m_analysis(&analysis) { m_analysis(&analysis) {
// Get number of clipping and culling planes from the // Get number of clipping and culling planes from the
// input and output signatures. We will need this to // input and output signatures. We will need this to

View File

@ -58,6 +58,7 @@ namespace dxvk {
const DxbcProgramInfo& programInfo, const DxbcProgramInfo& programInfo,
const Rc<DxbcIsgn>& isgn, const Rc<DxbcIsgn>& isgn,
const Rc<DxbcIsgn>& osgn, const Rc<DxbcIsgn>& osgn,
const Rc<DxbcIsgn>& psgn,
DxbcAnalysisInfo& analysis); DxbcAnalysisInfo& analysis);
~DxbcAnalyzer(); ~DxbcAnalyzer();
@ -73,6 +74,7 @@ namespace dxvk {
Rc<DxbcIsgn> m_isgn; Rc<DxbcIsgn> m_isgn;
Rc<DxbcIsgn> m_osgn; Rc<DxbcIsgn> m_osgn;
Rc<DxbcIsgn> m_psgn;
DxbcAnalysisInfo* m_analysis = nullptr; DxbcAnalysisInfo* m_analysis = nullptr;

View File

@ -15,11 +15,13 @@ namespace dxvk {
const DxbcProgramInfo& programInfo, const DxbcProgramInfo& programInfo,
const Rc<DxbcIsgn>& isgn, const Rc<DxbcIsgn>& isgn,
const Rc<DxbcIsgn>& osgn, const Rc<DxbcIsgn>& osgn,
const Rc<DxbcIsgn>& psgn,
const DxbcAnalysisInfo& analysis) const DxbcAnalysisInfo& analysis)
: m_moduleInfo (moduleInfo), : m_moduleInfo (moduleInfo),
m_programInfo(programInfo), m_programInfo(programInfo),
m_isgn (isgn), m_isgn (isgn),
m_osgn (osgn), m_osgn (osgn),
m_psgn (psgn),
m_analysis (&analysis) { m_analysis (&analysis) {
// Declare an entry point ID. We'll need it during the // Declare an entry point ID. We'll need it during the
// initialization phase where the execution mode is set. // initialization phase where the execution mode is set.

View File

@ -377,6 +377,7 @@ namespace dxvk {
const DxbcProgramInfo& programInfo, const DxbcProgramInfo& programInfo,
const Rc<DxbcIsgn>& isgn, const Rc<DxbcIsgn>& isgn,
const Rc<DxbcIsgn>& osgn, const Rc<DxbcIsgn>& osgn,
const Rc<DxbcIsgn>& psgn,
const DxbcAnalysisInfo& analysis); const DxbcAnalysisInfo& analysis);
~DxbcCompiler(); ~DxbcCompiler();
@ -410,6 +411,7 @@ namespace dxvk {
Rc<DxbcIsgn> m_isgn; Rc<DxbcIsgn> m_isgn;
Rc<DxbcIsgn> m_osgn; Rc<DxbcIsgn> m_osgn;
Rc<DxbcIsgn> m_psgn;
const DxbcAnalysisInfo* m_analysis; const DxbcAnalysisInfo* m_analysis;

View File

@ -28,6 +28,9 @@ namespace dxvk {
if ((tag == "OSGN") || (tag == "OSG5") || (tag == "OSG1")) if ((tag == "OSGN") || (tag == "OSG5") || (tag == "OSG1"))
m_osgnChunk = new DxbcIsgn(chunkReader, tag); m_osgnChunk = new DxbcIsgn(chunkReader, tag);
if ((tag == "PCSG") || (tag == "PSG1"))
m_psgnChunk = new DxbcIsgn(chunkReader, tag);
} }
} }
@ -48,7 +51,7 @@ namespace dxvk {
DxbcAnalyzer analyzer(moduleInfo, DxbcAnalyzer analyzer(moduleInfo,
m_shexChunk->programInfo(), m_shexChunk->programInfo(),
m_isgnChunk, m_osgnChunk, m_isgnChunk, m_osgnChunk,
analysisInfo); m_psgnChunk, analysisInfo);
this->runAnalyzer(analyzer, m_shexChunk->slice()); this->runAnalyzer(analyzer, m_shexChunk->slice());
@ -56,7 +59,7 @@ namespace dxvk {
fileName, moduleInfo, fileName, moduleInfo,
m_shexChunk->programInfo(), m_shexChunk->programInfo(),
m_isgnChunk, m_osgnChunk, m_isgnChunk, m_osgnChunk,
analysisInfo); m_psgnChunk, analysisInfo);
this->runCompiler(compiler, m_shexChunk->slice()); this->runCompiler(compiler, m_shexChunk->slice());
@ -76,7 +79,7 @@ namespace dxvk {
fileName, moduleInfo, fileName, moduleInfo,
DxbcProgramType::GeometryShader, DxbcProgramType::GeometryShader,
m_osgnChunk, m_osgnChunk, m_osgnChunk, m_osgnChunk,
analysisInfo); m_psgnChunk, analysisInfo);
compiler.processXfbPassthrough(); compiler.processXfbPassthrough();
return compiler.finalize(); return compiler.finalize();

View File

@ -80,6 +80,7 @@ namespace dxvk {
Rc<DxbcIsgn> m_isgnChunk; Rc<DxbcIsgn> m_isgnChunk;
Rc<DxbcIsgn> m_osgnChunk; Rc<DxbcIsgn> m_osgnChunk;
Rc<DxbcIsgn> m_psgnChunk;
Rc<DxbcShex> m_shexChunk; Rc<DxbcShex> m_shexChunk;
void runAnalyzer( void runAnalyzer(