866{
868 {{{2.001f, 1.502f, 9.003f, 1.004f,
869 5.005f, 3.006f, 3.007f, 6.008f,
870 9.009f, 5.010f, 7.011f, 1.012f,
871 5.013f, 5.014f, 5.015f, 9.016f}}};
872 static const D3DXMATRIX *matrix_pointer[] = {&fmatrix};
873
874 ID3DXConstantTable *
ctable;
875
878
880 ok(
res ==
D3D_OK,
"D3DXGetShaderConstantTable failed: got %#x\n",
res);
881
883 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable imatrix2x3: got %#x\n",
res);
884
886 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable fmatrix3x1: got %#x\n",
res);
887
889 ok(
out[0] == (
int)
S(
U(fmatrix)).
_11 &&
out[1] == (
int)
S(
U(fmatrix))._12 &&
out[2] == (
int)
S(
U(fmatrix))._13
891 &&
out[4] == (
int)
S(
U(fmatrix))._21 &&
out[5] == (
int)
S(
U(fmatrix))._22 &&
out[6] == (
int)
S(
U(fmatrix))._23
893 "The variable imatrix2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f}, "
894 "should be {%d, %d, %d, %d; %d, %d, %d, %d}\n",
896 (
int)
S(
U(fmatrix)).
_11, (
int)
S(
U(fmatrix))._12, (
int)
S(
U(fmatrix))._13, 0,
897 (
int)
S(
U(fmatrix))._21, (
int)
S(
U(fmatrix))._22, (
int)
S(
U(fmatrix))._23, 0);
898
900 ok(
out[0] ==
S(
U(fmatrix)).
_11 &&
out[1] ==
S(
U(fmatrix))._21 &&
out[2] ==
S(
U(fmatrix))._31 &&
out[3] == 0.0f,
901 "The variable fmatrix3x1 was not set correctly, out={%f, %f, %f, %f}, should be {%f, %f, %f, %f}\n",
903 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._21,
S(
U(fmatrix))._31, 0.0f);
904
906
908 ok(
res ==
D3D_OK,
"D3DXGetShaderConstantTable failed: got %#x\n",
res);
909
910
912 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable c2x3: got %#x\n",
res);
913
915 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable r2x3: got %#x\n",
res);
916
918 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable c3x2: got %#x\n",
res);
919
921 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable r3x2: got %#x\n",
res);
922
924 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable c3x3: got %#x\n",
res);
925
928 &&
out[4] ==
S(
U(fmatrix))._12 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] == 0.0f &&
out[7] == 0.0f
929 &&
out[8] ==
S(
U(fmatrix))._13 &&
out[9] ==
S(
U(fmatrix))._23 &&
out[10] == 0.0f &&
out[11] == 0.0f,
930 "The variable c2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}, "
931 "should be {%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}\n",
935 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._21, 0.0f, 0.0f,
936 S(
U(fmatrix))._12,
S(
U(fmatrix))._22, 0.0f, 0.0f,
937 S(
U(fmatrix))._13,
S(
U(fmatrix))._23, 0.0f, 0.0f);
938
940 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrix failed on variable r4x4: got %#x\n",
res);
941
944 &&
out[4] ==
S(
U(fmatrix))._21 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] ==
S(
U(fmatrix))._23 &&
out[7] == 0.0f,
945 "The variable r2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f}, "
946 "should be {%f, %f, %f, %f; %f, %f, %f, %f}\n",
948 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._12,
S(
U(fmatrix))._13, 0.0f,
949 S(
U(fmatrix))._21,
S(
U(fmatrix))._22,
S(
U(fmatrix))._23, 0.0f);
950
953 &&
out[4] ==
S(
U(fmatrix))._12 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] ==
S(
U(fmatrix))._32 &&
out[7] == 0.0f,
954 "The variable c3x2 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f}, "
955 "should be {%f, %f, %f, %f; %f, %f, %f, %f}\n",
957 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._21,
S(
U(fmatrix))._31, 0.0f,
958 S(
U(fmatrix))._12,
S(
U(fmatrix))._22,
S(
U(fmatrix))._32, 0.0f);
959
962 &&
out[4] ==
S(
U(fmatrix))._21 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] == 0.0f &&
out[7] == 0.0f
963 &&
out[8] ==
S(
U(fmatrix))._31 &&
out[9] ==
S(
U(fmatrix))._32 &&
out[10] == 0.0f &&
out[11] == 0.0f,
964 "The variable r3x2 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}, "
965 "should be {%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}\n",
966 out[0],
out[1],
out[2],
out[3],
out[4],
out[5],
out[6],
out[7],
out[8],
out[9],
out[10],
out[11],
967 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._12, 0.0f, 0.0f,
968 S(
U(fmatrix))._21,
S(
U(fmatrix))._22, 0.0f, 0.0f,
969 S(
U(fmatrix))._31,
S(
U(fmatrix))._32, 0.0f, 0.0f);
970
973 &&
out[4] ==
S(
U(fmatrix))._12 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] ==
S(
U(fmatrix))._32 &&
out[7] == 0.0f
974 &&
out[8] ==
S(
U(fmatrix))._13 &&
out[9] ==
S(
U(fmatrix))._23 &&
out[10] ==
S(
U(fmatrix))._33 &&
out[11] == 0.0f,
975 "The variable c3x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}, "
976 "should be {%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}\n",
977 out[0],
out[1],
out[2],
out[3],
out[4],
out[5],
out[6],
out[7],
out[8],
out[9],
out[10],
out[11],
978 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._21,
S(
U(fmatrix))._31, 0.0f,
979 S(
U(fmatrix))._12,
S(
U(fmatrix))._22,
S(
U(fmatrix))._32, 0.0f,
980 S(
U(fmatrix))._13,
S(
U(fmatrix))._23,
S(
U(fmatrix))._33, 0.0f);
981
983 ok(
out[0] ==
S(
U(fmatrix)).
_11 &&
out[1] ==
S(
U(fmatrix))._12 &&
out[2] ==
S(
U(fmatrix))._13 &&
out[3] ==
S(
U(fmatrix))._14
984 &&
out[4] ==
S(
U(fmatrix))._21 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] ==
S(
U(fmatrix))._23 &&
out[7] ==
S(
U(fmatrix))._24
985 &&
out[8] ==
S(
U(fmatrix))._31 &&
out[9] ==
S(
U(fmatrix))._32 &&
out[10] ==
S(
U(fmatrix))._33 &&
out[11] ==
S(
U(fmatrix))._34
986 &&
out[12] ==
S(
U(fmatrix))._41 &&
out[13] ==
S(
U(fmatrix))._42 &&
out[14] ==
S(
U(fmatrix))._43 &&
out[15] ==
S(
U(fmatrix))._44,
987 "The variable r4x4 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}, "
988 "should be {%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}\n",
991 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._12,
S(
U(fmatrix))._13,
S(
U(fmatrix))._14,
992 S(
U(fmatrix))._21,
S(
U(fmatrix))._22,
S(
U(fmatrix))._23,
S(
U(fmatrix))._24,
993 S(
U(fmatrix))._31,
S(
U(fmatrix))._32,
S(
U(fmatrix))._33,
S(
U(fmatrix))._34,
994 S(
U(fmatrix))._41,
S(
U(fmatrix))._42,
S(
U(fmatrix))._43,
S(
U(fmatrix))._44);
995
996
998 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrixTranspose failed on variable c2x3: got %#x\n",
res);
999
1001 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrixTranspose failed on variable r2x3: got %#x\n",
res);
1002
1005 &&
out[4] ==
S(
U(fmatrix))._21 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] == 0.0f &&
out[7] == 0.0f
1006 &&
out[8] ==
S(
U(fmatrix))._31 &&
out[9] ==
S(
U(fmatrix))._32 &&
out[10] == 0.0f &&
out[11] == 0.0f,
1007 "The variable c2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}, "
1008 "should be {%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}\n",
1012 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._12, 0.0f, 0.0f,
1013 S(
U(fmatrix))._21,
S(
U(fmatrix))._22, 0.0f, 0.0f,
1014 S(
U(fmatrix))._31,
S(
U(fmatrix))._32, 0.0f, 0.0f);
1015
1017 ok(
out[0] ==
S(
U(fmatrix)).
_11 &&
out[1] ==
S(
U(fmatrix))._21 &&
out[2] ==
S(
U(fmatrix))._31 &&
out[3] == 0.0f
1018 &&
out[4] ==
S(
U(fmatrix))._12 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] ==
S(
U(fmatrix))._32 &&
out[7] == 0.0f,
1019 "The variable r2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f}, "
1020 "should be {%f, %f, %f, %f; %f, %f, %f, %f}\n",
1022 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._21,
S(
U(fmatrix))._31, 0.0f,
1023 S(
U(fmatrix))._12,
S(
U(fmatrix))._22,
S(
U(fmatrix))._32, 0.0f);
1024
1025
1027 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrixPointerArray failed on variable c2x3: got %#x\n",
res);
1028
1030 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrixPointerArray failed on variable r2x3: got %#x\n",
res);
1031
1034 &&
out[4] ==
S(
U(fmatrix))._12 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] == 0.0f &&
out[7] == 0.0f
1035 &&
out[8] ==
S(
U(fmatrix))._13 &&
out[9] ==
S(
U(fmatrix))._23 &&
out[10] == 0.0f &&
out[11] == 0.0f,
1036 "The variable c2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}, "
1037 "should be {%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}\n",
1041 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._21, 0.0f, 0.0f,
1042 S(
U(fmatrix))._12,
S(
U(fmatrix))._22, 0.0f, 0.0f,
1043 S(
U(fmatrix))._13,
S(
U(fmatrix))._23, 0.0f, 0.0f);
1044
1046 ok(
out[0] ==
S(
U(fmatrix)).
_11 &&
out[1] ==
S(
U(fmatrix))._12 &&
out[2] ==
S(
U(fmatrix))._13 &&
out[3] == 0.0f
1047 &&
out[4] ==
S(
U(fmatrix))._21 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] ==
S(
U(fmatrix))._23 &&
out[7] == 0.0f,
1048 "The variable r2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f}, "
1049 "should be {%f, %f, %f, %f; %f, %f, %f, %f}\n",
1051 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._12,
S(
U(fmatrix))._13, 0.0f,
1052 S(
U(fmatrix))._21,
S(
U(fmatrix))._22,
S(
U(fmatrix))._23, 0.0f);
1053
1054
1056 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrixTransposePointerArray failed on variable c2x3: got %#x\n",
res);
1057
1059 ok(
res ==
D3D_OK,
"ID3DXConstantTable_SetMatrixTransposePointerArray failed on variable r2x3: got %#x\n",
res);
1060
1063 &&
out[4] ==
S(
U(fmatrix))._21 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] == 0.0f &&
out[7] == 0.0f
1064 &&
out[8] ==
S(
U(fmatrix))._31 &&
out[9] ==
S(
U(fmatrix))._32 &&
out[10] == 0.0f &&
out[11] == 0.0f,
1065 "The variable c2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}, "
1066 "should be {%f, %f, %f, %f; %f, %f, %f, %f; %f, %f, %f, %f}\n",
1070 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._12, 0.0f, 0.0f,
1071 S(
U(fmatrix))._21,
S(
U(fmatrix))._22, 0.0f, 0.0f,
1072 S(
U(fmatrix))._31,
S(
U(fmatrix))._32, 0.0f, 0.0f);
1073
1075 ok(
out[0] ==
S(
U(fmatrix)).
_11 &&
out[1] ==
S(
U(fmatrix))._21 &&
out[2] ==
S(
U(fmatrix))._31 &&
out[3] == 0.0f
1076 &&
out[4] ==
S(
U(fmatrix))._12 &&
out[5] ==
S(
U(fmatrix))._22 &&
out[6] ==
S(
U(fmatrix))._32 &&
out[7] == 0.0f,
1077 "The variable r2x3 was not set correctly, out={%f, %f, %f, %f; %f, %f, %f, %f}, "
1078 "should be {%f, %f, %f, %f; %f, %f, %f, %f}\n",
1080 S(
U(fmatrix)).
_11,
S(
U(fmatrix))._21,
S(
U(fmatrix))._31, 0.0f,