UE4 - Metal integration from Zebra

- Shader changes/fix-ups, support for MRT & SM5 on the shader code gen backend
#codereview Mark.Satterthwaite, Michael.Trepka, Josh.Adams, Peter.Sauerbrei

[CL 2599662 by Rolando Caloca in Main branch]
This commit is contained in:
Rolando Caloca
2015-06-24 17:40:55 -04:00
committed by Rolando.Caloca@epicgames.com
parent 0f9cefe6cf
commit 215d4c8c16
8 changed files with 511 additions and 295 deletions

View File

@@ -10,12 +10,13 @@
static FName NAME_SF_METAL(TEXT("SF_METAL"));
static FName NAME_SF_METAL_MRT(TEXT("SF_METAL_MRT"));
static FName NAME_SF_METAL_SM5(TEXT("SF_METAL_SM5"));
class FMetalShaderFormat : public IShaderFormat
{
enum
{
HEADER_VERSION = 14,
HEADER_VERSION = 17,
};
struct FVersion
{
@@ -51,10 +52,11 @@ public:
{
OutFormats.Add(NAME_SF_METAL);
OutFormats.Add(NAME_SF_METAL_MRT);
OutFormats.Add(NAME_SF_METAL_SM5);
}
virtual void CompileShader(FName Format, const struct FShaderCompilerInput& Input, struct FShaderCompilerOutput& Output,const FString& WorkingDirectory) const
{
check(Format == NAME_SF_METAL || Format == NAME_SF_METAL_MRT);
check(Format == NAME_SF_METAL || Format == NAME_SF_METAL_MRT || Format == NAME_SF_METAL_SM5);
CompileShader_Metal(Input, Output, WorkingDirectory);
}
};