mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2026-05-05 04:45:48 +00:00
feature: .NET 10 (ryubing/ryujinx!214)
See merge request ryubing/ryujinx!214
This commit is contained in:
@@ -171,7 +171,7 @@ namespace Ryujinx.Graphics.Gpu.Engine.InlineToMemory
|
||||
{
|
||||
MemoryManager memoryManager = _channel.MemoryManager;
|
||||
|
||||
Span<byte> data = MemoryMarshal.Cast<int, byte>(_buffer)[.._size];
|
||||
Span<byte> data = MemoryMarshal.Cast<int, byte>(new Span<int>(_buffer))[.._size];
|
||||
|
||||
if (_isLinear && _lineCount == 1)
|
||||
{
|
||||
|
||||
@@ -176,7 +176,7 @@ namespace Ryujinx.Graphics.Gpu.Engine.Threed.ComputeDraw
|
||||
ulong vbSize = GetVertexBufferSize(address, endAddress.Pack(), vbStride, _indexed, instanced, _firstVertex, _count);
|
||||
|
||||
ulong attributeOffset = (ulong)vertexAttrib.UnpackOffset();
|
||||
int componentSize = format.GetScalarSize();
|
||||
int componentSize = format.ScalarSize;
|
||||
|
||||
address += attributeOffset;
|
||||
|
||||
|
||||
@@ -849,8 +849,8 @@ namespace Ryujinx.Graphics.Gpu.Engine.Threed
|
||||
|
||||
FormatInfo dsFormat = _state.State.RtDepthStencilState.Format.Convert();
|
||||
|
||||
bool hasDepth = dsFormat.Format.HasDepth();
|
||||
bool hasStencil = dsFormat.Format.HasStencil();
|
||||
bool hasDepth = dsFormat.Format.HasDepth;
|
||||
bool hasStencil = dsFormat.Format.HasStencil;
|
||||
|
||||
if (hasStencil && (!clearStencil || (clearAffectedByStencilMask && _state.State.StencilTestState.FrontMask != 0xff)))
|
||||
{
|
||||
|
||||
@@ -297,7 +297,9 @@ namespace Ryujinx.Graphics.Gpu.Engine.Threed
|
||||
{
|
||||
Format format = colorState.Format.Convert().Format;
|
||||
|
||||
AttributeType type = format.IsInteger() ? (format.IsSint() ? AttributeType.Sint : AttributeType.Uint) : AttributeType.Float;
|
||||
AttributeType type = format.IsInt
|
||||
? (format.IsSignedInt ? AttributeType.Sint : AttributeType.Uint)
|
||||
: AttributeType.Float;
|
||||
|
||||
if (type != fragmentOutputTypesSpan[index])
|
||||
{
|
||||
|
||||
@@ -534,7 +534,7 @@ namespace Ryujinx.Graphics.Gpu.Engine.Threed
|
||||
|
||||
if (!_context.Capabilities.SupportsBgraFormat)
|
||||
{
|
||||
_context.SupportBufferUpdater.SetRenderTargetIsBgra(index, color.Format.IsBgr());
|
||||
_context.SupportBufferUpdater.SetRenderTargetIsBgra(index, color.Format.IsBgr);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1317,10 +1317,10 @@ namespace Ryujinx.Graphics.Gpu.Engine.Threed
|
||||
FilterBlendFactor(blend.AlphaDstFactor, index));
|
||||
|
||||
if (enable &&
|
||||
(blend.ColorSrcFactor.IsDualSource() ||
|
||||
blend.ColorDstFactor.IsDualSource() ||
|
||||
blend.AlphaSrcFactor.IsDualSource() ||
|
||||
blend.AlphaDstFactor.IsDualSource()))
|
||||
(blend.ColorSrcFactor.IsDualSource ||
|
||||
blend.ColorDstFactor.IsDualSource ||
|
||||
blend.AlphaSrcFactor.IsDualSource ||
|
||||
blend.AlphaDstFactor.IsDualSource))
|
||||
{
|
||||
dualSourceBlendEnabled = true;
|
||||
}
|
||||
@@ -1345,10 +1345,10 @@ namespace Ryujinx.Graphics.Gpu.Engine.Threed
|
||||
FilterBlendFactor(blend.AlphaDstFactor, 0));
|
||||
|
||||
if (enable &&
|
||||
(blend.ColorSrcFactor.IsDualSource() ||
|
||||
blend.ColorDstFactor.IsDualSource() ||
|
||||
blend.AlphaSrcFactor.IsDualSource() ||
|
||||
blend.AlphaDstFactor.IsDualSource()))
|
||||
(blend.ColorSrcFactor.IsDualSource ||
|
||||
blend.ColorDstFactor.IsDualSource ||
|
||||
blend.AlphaSrcFactor.IsDualSource ||
|
||||
blend.AlphaDstFactor.IsDualSource))
|
||||
{
|
||||
dualSourceBlendEnabled = true;
|
||||
}
|
||||
|
||||
@@ -333,7 +333,7 @@ namespace Ryujinx.Graphics.Gpu.Engine.Twod
|
||||
// as copies between depth and color formats are not allowed.
|
||||
// For depth blit, the destination texture format should always match exactly.
|
||||
|
||||
if (srcTexture.Format.IsDepthOrStencil())
|
||||
if (srcTexture.Format.IsDepthOrStencil)
|
||||
{
|
||||
dstCopyTextureFormat = srcTexture.Info.FormatInfo;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user