Silence several build warnings (#1428)

* Silence several build warnings

* Remove fixed buffers from NVDEC struct

* Remove unused field and usings

* Fix wrong name

* Silence more warning on H264 PictureInfo
This commit is contained in:
gdkchan 2020-08-06 18:40:41 -03:00 committed by GitHub
parent ee22517d92
commit 157ad3f54f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
26 changed files with 177 additions and 12 deletions

View File

@ -12,504 +12,630 @@ namespace Ryujinx.Common.Memory
} }
public struct Array2<T> : IArray<T> where T : unmanaged public struct Array2<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array1<T> _other; Array1<T> _other;
#pragma warning restore CS0169
public int Length => 2; public int Length => 2;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 2); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 2);
} }
public struct Array3<T> : IArray<T> where T : unmanaged public struct Array3<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array2<T> _other; Array2<T> _other;
#pragma warning restore CS0169
public int Length => 3; public int Length => 3;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 3); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 3);
} }
public struct Array4<T> : IArray<T> where T : unmanaged public struct Array4<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array3<T> _other; Array3<T> _other;
#pragma warning restore CS0169
public int Length => 4; public int Length => 4;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 4); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 4);
} }
public struct Array5<T> : IArray<T> where T : unmanaged public struct Array5<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array4<T> _other; Array4<T> _other;
#pragma warning restore CS0169
public int Length => 5; public int Length => 5;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 5); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 5);
} }
public struct Array6<T> : IArray<T> where T : unmanaged public struct Array6<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array5<T> _other; Array5<T> _other;
#pragma warning restore CS0169
public int Length => 6; public int Length => 6;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 6); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 6);
} }
public struct Array7<T> : IArray<T> where T : unmanaged public struct Array7<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array6<T> _other; Array6<T> _other;
#pragma warning restore CS0169
public int Length => 7; public int Length => 7;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 7); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 7);
} }
public struct Array8<T> : IArray<T> where T : unmanaged public struct Array8<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array7<T> _other; Array7<T> _other;
#pragma warning restore CS0169
public int Length => 8; public int Length => 8;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 8); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 8);
} }
public struct Array9<T> : IArray<T> where T : unmanaged public struct Array9<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array8<T> _other; Array8<T> _other;
#pragma warning restore CS0169
public int Length => 9; public int Length => 9;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 9); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 9);
} }
public struct Array10<T> : IArray<T> where T : unmanaged public struct Array10<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array9<T> _other; Array9<T> _other;
#pragma warning restore CS0169
public int Length => 10; public int Length => 10;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 10); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 10);
} }
public struct Array11<T> : IArray<T> where T : unmanaged public struct Array11<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array10<T> _other; Array10<T> _other;
#pragma warning restore CS0169
public int Length => 11; public int Length => 11;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 11); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 11);
} }
public struct Array12<T> : IArray<T> where T : unmanaged public struct Array12<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array11<T> _other; Array11<T> _other;
#pragma warning restore CS0169
public int Length => 12; public int Length => 12;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 12); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 12);
} }
public struct Array13<T> : IArray<T> where T : unmanaged public struct Array13<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array12<T> _other; Array12<T> _other;
#pragma warning restore CS0169
public int Length => 13; public int Length => 13;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 13); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 13);
} }
public struct Array14<T> : IArray<T> where T : unmanaged public struct Array14<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array13<T> _other; Array13<T> _other;
#pragma warning restore CS0169
public int Length => 14; public int Length => 14;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 14); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 14);
} }
public struct Array15<T> : IArray<T> where T : unmanaged public struct Array15<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array14<T> _other; Array14<T> _other;
#pragma warning restore CS0169
public int Length => 15; public int Length => 15;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 15); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 15);
} }
public struct Array16<T> : IArray<T> where T : unmanaged public struct Array16<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array15<T> _other; Array15<T> _other;
#pragma warning restore CS0169
public int Length => 16; public int Length => 16;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 16); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 16);
} }
public struct Array17<T> : IArray<T> where T : unmanaged public struct Array17<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array16<T> _other; Array16<T> _other;
#pragma warning restore CS0169
public int Length => 17; public int Length => 17;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 17); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 17);
} }
public struct Array18<T> : IArray<T> where T : unmanaged public struct Array18<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array17<T> _other; Array17<T> _other;
#pragma warning restore CS0169
public int Length => 18; public int Length => 18;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 18); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 18);
} }
public struct Array19<T> : IArray<T> where T : unmanaged public struct Array19<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array18<T> _other; Array18<T> _other;
#pragma warning restore CS0169
public int Length => 19; public int Length => 19;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 19); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 19);
} }
public struct Array20<T> : IArray<T> where T : unmanaged public struct Array20<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array19<T> _other; Array19<T> _other;
#pragma warning restore CS0169
public int Length => 20; public int Length => 20;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 20); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 20);
} }
public struct Array21<T> : IArray<T> where T : unmanaged public struct Array21<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array20<T> _other; Array20<T> _other;
#pragma warning restore CS0169
public int Length => 21; public int Length => 21;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 21); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 21);
} }
public struct Array22<T> : IArray<T> where T : unmanaged public struct Array22<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array21<T> _other; Array21<T> _other;
#pragma warning restore CS0169
public int Length => 22; public int Length => 22;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 22); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 22);
} }
public struct Array23<T> : IArray<T> where T : unmanaged public struct Array23<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array22<T> _other; Array22<T> _other;
#pragma warning restore CS0169
public int Length => 23; public int Length => 23;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 23); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 23);
} }
public struct Array24<T> : IArray<T> where T : unmanaged public struct Array24<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array23<T> _other; Array23<T> _other;
#pragma warning restore CS0169
public int Length => 24; public int Length => 24;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 24); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 24);
} }
public struct Array25<T> : IArray<T> where T : unmanaged public struct Array25<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array24<T> _other; Array24<T> _other;
#pragma warning restore CS0169
public int Length => 25; public int Length => 25;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 25); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 25);
} }
public struct Array26<T> : IArray<T> where T : unmanaged public struct Array26<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array25<T> _other; Array25<T> _other;
#pragma warning restore CS0169
public int Length => 26; public int Length => 26;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 26); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 26);
} }
public struct Array27<T> : IArray<T> where T : unmanaged public struct Array27<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array26<T> _other; Array26<T> _other;
#pragma warning restore CS0169
public int Length => 27; public int Length => 27;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 27); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 27);
} }
public struct Array28<T> : IArray<T> where T : unmanaged public struct Array28<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array27<T> _other; Array27<T> _other;
#pragma warning restore CS0169
public int Length => 28; public int Length => 28;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 28); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 28);
} }
public struct Array29<T> : IArray<T> where T : unmanaged public struct Array29<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array28<T> _other; Array28<T> _other;
#pragma warning restore CS0169
public int Length => 29; public int Length => 29;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 29); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 29);
} }
public struct Array30<T> : IArray<T> where T : unmanaged public struct Array30<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array29<T> _other; Array29<T> _other;
#pragma warning restore CS0169
public int Length => 30; public int Length => 30;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 30); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 30);
} }
public struct Array31<T> : IArray<T> where T : unmanaged public struct Array31<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array30<T> _other; Array30<T> _other;
#pragma warning restore CS0169
public int Length => 31; public int Length => 31;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 31); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 31);
} }
public struct Array32<T> : IArray<T> where T : unmanaged public struct Array32<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array31<T> _other; Array31<T> _other;
#pragma warning restore CS0169
public int Length => 32; public int Length => 32;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 32); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 32);
} }
public struct Array33<T> : IArray<T> where T : unmanaged public struct Array33<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array32<T> _other; Array32<T> _other;
#pragma warning restore CS0169
public int Length => 33; public int Length => 33;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 33); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 33);
} }
public struct Array34<T> : IArray<T> where T : unmanaged public struct Array34<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array33<T> _other; Array33<T> _other;
#pragma warning restore CS0169
public int Length => 34; public int Length => 34;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 34); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 34);
} }
public struct Array35<T> : IArray<T> where T : unmanaged public struct Array35<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array34<T> _other; Array34<T> _other;
#pragma warning restore CS0169
public int Length => 35; public int Length => 35;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 35); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 35);
} }
public struct Array36<T> : IArray<T> where T : unmanaged public struct Array36<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array35<T> _other; Array35<T> _other;
#pragma warning restore CS0169
public int Length => 36; public int Length => 36;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 36); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 36);
} }
public struct Array37<T> : IArray<T> where T : unmanaged public struct Array37<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array36<T> _other; Array36<T> _other;
#pragma warning restore CS0169
public int Length => 37; public int Length => 37;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 37); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 37);
} }
public struct Array38<T> : IArray<T> where T : unmanaged public struct Array38<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array37<T> _other; Array37<T> _other;
#pragma warning restore CS0169
public int Length => 38; public int Length => 38;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 38); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 38);
} }
public struct Array39<T> : IArray<T> where T : unmanaged public struct Array39<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array38<T> _other; Array38<T> _other;
#pragma warning restore CS0169
public int Length => 39; public int Length => 39;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 39); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 39);
} }
public struct Array40<T> : IArray<T> where T : unmanaged public struct Array40<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array39<T> _other; Array39<T> _other;
#pragma warning restore CS0169
public int Length => 40; public int Length => 40;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 40); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 40);
} }
public struct Array41<T> : IArray<T> where T : unmanaged public struct Array41<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array40<T> _other; Array40<T> _other;
#pragma warning restore CS0169
public int Length => 41; public int Length => 41;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 41); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 41);
} }
public struct Array42<T> : IArray<T> where T : unmanaged public struct Array42<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array41<T> _other; Array41<T> _other;
#pragma warning restore CS0169
public int Length => 42; public int Length => 42;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 42); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 42);
} }
public struct Array43<T> : IArray<T> where T : unmanaged public struct Array43<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array42<T> _other; Array42<T> _other;
#pragma warning restore CS0169
public int Length => 43; public int Length => 43;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 43); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 43);
} }
public struct Array44<T> : IArray<T> where T : unmanaged public struct Array44<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array43<T> _other; Array43<T> _other;
#pragma warning restore CS0169
public int Length => 44; public int Length => 44;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 44); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 44);
} }
public struct Array45<T> : IArray<T> where T : unmanaged public struct Array45<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array44<T> _other; Array44<T> _other;
#pragma warning restore CS0169
public int Length => 45; public int Length => 45;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 45); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 45);
} }
public struct Array46<T> : IArray<T> where T : unmanaged public struct Array46<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array45<T> _other; Array45<T> _other;
#pragma warning restore CS0169
public int Length => 46; public int Length => 46;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 46); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 46);
} }
public struct Array47<T> : IArray<T> where T : unmanaged public struct Array47<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array46<T> _other; Array46<T> _other;
#pragma warning restore CS0169
public int Length => 47; public int Length => 47;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 47); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 47);
} }
public struct Array48<T> : IArray<T> where T : unmanaged public struct Array48<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array47<T> _other; Array47<T> _other;
#pragma warning restore CS0169
public int Length => 48; public int Length => 48;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 48); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 48);
} }
public struct Array49<T> : IArray<T> where T : unmanaged public struct Array49<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array48<T> _other; Array48<T> _other;
#pragma warning restore CS0169
public int Length => 49; public int Length => 49;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 49); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 49);
} }
public struct Array50<T> : IArray<T> where T : unmanaged public struct Array50<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array49<T> _other; Array49<T> _other;
#pragma warning restore CS0169
public int Length => 50; public int Length => 50;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 50); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 50);
} }
public struct Array51<T> : IArray<T> where T : unmanaged public struct Array51<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array50<T> _other; Array50<T> _other;
#pragma warning restore CS0169
public int Length => 51; public int Length => 51;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 51); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 51);
} }
public struct Array52<T> : IArray<T> where T : unmanaged public struct Array52<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array51<T> _other; Array51<T> _other;
#pragma warning restore CS0169
public int Length => 52; public int Length => 52;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 52); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 52);
} }
public struct Array53<T> : IArray<T> where T : unmanaged public struct Array53<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array52<T> _other; Array52<T> _other;
#pragma warning restore CS0169
public int Length => 53; public int Length => 53;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 53); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 53);
} }
public struct Array54<T> : IArray<T> where T : unmanaged public struct Array54<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array53<T> _other; Array53<T> _other;
#pragma warning restore CS0169
public int Length => 54; public int Length => 54;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 54); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 54);
} }
public struct Array55<T> : IArray<T> where T : unmanaged public struct Array55<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array54<T> _other; Array54<T> _other;
#pragma warning restore CS0169
public int Length => 55; public int Length => 55;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 55); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 55);
} }
public struct Array56<T> : IArray<T> where T : unmanaged public struct Array56<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array55<T> _other; Array55<T> _other;
#pragma warning restore CS0169
public int Length => 56; public int Length => 56;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 56); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 56);
} }
public struct Array57<T> : IArray<T> where T : unmanaged public struct Array57<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array56<T> _other; Array56<T> _other;
#pragma warning restore CS0169
public int Length => 57; public int Length => 57;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 57); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 57);
} }
public struct Array58<T> : IArray<T> where T : unmanaged public struct Array58<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array57<T> _other; Array57<T> _other;
#pragma warning restore CS0169
public int Length => 58; public int Length => 58;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 58); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 58);
} }
public struct Array59<T> : IArray<T> where T : unmanaged public struct Array59<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array58<T> _other; Array58<T> _other;
#pragma warning restore CS0169
public int Length => 59; public int Length => 59;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 59); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 59);
} }
public struct Array60<T> : IArray<T> where T : unmanaged public struct Array60<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array59<T> _other; Array59<T> _other;
#pragma warning restore CS0169
public int Length => 60; public int Length => 60;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 60); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 60);
} }
public struct Array61<T> : IArray<T> where T : unmanaged public struct Array61<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array60<T> _other; Array60<T> _other;
#pragma warning restore CS0169
public int Length => 61; public int Length => 61;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 61); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 61);
} }
public struct Array62<T> : IArray<T> where T : unmanaged public struct Array62<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array61<T> _other; Array61<T> _other;
#pragma warning restore CS0169
public int Length => 62; public int Length => 62;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 62); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 62);
} }
public struct Array63<T> : IArray<T> where T : unmanaged public struct Array63<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array62<T> _other; Array62<T> _other;
#pragma warning restore CS0169
public int Length => 63; public int Length => 63;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 63); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 63);
} }
public struct Array64<T> : IArray<T> where T : unmanaged public struct Array64<T> : IArray<T> where T : unmanaged
{ {
#pragma warning disable CS0169
T _e0; T _e0;
Array63<T> _other; Array63<T> _other;
#pragma warning restore CS0169
public int Length => 64; public int Length => 64;
public ref T this[int index] => ref ToSpan()[index]; public ref T this[int index] => ref ToSpan()[index];
public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 64); public Span<T> ToSpan() => MemoryMarshal.CreateSpan(ref _e0, 64);

View File

@ -25,7 +25,9 @@ namespace Ryujinx.Graphics.Gpu.Engine.GPFifo
struct CompressedMethod struct CompressedMethod
{ {
#pragma warning disable CS0649
public uint Method; public uint Method;
#pragma warning restore CS0649
public int MethodAddressOld => (int)((Method >> 2) & 0x7FF); public int MethodAddressOld => (int)((Method >> 2) & 0x7FF);
public int MethodAddress => (int)((Method >> 0) & 0xFFF); public int MethodAddress => (int)((Method >> 0) & 0xFFF);
public int SubdeviceMask => (int)((Method >> 4) & 0xFFF); public int SubdeviceMask => (int)((Method >> 4) & 0xFFF);

View File

@ -36,11 +36,15 @@ namespace Ryujinx.Graphics.Gpu.Engine.GPFifo
struct GPEntry struct GPEntry
{ {
#pragma warning disable CS0649
public uint Entry0; public uint Entry0;
#pragma warning restore CS0649
public Entry0Fetch Entry0Fetch => (Entry0Fetch)((Entry0 >> 0) & 0x1); public Entry0Fetch Entry0Fetch => (Entry0Fetch)((Entry0 >> 0) & 0x1);
public int Entry0Get => (int)((Entry0 >> 2) & 0x3FFFFFFF); public int Entry0Get => (int)((Entry0 >> 2) & 0x3FFFFFFF);
public int Entry0Operand => (int)(Entry0); public int Entry0Operand => (int)(Entry0);
#pragma warning disable CS0649
public uint Entry1; public uint Entry1;
#pragma warning restore CS0649
public int Entry1GetHi => (int)((Entry1 >> 0) & 0xFF); public int Entry1GetHi => (int)((Entry1 >> 0) & 0xFF);
public Entry1Priv Entry1Priv => (Entry1Priv)((Entry1 >> 8) & 0x1); public Entry1Priv Entry1Priv => (Entry1Priv)((Entry1 >> 8) & 0x1);
public Entry1Level Entry1Level => (Entry1Level)((Entry1 >> 9) & 0x1); public Entry1Level Entry1Level => (Entry1Level)((Entry1 >> 9) & 0x1);

View File

@ -106,6 +106,7 @@ namespace Ryujinx.Graphics.Gpu.Engine.GPFifo
struct GPFifoClassState struct GPFifoClassState
{ {
#pragma warning disable CS0649
public uint SetObject; public uint SetObject;
public int SetObjectNvclass => (int)((SetObject >> 0) & 0xFFFF); public int SetObjectNvclass => (int)((SetObject >> 0) & 0xFFFF);
public int SetObjectEngine => (int)((SetObject >> 16) & 0x1F); public int SetObjectEngine => (int)((SetObject >> 16) & 0x1F);
@ -182,5 +183,6 @@ namespace Ryujinx.Graphics.Gpu.Engine.GPFifo
public uint LoadMmeStartAddressRamPointer; public uint LoadMmeStartAddressRamPointer;
public uint LoadMmeStartAddressRam; public uint LoadMmeStartAddressRam;
public uint SetMmeShadowRamControl; public uint SetMmeShadowRamControl;
#pragma warning restore CS0649
} }
} }

View File

@ -4,6 +4,7 @@ namespace Ryujinx.Graphics.Host1x
{ {
struct Host1xClassRegisters struct Host1xClassRegisters
{ {
#pragma warning disable CS0649
public uint IncrSyncpt; public uint IncrSyncpt;
public uint IncrSyncptCntrl; public uint IncrSyncptCntrl;
public uint IncrSyncptError; public uint IncrSyncptError;
@ -37,5 +38,6 @@ namespace Ryujinx.Graphics.Host1x
public uint Xrefctrl; public uint Xrefctrl;
public uint ChannelXrefHi; public uint ChannelXrefHi;
public uint ChannelXrefLo; public uint ChannelXrefLo;
#pragma warning restore CS0649
} }
} }

View File

@ -4,6 +4,7 @@ namespace Ryujinx.Graphics.Host1x
{ {
struct ThiRegisters struct ThiRegisters
{ {
#pragma warning disable CS0649
public uint IncrSyncpt; public uint IncrSyncpt;
public uint Reserved4; public uint Reserved4;
public uint IncrSyncptErr; public uint IncrSyncptErr;
@ -18,5 +19,6 @@ namespace Ryujinx.Graphics.Host1x
public Array12<uint> Reserved48; public Array12<uint> Reserved48;
public uint IntStatus; public uint IntStatus;
public uint IntMask; public uint IntMask;
#pragma warning restore CS0649
} }
} }

View File

@ -1,6 +1,4 @@
using Ryujinx.Common.Memory; using System;
using System;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
namespace Ryujinx.Graphics.Nvdec.Vp9.Common namespace Ryujinx.Graphics.Nvdec.Vp9.Common

View File

@ -1,6 +1,4 @@
using Ryujinx.Graphics.Nvdec.Vp9.Types; namespace Ryujinx.Graphics.Nvdec.Vp9
namespace Ryujinx.Graphics.Nvdec.Vp9
{ {
internal static class Constants internal static class Constants
{ {

View File

@ -1,7 +1,6 @@
using Ryujinx.Common.Memory; using Ryujinx.Common.Memory;
using Ryujinx.Graphics.Nvdec.Vp9.Dsp; using Ryujinx.Graphics.Nvdec.Vp9.Dsp;
using Ryujinx.Graphics.Nvdec.Vp9.Types; using Ryujinx.Graphics.Nvdec.Vp9.Types;
using Ryujinx.Graphics.Video;
namespace Ryujinx.Graphics.Nvdec.Vp9 namespace Ryujinx.Graphics.Nvdec.Vp9
{ {

View File

@ -6,8 +6,10 @@ namespace Ryujinx.Graphics.Nvdec.Vp9.Types
// passed it can be loaded into vector registers. // passed it can be loaded into vector registers.
internal struct LoopFilterThresh internal struct LoopFilterThresh
{ {
#pragma warning disable CS0649
public Array16<byte> Mblim; public Array16<byte> Mblim;
public Array16<byte> Lim; public Array16<byte> Lim;
public Array16<byte> HevThr; public Array16<byte> HevThr;
#pragma warning restore CS0649
} }
} }

View File

@ -89,7 +89,6 @@ namespace Ryujinx.Graphics.Nvdec.Vp9.Types
public ArrayPtr<sbyte> AboveSegContext; public ArrayPtr<sbyte> AboveSegContext;
public ArrayPtr<sbyte> AboveContext; public ArrayPtr<sbyte> AboveContext;
public int AboveContextAllocCols;
public bool FrameIsIntraOnly() public bool FrameIsIntraOnly()
{ {

View File

@ -3,13 +3,15 @@
namespace Ryujinx.Graphics.Nvdec namespace Ryujinx.Graphics.Nvdec
{ {
// Note: Most of those names are not official. // 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 uint SetCodecID;
public fixed uint Reserved204[63]; public Array63<uint> Reserved204;
public uint Execute; public uint Execute;
public fixed uint Reserved304[63]; public Array63<uint> Reserved304;
public uint SetPlatformID; public uint SetPlatformID;
public uint SetPictureInfoOffset; public uint SetPictureInfoOffset;
public uint SetBitstreamOffset; public uint SetBitstreamOffset;
@ -37,5 +39,6 @@ namespace Ryujinx.Graphics.Nvdec
public uint SetVp9LastFrameMvsOffset; public uint SetVp9LastFrameMvsOffset;
public uint SetVp9CurrFrameMvsOffset; public uint SetVp9CurrFrameMvsOffset;
public uint Unknown5DC; public uint Unknown5DC;
#pragma warning restore CS0649
} }
} }

View File

@ -5,6 +5,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.H264
{ {
struct PictureInfo struct PictureInfo
{ {
#pragma warning disable CS0169, CS0649
Array18<uint> Unknown0; Array18<uint> Unknown0;
public uint BitstreamSize; public uint BitstreamSize;
public uint NumSlices; public uint NumSlices;
@ -47,6 +48,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.H264
public Array16<byte> MvcextViewRefMasksL1; public Array16<byte> MvcextViewRefMasksL1;
public uint Flags2; public uint Flags2;
public Array10<uint> Unknown2D4; public Array10<uint> Unknown2D4;
#pragma warning restore CS0169, CS0649
public bool MbAdaptiveFrameFieldFlag => (Flags & (1 << 0)) != 0; public bool MbAdaptiveFrameFieldFlag => (Flags & (1 << 0)) != 0;
public bool Direct8x8InferenceFlag => (Flags & (1 << 1)) != 0; public bool Direct8x8InferenceFlag => (Flags & (1 << 1)) != 0;

View File

@ -2,9 +2,11 @@
{ {
struct ReferenceFrame struct ReferenceFrame
{ {
#pragma warning disable CS0649
public uint Unknown0; public uint Unknown0;
public uint Unknown4; public uint Unknown4;
public uint Unknown8; public uint Unknown8;
public uint UnknownC; public uint UnknownC;
#pragma warning restore CS0649
} }
} }

View File

@ -5,6 +5,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{ {
struct EntropyProbs struct EntropyProbs
{ {
#pragma warning disable CS0649
public Array10<Array10<Array8<byte>>> KfYModeProbE0ToE7; public Array10<Array10<Array8<byte>>> KfYModeProbE0ToE7;
public Array10<Array10<byte>> KfYModeProbE8; public Array10<Array10<byte>> KfYModeProbE8;
public Array3<byte> Padding384; public Array3<byte> Padding384;
@ -41,6 +42,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
public Array5<byte> CompRefProb; public Array5<byte> CompRefProb;
public Array17<byte> Padding58F; public Array17<byte> Padding58F;
public Array4<Array2<Array2<Array6<Array6<Array4<byte>>>>>> CoefProbs; public Array4<Array2<Array2<Array6<Array6<Array4<byte>>>>>> CoefProbs;
#pragma warning restore CS0649
public void Convert(ref Vp9EntropyProbs fc) public void Convert(ref Vp9EntropyProbs fc)
{ {

View File

@ -2,9 +2,11 @@
{ {
struct FrameSize struct FrameSize
{ {
#pragma warning disable CS0649
public ushort Width; public ushort Width;
public ushort Height; public ushort Height;
public ushort LumaPitch; public ushort LumaPitch;
public ushort ChromaPitch; public ushort ChromaPitch;
#pragma warning restore CS0649
} }
} }

View File

@ -2,6 +2,7 @@
{ {
struct FrameStats struct FrameStats
{ {
#pragma warning disable CS0649
public uint Unknown0; public uint Unknown0;
public uint Unknown4; public uint Unknown4;
public uint Pass2CycleCount; public uint Pass2CycleCount;
@ -16,5 +17,6 @@
public uint ErrorCtbPos; public uint ErrorCtbPos;
public uint ErrorSlicePos; public uint ErrorSlicePos;
public uint Unknown34; public uint Unknown34;
#pragma warning restore CS0649
} }
} }

View File

@ -4,8 +4,10 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{ {
struct LoopFilter struct LoopFilter
{ {
#pragma warning disable CS0649
public byte ModeRefDeltaEnabled; public byte ModeRefDeltaEnabled;
public Array4<sbyte> RefDeltas; public Array4<sbyte> RefDeltas;
public Array2<sbyte> ModeDeltas; public Array2<sbyte> ModeDeltas;
#pragma warning restore CS0649
} }
} }

View File

@ -5,6 +5,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{ {
struct PictureInfo struct PictureInfo
{ {
#pragma warning disable CS0649
public Array12<uint> Unknown0; public Array12<uint> Unknown0;
public uint BitstreamSize; public uint BitstreamSize;
public uint IsEncrypted; public uint IsEncrypted;
@ -41,6 +42,7 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
public uint UnknownF4; public uint UnknownF4;
public uint UnknownF8; public uint UnknownF8;
public uint UnknownFC; public uint UnknownFC;
#pragma warning restore CS0649
public uint BitDepth => (SurfaceParams >> 1) & 0xf; public uint BitDepth => (SurfaceParams >> 1) & 0xf;

View File

@ -4,11 +4,13 @@ namespace Ryujinx.Graphics.Nvdec.Types.Vp9
{ {
struct Segmentation struct Segmentation
{ {
#pragma warning disable CS0649
public byte Enabled; public byte Enabled;
public byte UpdateMap; public byte UpdateMap;
public byte TemporalUpdate; public byte TemporalUpdate;
public byte AbsDelta; public byte AbsDelta;
public Array8<uint> FeatureMask; public Array8<uint> FeatureMask;
public Array8<Array4<short>> FeatureData; public Array8<Array4<short>> FeatureData;
#pragma warning restore CS0649
} }
} }

View File

@ -2,8 +2,10 @@
{ {
struct ClearRectStruct struct ClearRectStruct
{ {
#pragma warning disable CS0649
private long _word0; private long _word0;
private long _word1; private long _word1;
#pragma warning restore CS0649
public int ClearRect0Left => _word0.Extract(0, 14); public int ClearRect0Left => _word0.Extract(0, 14);
public int ClearRect0Right => _word0.Extract(16, 14); public int ClearRect0Right => _word0.Extract(16, 14);

View File

@ -4,11 +4,13 @@ namespace Ryujinx.Graphics.Vic.Types
{ {
struct ConfigStruct struct ConfigStruct
{ {
#pragma warning disable CS0649
public PipeConfig PipeConfig; public PipeConfig PipeConfig;
public OutputConfig OutputConfig; public OutputConfig OutputConfig;
public OutputSurfaceConfig OutputSurfaceConfig; public OutputSurfaceConfig OutputSurfaceConfig;
public MatrixStruct OutColorMatrix; public MatrixStruct OutColorMatrix;
public Array4<ClearRectStruct> ClearRectStruct; public Array4<ClearRectStruct> ClearRectStruct;
public Array8<SlotStruct> SlotStruct; public Array8<SlotStruct> SlotStruct;
#pragma warning restore CS0649
} }
} }

View File

@ -2,8 +2,10 @@
{ {
struct OutputConfig struct OutputConfig
{ {
#pragma warning disable CS0649
private long _word0; private long _word0;
private long _word1; private long _word1;
#pragma warning restore CS0649
public int AlphaFillMode => _word0.Extract(0, 3); public int AlphaFillMode => _word0.Extract(0, 3);
public int AlphaFillSlot => _word0.Extract(3, 3); public int AlphaFillSlot => _word0.Extract(3, 3);

View File

@ -2,8 +2,10 @@
{ {
struct OutputSurfaceConfig struct OutputSurfaceConfig
{ {
#pragma warning disable CS0649
private long _word0; private long _word0;
private long _word1; private long _word1;
#pragma warning restore CS0649
public PixelFormat OutPixelFormat => (PixelFormat)_word0.Extract(0, 7); public PixelFormat OutPixelFormat => (PixelFormat)_word0.Extract(0, 7);
public int OutChromaLocHoriz => _word0.Extract(7, 2); public int OutChromaLocHoriz => _word0.Extract(7, 2);

View File

@ -2,8 +2,10 @@
{ {
struct PipeConfig struct PipeConfig
{ {
#pragma warning disable CS0169, CS0649
private long _word0; private long _word0;
private long _word1; private long _word1;
#pragma warning restore CS0169, CS0649
public int DownsampleHoriz => _word0.Extract(0, 11); public int DownsampleHoriz => _word0.Extract(0, 11);
public int DownsampleVert => _word0.Extract(16, 11); public int DownsampleVert => _word0.Extract(16, 11);

View File

@ -11,6 +11,7 @@ namespace Ryujinx.Graphics.Vic
struct VicRegisters struct VicRegisters
{ {
#pragma warning disable CS0649
public Array64<uint> Reserved0; public Array64<uint> Reserved0;
public uint Nop; public uint Nop;
public Array15<uint> Reserved104; public Array15<uint> Reserved104;
@ -43,5 +44,6 @@ namespace Ryujinx.Graphics.Vic
public Array8<uint> SetSlotContextId; public Array8<uint> SetSlotContextId;
public Array8<uint> SetCompTagBufferOffset; public Array8<uint> SetCompTagBufferOffset;
public Array8<uint> SetHistoryBufferOffset; public Array8<uint> SetHistoryBufferOffset;
#pragma warning restore CS0649
} }
} }