aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Graphics.Nvdec
diff options
context:
space:
mode:
Diffstat (limited to 'Ryujinx.Graphics.Nvdec')
-rw-r--r--Ryujinx.Graphics.Nvdec/NvdecRegisters.cs11
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/H264/PictureInfo.cs2
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/H264/ReferenceFrame.cs2
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/Vp9/EntropyProbs.cs2
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/Vp9/FrameSize.cs2
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/Vp9/FrameStats.cs2
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/Vp9/LoopFilter.cs2
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/Vp9/PictureInfo.cs2
-rw-r--r--Ryujinx.Graphics.Nvdec/Types/Vp9/Segmentation.cs2
9 files changed, 23 insertions, 4 deletions
diff --git a/Ryujinx.Graphics.Nvdec/NvdecRegisters.cs b/Ryujinx.Graphics.Nvdec/NvdecRegisters.cs
index b40e08b0..84b2c4e0 100644
--- a/Ryujinx.Graphics.Nvdec/NvdecRegisters.cs
+++ b/Ryujinx.Graphics.Nvdec/NvdecRegisters.cs
@@ -3,13 +3,15 @@
namespace Ryujinx.Graphics.Nvdec
{
// Note: Most of those names are not official.
- unsafe struct NvdecRegisters
+ struct NvdecRegisters
{
- public fixed uint Reserved0[128];
+#pragma warning disable CS0649
+ public Array64<uint> Reserved0;
+ public Array64<uint> Reserved100;
public uint SetCodecID;
- public fixed uint Reserved204[63];
+ public Array63<uint> Reserved204;
public uint Execute;
- public fixed uint Reserved304[63];
+ public Array63<uint> Reserved304;
public uint SetPlatformID;
public uint SetPictureInfoOffset;
public uint SetBitstreamOffset;
@@ -37,5 +39,6 @@ namespace Ryujinx.Graphics.Nvdec
public uint SetVp9LastFrameMvsOffset;
public uint SetVp9CurrFrameMvsOffset;
public uint Unknown5DC;
+#pragma warning restore CS0649
}
}
diff --git a/Ryujinx.Graphics.Nvdec/Types/H264/PictureInfo.cs b/Ryujinx.Graphics.Nvdec/Types/H264/PictureInfo.cs
index 92767e35..86570342 100644
--- a/Ryujinx.Graphics.Nvdec/Types/H264/PictureInfo.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/H264/PictureInfo.cs
@@ -5,6 +5,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.H264
{
struct PictureInfo
{
+#pragma warning disable CS0169, CS0649
Array18<uint> Unknown0;
public uint BitstreamSize;
public uint NumSlices;
@@ -47,6 +48,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.H264
public Array16<byte> MvcextViewRefMasksL1;
public uint Flags2;
public Array10<uint> Unknown2D4;
+#pragma warning restore CS0169, CS0649
public bool MbAdaptiveFrameFieldFlag => (Flags & (1 << 0)) != 0;
public bool Direct8x8InferenceFlag => (Flags & (1 << 1)) != 0;
diff --git a/Ryujinx.Graphics.Nvdec/Types/H264/ReferenceFrame.cs b/Ryujinx.Graphics.Nvdec/Types/H264/ReferenceFrame.cs
index 5db311ae..163a8783 100644
--- a/Ryujinx.Graphics.Nvdec/Types/H264/ReferenceFrame.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/H264/ReferenceFrame.cs
@@ -2,9 +2,11 @@
{
struct ReferenceFrame
{
+#pragma warning disable CS0649
public uint Unknown0;
public uint Unknown4;
public uint Unknown8;
public uint UnknownC;
+#pragma warning restore CS0649
}
}
diff --git a/Ryujinx.Graphics.Nvdec/Types/Vp9/EntropyProbs.cs b/Ryujinx.Graphics.Nvdec/Types/Vp9/EntropyProbs.cs
index bc848454..b2858d2d 100644
--- a/Ryujinx.Graphics.Nvdec/Types/Vp9/EntropyProbs.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/Vp9/EntropyProbs.cs
@@ -5,6 +5,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{
struct EntropyProbs
{
+#pragma warning disable CS0649
public Array10<Array10<Array8<byte>>> KfYModeProbE0ToE7;
public Array10<Array10<byte>> KfYModeProbE8;
public Array3<byte> Padding384;
@@ -41,6 +42,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
public Array5<byte> CompRefProb;
public Array17<byte> Padding58F;
public Array4<Array2<Array2<Array6<Array6<Array4<byte>>>>>> CoefProbs;
+#pragma warning restore CS0649
public void Convert(ref Vp9EntropyProbs fc)
{
diff --git a/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameSize.cs b/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameSize.cs
index 70988b48..d449ec4d 100644
--- a/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameSize.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameSize.cs
@@ -2,9 +2,11 @@
{
struct FrameSize
{
+#pragma warning disable CS0649
public ushort Width;
public ushort Height;
public ushort LumaPitch;
public ushort ChromaPitch;
+#pragma warning restore CS0649
}
}
diff --git a/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameStats.cs b/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameStats.cs
index 3a3d4762..c360d378 100644
--- a/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameStats.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/Vp9/FrameStats.cs
@@ -2,6 +2,7 @@
{
struct FrameStats
{
+#pragma warning disable CS0649
public uint Unknown0;
public uint Unknown4;
public uint Pass2CycleCount;
@@ -16,5 +17,6 @@
public uint ErrorCtbPos;
public uint ErrorSlicePos;
public uint Unknown34;
+#pragma warning restore CS0649
}
}
diff --git a/Ryujinx.Graphics.Nvdec/Types/Vp9/LoopFilter.cs b/Ryujinx.Graphics.Nvdec/Types/Vp9/LoopFilter.cs
index d8d5ab20..7cb0fd7a 100644
--- a/Ryujinx.Graphics.Nvdec/Types/Vp9/LoopFilter.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/Vp9/LoopFilter.cs
@@ -4,8 +4,10 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{
struct LoopFilter
{
+#pragma warning disable CS0649
public byte ModeRefDeltaEnabled;
public Array4<sbyte> RefDeltas;
public Array2<sbyte> ModeDeltas;
+#pragma warning restore CS0649
}
}
diff --git a/Ryujinx.Graphics.Nvdec/Types/Vp9/PictureInfo.cs b/Ryujinx.Graphics.Nvdec/Types/Vp9/PictureInfo.cs
index f1f9e2f1..7d06f747 100644
--- a/Ryujinx.Graphics.Nvdec/Types/Vp9/PictureInfo.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/Vp9/PictureInfo.cs
@@ -5,6 +5,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{
struct PictureInfo
{
+#pragma warning disable CS0649
public Array12<uint> Unknown0;
public uint BitstreamSize;
public uint IsEncrypted;
@@ -41,6 +42,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
public uint UnknownF4;
public uint UnknownF8;
public uint UnknownFC;
+#pragma warning restore CS0649
public uint BitDepth => (SurfaceParams >> 1) & 0xf;
diff --git a/Ryujinx.Graphics.Nvdec/Types/Vp9/Segmentation.cs b/Ryujinx.Graphics.Nvdec/Types/Vp9/Segmentation.cs
index ed62293d..f6c4f0b1 100644
--- a/Ryujinx.Graphics.Nvdec/Types/Vp9/Segmentation.cs
+++ b/Ryujinx.Graphics.Nvdec/Types/Vp9/Segmentation.cs
@@ -4,11 +4,13 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{
struct Segmentation
{
+#pragma warning disable CS0649
public byte Enabled;
public byte UpdateMap;
public byte TemporalUpdate;
public byte AbsDelta;
public Array8<uint> FeatureMask;
public Array8<Array4<short>> FeatureData;
+#pragma warning restore CS0649
}
}