mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-10-01 12:30:00 +02:00
24 lines
612 B
C#
24 lines
612 B
C#
|
using OpenTK.Graphics.OpenGL;
|
||
|
using Ryujinx.Graphics.GAL;
|
||
|
using System;
|
||
|
|
||
|
namespace Ryujinx.Graphics.OpenGL
|
||
|
{
|
||
|
static class FaceConverter
|
||
|
{
|
||
|
public static CullFaceMode Convert(this Face face)
|
||
|
{
|
||
|
switch (face)
|
||
|
{
|
||
|
case Face.Back: return CullFaceMode.Back;
|
||
|
case Face.Front: return CullFaceMode.Front;
|
||
|
case Face.FrontAndBack: return CullFaceMode.FrontAndBack;
|
||
|
}
|
||
|
|
||
|
return CullFaceMode.FrontAndBack;
|
||
|
|
||
|
throw new ArgumentException($"Invalid face \"{face}\".");
|
||
|
}
|
||
|
}
|
||
|
}
|