WIP: Experimental: Metal backend #439

Closed
GreemDev wants to merge 374 commits from metal into master
Showing only changes of commit 20b1f6a6ee - Show all commits

View File

@ -227,10 +227,16 @@ namespace Ryujinx.Graphics.Metal
var vertexDescriptor = BuildVertexDescriptor(_currentState.VertexBuffers, _currentState.VertexAttribs);
renderPipelineDescriptor.VertexDescriptor = vertexDescriptor;
try
{
if (_currentState.VertexFunction != null)
{
renderPipelineDescriptor.VertexFunction = _currentState.VertexFunction.Value;
}
else
{
return;
}
if (_currentState.FragmentFunction != null)
{
@ -246,11 +252,14 @@ namespace Ryujinx.Graphics.Metal
_currentState.BlendColor.Green,
_currentState.BlendColor.Blue,
_currentState.BlendColor.Alpha);
}
finally
{
// Cleanup
renderPipelineDescriptor.Dispose();
vertexDescriptor.Dispose();
}
}
public void UpdateIndexBuffer(BufferRange buffer, IndexType type)
{