aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.Graphics.GAL/Multithreading/Commands/SetPolygonModeCommand.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Ryujinx.Graphics.GAL/Multithreading/Commands/SetPolygonModeCommand.cs')
-rw-r--r--src/Ryujinx.Graphics.GAL/Multithreading/Commands/SetPolygonModeCommand.cs20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/Ryujinx.Graphics.GAL/Multithreading/Commands/SetPolygonModeCommand.cs b/src/Ryujinx.Graphics.GAL/Multithreading/Commands/SetPolygonModeCommand.cs
new file mode 100644
index 00000000..ea2f838b
--- /dev/null
+++ b/src/Ryujinx.Graphics.GAL/Multithreading/Commands/SetPolygonModeCommand.cs
@@ -0,0 +1,20 @@
+namespace Ryujinx.Graphics.GAL.Multithreading.Commands
+{
+ struct SetPolygonModeCommand : IGALCommand, IGALCommand<SetPolygonModeCommand>
+ {
+ public CommandType CommandType => CommandType.SetPolygonMode;
+ private PolygonMode _frontMode;
+ private PolygonMode _backMode;
+
+ public void Set(PolygonMode frontMode, PolygonMode backMode)
+ {
+ _frontMode = frontMode;
+ _backMode = backMode;
+ }
+
+ public static void Run(ref SetPolygonModeCommand command, ThreadedRenderer threaded, IRenderer renderer)
+ {
+ renderer.Pipeline.SetPolygonMode(command._frontMode, command._backMode);
+ }
+ }
+}