mirror of
				https://github.com/hedge-dev/XenosRecomp.git
				synced 2025-10-30 07:12:17 +00:00 
			
		
		
		
	Initial vertex IO fixes
Signed-off-by: Isaac Marovitz <isaacryu@icloud.com>
This commit is contained in:
		
							parent
							
								
									790c8be91b
								
							
						
					
					
						commit
						6c7c8fa87d
					
				
					 1 changed files with 12 additions and 5 deletions
				
			
		|  | @ -1360,6 +1360,7 @@ void ShaderRecompiler::recompile(const uint8_t* shaderData, const std::string_vi | |||
| 
 | ||||
|     out += "#if __air__\n"; | ||||
| 
 | ||||
|     if (isPixelShader) { | ||||
|         out += "struct StageIn\n"; | ||||
|         out += "{\n"; | ||||
| 
 | ||||
|  | @ -1367,6 +1368,7 @@ void ShaderRecompiler::recompile(const uint8_t* shaderData, const std::string_vi | |||
|             println("\tfloat4 i{}{};", USAGE_VARIABLES[uint32_t(usage)], usageIndex); | ||||
| 
 | ||||
|         out += "};\n"; | ||||
|     } | ||||
| 
 | ||||
|     if (isPixelShader) | ||||
|         out += "[[fragment]]\n"; | ||||
|  | @ -1479,8 +1481,13 @@ void ShaderRecompiler::recompile(const uint8_t* shaderData, const std::string_vi | |||
|     #ifdef UNLEASHED_RECOMP | ||||
|         if (hasIndexCount) | ||||
|         { | ||||
|             out += "#ifdef __air__\n"; | ||||
|             out += "\tuint iVertexId [[vertex_id]],\n"; | ||||
|             out += "\tuint iInstanceId [[instance_id]],\n"; | ||||
|             out += "#else\n"; | ||||
|             out += "\tin uint iVertexId : SV_VertexID,\n"; | ||||
|             out += "\tin uint iInstanceId : SV_InstanceID,\n"; | ||||
|             out += "#endif\n"; | ||||
|         } | ||||
|     #endif | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue
	
	 Isaac Marovitz
						Isaac Marovitz