969 {
971 {
973 }
975 if (paramClass == EffectParameterClass.Vector &&
_rows == 1)
976 {
978 {
979 default:
981 case 4:
982 {
988 ID3DXBaseEffect* ptr =
pEffect;
989 int num2 = ((delegate* unmanaged[Stdcall, Stdcall]<
IntPtr, sbyte*, D3DXVECTOR4*,
int>)(
int)(*(uint*)(*(
int*)ptr + 136)))((nint)ptr,
_handle, &d3DXVECTOR2);
990 if (num2 < 0)
991 {
992 throw GraphicsHelpers.GetExceptionFromResult((uint)num2);
993 }
994 break;
995 }
996 case 3:
997 {
1002 ID3DXBaseEffect* ptr =
pEffect;
1003 int num3 = ((delegate* unmanaged[Stdcall, Stdcall]<
IntPtr, sbyte*,
float*, uint,
int>)(
int)(*(uint*)(*(
int*)ptr + 128)))((nint)ptr,
_handle, (
float*)(&d3DXVECTOR3), 3u);
1004 if (num3 < 0)
1005 {
1006 throw GraphicsHelpers.GetExceptionFromResult((uint)num3);
1007 }
1008 break;
1009 }
1010 case 2:
1011 {
1015 ID3DXBaseEffect* ptr =
pEffect;
1016 int num = ((delegate* unmanaged[Stdcall, Stdcall]<
IntPtr, sbyte*,
float*, uint,
int>)(
int)(*(uint*)(*(
int*)ptr + 128)))((nint)ptr,
_handle, (
float*)(&d3DXVECTOR), 2u);
1017 if (num < 0)
1018 {
1019 throw GraphicsHelpers.GetExceptionFromResult((uint)num);
1020 }
1021 break;
1022 }
1023 }
1024 return;
1025 }
1026 switch (paramClass)
1027 {
1028 case EffectParameterClass.Matrix:
1029 {
1031 System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 48)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 52)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 56)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 60)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 32)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 36)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 40)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 44)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 16)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 20)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 24)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 28)) = (*(
float*)(&d3DXMATRIX) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 4)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 8)) = (
System.
Runtime.
CompilerServices.
Unsafe.As<D3DXMATRIX,
float>(ref
System.
Runtime.
CompilerServices.
Unsafe.AddByteOffset(ref d3DXMATRIX, 12)) =
value)))))))))))))));
1032 ID3DXBaseEffect* ptr =
pEffect;
1033 int num5 = ((delegate* unmanaged[Stdcall, Stdcall]<
IntPtr, sbyte*, D3DXMATRIX*,
int>)(
int)(*(uint*)(*(
int*)ptr + 152)))((nint)ptr,
_handle, &d3DXMATRIX);
1034 if (num5 < 0)
1035 {
1036 throw GraphicsHelpers.GetExceptionFromResult((uint)num5);
1037 }
1038 break;
1039 }
1040 default:
1042 case EffectParameterClass.Scalar:
1043 {
1044 ID3DXBaseEffect* ptr =
pEffect;
1045 int num4 = ((delegate* unmanaged[Stdcall, Stdcall]<
IntPtr, sbyte*, int,
int>)(
int)(*(uint*)(*(
int*)ptr + 104)))((nint)ptr,
_handle,
value);
1046 if (num4 < 0)
1047 {
1048 throw GraphicsHelpers.GetExceptionFromResult((uint)num4);
1049 }
1050 break;
1051 }
1052 }
1053 }
EffectParameterClass _paramClass
unsafe ID3DXBaseEffect * pEffect
EffectParameterCollection pElementCollection