mirror of
				https://git.zaroz.cloud/nintendo-back-up/yuzu/yuzu-mainline.git
				synced 2025-03-21 01:53:15 +00:00 
			
		
		
		
	shader_decode: Implement LDG and basic cbuf tracking
This commit is contained in:
		
							parent
							
								
									10ab714fe0
								
							
						
					
					
						commit
						049050856f
					
				| @ -92,6 +92,39 @@ private: | ||||
|     std::string name; | ||||
| }; | ||||
| 
 | ||||
| class GlobalMemoryEntry { | ||||
| public: | ||||
|     explicit GlobalMemoryEntry(u32 cbuf_index, u32 cbuf_offset, Maxwell::ShaderStage stage, | ||||
|                                std::string name) | ||||
|         : cbuf_index{cbuf_index}, cbuf_offset{cbuf_offset}, stage{stage}, name{std::move(name)} {} | ||||
| 
 | ||||
|     u32 GetCbufIndex() const { | ||||
|         return cbuf_index; | ||||
|     } | ||||
| 
 | ||||
|     u32 GetCbufOffset() const { | ||||
|         return cbuf_offset; | ||||
|     } | ||||
| 
 | ||||
|     const std::string& GetName() const { | ||||
|         return name; | ||||
|     } | ||||
| 
 | ||||
|     Maxwell::ShaderStage GetStage() const { | ||||
|         return stage; | ||||
|     } | ||||
| 
 | ||||
|     u32 GetHash() const { | ||||
|         return (static_cast<u32>(stage) << 24) | (cbuf_index << 16) | cbuf_offset; | ||||
|     } | ||||
| 
 | ||||
| private: | ||||
|     u32 cbuf_index{}; | ||||
|     u32 cbuf_offset{}; | ||||
|     Maxwell::ShaderStage stage{}; | ||||
|     std::string name; | ||||
| }; | ||||
| 
 | ||||
| struct ShaderEntries { | ||||
|     std::vector<ConstBufferEntry> const_buffers; | ||||
|     std::vector<SamplerEntry> samplers; | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 ReinUsesLisp
						ReinUsesLisp