aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.Graphics.Shader/CodeGen/Glsl/Instructions/InstGenFSI.cs
blob: 1697aa47e778a5d98cf824896c3956c154a98338 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
namespace Ryujinx.Graphics.Shader.CodeGen.Glsl.Instructions
{
    static class InstGenFSI
    {
        public static string FSIBegin(CodeGenContext context)
        {
            if (context.HostCapabilities.SupportsFragmentShaderInterlock)
            {
                return "beginInvocationInterlockARB()";
            }
            else if (context.HostCapabilities.SupportsFragmentShaderOrderingIntel)
            {
                return "beginFragmentShaderOrderingINTEL()";
            }

            return null;
        }

        public static string FSIEnd(CodeGenContext context)
        {
            if (context.HostCapabilities.SupportsFragmentShaderInterlock)
            {
                return "endInvocationInterlockARB()";
            }

            return null;
        }
    }
}