This commit is contained in:
riperiperi 2022-01-23 19:05:02 +00:00
parent 2f066d1d6d
commit 3f38a8526c
2 changed files with 8 additions and 13 deletions

View file

@ -84,7 +84,11 @@ namespace Ryujinx.Graphics.Vulkan.Queries
{
Marshal.WriteInt64(_bufferMap, DefaultValue);
_pipeline.CopyQueryResults(_queryPool, _buffer);
// _pipeline.FlushCommandsImpl();
}
else
{
// Dummy result, just return 0.
Marshal.WriteInt64(_bufferMap, 0);
}
}

View file

@ -125,19 +125,10 @@ namespace Ryujinx.Graphics.Vulkan.Queries
_current.ReserveForHostAccess();
}
if (draws > 0 && Type != CounterType.TransformFeedbackPrimitivesWritten)
{
_current.Complete(true);
_events.Enqueue(_current);
_current.Complete(draws > 0 && Type != CounterType.TransformFeedbackPrimitivesWritten);
_events.Enqueue(_current);
_current.OnResult += resultHandler;
}
else
{
_current.Complete(false);
_current.Dispose();
resultHandler(_current, 0);
}
_current.OnResult += resultHandler;
result = _current;