mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
Compare commits
1986 Commits
vkd3d-1.13
...
vkd3d-1.17
Author | SHA1 | Date | |
---|---|---|---|
|
f732fb7889 | ||
|
44fffee5e1 | ||
|
bb2a6a0322 | ||
|
975ba8f9da | ||
|
7007a1e264 | ||
|
cab0bd07e5 | ||
|
9336b4647c | ||
|
8334386d99 | ||
|
880cb1083f | ||
|
a91b880afa | ||
|
0ed34c22c9 | ||
|
14643b02f6 | ||
|
bd52ed8918 | ||
|
f7890fc54c | ||
|
f95fc28851 | ||
|
85603dc9c6 | ||
|
e7be5aa9fd | ||
|
7c37fc6a8b | ||
|
e4bb77ecef | ||
|
f9bb84e5ef | ||
|
731b94f6f9 | ||
|
9c605c942c | ||
|
a4f69d4ae6 | ||
|
2201c32e6d | ||
|
f6d0c689ee | ||
|
aab02b1bca | ||
|
6c840b80d6 | ||
|
e428528a7c | ||
|
f818d052cd | ||
|
b3badec039 | ||
|
304caa885f | ||
|
37ca1b55c9 | ||
|
97e3877aa4 | ||
|
6dc9ff1bd8 | ||
|
ce20f9d4b2 | ||
|
47a183c75b | ||
|
4bb880f9ed | ||
|
8d0d8d106b | ||
|
c8d2d40b91 | ||
|
fa560b589e | ||
|
3802344e97 | ||
|
e615e435d9 | ||
|
e718546ee5 | ||
|
5dbf859029 | ||
|
161d463f3c | ||
|
721859005f | ||
|
243207701b | ||
|
5dca0da2da | ||
|
be5a9c2ca8 | ||
|
81488ce330 | ||
|
8717fe9c47 | ||
|
3817df1164 | ||
|
d898923b1c | ||
|
1d71cf9af1 | ||
|
bec000b88e | ||
|
691dd49e49 | ||
|
1293db7536 | ||
|
bd3d0f3495 | ||
|
b9fe19701c | ||
|
cd8cea6913 | ||
|
55fe8df979 | ||
|
74d8c23f71 | ||
|
d0ce3e61bf | ||
|
75cb4336ec | ||
|
67fd9bb76b | ||
|
f6a9def564 | ||
|
bb2979aa4c | ||
|
49b857c5b7 | ||
|
dbaecb3f36 | ||
|
6805612918 | ||
|
247fbd869a | ||
|
812f6faa11 | ||
|
50afaf4ac6 | ||
|
aba355896f | ||
|
22f84317c0 | ||
|
3797c922a5 | ||
|
52b9ef0426 | ||
|
53754f0583 | ||
|
bdccdd9996 | ||
|
f7866df201 | ||
|
3cf35ce22e | ||
|
7df92b6e50 | ||
|
9476a235b2 | ||
|
16b06c295b | ||
|
6ed0bd0bab | ||
|
19bc3ec104 | ||
|
3a0a96b851 | ||
|
a4f5225229 | ||
|
2c49f04411 | ||
|
dcd1747f12 | ||
|
0652cb4adb | ||
|
9b0087a111 | ||
|
b3cac7b86d | ||
|
eaebef4265 | ||
|
4300e6c8b5 | ||
|
b3e367b099 | ||
|
a4c25b81c5 | ||
|
f02405350e | ||
|
b88be5b92b | ||
|
b8c73e4a2c | ||
|
ed2a06af35 | ||
|
7295a8d0b5 | ||
|
795211141f | ||
|
aebe64ecac | ||
|
f74b56622a | ||
|
ca24aada9a | ||
|
b055a16e03 | ||
|
ed695cc551 | ||
|
ed27427508 | ||
|
2f4be1dbb6 | ||
|
17ffd21113 | ||
|
bb51b976df | ||
|
83e54bdc0c | ||
|
969b6f5946 | ||
|
a7266284ee | ||
|
db80f09c7a | ||
|
f4d95af91d | ||
|
66895e2605 | ||
|
844f33025e | ||
|
f420e25fd5 | ||
|
68cd72c7fc | ||
|
b3db78e3c1 | ||
|
f3f8056800 | ||
|
59738c7a4a | ||
|
6266f89827 | ||
|
1c7c66912b | ||
|
4789295e91 | ||
|
3234c428b3 | ||
|
14ee6b86e0 | ||
|
4a1ca99cba | ||
|
42f53c82f3 | ||
|
ddb65aac35 | ||
|
01068dada2 | ||
|
7d9a86790e | ||
|
7e76e62db7 | ||
|
0789578175 | ||
|
b4bf2af315 | ||
|
1487764e23 | ||
|
742cce9a08 | ||
|
163b87444f | ||
|
40bbd61abd | ||
|
a04e4e4010 | ||
|
8f05fbc75d | ||
|
13c9826c30 | ||
|
7b36453b9d | ||
|
b3c1fb6740 | ||
|
dfc18781cc | ||
|
b02c3759be | ||
|
226afa47c4 | ||
|
f0906e9c5c | ||
|
decc155cca | ||
|
079e989b8e | ||
|
f5cd0b4a15 | ||
|
59253a5e7f | ||
|
834f762cb5 | ||
|
18ef9a4f9f | ||
|
9f453fbb66 | ||
|
3d23ef6bf8 | ||
|
ee0447b973 | ||
|
61c46f95da | ||
|
87545dc4fd | ||
|
366c899a00 | ||
|
5dd226ffeb | ||
|
2237e251fa | ||
|
34cb8c63f4 | ||
|
a8e8a9ee64 | ||
|
db149cd8cf | ||
|
c5c1c03430 | ||
|
d1dcbc26e5 | ||
|
0126beb3b2 | ||
|
53dd048ad5 | ||
|
8d4222764c | ||
|
5407c8b975 | ||
|
55b8002bf6 | ||
|
c1f7720075 | ||
|
0f18d25987 | ||
|
faeff50548 | ||
|
a9a5c77222 | ||
|
7e9834ee36 | ||
|
f08fed5ffb | ||
|
28f74a73aa | ||
|
4f5d34265c | ||
|
9836c88ac6 | ||
|
7e66d0db6f | ||
|
e9d3b9dfd3 | ||
|
a7807dea08 | ||
|
ccc82a184b | ||
|
2c1d210d21 | ||
|
791a93d0b1 | ||
|
68ad2becdb | ||
|
fb1fc9eb38 | ||
|
df18a05303 | ||
|
b287e7959c | ||
|
195e62430e | ||
|
a12d64fba1 | ||
|
9867d48c3a | ||
|
2d848b5bc0 | ||
|
ba545669cd | ||
|
126ff8e4f5 | ||
|
94d999bd8a | ||
|
636e9a91bb | ||
|
7d92142fe0 | ||
|
d288d3c088 | ||
|
2a62b7035c | ||
|
5fc8baabfb | ||
|
56247130c1 | ||
|
32bf71ba96 | ||
|
9c040caa40 | ||
|
5c0e6747b8 | ||
|
39db6731c0 | ||
|
3163e589bc | ||
|
46c75137c7 | ||
|
1a5a2969be | ||
|
fb91bd7b8b | ||
|
fc77bddb9c | ||
|
15561c1e56 | ||
|
44ca7b7b1b | ||
|
ad1aa739c2 | ||
|
b6725a3a00 | ||
|
00f53b72a1 | ||
|
673c26a040 | ||
|
1a20395e6f | ||
|
955fff7570 | ||
|
90b6412daa | ||
|
ed464a4f4c | ||
|
715d23ebbb | ||
|
9f455667eb | ||
|
c29e8188ff | ||
|
4d1fabd350 | ||
|
e954f75862 | ||
|
5dd452a5c7 | ||
|
cc42581a34 | ||
|
395d456386 | ||
|
98b0ca544a | ||
|
0c3250122c | ||
|
f2238deea9 | ||
|
e312207124 | ||
|
b58ff893a5 | ||
|
587c2dc76e | ||
|
04d3996b07 | ||
|
22ebccfeb7 | ||
|
043f6f21b0 | ||
|
96cd4cc954 | ||
|
3376015d88 | ||
|
3c469edc8e | ||
|
e267ea9551 | ||
|
8feeb07900 | ||
|
32cab7c81e | ||
|
afec7cc96b | ||
|
8cf7a12502 | ||
|
a6e6e36994 | ||
|
17b0e0d1d9 | ||
|
596f02210d | ||
|
82ef9bf2e5 | ||
|
78e0f8412d | ||
|
ada09d003d | ||
|
823a8724de | ||
|
f4a4e2afec | ||
|
752a48f4ac | ||
|
543ee120fc | ||
|
b9ce945e61 | ||
|
06a0453762 | ||
|
cdfaeb209a | ||
|
d219cccc99 | ||
|
cd43ab1ca2 | ||
|
bcb2acbdab | ||
|
a1eb53df3c | ||
|
ecb19b33ba | ||
|
41cacba5ce | ||
|
3a4f95aca6 | ||
|
5452e79a19 | ||
|
c2a01fff1e | ||
|
6f8ce6df72 | ||
|
449804623a | ||
|
841cf65a41 | ||
|
3cc404759d | ||
|
99db7270f0 | ||
|
cbd508fce6 | ||
|
7acebfc978 | ||
|
6bf25800c2 | ||
|
95e095992d | ||
|
96bb2953cc | ||
|
ad320776a1 | ||
|
19c2734d31 | ||
|
bcaa1d50b0 | ||
|
1862c28b90 | ||
|
318d7466a8 | ||
|
65c23999e8 | ||
|
0252e2e660 | ||
|
85dcbf7a51 | ||
|
31581b0002 | ||
|
4a39db797b | ||
|
f3dec58423 | ||
|
4ede2f1365 | ||
|
84a0a8ae86 | ||
|
3bf232e841 | ||
|
d8edf20c2b | ||
|
dda2ec1814 | ||
|
b8cbe03308 | ||
|
ba5d5a8091 | ||
|
92c711a7d5 | ||
|
3537feb45c | ||
|
43a29044d6 | ||
|
9f9cf59b6e | ||
|
99d61aeb89 | ||
|
f6af47f9b6 | ||
|
bc4dda75dd | ||
|
6ef23544f4 | ||
|
2d783da3a7 | ||
|
eec2b13dc6 | ||
|
a115cd9ec0 | ||
|
402c2bf10a | ||
|
32746c664d | ||
|
2f4038bae7 | ||
|
bd4681622d | ||
|
dc33622919 | ||
|
666eb98ab6 | ||
|
227df56c6c | ||
|
2b922e6b8e | ||
|
ead690a17a | ||
|
be2c8041d0 | ||
|
e5bf48a2ba | ||
|
83979ec07a | ||
|
2e0cbff3a0 | ||
|
e0359c5299 | ||
|
cf726cf521 | ||
|
46265061c3 | ||
|
db89687807 | ||
|
f30510a9b3 | ||
|
0c8bc0f42c | ||
|
af8b3f94e7 | ||
|
d5237ec1cc | ||
|
288020bce8 | ||
|
7b9d04fff8 | ||
|
5e4c61eba6 | ||
|
34dbd60e01 | ||
|
9d490b83d4 | ||
|
c3110d2f94 | ||
|
a410c448ce | ||
|
f135f7fe07 | ||
|
93e1a8c784 | ||
|
37c2f709d1 | ||
|
6f092fb84a | ||
|
322f2e5496 | ||
|
b7fbd3c0f0 | ||
|
3689d3076c | ||
|
e1ca552173 | ||
|
b2e1c3b90a | ||
|
eb3383b04e | ||
|
46fac7f264 | ||
|
4da83fe83b | ||
|
813021e60b | ||
|
16e142465c | ||
|
0edd654c9e | ||
|
475e16b87f | ||
|
65e896fd60 | ||
|
5911e410a8 | ||
|
d572f4ac1f | ||
|
cef3e07e3d | ||
|
8b78747629 | ||
|
b05153e6f9 | ||
|
39603f4bc2 | ||
|
5e1c8056ae | ||
|
7c0da1747a | ||
|
d08673bad1 | ||
|
7281f4ed39 | ||
|
586b2b5a79 | ||
|
e28af05957 | ||
|
3f6013ea27 | ||
|
ddb433d552 | ||
|
590ea03255 | ||
|
bf92190924 | ||
|
c3c36d8517 | ||
|
eb988e95e1 | ||
|
f46c8ea03c | ||
|
81279b763b | ||
|
0778fb93df | ||
|
616fea0c2b | ||
|
a8ca1f95c5 | ||
|
229f792db6 | ||
|
8eeefc2906 | ||
|
d92ef93611 | ||
|
6aeb168d63 | ||
|
dfb3494600 | ||
|
a5ff884605 | ||
|
9c2643b9f7 | ||
|
2d90f51d57 | ||
|
5899d8f54b | ||
|
36a999e09f | ||
|
6a159a5565 | ||
|
1913f5e6f9 | ||
|
90032acbcf | ||
|
d403705de9 | ||
|
b098af3ef8 | ||
|
f525399545 | ||
|
d6a4084321 | ||
|
47b9316a86 | ||
|
94cbb333f8 | ||
|
0b5a96d963 | ||
|
73940cde73 | ||
|
5e86d5c21b | ||
|
1d780e1a6b | ||
|
14477b1066 | ||
|
cea7b4e920 | ||
|
9c987e5a0b | ||
|
95cf0a8b2c | ||
|
73820756d1 | ||
|
b09e9159ba | ||
|
261cdb0f29 | ||
|
7dfa9e8f81 | ||
|
f538085e41 | ||
|
79be1d3051 | ||
|
a570932b82 | ||
|
a2eb3324d4 | ||
|
83ed825e5a | ||
|
c8e6d35e17 | ||
|
66c0530a05 | ||
|
6a06929f6b | ||
|
1214359022 | ||
|
1b389f29c5 | ||
|
20d8ba7f8d | ||
|
873043226c | ||
|
59fb3a7893 | ||
|
31e4cbba2e | ||
|
2e3f99e61e | ||
|
f4f2617584 | ||
|
361ecd6cf5 | ||
|
0ac20b3029 | ||
|
fcb5650dbf | ||
|
b22ebe73bc | ||
|
8aacee8eae | ||
|
8da518f2cd | ||
|
45ef9fdbe8 | ||
|
d881356ab2 | ||
|
3673b65485 | ||
|
cc33439f19 | ||
|
fc6249a228 | ||
|
ea5cf883fa | ||
|
66d0c2a426 | ||
|
d65be3d0c5 | ||
|
7e134f85a4 | ||
|
0e406cf0a8 | ||
|
00b3fb96d9 | ||
|
a9a3100cca | ||
|
af5e5fe31b | ||
|
5e6def0843 | ||
|
d768ea6709 | ||
|
0eb5fee633 | ||
|
5ea697b8eb | ||
|
34d8be3b2e | ||
|
a8defb4e21 | ||
|
1cdfed919a | ||
|
cf312e14a9 | ||
|
e948098ae3 | ||
|
f14a0dfe07 | ||
|
0b829db149 | ||
|
fadcbf3eeb | ||
|
6a93c503cd | ||
|
02d7d6038d | ||
|
671fbfea7d | ||
|
87fe08fe0e | ||
|
1d77d51ca4 | ||
|
bda2be3423 | ||
|
0236308866 | ||
|
f1b36edc07 | ||
|
a4c727ac40 | ||
|
c82d1aac4d | ||
|
7f04060f33 | ||
|
b9ce828451 | ||
|
a91fb0523a | ||
|
a90b74baaa | ||
|
0e006715d8 | ||
|
9552dab5aa | ||
|
85d2703c03 | ||
|
2b257caea9 | ||
|
b6ef417e71 | ||
|
c895f63a1c | ||
|
108f4fe47e | ||
|
4e2fefdfdf | ||
|
4ef4baa6bf | ||
|
68386f5180 | ||
|
6b2800fa99 | ||
|
e33189546a | ||
|
9f0185f304 | ||
|
bc0dd891c3 | ||
|
ed60dd5926 | ||
|
10be58a74f | ||
|
9f5db1e3e4 | ||
|
df8b611334 | ||
|
5998723e7c | ||
|
215dfe0450 | ||
|
0b9268a91b | ||
|
ea4f1dece5 | ||
|
c8b07e9fa6 | ||
|
898bc5c4c8 | ||
|
de8dbdc2cb | ||
|
12da0f9d24 | ||
|
308d3aa676 | ||
|
7f7077a156 | ||
|
8106c5a199 | ||
|
752b13b111 | ||
|
847c008b49 | ||
|
b25362e036 | ||
|
618d8e6a4a | ||
|
7929ba9747 | ||
|
9983d9c4de | ||
|
d5dcf31123 | ||
|
d368d18527 | ||
|
7da7ccaf45 | ||
|
a743d9ae60 | ||
|
0a1e7b5f64 | ||
|
79ec2fe9f2 | ||
|
93fb51c899 | ||
|
d36e37555a | ||
|
c050c8be75 | ||
|
87ec2d9897 | ||
|
bb50117747 | ||
|
365f6d3be9 | ||
|
85dcd03642 | ||
|
9ab1cadaa5 | ||
|
6fe0d71ae1 | ||
|
70c51984c9 | ||
|
7261b40df7 | ||
|
e6267dd6b4 | ||
|
bd1b737e4e | ||
|
d214f9ebca | ||
|
6a699d2872 | ||
|
1496ddc52f | ||
|
deb3b74c66 | ||
|
adca5a66e7 | ||
|
f7c2fbfe85 | ||
|
ffafa7fdaa | ||
|
ee85e6b534 | ||
|
5581c42a79 | ||
|
0a28abd8f6 | ||
|
e17a98f870 | ||
|
c4c7f10d99 | ||
|
2e40154801 | ||
|
a06ecb6867 | ||
|
11d4fcff46 | ||
|
a4e43402e5 | ||
|
e7b2ca28ab | ||
|
f5e0c47811 | ||
|
3fb662c9e7 | ||
|
cb1ee9cdd5 | ||
|
a477502a05 | ||
|
fdc173506e | ||
|
bd6dbd096f | ||
|
6a85df013b | ||
|
b0940729ff | ||
|
6b9df6b7a5 | ||
|
fe747b065f | ||
|
ef3e10a14e | ||
|
9156de0593 | ||
|
4eab50755e | ||
|
a58b1f7011 | ||
|
18ec4caded | ||
|
a93d258a86 | ||
|
379b297d2c | ||
|
07d8fe0462 | ||
|
129b3a8c4b | ||
|
1aa33ebc80 | ||
|
d5410e3115 | ||
|
f5a26fd2b8 | ||
|
1efbcebed4 | ||
|
c1adf54a44 | ||
|
8ca50a2f7e | ||
|
5ad2e7ee6d | ||
|
bfa655a01f | ||
|
e16176672a | ||
|
cfb59828f3 | ||
|
a06b9f6646 | ||
|
cdc74a9377 | ||
|
8f6616993b | ||
|
65e1ef047f | ||
|
d40422592a | ||
|
d4032f7d09 | ||
|
3c8fd8a2f2 | ||
|
a2d5358ac6 | ||
|
dd34899e97 | ||
|
820430001f | ||
|
4a5411aa6e | ||
|
4cdea712d0 | ||
|
42df4517c6 | ||
|
fd918062d6 | ||
|
cb5a548740 | ||
|
8635a7ff6e | ||
|
1d88638bd3 | ||
|
960244bf1e | ||
|
5d5d892830 | ||
|
d660a0d2ae | ||
|
fd1f74f44d | ||
|
44e0b17606 | ||
|
7381598310 | ||
|
e9e02884e5 | ||
|
7c344bdfd0 | ||
|
326f3624d9 | ||
|
527c1518f2 | ||
|
b389fa89e4 | ||
|
7b07d77396 | ||
|
cb4b5641ea | ||
|
3fabac3f70 | ||
|
9222f5e5b1 | ||
|
52b947a005 | ||
|
3ea84156c7 | ||
|
75ce9cef92 | ||
|
e54070c2d7 | ||
|
615dce0eaa | ||
|
4289ec60a1 | ||
|
9fdaee1529 | ||
|
31f8ed1d1e | ||
|
fae03b2ba5 | ||
|
bd73de7198 | ||
|
b8c6092a16 | ||
|
9e7ad75944 | ||
|
648a60d4c8 | ||
|
8b58ce9e85 | ||
|
5b06fe83df | ||
|
c8c1e270e0 | ||
|
729a3ac089 | ||
|
34b4b34f2c | ||
|
e6db0ab614 | ||
|
b89f0bc730 | ||
|
a975c56695 | ||
|
758a4bef09 | ||
|
541060215e | ||
|
315247bf02 | ||
|
50ca4a2101 | ||
|
bb78c06193 | ||
|
a1f48d2575 | ||
|
8882d324a6 | ||
|
c69d2ab0ae | ||
|
dfe3ad5551 | ||
|
883ffc5fd6 | ||
|
ceb2787d46 | ||
|
aa8161a7ad | ||
|
88bbc106c7 | ||
|
4c8c31fa2e | ||
|
c75b318805 | ||
|
5d29554fed | ||
|
2a89b23ede | ||
|
f2f44b054d | ||
|
d620ad4942 | ||
|
8059608af9 | ||
|
9525eb2f0c | ||
|
9b65cc8895 | ||
|
6ca9395368 | ||
|
bc637f2633 | ||
|
c1d04b84c7 | ||
|
f890db872a | ||
|
f932af7f18 | ||
|
4324817c68 | ||
|
c764f71cf5 | ||
|
ee7895465c | ||
|
834017c198 | ||
|
a189a4cfb7 | ||
|
dbd1938ce4 | ||
|
3186d66596 | ||
|
9db9f3bdaf | ||
|
26656808e6 | ||
|
df1aecb7bd | ||
|
0ac661f571 | ||
|
64bd2af015 | ||
|
9378d51b18 | ||
|
77941b131e | ||
|
ff5f9cbcb6 | ||
|
f3ba7a84f4 | ||
|
128688a573 | ||
|
58706474ec | ||
|
922cb47a4b | ||
|
be94a37e23 | ||
|
01f47e00f2 | ||
|
0da80c1f25 | ||
|
869e6ef583 | ||
|
f02ea94c42 | ||
|
0417f4f162 | ||
|
bac6949365 | ||
|
fd16bba29d | ||
|
f4e10ea9d5 | ||
|
24e61cf74e | ||
|
4412a83655 | ||
|
85e848289b | ||
|
4e783e2d66 | ||
|
7b21059ee5 | ||
|
2dce34d7e0 | ||
|
0c18736370 | ||
|
d91d552a5e | ||
|
1a1f1f1369 | ||
|
7331c70e9e | ||
|
ba7a9a0b29 | ||
|
015a751ea0 | ||
|
3493688a4d | ||
|
ed677a8f32 | ||
|
e5bb3a5233 | ||
|
eb9e254b8c | ||
|
cbce3a8631 | ||
|
bb8f1304ba | ||
|
fdd21470b9 | ||
|
bb8b4f3827 | ||
|
3c950e5977 | ||
|
88a85024e2 | ||
|
7fb288819a | ||
|
0c139ef7a0 | ||
|
7ba84b7787 | ||
|
d3b32fefa3 | ||
|
05f8dd8273 | ||
|
ec2f18ab17 | ||
|
d1df10ac86 | ||
|
70655012ab | ||
|
b12e3d8eec | ||
|
89d3e667e0 | ||
|
cc9f4ac587 | ||
|
7b21183f45 | ||
|
3e8b56c509 | ||
|
8866a43b2d | ||
|
f576ecc992 | ||
|
1a999f74fc | ||
|
7b4a29da81 | ||
|
653e4f47ac | ||
|
aab8ba02d8 | ||
|
2540081988 | ||
|
4ff14104b0 | ||
|
ea21dddec9 | ||
|
33cd10581e | ||
|
4b9c23272a | ||
|
875c5df519 | ||
|
c181f147ce | ||
|
9b7256c0c8 | ||
|
10d8760134 | ||
|
3e44bd4e5b | ||
|
7aebed0eea | ||
|
b1d8915440 | ||
|
3ead8d532b | ||
|
f65e6265e0 | ||
|
fd02d69dda | ||
|
0e0ed72652 | ||
|
2327f87e37 | ||
|
b6ce1479fe | ||
|
20b76f87bf | ||
|
7cb5a7bebc | ||
|
950f78041a | ||
|
856f4b55f6 | ||
|
227e2cc0f5 | ||
|
110edf32d0 | ||
|
21e08955d3 | ||
|
803bf59654 | ||
|
05f7f03dab | ||
|
8f19d02501 | ||
|
62c00be873 | ||
|
bd055fac1c | ||
|
b1ace5763a | ||
|
8af3173955 | ||
|
2377db33db | ||
|
4308fa3f68 | ||
|
fc520e7b4c | ||
|
5ce03258b5 | ||
|
549659dab6 | ||
|
ea99d2c2cd | ||
|
828afe188c | ||
|
e3923876c0 | ||
|
080672478d | ||
|
a3f80061b1 | ||
|
bc382c6835 | ||
|
e418bbcfac | ||
|
44072062ff | ||
|
c3f01d7db9 | ||
|
8cf61c859d | ||
|
101f070f12 | ||
|
0dff53ada7 | ||
|
674614cc7a | ||
|
0761d73e9c | ||
|
0c9c29fb34 | ||
|
808931b108 | ||
|
ba79890398 | ||
|
ff7591171b | ||
|
fb16ae2325 | ||
|
36e1a0ceae | ||
|
3e86484091 | ||
|
fb5d53bf57 | ||
|
fc4316f664 | ||
|
0b273ea88c | ||
|
a4f58be00c | ||
|
c9a5f586b7 | ||
|
09b9f8ff9f | ||
|
bff9068a7f | ||
|
a87b1efbd2 | ||
|
193e40c271 | ||
|
7b5b5dbb8d | ||
|
2ee19c4d34 | ||
|
25f476c7ad | ||
|
0642531c2a | ||
|
f8c53fae37 | ||
|
b9ebf87114 | ||
|
b4296e1a2d | ||
|
dd1072a99b | ||
|
ae5261b98b | ||
|
4137ea5ab7 | ||
|
b650e7a503 | ||
|
870c68dd27 | ||
|
57bb28e841 | ||
|
e880b11626 | ||
|
7be7e589a9 | ||
|
1b03676a36 | ||
|
7ab7b2ab8b | ||
|
f484527cfb | ||
|
2bc7fa568f | ||
|
2368ff6637 | ||
|
c6f18c9394 | ||
|
f6c35144e4 | ||
|
261b5120f6 | ||
|
1c2434f4d3 | ||
|
766492d1cc | ||
|
16b0afc192 | ||
|
81dc67b1ef | ||
|
8f28956108 | ||
|
d075c3c274 | ||
|
553e37314a | ||
|
3749171656 | ||
|
d34f5fbae2 | ||
|
5a898254b0 | ||
|
f05386e006 | ||
|
2f260a344e | ||
|
f4042ba752 | ||
|
e7ff5da5b1 | ||
|
e5cabeafe5 | ||
|
62196b2bf1 | ||
|
20aa37237d | ||
|
5d55a5894c | ||
|
00039ba629 | ||
|
321154d25a | ||
|
0e092aef70 | ||
|
8afeb13035 | ||
|
b9e78f2e2e | ||
|
e83f4f40f9 | ||
|
bebc550f02 | ||
|
997f3f8266 | ||
|
8c785f1dc9 | ||
|
1417af2eab | ||
|
fb76e5daa2 | ||
|
36b8186021 | ||
|
a6fda3e65d | ||
|
18ca7affad | ||
|
16be9181a0 | ||
|
3cf4a4e95e | ||
|
bd34ec1fb3 | ||
|
6cdfe38319 | ||
|
c2ca6b6bdf | ||
|
055625448b | ||
|
d52df527ba | ||
|
7b486fe239 | ||
|
009f5765df | ||
|
9e3ac35669 | ||
|
5ab5a721a1 | ||
|
871c9c61a5 | ||
|
1c43b7b55c | ||
|
db7c22d9d6 | ||
|
50254c284b | ||
|
9809bda0e5 | ||
|
9f09ac6893 | ||
|
aa032f31bb | ||
|
e76c596d56 | ||
|
fc4f440245 | ||
|
eafc97bcb3 | ||
|
d053f3665d | ||
|
662d60ad6b | ||
|
f24cc55c14 | ||
|
7cb1970952 | ||
|
0ce2b1359f | ||
|
57518d5312 | ||
|
8297ea9aa6 | ||
|
e746a4c12f | ||
|
09226543fe | ||
|
58aed8fd0d | ||
|
2989373212 | ||
|
858b6a3e0b | ||
|
2e09257d94 | ||
|
b7ea23303e | ||
|
e830cdee71 | ||
|
439652f023 | ||
|
1fd89abcc3 | ||
|
73c0356861 | ||
|
fe4143ad19 | ||
|
f5d702b09a | ||
|
b8d740ebfc | ||
|
3bcdb85ddc | ||
|
2feb3a3bba | ||
|
42b65e80cf | ||
|
0796af7b4b | ||
|
2e62e9ea7e | ||
|
ce5164e26e | ||
|
4e28d1c658 | ||
|
f4a3d17269 | ||
|
970a1a2b35 | ||
|
d5a2ff5c12 | ||
|
992d20def3 | ||
|
79ad8c9354 | ||
|
4072aa4a4b | ||
|
ba868ed4a6 | ||
|
153b7c8460 | ||
|
e60c89c532 | ||
|
321fda9c26 | ||
|
8e6ddb0c1a | ||
|
1d74ff075e | ||
|
f830ac1206 | ||
|
07b7975d09 | ||
|
6415c6b0e0 | ||
|
67d8cf744c | ||
|
36f9510bb3 | ||
|
6ee650f316 | ||
|
2b325d3b59 | ||
|
94b8747da4 | ||
|
e355cdbae0 | ||
|
a7337bc999 | ||
|
604fe3ccee | ||
|
681b839419 | ||
|
72b603780c | ||
|
3aecbc5ac1 | ||
|
665c29f0be | ||
|
4b84fb486b | ||
|
b5350f9387 | ||
|
ec7bac7ba7 | ||
|
8887501042 | ||
|
84a59fe4c0 | ||
|
985d317e0e | ||
|
872a96e599 | ||
|
e0df4cdc6d | ||
|
86462db9ed | ||
|
751f8b313c | ||
|
a169ae05e8 | ||
|
1cf6e8a85d | ||
|
c3555a34dc | ||
|
504bdcc8bb | ||
|
163801507c | ||
|
7ee6101291 | ||
|
498e86fb86 | ||
|
940c67f521 | ||
|
1b7340a6ed | ||
|
49a683f260 | ||
|
becb749792 | ||
|
2a0d49bb58 | ||
|
fe52e69662 | ||
|
d7cd33fd88 | ||
|
b7d7deb983 | ||
|
602103dcf0 | ||
|
fb290f3847 | ||
|
2f77d56b77 | ||
|
ec6b4ed4ff | ||
|
3fb241d4d6 | ||
|
2a1e3b100b | ||
|
2ddbc69f1a | ||
|
f127f0849e | ||
|
aa29d0a2e5 | ||
|
29abe73918 | ||
|
f5d216835a | ||
|
0c8414c13f | ||
|
0f7bb922ba | ||
|
f1412e422c | ||
|
fbd17266cf | ||
|
e40d4a0e12 | ||
|
2863d86bcc | ||
|
75ef230fbe | ||
|
7d1e4a40b1 | ||
|
73183d33c5 | ||
|
8a5559ab17 | ||
|
f064a4022a | ||
|
f4d5e05d96 | ||
|
32c081ba8c | ||
|
a77dca528a | ||
|
25c6d16b45 | ||
|
033a0d29c5 | ||
|
a5d4cbddac | ||
|
40c225095f | ||
|
f63254d905 | ||
|
a557ad0aea | ||
|
d049ea640f | ||
|
9065a1ee23 | ||
|
5bfcd81182 | ||
|
d36864500f | ||
|
343022cdc1 | ||
|
4d18fb39b6 | ||
|
0a15ab702f | ||
|
b55fe1950e | ||
|
c2e224c5fb | ||
|
dc37d90190 | ||
|
60f75cc542 | ||
|
51db232368 | ||
|
c7b209124b | ||
|
de57afd672 | ||
|
004a381d9c | ||
|
e805fe3e36 | ||
|
e5ec52d63b | ||
|
e40b191943 | ||
|
fb75c0530a | ||
|
8b4f0f348a | ||
|
5f55f5adc7 | ||
|
5b2d62e59a | ||
|
f3f2880261 | ||
|
f0070cd595 | ||
|
a9d7c65eb8 | ||
|
22d0841412 | ||
|
bdb8291f6c | ||
|
ed7a846e2e | ||
|
4fbfb44681 | ||
|
802d7317cb | ||
|
cbd504e888 | ||
|
5b9634a7b7 | ||
|
63fbe161f2 | ||
|
b447fdce51 | ||
|
3fb47373a1 | ||
|
22ab08f4d8 | ||
|
3b19a4aaf3 | ||
|
660a71ef22 | ||
|
5f943e9110 | ||
|
b3c13b443f | ||
|
728cf1dcfe | ||
|
c8b87f9bd9 | ||
|
24653b88f3 | ||
|
9fab6e4383 | ||
|
31c3d46925 | ||
|
10edcec030 | ||
|
e99906f05d | ||
|
1a4dedbc8d | ||
|
17adde7f73 | ||
|
a082daeb56 | ||
|
ce4f2728ba | ||
|
cf19b4da49 | ||
|
2d91bd9200 | ||
|
4f7c117296 | ||
|
efd7f2e014 | ||
|
0a5955372a | ||
|
00b79cd781 | ||
|
c7e173a1ff | ||
|
fb4b150f27 | ||
|
4227858cfe | ||
|
9b3b47b1b8 | ||
|
8056058aa1 | ||
|
7b23cd4d3c | ||
|
eaf4d0bfbf | ||
|
29bac62ba2 | ||
|
392398794f | ||
|
1ff1a51e4b | ||
|
646087d54c | ||
|
b60995b106 | ||
|
45d9a097e6 | ||
|
b143754360 | ||
|
0236c480e3 | ||
|
4f7eb890ef | ||
|
495e10e93b | ||
|
513609ef0e | ||
|
23d4bd1dae | ||
|
67420aa8b6 | ||
|
7de7025750 | ||
|
922af42aca | ||
|
d5ed4df254 | ||
|
31ea11fb0e | ||
|
d164752efc | ||
|
3c53293028 | ||
|
8132239ed2 | ||
|
0df5dea653 | ||
|
65f3f56f63 | ||
|
118617916a | ||
|
dd450c526f | ||
|
efe686105d | ||
|
4130ce5bb9 | ||
|
f416713608 | ||
|
825784322d | ||
|
02fc26507b | ||
|
7cc802afd7 | ||
|
59df26af79 | ||
|
f09ac4959e | ||
|
fd8bcc188f | ||
|
8d479d2ea6 | ||
|
1bb3b13c0a | ||
|
ed552e4519 | ||
|
a68fd1b0de | ||
|
3db458697e | ||
|
e8cc288426 | ||
|
c681673993 | ||
|
00538c377e | ||
|
3dc7f322cc | ||
|
7d87b4e869 | ||
|
b194e5dc4e | ||
|
38a5c905db | ||
|
8d4b790eb2 | ||
|
27c7776947 | ||
|
8fcbbfb8b1 | ||
|
067e6deee4 | ||
|
e91c07e1de | ||
|
de615609dc | ||
|
77ac13e6b9 | ||
|
1e43088662 | ||
|
c4f69f4d3d | ||
|
64bb4150f0 | ||
|
32d432ab5e | ||
|
6b8878377f | ||
|
63fce3062e | ||
|
cdf6100fe5 | ||
|
5827197246 | ||
|
830bdd0037 | ||
|
edb36c078f | ||
|
dd0ed989a1 | ||
|
64126a00c3 | ||
|
09095403ac | ||
|
474a0ac4e2 | ||
|
a905a78a96 | ||
|
70e2148fcb | ||
|
ed6061dfae | ||
|
a1d995e740 | ||
|
351d58a95b | ||
|
5d8448a44e | ||
|
de3a365fea | ||
|
0a8c4a6fa2 | ||
|
6c3a60cc54 | ||
|
7bee33f948 | ||
|
3cb9e8dc3b | ||
|
77843aa837 | ||
|
2c9cf7c78b | ||
|
65b67e84a8 | ||
|
f22729461e | ||
|
347e7a396d | ||
|
ca9bb2e089 | ||
|
ecddc39b31 | ||
|
aa3a716249 | ||
|
2c9269ac3a | ||
|
455846a305 | ||
|
3a6bf3be24 | ||
|
58d318719c | ||
|
a0a555878f | ||
|
c1df64b3a6 | ||
|
b6a00579a2 | ||
|
59a3a8e2d6 | ||
|
db5a3197b7 | ||
|
267c70fa55 | ||
|
703da18955 | ||
|
bbeecfc835 | ||
|
d2feb33b47 | ||
|
1d290bf5db | ||
|
37a61bf41a | ||
|
d3108de72a | ||
|
d9c4a257c2 | ||
|
b484288a82 | ||
|
ac2901d2cb | ||
|
9b4f5dab77 | ||
|
3f548ccf9c | ||
|
e218dae281 | ||
|
6cac18e395 | ||
|
49fba97b0a | ||
|
f3fac95bb6 | ||
|
50306a8b08 | ||
|
f0f8bb3f36 | ||
|
9d4bcc951d | ||
|
138e7caa03 | ||
|
5d6ed0fa30 | ||
|
a425c242a4 | ||
|
8e0de82c74 | ||
|
ebf5828542 | ||
|
bbe10dcf17 | ||
|
74fa51d57c | ||
|
aae0a74d60 | ||
|
38c53dca08 | ||
|
b5e1c45827 | ||
|
abf7a91834 | ||
|
239c88e8d3 | ||
|
a43f6a6600 | ||
|
e729ceeb1a | ||
|
a97c7c1fda | ||
|
19c6df1adb | ||
|
8dc9fe725a | ||
|
9d46a1863b | ||
|
7c0ce25bb7 | ||
|
3c620e88a0 | ||
|
4a94bfc2f6 | ||
|
01117c716d | ||
|
a3c74fd429 | ||
|
82963035e9 | ||
|
a06e664730 | ||
|
bc67f2eb75 | ||
|
ab2cb43e15 | ||
|
64ea033c81 | ||
|
b1e6dbe83f | ||
|
568296c88f | ||
|
610a11ddf8 | ||
|
28068c9d4c | ||
|
36fda8e28c | ||
|
3d6f836801 | ||
|
7a7dc4bf0e | ||
|
e2961a2e3c | ||
|
a81a9fb7bc | ||
|
24753747a1 | ||
|
ac897781ba | ||
|
67dd1d2b0c | ||
|
8ae6a04561 | ||
|
77ed788a60 | ||
|
6f7ee57e29 | ||
|
046e9b5286 | ||
|
74365417ac | ||
|
4ca4dc0b2a | ||
|
0b726e4408 | ||
|
d0e4331640 | ||
|
1c93d706d7 | ||
|
4717775abb | ||
|
4ef946287c | ||
|
66382f0d68 | ||
|
18e422dfe4 | ||
|
a92b602b33 | ||
|
8bc9e15618 | ||
|
e060b47330 | ||
|
c553c45f00 | ||
|
97eac342d3 | ||
|
9c70348b39 | ||
|
3264378fa0 | ||
|
73be28a252 | ||
|
39cbef9e01 | ||
|
d56601c8d0 | ||
|
1fbbc82f3a | ||
|
fc98cb482f | ||
|
f86d1e72a4 | ||
|
a1de406de4 | ||
|
7d2819249b | ||
|
b7203b0bbe | ||
|
004a6d3055 | ||
|
949708450b | ||
|
9619582d1b | ||
|
778382cd94 | ||
|
a7ae6404de | ||
|
9fd7f4f1ec | ||
|
ffbade9ed1 | ||
|
16409569fd | ||
|
9e0c02a0ea | ||
|
1cfe23569c | ||
|
198c3dc7b9 | ||
|
d6d6f37578 | ||
|
81fa4d45b9 | ||
|
28ad600b43 | ||
|
2c3a7b0dd9 | ||
|
3832e38ce0 | ||
|
e7770eaaf6 | ||
|
1d9862261f | ||
|
09ede1e7f2 | ||
|
31f6b18c84 | ||
|
fadaa69b92 | ||
|
b007b1dd79 | ||
|
a8c5f9e667 | ||
|
c22812e20b | ||
|
e367dc0783 | ||
|
5b04a7973b | ||
|
820a545950 | ||
|
07b31761fb | ||
|
9f3bbad6bc | ||
|
71ce43313f | ||
|
32a507ace6 | ||
|
154847c696 | ||
|
38d7f8415d | ||
|
64ea19b7f7 | ||
|
b7605f1c34 | ||
|
f2a32589ea | ||
|
a2d56c8bfc | ||
|
4f549155c5 | ||
|
c89f503604 | ||
|
4382af6e1b | ||
|
42ce821603 | ||
|
52b81f42eb | ||
|
fd1beedc07 | ||
|
68d7470fc2 | ||
|
65b0e13a1a | ||
|
4add058cd8 | ||
|
5bb7dcaba3 | ||
|
05b9331d0d | ||
|
b314a9eb84 | ||
|
3784919213 | ||
|
0f362ab720 | ||
|
5894e79064 | ||
|
0245d22c83 | ||
|
050840f493 | ||
|
595fe9a7aa | ||
|
fd9da5db2d | ||
|
26251d02a9 | ||
|
f2659c14a2 | ||
|
808b28b425 | ||
|
860bb59c89 | ||
|
0c3c4e0563 | ||
|
64bc0515e0 | ||
|
2c15015ec2 | ||
|
ad5377f995 | ||
|
2c0773c9ad | ||
|
e383834049 | ||
|
018f3e8094 | ||
|
1ed8d907b3 | ||
|
49ec9add38 | ||
|
8d8de1db10 | ||
|
9f3bbab2f0 | ||
|
1a6409cd5b | ||
|
13dfccc1c6 | ||
|
5b4af411f5 | ||
|
874ca85a95 | ||
|
5dedcff665 | ||
|
843fc980b5 | ||
|
12ac1dd46b | ||
|
e20b63c55e | ||
|
1f4d17a4a2 | ||
|
3669763835 | ||
|
5c00766eff | ||
|
1f09f4fb3a | ||
|
05c87b02f6 | ||
|
36510cd0be | ||
|
1efc0ac740 | ||
|
14991f2e17 | ||
|
176e35b6cc | ||
|
f0a864c8a2 | ||
|
6d6cd8021e | ||
|
5a679a1af3 | ||
|
df86a2842a | ||
|
9e3b8ec98a | ||
|
2669ae16ea | ||
|
e6acf3090d | ||
|
40cccaccea | ||
|
7a1d36ba05 | ||
|
b29f1e6cdc | ||
|
c246c8db79 | ||
|
0dc07f5cce | ||
|
683e11aece | ||
|
72394d9ae3 | ||
|
c010fb63a1 | ||
|
4c9821e5d5 | ||
|
92fa68cb07 | ||
|
2996ad6bd2 | ||
|
21681489ed | ||
|
3d53d90d4b | ||
|
7412e66064 | ||
|
c34dc81753 | ||
|
a89ceb6590 | ||
|
94900131a8 | ||
|
756b98f093 | ||
|
ca42adbf6b | ||
|
3dbaf11f8c | ||
|
6ae4da02c9 | ||
|
466d849c72 | ||
|
5df836c513 | ||
|
30bc6965a2 | ||
|
e8b373e3ff | ||
|
24f4308982 | ||
|
e4d36bd855 | ||
|
2e3f4a01bf | ||
|
3c4889add3 | ||
|
befba8e813 | ||
|
026624a266 | ||
|
7450c4a368 | ||
|
ba5c3b576e | ||
|
5639b54c1b | ||
|
9af17d4a9d | ||
|
e5ba79b4f1 | ||
|
1a28e7d9c6 | ||
|
8438aacc3b | ||
|
76fd1388d8 | ||
|
fb8660c196 | ||
|
4290d85397 | ||
|
a10ee075ff | ||
|
5a513ffcec | ||
|
f50b20ddd6 | ||
|
aa1ce9e295 | ||
|
90a07ada8e | ||
|
950c381728 | ||
|
ab60f4e082 | ||
|
b4608e99e3 | ||
|
6eda775047 | ||
|
64c4a3a442 | ||
|
5ea946aa90 | ||
|
794f4c30f4 | ||
|
68311ef010 | ||
|
404644bad3 | ||
|
6f52bb6b1a | ||
|
2083d505c7 | ||
|
e6c84862a8 | ||
|
1b0248f31b | ||
|
51c37735a9 | ||
|
3681b83fb4 | ||
|
7e4ab9c7c0 | ||
|
e781abc3fb | ||
|
cc9fcee676 | ||
|
61bda1c054 | ||
|
568776bbf6 | ||
|
b0646cb427 | ||
|
da75582a14 | ||
|
b5f1979475 | ||
|
ad2208b726 | ||
|
1a8e9ff94e | ||
|
96c13aeb97 | ||
|
3511b54040 | ||
|
08253504dc | ||
|
5883e01032 | ||
|
a595b96f62 | ||
|
5188883142 | ||
|
aeae8322da | ||
|
072b45b972 | ||
|
cc340b2838 | ||
|
9690ffff61 | ||
|
fa6d03a4cb | ||
|
89e5912fd2 | ||
|
6637948ae1 | ||
|
cf27065b7d | ||
|
4195a2f18a | ||
|
f7bc30bad2 | ||
|
624eccbab1 | ||
|
fd33d51b1b | ||
|
e83387d8b7 | ||
|
d6efdeea61 | ||
|
5667da7b80 | ||
|
212333bfa6 | ||
|
e452519dcb | ||
|
d12a9738a0 | ||
|
d287e0d8a6 | ||
|
b3eee0a323 | ||
|
591ae5e18e | ||
|
b492ebc374 | ||
|
ccdac48923 | ||
|
d39e840c14 | ||
|
390a330b8e | ||
|
bb74180659 | ||
|
7905c47765 | ||
|
8b98e483ac | ||
|
94cf432035 | ||
|
ae1d62f6a0 | ||
|
5eff8bf918 | ||
|
d48f7409fe | ||
|
5e9edf25d0 | ||
|
d477a00734 | ||
|
d58282c6d1 | ||
|
85697d76be | ||
|
6a119b6946 | ||
|
9d82915629 | ||
|
23be6ed0dd | ||
|
158bf794e6 | ||
|
cf7fade580 | ||
|
91701f8303 | ||
|
6a03369f84 | ||
|
a1f712d100 | ||
|
bc2b137df9 | ||
|
96b324c156 | ||
|
8d030718ae | ||
|
32e6a1bb4d | ||
|
3a3f95e1e7 | ||
|
4889c71857 | ||
|
1113d24a70 | ||
|
21e9029177 | ||
|
5958e527e5 | ||
|
19c493722e | ||
|
e408f1d984 | ||
|
f76dd80cba | ||
|
8d8e0fd55a | ||
|
7fbed358c9 | ||
|
dff7c0e7b8 | ||
|
b411086398 | ||
|
987dbe31e3 | ||
|
bc830fa06b | ||
|
cf3e251a9f | ||
|
f54797bae5 | ||
|
2a8c1b2823 | ||
|
51d05c1844 | ||
|
88dd082160 | ||
|
d562b03c43 | ||
|
7fd6c29ee8 | ||
|
b65f5fb069 | ||
|
7180a96741 | ||
|
9ce7b7806f | ||
|
d9b631182e | ||
|
fb2b974466 | ||
|
6fd1a1ce7e | ||
|
a492d64fef | ||
|
8a3fe9cd1e | ||
|
ae772d40cf | ||
|
3bf114f3c3 | ||
|
ed4d45355a | ||
|
9f3b21cc78 | ||
|
1301014b28 | ||
|
3c86094371 | ||
|
773e1bbeae | ||
|
abed6d9cb7 | ||
|
0273ff007b | ||
|
26efba30b4 | ||
|
2b897296a1 | ||
|
768b19d410 | ||
|
976fe27836 | ||
|
7408ab145a | ||
|
a3b8aaf679 | ||
|
03ad04c890 | ||
|
1e86f00247 | ||
|
a4ab53ab7b | ||
|
62d5bc91f5 | ||
|
349fdd0843 | ||
|
d9508558a9 | ||
|
eba8fd4720 | ||
|
7ae1284c16 | ||
|
071130b944 | ||
|
ca309e439a | ||
|
19c699870b | ||
|
7c3f424a97 | ||
|
2b84e30e26 | ||
|
51cdb74061 | ||
|
eeb7bbe3c5 | ||
|
d95962068a | ||
|
dfe79cb6a9 | ||
|
d8892a4ca2 | ||
|
44ea7b5e12 | ||
|
e411fcb60e | ||
|
0e43dea42d | ||
|
083b87c712 | ||
|
8943999bd2 | ||
|
bfaab9700d | ||
|
0b8a53d75d | ||
|
74da9ed6fe | ||
|
b5c56a50b5 | ||
|
3aec841a9f | ||
|
416ce575f6 | ||
|
eca344ff56 | ||
|
3f98ca53ca | ||
|
b092fcfc46 | ||
|
c89e547e3e | ||
|
2b45878ff8 | ||
|
f470eb2a1a | ||
|
c5c3151414 | ||
|
4e8b34c075 | ||
|
b2460a6794 | ||
|
a8b9a92c10 | ||
|
1ed5f1a4d0 | ||
|
f771f081d9 | ||
|
ae2d86b99c | ||
|
df3aaac7cf | ||
|
147f8898ca | ||
|
aee00ea55a | ||
|
cbed70c60f | ||
|
beb342ed5f | ||
|
47fcbc335b | ||
|
069b8aac64 | ||
|
013e354b46 | ||
|
7eee877dd4 | ||
|
a243862b8c | ||
|
7cc8151b81 | ||
|
c75fbaf94e | ||
|
10442369d8 | ||
|
16d9a10dd5 | ||
|
5b21cc67f1 | ||
|
3601397703 | ||
|
0ab5e1cb03 | ||
|
d3c464212d | ||
|
bc351f4b70 | ||
|
7f834f57e5 | ||
|
859b911b3a | ||
|
bd3ba87747 | ||
|
90616be301 | ||
|
2d848cf001 | ||
|
104435df5f | ||
|
ad2f821ff5 | ||
|
5fb3a91276 | ||
|
cb55ba5b9b | ||
|
0c5dc53fd2 | ||
|
5f8570b933 | ||
|
f15a1c0b23 | ||
|
bbc6b56ab0 | ||
|
5571522efe | ||
|
9dd42d15dd | ||
|
5dfaa26990 | ||
|
cd5718f59d | ||
|
33972998a9 | ||
|
0465549c9d | ||
|
20b3a4c362 | ||
|
962ce961d4 | ||
|
2d452842ed | ||
|
15d8591a26 | ||
|
7021a57193 | ||
|
c60eecbac8 | ||
|
edbf7349bd | ||
|
52761e689b | ||
|
ce638b9cca | ||
|
92d1ba9188 | ||
|
1c43b2e55f | ||
|
35d2df14d8 | ||
|
907b6705fe | ||
|
6801ad9b7a | ||
|
cd249a47b8 | ||
|
1e3c1392bd | ||
|
ec53e325b6 | ||
|
3ddf46649b | ||
|
54092286be | ||
|
6ee17cf77e | ||
|
a29a4288d2 | ||
|
56e5fca501 | ||
|
f0e31dd6b3 | ||
|
f2d181e65c | ||
|
6cbe5ffa15 | ||
|
5b5a27dccb | ||
|
bf71b13797 | ||
|
fb17ba18ae | ||
|
8e47ecbd92 | ||
|
afb1a2610e | ||
|
845d6f9134 | ||
|
080f25c583 | ||
|
690c47dbf8 | ||
|
e366fc3ad6 | ||
|
831a797837 | ||
|
7b1bc5ca74 | ||
|
5034e1eeb5 | ||
|
6e14d7ab90 | ||
|
71dccc0132 | ||
|
3285d1ad8c | ||
|
ccc48291b3 | ||
|
48a2207511 | ||
|
75e0cde045 | ||
|
2d7832e738 | ||
|
9cb4207c92 | ||
|
aba45d0386 | ||
|
bc4aacd21e | ||
|
27eb3c07ad | ||
|
93f1af721f | ||
|
790f35533b | ||
|
bb0e4506a6 | ||
|
c3b31b96e1 | ||
|
a29270fa64 | ||
|
118f494de3 | ||
|
7202e6e2f3 | ||
|
16efb7c0c6 | ||
|
cd74461d6d | ||
|
c332adaa68 | ||
|
c7d09bba97 | ||
|
b21ae8d9c2 | ||
|
1256b4f862 | ||
|
3428ed7a64 | ||
|
cf92d9f398 | ||
|
fc8384462f | ||
|
c2a42214ff | ||
|
e55bc76fd2 | ||
|
0acebd6e09 | ||
|
95a46fb0f0 | ||
|
fcb09be6e3 | ||
|
ce83628882 | ||
|
fc65170521 | ||
|
d76435cd21 | ||
|
102cfdab36 | ||
|
3342d307a8 | ||
|
c571a45e65 | ||
|
b5ccc0e705 | ||
|
fbd8b1a8c4 | ||
|
34fdb304bb | ||
|
84685fb56d | ||
|
c66f25016b | ||
|
41ff4343e1 | ||
|
10efdd3f63 | ||
|
aa79bfa681 | ||
|
e7c4867359 | ||
|
944929d0da | ||
|
4eed6b8887 | ||
|
7b47528e4b | ||
|
79455041f0 | ||
|
565698711b | ||
|
d1c2ae3f0e | ||
|
0b989c9f37 | ||
|
b7314e2438 | ||
|
7c42da465a | ||
|
cd070f9995 | ||
|
a88f3168e5 | ||
|
577cc47740 | ||
|
cd5917c648 | ||
|
25232f2b2b | ||
|
4dec4e9959 | ||
|
68492e704f | ||
|
cf6a3ad676 | ||
|
eb10f0897e | ||
|
0e50825b83 | ||
|
3ab68c1e46 | ||
|
ab23038367 | ||
|
da7c9694f1 | ||
|
cebe0a8b95 | ||
|
600f90e8b0 | ||
|
c94aa5e03c | ||
|
d6052bc31b | ||
|
5d52bef19d | ||
|
67093c5833 | ||
|
ae27fded1a | ||
|
fc4c9b7a95 | ||
|
babbf11d52 | ||
|
7f1c78f8e2 | ||
|
f501b8c661 | ||
|
4103e76245 | ||
|
49121937cf | ||
|
2129a7f09d | ||
|
79aa75e98f | ||
|
7e9dc8da97 | ||
|
99aebb1b31 | ||
|
19d35d89cd | ||
|
6259832680 | ||
|
c3757e6930 | ||
|
53e35f2d76 | ||
|
caa2a9d314 | ||
|
f47d523e0b | ||
|
125bf74ef3 | ||
|
994e994231 | ||
|
2722346ffb | ||
|
849d4b3b2b | ||
|
3b1760134f | ||
|
4400315c4b | ||
|
85b8503995 | ||
|
3452d126a8 | ||
|
01ba2ba6db | ||
|
1812258f37 | ||
|
5cf8562124 | ||
|
4f054aed48 | ||
|
2ea5f187f9 | ||
|
8010ef8771 | ||
|
5e52ccbf3d | ||
|
f28d39b609 | ||
|
c94eac2d33 | ||
|
6822f1fe6c | ||
|
5f20103518 | ||
|
8acaa3a62c | ||
|
0f91149260 | ||
|
10559fa17a | ||
|
700eba0b01 | ||
|
0cc0b68fb4 | ||
|
308121ba04 | ||
|
e911433e0c | ||
|
5c2b057b56 | ||
|
b7b5b0cff8 | ||
|
a0b98c1610 | ||
|
7404fa5285 | ||
|
300e4e0d12 | ||
|
c9c537faa0 | ||
|
da0469f190 | ||
|
2626dcc55d | ||
|
2bf517782d | ||
|
6a86e1a8d9 | ||
|
95bd06be83 | ||
|
42f910e56e | ||
|
828e5f1249 | ||
|
674ad7d655 | ||
|
6de741e5e7 | ||
|
8d85ea2dc5 | ||
|
e58726310b | ||
|
2934f820a9 | ||
|
afa2fd527c | ||
|
466c8bfbb7 | ||
|
44e96ad4d6 | ||
|
d68e60a78a | ||
|
55de9ea405 | ||
|
f0c8b4a3c5 | ||
|
5ad83a05ff | ||
|
92a7cc3420 | ||
|
b9d8b84b06 | ||
|
93cd63bc93 | ||
|
929010ffd7 | ||
|
459f141e81 | ||
|
e8b14d765d | ||
|
ebc4f84185 | ||
|
a4262c3836 | ||
|
94af1754dd | ||
|
f37be27bdc | ||
|
8e39783770 | ||
|
58472e7404 | ||
|
f441d3e112 | ||
|
a3d06c8f12 | ||
|
b81cdcb488 | ||
|
91475c684f | ||
|
ae4a6c7044 | ||
|
e2c6058734 | ||
|
a3017fe9d5 | ||
|
a2aeb3a142 | ||
|
3a21daa49e | ||
|
945e8a9024 | ||
|
966e627733 | ||
|
650bf4d83f | ||
|
b2cddecfc5 | ||
|
1e97e1203f | ||
|
ee8e005209 | ||
|
7b99c33510 | ||
|
36c08b47e9 | ||
|
28ef331704 | ||
|
b9366def96 | ||
|
43b714d896 | ||
|
7e3231c749 | ||
|
c43e5c8eb5 | ||
|
7daaaf6386 | ||
|
010aa53bfa | ||
|
f73a23f735 | ||
|
eb7f5f7f68 | ||
|
8975933aff | ||
|
799e6105a4 | ||
|
d7def84253 | ||
|
968a3dfc1a | ||
|
b5c5783293 | ||
|
2ac7f650a1 | ||
|
f64689eed8 | ||
|
478e28ea79 | ||
|
bec7188333 | ||
|
bc70d575ae | ||
|
e289c3999d | ||
|
3b3fe1da2c | ||
|
2fc35da940 | ||
|
2409966ff2 | ||
|
9777c8bc65 | ||
|
35d3161f9d | ||
|
637a3cabe7 | ||
|
32ced3bd8f | ||
|
01f6ef5e6d | ||
|
7c9695b261 | ||
|
d4bc51b850 | ||
|
f8d403f330 | ||
|
c8acf285cb | ||
|
1d485cc8a9 | ||
|
ab07637ee1 | ||
|
ae40184631 | ||
|
e9f0c6fef3 | ||
|
6cae2d006c | ||
|
29e58a2be3 | ||
|
9b1b7e86cf | ||
|
7aa0de27e9 | ||
|
a1487380bb | ||
|
c462c62108 | ||
|
deda49e501 | ||
|
842841907e | ||
|
c278c901b5 | ||
|
56ec211d04 | ||
|
259273a133 | ||
|
a3c7bebc18 | ||
|
48f512a83a | ||
|
8aa2364381 | ||
|
0e9fcb1431 | ||
|
947b151ed4 | ||
|
7c12371298 | ||
|
90fc57ff89 | ||
|
97cc27d33f | ||
|
c45bb5badc | ||
|
dec7a0dbd2 | ||
|
22ba37c8b9 | ||
|
936adff58b | ||
|
0f07a2c512 | ||
|
e1c3266793 | ||
|
1d21588de7 | ||
|
3e012c355d | ||
|
27b421be6a | ||
|
e27cf68173 | ||
|
9696a0cd4a | ||
|
ce6306c6fb | ||
|
504f4223c2 | ||
|
c447a062c4 | ||
|
88b3d4fb3a | ||
|
4939f580a4 | ||
|
4b85e6b1f8 | ||
|
b72ef6038d | ||
|
6bd0390498 | ||
|
6b0baeb6c2 | ||
|
3b68aa5b87 | ||
|
7ea8a29036 | ||
|
ca445cd832 | ||
|
d54e2ebd7d | ||
|
4bad83c9fb | ||
|
ffc1449412 | ||
|
4aa262d773 | ||
|
1f9fc2a422 | ||
|
3423d1b54b | ||
|
02b249d5e7 | ||
|
4c03cda3c7 | ||
|
9e4b2f5a1b | ||
|
7bd6c6b172 | ||
|
908833fa6b | ||
|
cfa8f0dccb | ||
|
44222ea739 | ||
|
e9fbbf26bb | ||
|
bf9022d3df | ||
|
5ce10b9e68 | ||
|
34c8aaad29 | ||
|
244838d344 | ||
|
8af2d04dbc | ||
|
af687c9522 | ||
|
35fe5b48c8 | ||
|
d30160710b | ||
|
14ee3b3e4a | ||
|
1aa857735f | ||
|
e146cc4c8e | ||
|
1176aaad22 | ||
|
ebaf877b62 | ||
|
534d546ed9 | ||
|
9260078300 | ||
|
e61046fb23 | ||
|
fe8a2f820b | ||
|
0c621f9e4e | ||
|
08fb683784 | ||
|
961c4f8b23 | ||
|
8933620109 | ||
|
866f138875 | ||
|
dcee148b1a | ||
|
ec644b395b | ||
|
5df81049aa | ||
|
47981def0d | ||
|
23ba1a5e07 | ||
|
ab525f31e4 | ||
|
f3e6c75c89 | ||
|
b31c9831fa | ||
|
096f133b09 | ||
|
03ab0156a2 | ||
|
5c0d640d18 | ||
|
4b06729be8 | ||
|
c2fd1e42fd | ||
|
82773eb805 | ||
|
2688a24bde | ||
|
b23c172a47 | ||
|
e7eadb38b8 | ||
|
24e29649c4 | ||
|
7636f2a233 | ||
|
6e6e2910d6 | ||
|
4ed16108f0 | ||
|
5db2c2a949 | ||
|
d70342d66d | ||
|
82dec5db46 | ||
|
f6a8cdf2bb | ||
|
304724608a | ||
|
4683186166 | ||
|
9fbf646748 | ||
|
127ae6cf12 | ||
|
61a700bcdc | ||
|
e761b2cad1 | ||
|
3eb2a3d0e4 | ||
|
12a7cde092 | ||
|
04d7ad90e5 | ||
|
3b4e0ce8e9 | ||
|
d71966c77e | ||
|
05a5bd620d | ||
|
e550901efa | ||
|
828dfdf1bd | ||
|
1c285d40bd | ||
|
d8c41cc270 | ||
|
a3fdc447de | ||
|
5fd93c28c4 | ||
|
5ebbba6fff | ||
|
207664baca | ||
|
f163df787e | ||
|
de6abd964e | ||
|
75299c04fd | ||
|
bfd1fc9cd6 | ||
|
7b9a1bf6df | ||
|
08c1f4d45e | ||
|
455c826a6a | ||
|
e935dcb88d | ||
|
4a28433ef5 | ||
|
fade5dd54c | ||
|
ffb7284fb6 | ||
|
829e6f5cd0 | ||
|
03d76f653b | ||
|
b9693393fd | ||
|
0a6bcf5da7 | ||
|
a214e96cf8 | ||
|
b61675d0f3 | ||
|
c1babbc8aa | ||
|
6c1dc53d15 | ||
|
41cb29c4c8 | ||
|
615ffb823b | ||
|
dae88bab52 | ||
|
4dfd682446 | ||
|
51e9b05fe5 | ||
|
62fad1c185 | ||
|
ed1e74dd62 | ||
|
73ee5a135a | ||
|
855b9713b8 | ||
|
384810b4ba | ||
|
7ec44bd70b | ||
|
45f18a7838 | ||
|
379cd9b7b5 | ||
|
b46eac35c0 | ||
|
9aace1ac4e | ||
|
23e3ec84f7 | ||
|
a61846c28a | ||
|
9a564872c5 | ||
|
7abf3c3a37 | ||
|
3d8fc1a467 | ||
|
a39227c79c | ||
|
d507acb5ac | ||
|
8515fcbc70 | ||
|
6d28cc131b | ||
|
9673b660d4 | ||
|
1ed4543007 | ||
|
ee2da76e6d | ||
|
7a74e79f2d | ||
|
1c01560321 | ||
|
f5205da8e9 | ||
|
672a8f5ce9 | ||
|
22aad955ec | ||
|
2a52ccf2c6 | ||
|
527966580e | ||
|
1a0d6a4db4 |
2
AUTHORS
2
AUTHORS
@@ -4,6 +4,7 @@ Alistair Leslie-Hughes
|
||||
Andrew Eikum
|
||||
Andrey Gusev
|
||||
Anna (navi) Figueiredo Gomes
|
||||
Arkadiusz Hiler
|
||||
Atharva Nimbalkar
|
||||
Biswapriyo Nath
|
||||
Brendan Shanks
|
||||
@@ -15,6 +16,7 @@ Elizabeth Figura
|
||||
Ethan Lee
|
||||
Evan Tang
|
||||
Fabian Maurer
|
||||
Feifan He
|
||||
Florian Weimer
|
||||
Francisco Casas
|
||||
Francois Gouget
|
||||
|
2
COPYING
2
COPYING
@@ -1,4 +1,4 @@
|
||||
Copyright 2016-2024 the Vkd3d project authors (see the file AUTHORS for a
|
||||
Copyright 2016-2025 the Vkd3d project authors (see the file AUTHORS for a
|
||||
complete list)
|
||||
|
||||
Vkd3d is free software; you can redistribute it and/or modify it under
|
||||
|
392
ChangeLog.md
392
ChangeLog.md
@@ -1,3 +1,395 @@
|
||||
# What's new in vkd3d 1.17 (21 August 2025)
|
||||
|
||||
### libvkd3d
|
||||
|
||||
- The EnumerateMetaCommands() method of the ID3D12Device5 interface is
|
||||
implemented.
|
||||
|
||||
### libvkd3d-shader
|
||||
|
||||
- Several new features and improvements for the HLSL source type:
|
||||
- Initial thread group shared memory support.
|
||||
- Improved support for geometry shaders: shader model 5 multiple output
|
||||
streams, as well as SV_IsFrontFace, SV_RenderTargetArrayIndex, and
|
||||
SV_ViewportArrayIndex outputs.
|
||||
- Structure variable input/output semantics are propagated to the
|
||||
constituent structure fields.
|
||||
- Shader entry point return values are allocated before any other outputs
|
||||
in the output signature. This matches d3dcompiler/fxc more closely.
|
||||
- Hull shader control point pass-through.
|
||||
- Reflection information can be retrieved using vkd3d_shader_scan().
|
||||
- Improved preprocessor handling of comments inside include directives, as
|
||||
well as inclusion of empty files.
|
||||
- Memory barrier intrinsics are supported in shader model 4 target
|
||||
profiles. Previous these were only supported in shader model 5 target
|
||||
profiles.
|
||||
- Parser support for the noise() intrinsic. Although the intrinsic itself
|
||||
isn't implemented, parser support for the intrinsic is required to allow
|
||||
compilation of any other shaders in the same source file to succeed as
|
||||
well.
|
||||
- Parser support for StructuredBuffer resources.
|
||||
|
||||
- Various new features and improvements for the effects (FX) source type:
|
||||
- Shader blob assignments and FXLVM value expressions in ‘fx_2_0’ effects.
|
||||
- Nameless structure types.
|
||||
- Explicit constant buffer bind points and constant packing offsets.
|
||||
- The ‘d3ds_noiseswiz’, ‘ge’, ‘lt’, and ‘noise’ FXLVM operations.
|
||||
|
||||
- The experimental Metal Shading Language (MSL) target supports the
|
||||
following features:
|
||||
- Texture sampling and gather operations.
|
||||
- Loops and switches.
|
||||
- Screen-space partial derivatives.
|
||||
- Various integer arithmetic and comparison operations.
|
||||
- Indirect addressing of constant buffers.
|
||||
- Indexable temporary registers.
|
||||
- Fragment shader output sample coverage masks.
|
||||
- SV_Position and SV_SampleIndex fragment shader inputs.
|
||||
- SV_VertexID inputs.
|
||||
|
||||
- When the experimental MSL target is enabled, the ‘dxbc-dxil’ source type
|
||||
can be used in combination with the ‘msl’ target type to convert DXIL
|
||||
shaders to MSL.
|
||||
|
||||
- The new ‘tx’ source type can be used in combination with the ‘d3d-asm’
|
||||
target type to disassemble D3DX ‘tx_1_0’ texture shaders.
|
||||
|
||||
- The FX target takes alignment and padding into account in ‘fx_4_0’ buffer
|
||||
size calculations.
|
||||
|
||||
- The SPIR-V target is capable of outputting OpSource and OpLine debug
|
||||
information.
|
||||
|
||||
- The core grammar for the experimental SPIR-V disassembler has been updated
|
||||
to the ‘vulkan-sdk-1.4.313.0’ release.
|
||||
|
||||
- New interfaces:
|
||||
- The VKD3D_SHADER_SOURCE_TX source type specifies D3DX ‘tx_1_0’ texture
|
||||
shaders.
|
||||
|
||||
### vkd3d-compiler
|
||||
|
||||
- The new ‘tx’ source type specifies D3DX ‘tx_1_0’ texture shaders.
|
||||
|
||||
### demos
|
||||
|
||||
- The new vkd3d-teapot demo uses tessellation shaders to render a version of
|
||||
Martin Newell's famous teapot. It should be noted that current versions of
|
||||
MoltenVK unfortunately do not support all features required to execute
|
||||
this demo correctly.
|
||||
|
||||
# What's new in vkd3d 1.16 (20 May 2025)
|
||||
|
||||
### libvkd3d
|
||||
|
||||
- DXIL shaders are supported in the default configuration. Previously this
|
||||
required building vkd3d with the ‘-DVKD3D_SHADER_UNSUPPORTED_DXIL’
|
||||
preprocessor option. The also raises the maximum supported shader model to
|
||||
version 6.0.
|
||||
|
||||
- Graphics pipeline state objects can be created from shaders with embedded
|
||||
root signatures. This was already possible for compute pipeline state
|
||||
objects.
|
||||
|
||||
- The SetEventOnMultipleFenceCompletion() method of the ID3D12Device1
|
||||
interface is implemented.
|
||||
|
||||
- When the VK_KHR_zero_initialize_workgroup_memory extension is supported,
|
||||
libvkd3d supports zero-initialising compute shader thread group shared
|
||||
memory.
|
||||
|
||||
- The VK_KHR_maintenance2 extension is now explicitly required. libvkd3d
|
||||
already unconditionally used features provided by this extension, but
|
||||
unfortunately didn't explicitly require it. Support for this extension is
|
||||
widespread, and the extension is part of Vulkan 1.1.
|
||||
|
||||
### libvkd3d-shader
|
||||
|
||||
- The previously experimental support for compiling DXIL shaders is now a
|
||||
supported feature and enabled by default. Please note that this feature is
|
||||
nevertheless still far from perfect.
|
||||
|
||||
- New features for the HLSL source type:
|
||||
- Initial support for geometry shaders.
|
||||
- Indirect addressing in shader model 1-3 target profiles.
|
||||
- Modulus and truncation operations in shader model 1-3 target profiles.
|
||||
- Vectorised output code.
|
||||
- Further improved constant folding and propagation.
|
||||
- The following intrinsic functions are supported:
|
||||
- AllMemoryBarrier()
|
||||
- AllMemoryBarrierWithGroupSync()
|
||||
- DeviceMemoryBarrier()
|
||||
- DeviceMemoryBarrierWithGroupSync()
|
||||
- GroupMemoryBarrier()
|
||||
- GroupMemoryBarrierWithGroupSync()
|
||||
- The ‘.Length’ Texture object property.
|
||||
- The ‘SV_RenderTargetArrayIndex’ and ‘SV_ViewportArrayIndex’ semantics in
|
||||
tessellation shaders.
|
||||
|
||||
- Disassembler support for binary ‘fx_2_0’ effects.
|
||||
|
||||
- Experimental built-in support for disassembling SPIR-V shaders, enabled by
|
||||
building vkd3d with the ‘-DVKD3D_SHADER_UNSUPPORTED_SPIRV_PARSER’
|
||||
preprocessor option. When enabled, the built-in SPIR-V disassembler is
|
||||
used instead of SPIRV-Tools for the ‘spirv-text’ target type, as well as
|
||||
for the debug output enabled by the VKD3D_SHADER_DEBUG environment
|
||||
variable.
|
||||
|
||||
- The experimental OpenGL Shading Language (GLSL) target supports indirect
|
||||
addressing of constant buffers.
|
||||
|
||||
- The experimental Metal Shading Language (MSL) target supports texture
|
||||
loads.
|
||||
|
||||
- New interfaces:
|
||||
- The VKD3D_SHADER_COMPILE_OPTION_FEATURE_ZERO_INITIALIZE_WORKGROUP_MEMORY
|
||||
flag indicates support for zero-initialising workgroup memory in the
|
||||
SPIR-V target environment.
|
||||
- The VKD3D_SHADER_COMPONENT_INT64 enumeration value indicates a 64-bit
|
||||
signed integer value.
|
||||
- The VKD3D_SHADER_COMPONENT_FLOAT16 enumeration value indicates a 16-bit
|
||||
IEEE floating-point value.
|
||||
- The VKD3D_SHADER_COMPONENT_UINT16 enumeration value indicates a 16-bit
|
||||
unsigned integer value.
|
||||
- The VKD3D_SHADER_COMPONENT_INT16 enumeration value indicates a 16-bit
|
||||
signed integer value.
|
||||
- When targeting VKD3D_SHADER_API_1_16, the
|
||||
VKD3D_SHADER_RESOURCE_DATA_NONE enumeration value is returned for the
|
||||
‘resource_data_type’ field in the vkd3d_shader_descriptor_info structure
|
||||
for sampler descriptors. VKD3D_SHADER_API_1_15 and before use the
|
||||
VKD3D_SHADER_RESOURCE_DATA_UINT enumeration value for this.
|
||||
|
||||
### demos
|
||||
|
||||
- The vkd3d demos now work on both the Microsoft Windows and Apple macOS
|
||||
builds. The macOS versions of the vkd3d demos are completely new in vkd3d
|
||||
1.16, while the Windows demos could previously be built, but only worked
|
||||
on Wine. Note that the vkd3d demos produced by a Windows build of vkd3d
|
||||
are distinct from those produced by the ‘make crosstest’ target: the
|
||||
former are Vulkan applications using vkd3d, while the latter are Direct3D
|
||||
12 applications.
|
||||
|
||||
- The vkd3d demos have basic support for DPI scaling.
|
||||
|
||||
### build
|
||||
|
||||
- Perl and the ‘JSON’ Perl module have been added as build dependencies.
|
||||
These are used for the experimental built-in SPIR-V disassembler, as well
|
||||
as for the macOS versions of the vkd3d demos.
|
||||
|
||||
# What's new in vkd3d 1.15 (19 February 2025)
|
||||
|
||||
### libvkd3d
|
||||
|
||||
- New interfaces:
|
||||
- vkd3d_queue_signal_on_cpu() allows a Direct3D 12 fence to be signalled
|
||||
when all preceding work on a Direct3D 12 command queue has been submitted
|
||||
to the corresponding Vulkan queue.
|
||||
|
||||
### libvkd3d-shader
|
||||
|
||||
- New features for the HLSL source type:
|
||||
- ‘InputPatch’ and ‘OutputPatch’ tessellation shader objects. This was the
|
||||
main feature required by most tessellation shaders that was still missing,
|
||||
and tessellation shaders should be considered generally usable now.
|
||||
- Unrolling of loops containing conditional jumps.
|
||||
- Improved function overload resolution. Previously the compiler was unable
|
||||
to decide between multiple function overloads with the same number of
|
||||
parameters.
|
||||
- The parser is able to continue parsing in a larger number of error cases.
|
||||
This allows more issues in the input to be reported during a single
|
||||
compilaton attempt.
|
||||
- The following intrinsic functions are supported:
|
||||
- GatherCmp()
|
||||
- GatherCmpAlpha(), GatherCmpBlue(), GatherCmpGreen(), and GatherCmpRed()
|
||||
- InterlockedAdd(), InterlockedAnd(), InterlockedCompareExchange(),
|
||||
InterlockedCompareStore(), InterlockedExchange(), InterlockedMax(),
|
||||
InterlockedMin(), InterlockedOr(), and InterlockedXor()
|
||||
- isinf()
|
||||
- Separate resource and sampler support for shader model 1-3 target
|
||||
profiles.
|
||||
- Casts on the left hand side of assignments.
|
||||
- Reassociation and redistribution of constants in binary expressions, to
|
||||
facilitate constant folding.
|
||||
- Packing of interstage I/O variables with the ‘SV_IsFrontFace’,
|
||||
‘SV_PrimitiveID’, ‘SV_RenderTargetArrayIndex’, ‘SV_SampleIndex’, and
|
||||
‘SV_ViewPortArrayIndex’ semantics matches d3dcompiler/fxc more closely.
|
||||
- Parser support for the ‘LineStream’, ‘PointStream’, and ‘TriangleStream’
|
||||
Stream-Output objects.
|
||||
|
||||
- A number of instructions have been implemented for the experimental MSL
|
||||
target. Although more and more shaders are starting to work, support is
|
||||
still fairly limited. For example, shader resource views and unordered
|
||||
access views are still entirely unsupported.
|
||||
|
||||
- Shader code generation for fixed-function fog. Like the existing shader code
|
||||
generation for other fixed-function features, this is mainly relevant for
|
||||
executing shader model 1-3 sources in modern target environments like
|
||||
Vulkan.
|
||||
|
||||
- The ‘fx’ parser can parse binary effects containing inline shader blobs.
|
||||
|
||||
- Internal validator support for validating I/O signatures, as well as I/O
|
||||
source and destination parameters. The validator is enabled by the
|
||||
‘force_validation’ option, specified through the VKD3D_SHADER_CONFIG
|
||||
environment variable.
|
||||
|
||||
- Internal validator support for validating the number of indices used with a
|
||||
register, as well as basic bounds checking for static indices.
|
||||
|
||||
- New interfaces:
|
||||
- The vkd3d_shader_scan_hull_shader_tessellation_info structure extends the
|
||||
vkd3d_shader_compile_info structure, and can be used to retrieve the
|
||||
output primitive type and partitioning mode used by a hull shader. This
|
||||
information is particularly useful for specifying
|
||||
vkd3d_shader_spirv_domain_shader_target_info structures when targetting
|
||||
SPIR-V in OpenGL environments.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_FOG_FRAGMENT_MODE shader parameter
|
||||
specifies the kind of fog to generate in a fragment shader.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_FOG_COLOUR shader parameter
|
||||
specifies the fog colour.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_FOG_END shader parameter
|
||||
specifies the ‘end’ parameter used for linear fog generation.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_FOG_SCALE shader parameter
|
||||
specifies the ‘scale’ parameter used for fog generation.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_FOG_SOURCE shader parameter
|
||||
specifies the kind of fog coordinate to output from a pre-rasterisation
|
||||
shader.
|
||||
|
||||
### vkd3d-compiler
|
||||
|
||||
- The new ‘dxbc-fx’ source type specifies an effect binary embedded in a DXBC
|
||||
container. This is a convenience feature;
|
||||
‘vkd3d-compiler -x dxbc-fx blob.dxbc’ is equivalent to
|
||||
‘vkd3d-dxbc -x t:FX10 blob.dxbc | vkd3d-compiler -x fx’.
|
||||
|
||||
# What's new in vkd3d 1.14 (21 November 2024)
|
||||
|
||||
### libvkd3d
|
||||
|
||||
- Depth bounds can be changed dynamically using the OMSetDepthBounds() method
|
||||
of the ID3D12GraphicsCommandList1 interface.
|
||||
|
||||
- The new VKD3D_CAPS_OVERRIDE environment variable can be used to override the
|
||||
value of capabilities like the maximum feature level and resource binding
|
||||
tier reported to applications.
|
||||
|
||||
### libvkd3d-shader
|
||||
|
||||
- New features for the HLSL source type:
|
||||
- Interstage I/O variable packing matches d3dcompiler/fxc more closely.
|
||||
- The following intrinsic functions are supported:
|
||||
- dst()
|
||||
- f32tof16()
|
||||
- mad()
|
||||
- modf()
|
||||
- sincos()
|
||||
- ‘discard’ support for shader model 1-3 target profiles.
|
||||
- The ‘SV_SampleIndex’ input semantic for fragment shaders.
|
||||
- The ‘SV_GroupIndex’ input semantic for compute shaders.
|
||||
- The ‘earlydepthstencil’ function attribute.
|
||||
- Constant folding of expressions like ‘x && c’ and ‘x || c’, where ‘c’ is a
|
||||
constant.
|
||||
- Preprocessor support for namespaces in macro identifiers. I.e., syntax
|
||||
like ‘#define NAME1::NAME2::NAME3 1’ works as intended now.
|
||||
- Structure inheritance. Multiple inheritance is not supported.
|
||||
- Register assignments for unused constant buffers are allowed to overlap
|
||||
register assignments for used constant buffers.
|
||||
- Instruction count reflection data for shader model 4+ target profiles.
|
||||
This data is contained in the ‘STAT’ DXBC section, and can be queried with
|
||||
the GetDesc() method of the ID3D11ShaderReflection and
|
||||
ID3D12ShaderReflection interfaces. Note that the ID3D12ShaderReflection
|
||||
implementation provided by vkd3d-utils does not currently correctly report
|
||||
this information.
|
||||
- ‘unorm’ and ‘snorm’ resource format modifiers. For example,
|
||||
‘Texture2D<unorm float4> t;’
|
||||
- Parser support for ‘ByteAddressBuffer’ resources, as well as their
|
||||
Load()/Load2()/Load3()/Load4() methods.
|
||||
- Parser support for ‘RWByteAddressBuffer’ resources, as well as their
|
||||
Store()/Store2()/Store3()/Store4() methods.
|
||||
- Parser support for the ‘compile’ keyword, as well as the CompileShader()
|
||||
and ConstructGSWithSO() intrinsic functions. Actual compilation of
|
||||
embedded shaders is not implemented yet, but parser support is sufficient
|
||||
for allowing compilation of HLSL sources containing this syntax to succeed
|
||||
when targetting shader target profiles like ‘vs_5_0’ or ‘ps_5_0’.
|
||||
- Initial support for tessellation shaders. Only the most trivial shaders
|
||||
are supported in this release. Perhaps most notably, both ‘InputPatch’ and
|
||||
‘OutputPatch’ are not implemented yet.
|
||||
|
||||
- The new ‘fx’ source type can be used in combination with the ‘d3d-asm’
|
||||
target type to disassemble binary effects.
|
||||
|
||||
- More complete support for fx_2_0 binary effect output, including support for
|
||||
annotations, default values, as well as object initialiser data used for e.g.
|
||||
string, texture, and shader objects.
|
||||
|
||||
- A significant number of instructions have been implemented for the
|
||||
experimental GLSL target. The GLSL output currently targets version 4.40
|
||||
without extensions, but the intention is to make this configurable in a
|
||||
future release of vkd3d.
|
||||
|
||||
- Experimental support for Metal Shading Language (MSL) output, enabled by
|
||||
building vkd3d with the ‘-DVKD3D_SHADER_UNSUPPORTED_MSL’ preprocessor
|
||||
option. The current release is only able to compile the most basic shaders
|
||||
when targetting MSL. Being an experimental feature, both the ABI and API may
|
||||
change in future releases; the feature may even go away completely.
|
||||
Nevertheless, we hope our users find this feature useful, and welcome
|
||||
feedback and contributions.
|
||||
|
||||
- Shader code generation for various legacy fixed-function features, including
|
||||
clip planes, point sizes, and point sprites. This is mainly relevant for
|
||||
executing shader model 1-3 sources in modern target environments like
|
||||
Vulkan, because those target environments do not implement equivalent
|
||||
fixed-function features.
|
||||
|
||||
- The amount of shader validation done by the internal validator has been
|
||||
greatly extended. The validator is enabled by the ‘force_validation’ option,
|
||||
specified through the VKD3D_SHADER_CONFIG environment variable.
|
||||
|
||||
- New interfaces:
|
||||
- The VKD3D_SHADER_COMPILE_OPTION_DOUBLE_AS_FLOAT_ALIAS flag specifies that
|
||||
the ‘double’ type behaves as an alias for the ‘float’ type in HLSL sources
|
||||
with shader model 1-3 target profiles.
|
||||
- The VKD3D_SHADER_PARAMETER_DATA_TYPE_FLOAT32_VEC4 enumeration value
|
||||
specifies that a shader parameter contains a 4-dimensional vector of
|
||||
32-bit floating-point data.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_CLIP_PLANE_MASK shader parameter specifies
|
||||
which clip planes are enabled.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_CLIP_PLANE_[0-7] shader parameters specify
|
||||
the corresponding clip planes.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE shader parameter specifies the
|
||||
point size to output when the source shader does not explicitly output a
|
||||
point size.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE_MIN shader parameter specifies
|
||||
the minimum point size to clamp point size outputs to.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_POINT_SIZE_MAX shader parameter specifies
|
||||
the maximum point size to clamp point size outputs to.
|
||||
- The VKD3D_SHADER_PARAMETER_NAME_POINT_SPRITE shader parameter specifies
|
||||
whether texture coordinate inputs in fragment shaders should be replaced
|
||||
with point coordinates.
|
||||
- The VKD3D_SHADER_SOURCE_FX source type specifies binary Direct3D effects.
|
||||
- The VKD3D_SHADER_TARGET_MSL target type specifies Metal Shading Language
|
||||
shaders.
|
||||
|
||||
### libvkd3d-utils
|
||||
|
||||
- The GetDesc() method of the ID3D12ShaderReflection interface returned by
|
||||
D3DReflect() returns shader version information.
|
||||
|
||||
- New interfaces:
|
||||
- D3DCompile2VKD3D() is a variant of D3DCompile2() that allows targeting the
|
||||
behaviour of a specific d3dcompiler version.
|
||||
|
||||
### vkd3d-compiler
|
||||
|
||||
- The ‘--alias-double-as-float’ option specifies that the ‘double’ type
|
||||
behaves as an alias for the ‘float’ type in HLSL sources with shader model
|
||||
1-3 target profiles.
|
||||
|
||||
- The ‘fx’ source type specifies binary Direct3D effects.
|
||||
|
||||
- The ‘msl’ target type specifies Metal Shading Language shaders.
|
||||
|
||||
# What's new in vkd3d 1.13 (29 August 2024)
|
||||
|
||||
### libvkd3d
|
||||
|
@@ -10,6 +10,7 @@ OPTIMIZE_OUTPUT_FOR_C = YES
|
||||
EXTRACT_STATIC = YES
|
||||
QUIET = YES
|
||||
WARN_IF_UNDOCUMENTED = NO
|
||||
WARN_IF_INCOMPLETE_DOC = NO
|
||||
LATEX_BATCHMODE = YES
|
||||
|
||||
INPUT = @srcdir@/include/vkd3d.h \
|
||||
|
146
Makefile.am
146
Makefile.am
@@ -2,6 +2,12 @@ ACLOCAL_AMFLAGS = -I m4
|
||||
AM_CFLAGS = @VKD3D_CFLAGS@
|
||||
AM_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/private -I$(builddir)/include/private
|
||||
AM_LDFLAGS = -no-undefined
|
||||
VKD3D_PERL = $(PERL) -w
|
||||
|
||||
objc_headers = \
|
||||
include/private/appkit.h \
|
||||
include/private/foundation.h \
|
||||
include/private/quartzcore.h
|
||||
|
||||
widl_headers = \
|
||||
include/vkd3d_d3d12.h \
|
||||
@@ -50,7 +56,6 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/all.shader_test \
|
||||
tests/hlsl/alpha-test.shader_test \
|
||||
tests/hlsl/angle-unit.shader_test \
|
||||
tests/hlsl/annotations.shader_test \
|
||||
tests/hlsl/any.shader_test \
|
||||
tests/hlsl/arithmetic-float-uniform.shader_test \
|
||||
tests/hlsl/arithmetic-float.shader_test \
|
||||
@@ -64,6 +69,7 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/asint.shader_test \
|
||||
tests/hlsl/asuint.shader_test \
|
||||
tests/hlsl/attributes.shader_test \
|
||||
tests/hlsl/barriers.shader_test \
|
||||
tests/hlsl/bitwise-assignment.shader_test \
|
||||
tests/hlsl/bitwise.shader_test \
|
||||
tests/hlsl/bool-cast.shader_test \
|
||||
@@ -81,25 +87,35 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/ceil.shader_test \
|
||||
tests/hlsl/cf-cond-types.shader_test \
|
||||
tests/hlsl/clamp.shader_test \
|
||||
tests/hlsl/clip-distance.shader_test \
|
||||
tests/hlsl/clip-cull-distance.shader_test \
|
||||
tests/hlsl/clip-planes.shader_test \
|
||||
tests/hlsl/clip.shader_test \
|
||||
tests/hlsl/combined-samplers.shader_test \
|
||||
tests/hlsl/comma.shader_test \
|
||||
tests/hlsl/compute.shader_test \
|
||||
tests/hlsl/conditional.shader_test \
|
||||
tests/hlsl/const.shader_test \
|
||||
tests/hlsl/constructgswithso.shader_test \
|
||||
tests/hlsl/coverage.shader_test \
|
||||
tests/hlsl/cross.shader_test \
|
||||
tests/hlsl/d3dcolor-to-ubyte4.shader_test \
|
||||
tests/hlsl/ddxddy.shader_test \
|
||||
tests/hlsl/default-values.shader_test \
|
||||
tests/hlsl/depth-bounds.shader_test \
|
||||
tests/hlsl/depth-out.shader_test \
|
||||
tests/hlsl/determinant.shader_test \
|
||||
tests/hlsl/discard.shader_test \
|
||||
tests/hlsl/distance.shader_test \
|
||||
tests/hlsl/dot.shader_test \
|
||||
tests/hlsl/duplicate-modifiers.shader_test \
|
||||
tests/hlsl/early-depth-stencil.shader_test \
|
||||
tests/hlsl/effect-annotations-fx_2.shader_test \
|
||||
tests/hlsl/effect-annotations-fx_4.shader_test \
|
||||
tests/hlsl/effect-assignments-fx_5.shader_test \
|
||||
tests/hlsl/effect-compile.shader_test \
|
||||
tests/hlsl/effect-initial-values-fx_2.shader_test \
|
||||
tests/hlsl/effect-initial-values-fx_4.shader_test \
|
||||
tests/hlsl/effect-pass-states-fx_4.shader_test \
|
||||
tests/hlsl/effect-pass-states-fx_5.shader_test \
|
||||
tests/hlsl/effect-shader-objects-fx_2.shader_test \
|
||||
tests/hlsl/effect-shader-objects-fx_5.shader_test \
|
||||
@@ -108,15 +124,20 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/effect-technique-fx_5.shader_test \
|
||||
tests/hlsl/effect-variables-fx_2.shader_test \
|
||||
tests/hlsl/effect-variables-fx_4.shader_test \
|
||||
tests/hlsl/effect-variables-fx_4_1.shader_test \
|
||||
tests/hlsl/effect-variables-fx_5.shader_test \
|
||||
tests/hlsl/entry-point-semantics.shader_test \
|
||||
tests/hlsl/eval-attrib.shader_test \
|
||||
tests/hlsl/exp.shader_test \
|
||||
tests/hlsl/expr-indexing.shader_test \
|
||||
tests/hlsl/f16tof32.shader_test \
|
||||
tests/hlsl/f32tof16.shader_test \
|
||||
tests/hlsl/faceforward.shader_test \
|
||||
tests/hlsl/ffp-point-size.shader_test \
|
||||
tests/hlsl/float-comparison.shader_test \
|
||||
tests/hlsl/floor.shader_test \
|
||||
tests/hlsl/fmod.shader_test \
|
||||
tests/hlsl/fog.shader_test \
|
||||
tests/hlsl/for.shader_test \
|
||||
tests/hlsl/frac.shader_test \
|
||||
tests/hlsl/function-cast.shader_test \
|
||||
@@ -125,13 +146,17 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/function.shader_test \
|
||||
tests/hlsl/fwidth.shader_test \
|
||||
tests/hlsl/fxgroup-syntax.shader_test \
|
||||
tests/hlsl/gather-cmp.shader_test \
|
||||
tests/hlsl/gather-offset.shader_test \
|
||||
tests/hlsl/gather.shader_test \
|
||||
tests/hlsl/geometry-shader-syntax.shader_test \
|
||||
tests/hlsl/geometry.shader_test \
|
||||
tests/hlsl/get-sample-pos.shader_test \
|
||||
tests/hlsl/getdimensions.shader_test \
|
||||
tests/hlsl/half.shader_test \
|
||||
tests/hlsl/hard-copy-prop.shader_test \
|
||||
tests/hlsl/hull-shader-attributes.shader_test \
|
||||
tests/hlsl/hull-shader-syntax.shader_test \
|
||||
tests/hlsl/initializer-flatten.shader_test \
|
||||
tests/hlsl/initializer-implicit-array.shader_test \
|
||||
tests/hlsl/initializer-invalid-arg-count.shader_test \
|
||||
@@ -144,13 +169,18 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/initializer-static-array.shader_test \
|
||||
tests/hlsl/initializer-struct.shader_test \
|
||||
tests/hlsl/instance-id.shader_test \
|
||||
tests/hlsl/interface-packing.shader_test \
|
||||
tests/hlsl/intrinsic-override.shader_test \
|
||||
tests/hlsl/invalid.shader_test \
|
||||
tests/hlsl/inverse-trig.shader_test \
|
||||
tests/hlsl/is-front-face.shader_test \
|
||||
tests/hlsl/isinf.shader_test \
|
||||
tests/hlsl/ldexp.shader_test \
|
||||
tests/hlsl/length-property.shader_test \
|
||||
tests/hlsl/length.shader_test \
|
||||
tests/hlsl/lerp.shader_test \
|
||||
tests/hlsl/lhs-cast.shader_test \
|
||||
tests/hlsl/lhs-partial-assignment.shader_test \
|
||||
tests/hlsl/lit.shader_test \
|
||||
tests/hlsl/load-level.shader_test \
|
||||
tests/hlsl/log.shader_test \
|
||||
@@ -164,10 +194,12 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/matrix-semantics.shader_test \
|
||||
tests/hlsl/max-min.shader_test \
|
||||
tests/hlsl/minimum-precision.shader_test \
|
||||
tests/hlsl/modf.shader_test \
|
||||
tests/hlsl/mul.shader_test \
|
||||
tests/hlsl/multiple-rt.shader_test \
|
||||
tests/hlsl/nested-arrays.shader_test \
|
||||
tests/hlsl/nointerpolation.shader_test \
|
||||
tests/hlsl/noise.shader_test \
|
||||
tests/hlsl/non-const-indexing.shader_test \
|
||||
tests/hlsl/normalize.shader_test \
|
||||
tests/hlsl/null.shader_test \
|
||||
@@ -177,9 +209,14 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/object-field-offsets.shader_test \
|
||||
tests/hlsl/object-parameters.shader_test \
|
||||
tests/hlsl/object-references.shader_test \
|
||||
tests/hlsl/patch-syntax.shader_test \
|
||||
tests/hlsl/pixel-position.shader_test \
|
||||
tests/hlsl/point-sprite.shader_test \
|
||||
tests/hlsl/pointer-cast.shader_test \
|
||||
tests/hlsl/pow.shader_test \
|
||||
tests/hlsl/precise-modifier.shader_test \
|
||||
tests/hlsl/primitive-id.shader_test \
|
||||
tests/hlsl/ps1-sampler.shader_test \
|
||||
tests/hlsl/rasteriser-ordered-views.shader_test \
|
||||
tests/hlsl/rcp.shader_test \
|
||||
tests/hlsl/reflect.shader_test \
|
||||
@@ -189,29 +226,39 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/register-reservations-resources.shader_test \
|
||||
tests/hlsl/register-reservations-space.shader_test \
|
||||
tests/hlsl/return-implicit-conversion.shader_test \
|
||||
tests/hlsl/return-semantics.shader_test \
|
||||
tests/hlsl/return.shader_test \
|
||||
tests/hlsl/round.shader_test \
|
||||
tests/hlsl/rt-array-index.shader_test \
|
||||
tests/hlsl/rt-format-mismatch.shader_test \
|
||||
tests/hlsl/rt-get-sample-info.shader_test \
|
||||
tests/hlsl/sample-bias.shader_test \
|
||||
tests/hlsl/sample-cmp.shader_test \
|
||||
tests/hlsl/sample-grad.shader_test \
|
||||
tests/hlsl/sample-level.shader_test \
|
||||
tests/hlsl/sampler-offset.shader_test \
|
||||
tests/hlsl/sampler-state.shader_test \
|
||||
tests/hlsl/sampler.shader_test \
|
||||
tests/hlsl/saturate.shader_test \
|
||||
tests/hlsl/scope.shader_test \
|
||||
tests/hlsl/semantic-cascading.shader_test \
|
||||
tests/hlsl/shade-mode.shader_test \
|
||||
tests/hlsl/shader-interstage-interface.shader_test \
|
||||
tests/hlsl/shader-point-size.shader_test \
|
||||
tests/hlsl/shape.shader_test \
|
||||
tests/hlsl/side-effects.shader_test \
|
||||
tests/hlsl/sign.shader_test \
|
||||
tests/hlsl/single-numeric-initializer.shader_test \
|
||||
tests/hlsl/sm1-const-allocation.shader_test \
|
||||
tests/hlsl/sm1-const-folding.shader_test \
|
||||
tests/hlsl/sm1-interstage-interface.shader_test \
|
||||
tests/hlsl/sm6-ternary.shader_test \
|
||||
tests/hlsl/sm6-uav-rwtexture.shader_test \
|
||||
tests/hlsl/smoothstep.shader_test \
|
||||
tests/hlsl/sqrt.shader_test \
|
||||
tests/hlsl/srv-buffers.shader_test \
|
||||
tests/hlsl/srv-byteaddressbuffer.shader_test \
|
||||
tests/hlsl/srv-structuredbuffer.shader_test \
|
||||
tests/hlsl/state-block-function-syntax.shader_test \
|
||||
tests/hlsl/state-block-syntax.shader_test \
|
||||
tests/hlsl/static-initializer.shader_test \
|
||||
@@ -220,12 +267,15 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/strings.shader_test \
|
||||
tests/hlsl/struct-array.shader_test \
|
||||
tests/hlsl/struct-assignment.shader_test \
|
||||
tests/hlsl/struct-inheritance.shader_test \
|
||||
tests/hlsl/struct-semantics.shader_test \
|
||||
tests/hlsl/struct-syntax.shader_test \
|
||||
tests/hlsl/switch.shader_test \
|
||||
tests/hlsl/swizzle-constant-prop.shader_test \
|
||||
tests/hlsl/swizzle-matrix.shader_test \
|
||||
tests/hlsl/swizzles.shader_test \
|
||||
tests/hlsl/ternary.shader_test \
|
||||
tests/hlsl/tessellation-patch-vars.shader_test \
|
||||
tests/hlsl/tessellation.shader_test \
|
||||
tests/hlsl/texture-load-offset.shader_test \
|
||||
tests/hlsl/texture-load-typed.shader_test \
|
||||
@@ -247,11 +297,14 @@ vkd3d_shader_tests = \
|
||||
tests/hlsl/unbounded-array-5.1.shader_test \
|
||||
tests/hlsl/uniform-parameters.shader_test \
|
||||
tests/hlsl/uniform-semantics.shader_test \
|
||||
tests/hlsl/uninitialized-varyings.shader_test \
|
||||
tests/hlsl/unorm-snorm.shader_test \
|
||||
tests/hlsl/unroll.shader_test \
|
||||
tests/hlsl/unsigned.shader_test \
|
||||
tests/hlsl/vector-indexing-uniform.shader_test \
|
||||
tests/hlsl/vector-indexing.shader_test \
|
||||
tests/hlsl/vertex-shader-ops.shader_test \
|
||||
tests/hlsl/vp-array-index.shader_test \
|
||||
tests/hlsl/wave-ops-float.shader_test \
|
||||
tests/hlsl/wave-ops-int.shader_test \
|
||||
tests/hlsl/wave-ops-uint.shader_test \
|
||||
@@ -273,18 +326,24 @@ vkd3d_test_headers = \
|
||||
tests/dxcompiler.h \
|
||||
tests/shader_runner.h \
|
||||
tests/utils.h \
|
||||
tests/vulkan_procs.h
|
||||
tests/vulkan_procs.h \
|
||||
tests/vulkan_utils.h
|
||||
|
||||
vkd3d_demos = \
|
||||
demos/vkd3d-gears \
|
||||
demos/vkd3d-teapot \
|
||||
demos/vkd3d-triangle
|
||||
|
||||
vkd3d_demos_headers = \
|
||||
demos/demo.h \
|
||||
demos/demo_d3d12.h \
|
||||
demos/demo_macos.h \
|
||||
demos/demo_vkd3d.h \
|
||||
demos/demo_win32.h \
|
||||
demos/demo_xcb.h
|
||||
|
||||
BUILT_SOURCES = $(widl_headers) \
|
||||
BUILT_SOURCES = $(objc_headers) $(widl_headers) \
|
||||
include/private/spirv_grammar.h \
|
||||
include/private/vkd3d_version.h
|
||||
|
||||
noinst_LTLIBRARIES = libvkd3d-common.la
|
||||
@@ -343,6 +402,7 @@ nodist_libvkd3d_shader_la_SOURCES = $(vkd3d_shader_yyfiles)
|
||||
libvkd3d_shader_la_SOURCES = \
|
||||
include/private/list.h \
|
||||
include/private/rbtree.h \
|
||||
include/private/spirv_grammar.h \
|
||||
include/private/vkd3d_common.h \
|
||||
include/private/vkd3d_memory.h \
|
||||
include/vkd3d_shader.h \
|
||||
@@ -358,6 +418,7 @@ libvkd3d_shader_la_SOURCES = \
|
||||
libs/vkd3d-shader/hlsl_codegen.c \
|
||||
libs/vkd3d-shader/hlsl_constant_ops.c \
|
||||
libs/vkd3d-shader/ir.c \
|
||||
libs/vkd3d-shader/msl.c \
|
||||
libs/vkd3d-shader/preproc.h \
|
||||
libs/vkd3d-shader/spirv.c \
|
||||
libs/vkd3d-shader/tpf.c \
|
||||
@@ -365,7 +426,7 @@ libvkd3d_shader_la_SOURCES = \
|
||||
libs/vkd3d-shader/vkd3d_shader_main.c \
|
||||
libs/vkd3d-shader/vkd3d_shader_private.h
|
||||
libvkd3d_shader_la_CFLAGS = $(AM_CFLAGS) -DLIBVKD3D_SHADER_SOURCE -I$(srcdir)/libs/vkd3d-shader @SPIRV_TOOLS_CFLAGS@
|
||||
libvkd3d_shader_la_LDFLAGS = $(AM_LDFLAGS) -version-info 12:0:11
|
||||
libvkd3d_shader_la_LDFLAGS = $(AM_LDFLAGS) -version-info 16:0:15
|
||||
libvkd3d_shader_la_LIBADD = libvkd3d-common.la @SPIRV_TOOLS_LIBS@ -lm
|
||||
if HAVE_LD_VERSION_SCRIPT
|
||||
libvkd3d_shader_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d-shader/vkd3d_shader.map
|
||||
@@ -400,7 +461,7 @@ libvkd3d_la_SOURCES = \
|
||||
libs/vkd3d/vkd3d_shaders.h \
|
||||
libs/vkd3d/vulkan_procs.h
|
||||
libvkd3d_la_CFLAGS = $(AM_CFLAGS) -DLIBVKD3D_SOURCE
|
||||
libvkd3d_la_LDFLAGS = $(AM_LDFLAGS) -version-info 14:0:13
|
||||
libvkd3d_la_LDFLAGS = $(AM_LDFLAGS) -version-info 18:0:17
|
||||
libvkd3d_la_LIBADD = libvkd3d-common.la libvkd3d-shader.la @DL_LIBS@ @PTHREAD_LIBS@
|
||||
if HAVE_LD_VERSION_SCRIPT
|
||||
libvkd3d_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d/vkd3d.map
|
||||
@@ -413,7 +474,7 @@ libvkd3d_utils_la_SOURCES = \
|
||||
libs/vkd3d-utils/vkd3d_utils_main.c \
|
||||
libs/vkd3d-utils/vkd3d_utils_private.h
|
||||
libvkd3d_utils_la_CFLAGS = $(AM_CFLAGS) -DLIBVKD3D_UTILS_SOURCE
|
||||
libvkd3d_utils_la_LDFLAGS = $(AM_LDFLAGS) -version-info 6:2:5
|
||||
libvkd3d_utils_la_LDFLAGS = $(AM_LDFLAGS) -version-info 7:3:6
|
||||
libvkd3d_utils_la_LIBADD = libvkd3d-common.la libvkd3d-shader.la libvkd3d.la @PTHREAD_LIBS@
|
||||
if HAVE_LD_VERSION_SCRIPT
|
||||
libvkd3d_utils_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d-utils/vkd3d_utils.map
|
||||
@@ -445,15 +506,20 @@ LDADD = libvkd3d.la libvkd3d-shader.la libvkd3d-utils.la
|
||||
AM_DEFAULT_SOURCE_EXT = .c
|
||||
|
||||
TEST_EXTENSIONS = .shader_test
|
||||
TEST_CPPFLAGS = -I$(builddir)/tests
|
||||
|
||||
if BUILD_TESTS
|
||||
check_PROGRAMS = $(vkd3d_tests) $(vkd3d_cross_tests) tests/shader_runner
|
||||
dist_check_SCRIPTS = tests/test-driver.sh
|
||||
TESTS = $(vkd3d_tests) $(vkd3d_cross_tests) $(vkd3d_shader_tests)
|
||||
tests_d3d12_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||
tests_d3d12_LDADD = $(LDADD) @PTHREAD_LIBS@ @DL_LIBS@
|
||||
tests_d3d12_invalid_usage_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||
tests_d3d12_invalid_usage_LDADD = $(LDADD) @DL_LIBS@
|
||||
tests_hlsl_d3d12_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||
tests_hlsl_d3d12_LDADD = $(LDADD) @DL_LIBS@
|
||||
tests_shader_runner_CFLAGS = $(AM_CFLAGS) -I$(builddir)/tests @OPENGL_CFLAGS@
|
||||
tests_shader_runner_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||
tests_shader_runner_CFLAGS = $(AM_CFLAGS) @OPENGL_CFLAGS@
|
||||
tests_shader_runner_LDADD = $(LDADD) @OPENGL_LIBS@ @DL_LIBS@
|
||||
tests_shader_runner_SOURCES = \
|
||||
tests/shader_runner.c \
|
||||
@@ -462,9 +528,18 @@ tests_shader_runner_SOURCES = \
|
||||
tests/shader_runner_d3d12.c \
|
||||
tests/shader_runner_gl.c \
|
||||
tests/shader_runner_vulkan.c
|
||||
if HAVE_METAL
|
||||
tests_shader_runner_OBJCFLAGS = $(AM_CFLAGS)
|
||||
tests_shader_runner_SOURCES += tests/shader_runner_metal.m
|
||||
tests_shader_runner_LINK = $(OBJCLINK) -framework Foundation -framework Metal
|
||||
else
|
||||
tests_shader_runner_LINK = $(LINK)
|
||||
endif
|
||||
tests_vkd3d_api_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||
tests_vkd3d_api_LDADD = libvkd3d.la @DL_LIBS@
|
||||
tests_vkd3d_shader_api_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||
tests_vkd3d_shader_api_CFLAGS = $(AM_CFLAGS) @OPENGL_CFLAGS@
|
||||
tests_vkd3d_shader_api_LDADD = libvkd3d-shader.la @OPENGL_LIBS@
|
||||
tests_vkd3d_shader_api_LDADD = libvkd3d-shader.la @OPENGL_LIBS@ @DL_LIBS@
|
||||
SHADER_TEST_LOG_COMPILER = tests/shader_runner
|
||||
SHADER_TEST_LOG_DRIVER = $(srcdir)/tests/test-driver.sh
|
||||
endif
|
||||
@@ -472,20 +547,45 @@ endif
|
||||
EXTRA_DIST += $(vkd3d_shader_tests)
|
||||
|
||||
if BUILD_DEMOS
|
||||
DEMOS_LDADD = $(LDADD) libvkd3d-shader.la @DL_LIBS@ @DEMO_LIBS@
|
||||
DEMOS_CFLAGS = $(AM_CFLAGS) @DEMO_CFLAGS@
|
||||
DEMOS_LDADD = $(LDADD) @DL_LIBS@ @DEMO_LIBS@
|
||||
DEMOS_CFLAGS = $(AM_CFLAGS) @DEMO_CFLAGS@ -I$(srcdir)/demos -Wa,-I$(srcdir)/demos
|
||||
bin_PROGRAMS += $(vkd3d_demos)
|
||||
|
||||
demos_vkd3d_gears_SOURCES = demos/gears.c demos/gears_hlsl.h
|
||||
demos_vkd3d_gears_SOURCES = demos/gears.c demos/gears.hlsl
|
||||
demos_vkd3d_gears_CFLAGS = $(DEMOS_CFLAGS)
|
||||
demos_vkd3d_gears_LDADD = $(DEMOS_LDADD) -lm
|
||||
demos/vkd3d_gears-gears.$(OBJEXT): demos/gears.hlsl
|
||||
|
||||
demos_vkd3d_triangle_SOURCES = demos/triangle.c demos/triangle_hlsl.h
|
||||
teapot_shaders = \
|
||||
demos/teapot.hlsl \
|
||||
demos/text.hlsl
|
||||
demos_vkd3d_teapot_SOURCES = \
|
||||
$(teapot_shaders) \
|
||||
demos/etl16-unicode.h \
|
||||
demos/teapot.c \
|
||||
demos/teapot.h
|
||||
demos_vkd3d_teapot_CFLAGS = $(DEMOS_CFLAGS)
|
||||
demos_vkd3d_teapot_LDADD = $(DEMOS_LDADD) -lm
|
||||
demos/vkd3d_teapot-teapot.$(OBJEXT): $(teapot_shaders)
|
||||
|
||||
demos_vkd3d_triangle_SOURCES = demos/triangle.c demos/triangle.hlsl
|
||||
demos_vkd3d_triangle_CFLAGS = $(DEMOS_CFLAGS)
|
||||
demos_vkd3d_triangle_LDADD = $(DEMOS_LDADD)
|
||||
demos/vkd3d_triangle-triangle.$(OBJEXT): demos/triangle.hlsl
|
||||
endif
|
||||
|
||||
noinst_HEADERS = $(vkd3d_test_headers) $(vkd3d_demos_headers)
|
||||
dist_noinst_SCRIPTS = libs/vkd3d-shader/make_spirv demos/make_objc
|
||||
|
||||
VKD3D_V_PERL = $(vkd3d_v_perl_@AM_V@)
|
||||
vkd3d_v_perl_ = $(vkd3d_v_perl_@AM_DEFAULT_V@)
|
||||
vkd3d_v_perl_0 = @echo " PERL " $@;
|
||||
vkd3d_v_perl_1 =
|
||||
|
||||
CLEANFILES += $(objc_headers)
|
||||
${objc_headers}: %.h: demos/make_objc %.json
|
||||
@$(MKDIR_P) $(@D)
|
||||
$(VKD3D_V_PERL)$(VKD3D_PERL) $^ > $@.tmp && mv $@.tmp $@
|
||||
|
||||
VKD3D_V_WIDL = $(vkd3d_v_widl_@AM_V@)
|
||||
vkd3d_v_widl_ = $(vkd3d_v_widl_@AM_DEFAULT_V@)
|
||||
@@ -495,7 +595,11 @@ vkd3d_v_widl_1 =
|
||||
if HAVE_WIDL
|
||||
CLEANFILES += $(widl_headers)
|
||||
endif
|
||||
EXTRA_DIST += $(widl_headers) $(widl_headers:.h=.idl)
|
||||
EXTRA_DIST += \
|
||||
$(widl_headers) \
|
||||
$(widl_headers:.h=.idl) \
|
||||
$(objc_headers:.h=.json) \
|
||||
include/private/spirv.core.grammar.json
|
||||
$(widl_headers): %.h: %.idl
|
||||
if HAVE_WIDL
|
||||
$(VKD3D_V_WIDL)$(WIDL) -I$(srcdir)/include -h -o $@ $<
|
||||
@@ -527,6 +631,10 @@ libvkd3d.pc: $(srcdir)/libs/vkd3d/libvkd3d.pc.in Makefile
|
||||
-e 's![@]PACKAGE_VERSION[@]!$(PACKAGE_VERSION)!g' \
|
||||
$< > $@
|
||||
|
||||
include/private/spirv_grammar.h: libs/vkd3d-shader/make_spirv include/private/spirv.core.grammar.json
|
||||
@$(MKDIR_P) $(@D)
|
||||
$(VKD3D_V_PERL)$(VKD3D_PERL) $^ > $@.tmp && mv $@.tmp $@
|
||||
|
||||
include/private/vkd3d_version.h: dummy-vkd3d-version
|
||||
@$(MKDIR_P) include/private
|
||||
version=`(GIT_DIR=$(top_srcdir)/.git git rev-parse --short HEAD 2>/dev/null || echo '') \
|
||||
@@ -535,7 +643,7 @@ include/private/vkd3d_version.h: dummy-vkd3d-version
|
||||
&& (echo $$version | cmp -s - $@) \
|
||||
|| echo $$version >$@ || ($(RM) $@ && exit 1)
|
||||
.SILENT: include/private/vkd3d_version.h
|
||||
CLEANFILES += include/private/vkd3d_version.h
|
||||
CLEANFILES += include/private/spirv_grammar.h include/private/vkd3d_version.h
|
||||
|
||||
.PHONY: dummy-vkd3d-version
|
||||
dummy-vkd3d-version:
|
||||
@@ -543,7 +651,7 @@ dummy-vkd3d-version:
|
||||
## Cross-compile tests
|
||||
cross_implibs = crosslibs/d3d12
|
||||
CROSS_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/private -I$(builddir)/include -I$(builddir)/tests
|
||||
CROSS_CFLAGS = -g -O2 -Wall -municode ${CROSS_CPPFLAGS} \
|
||||
CROSS_CFLAGS = -g -O2 -Wall -municode ${CROSS_CPPFLAGS} -Wa,-I$(srcdir)/demos \
|
||||
-D_WIN32_WINNT=0x0600 -D__USE_MINGW_ANSI_STDIO=0 -DVKD3D_CROSSTEST=1
|
||||
EXTRA_DIST += $(cross_implibs:=.cross32.def) $(cross_implibs:=.cross64.def)
|
||||
EXTRA_DIST += tests/driver.c tests/shader_runner_d3d11.c tests/shader_runner_d3d9.c
|
||||
@@ -567,6 +675,9 @@ CROSS32_EXEFILES += $(vkd3d_cross_tests:=.cross32.exe)
|
||||
endif
|
||||
if BUILD_DEMOS
|
||||
CROSS32_EXEFILES += $(vkd3d_demos:demos/vkd3d-%=demos/%.cross32.exe)
|
||||
demos/gears.cross32.exe: demos/gears.hlsl
|
||||
demos/teapot.cross32.exe: $(teapot_shaders)
|
||||
demos/triangle.cross32.exe: demos/triangle.hlsl
|
||||
endif
|
||||
|
||||
CROSS32_FILES = $(CROSS32_EXEFILES)
|
||||
@@ -614,6 +725,9 @@ CROSS64_EXEFILES += $(vkd3d_cross_tests:=.cross64.exe)
|
||||
endif
|
||||
if BUILD_DEMOS
|
||||
CROSS64_EXEFILES += $(vkd3d_demos:demos/vkd3d-%=demos/%.cross64.exe)
|
||||
demos/gears.cross64.exe: demos/gears.hlsl
|
||||
demos/teapot.cross64.exe: $(teapot_shaders)
|
||||
demos/triangle.cross64.exe: demos/triangle.hlsl
|
||||
endif
|
||||
|
||||
CROSS64_FILES = $(CROSS64_EXEFILES)
|
||||
|
79
README
79
README
@@ -9,7 +9,8 @@ similar, but not identical, to Direct3D 12.
|
||||
Building vkd3d
|
||||
==============
|
||||
|
||||
Vkd3d depends on SPIRV-Headers and Vulkan-Headers (>= 1.3.228).
|
||||
Vkd3d depends on SPIRV-Headers and Vulkan-Headers (>= 1.3.228), as well as Perl
|
||||
and libjson-perl.
|
||||
|
||||
Vkd3d generates some of its headers from IDL files. If you are using the
|
||||
release tarballs, then these headers are pre-generated and are included. If
|
||||
@@ -19,10 +20,20 @@ available or is not recent (>= 3.21), then you can build Wine with `make
|
||||
tools/widl/widl' to avoid building all of Wine. You can then point vkd3d's
|
||||
configure at that widl binary with `WIDL="/path/to/widl"'.
|
||||
|
||||
For release builds, you may want to define NDEBUG. If you do not need debug log
|
||||
messages, you may also consider VKD3D_NO_TRACE_MESSAGES and
|
||||
VKD3D_NO_DEBUG_MESSAGES. For example, you can pass `CPPFLAGS="-DNDEBUG
|
||||
-DVKD3D_NO_TRACE_MESSAGES"' to configure.
|
||||
For release builds, you may want to disable debug log messages defining
|
||||
preprocessor macros VKD3D_NO_TRACE_MESSAGES and VKD3D_NO_DEBUG_MESSAGES.
|
||||
See the `Preprocessor definitions' section below for more details.
|
||||
|
||||
================
|
||||
Developing vkd3d
|
||||
================
|
||||
|
||||
Development of vkd3d happens on the Wine GitLab instance
|
||||
(https://gitlab.winehq.org/wine/vkd3d/). Contributors are encouraged
|
||||
to submit their patches using the merge request tool.
|
||||
|
||||
Each merge request is automatically tested with the GitLab CI
|
||||
system. See gitlab/README in the Git tree for more details.
|
||||
|
||||
===========
|
||||
Using vkd3d
|
||||
@@ -39,8 +50,8 @@ Environment variables
|
||||
=====================
|
||||
|
||||
Most of the environment variables used by vkd3d are for debugging purposes. The
|
||||
environment variables are not considered a part of API and might be changed or
|
||||
removed in the future versions of vkd3d.
|
||||
environment variables are not considered a stable interface and might be changed
|
||||
or removed in future versions of vkd3d.
|
||||
|
||||
Some of debug variables are lists of elements. Elements must be separated by
|
||||
commas or semicolons.
|
||||
@@ -65,6 +76,14 @@ commas or semicolons.
|
||||
* VKD3D_DISABLE_EXTENSIONS - a list of Vulkan extensions that libvkd3d should
|
||||
not use even if available.
|
||||
|
||||
* VKD3D_CAPS_OVERRIDE - a list of Direct3D 12 capabilities for which the
|
||||
default value detected by vkd3d should be overridden, in the form
|
||||
`capability1=value1,capability2=value2'. This doesn't change the vkd3d
|
||||
behaviour, only the information reported to the application. The following
|
||||
capabilities can currently be overridden:
|
||||
* feature_level (allowed values: 11.0, 11.1, 12.0, 12.1, 12.2)
|
||||
* resource_binding_tier (allowed values: 1, 2, 3)
|
||||
|
||||
* VKD3D_SHADER_CONFIG - a list of options that change the behavior of
|
||||
libvkd3d-shader.
|
||||
* force_validation - Enable (additional) validation of libvkd3d-shader's
|
||||
@@ -105,16 +124,46 @@ code for adding DXBC checksums, so the official release should be installed
|
||||
from:
|
||||
https://github.com/microsoft/DirectXShaderCompiler/releases
|
||||
|
||||
================
|
||||
Developing vkd3d
|
||||
================
|
||||
========================
|
||||
Preprocessor definitions
|
||||
========================
|
||||
|
||||
Development of vkd3d happens on the Wine GitLab instance
|
||||
(https://gitlab.winehq.org/wine/vkd3d/). Contributors are encouraged
|
||||
to submit their patches using the merge request tool.
|
||||
A number of preprocessor definitions can be used at compilation time to control
|
||||
the behaviour of the generated binary. You can pass something like
|
||||
`CPPFLAGS="-DVKD3D_VAR1 -DVKD3D_VAR2"' to the configure script. The preprocessor
|
||||
variables are not considered a stable interface and might be changed or removed
|
||||
in future versions of vkd3d.
|
||||
|
||||
Each merge request is automatically tested with the GitLab CI
|
||||
system. See gitlab/README in the Git tree for more details.
|
||||
* VKD3D_NO_TRACE_MESSAGES - do not emit trace messages in the debug log; this
|
||||
can be useful in release builds to reduce the size of the binary and make it
|
||||
slightly faster.
|
||||
|
||||
* VKD3D_NO_DEBUG_MESSAGES - do not emit warn and fixme messages in the debug
|
||||
log; this will further optimise the binary, but may omit messages that could
|
||||
help debug problems with vkd3d.
|
||||
|
||||
* VKD3D_NO_ERROR_MESSAGES - do not emit error messages; this will optimise the
|
||||
binary even more, but may omit very important messages, so it is not
|
||||
recommended in most circumstances.
|
||||
|
||||
* VKD3D_ABORT_ON_ERR - abort the process as soon as an error message is
|
||||
emitted; this can be useful for developers to make error conditions as
|
||||
conspicuous as possible.
|
||||
|
||||
* VKD3D_SHADER_UNSUPPORTED_GLSL - enable GLSL (GL Shading Language) support in
|
||||
vkd3d-shader, which is disabled by default because it is not considered ready
|
||||
for release yet. Please note that this feature is not currently supported,
|
||||
and it might change in a non-compatible way before it is released.
|
||||
|
||||
* VKD3D_SHADER_UNSUPPORTED_MSL - enable MSL (Metal Shading Language) support in
|
||||
vkd3d-shader, which is disabled by default because it is not considered ready
|
||||
for release yet. Please note that this feature is not currently supported,
|
||||
and it might change in a non-compatible way before it is released.
|
||||
|
||||
* VKD3D_SHADER_UNSUPPORTED_SPIRV_PARSER - enable SPIR-V parser support in
|
||||
vkd3d-shader, which is disabled by default because it is not considered ready
|
||||
for release yet. Please note that this feature is not currently supported,
|
||||
and it might change in a non-compatible way before it is released.
|
||||
|
||||
============================
|
||||
Testing with the Agility SDK
|
||||
|
31
configure.ac
31
configure.ac
@@ -1,13 +1,15 @@
|
||||
AC_PREREQ([2.69])
|
||||
AC_INIT([vkd3d],[1.13])
|
||||
AC_INIT([vkd3d],[1.17])
|
||||
|
||||
AC_CONFIG_AUX_DIR([bin])
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
AC_CONFIG_HEADERS(include/config.h)
|
||||
|
||||
AC_ARG_VAR([PERL], [The Perl 5 language interpreter])
|
||||
AC_ARG_VAR([WIDL], [widl IDL compiler])
|
||||
AC_ARG_VAR([CROSSCC32], [32-bit Windows cross compiler])
|
||||
AC_ARG_VAR([CROSSCC64], [64-bit Windows cross compiler])
|
||||
AC_ARG_WITH([metal], AS_HELP_STRING([--with-metal], [Build with the Metal library (default: test)]))
|
||||
AC_ARG_WITH([ncurses], AS_HELP_STRING([--with-ncurses], [Build with the ncurses library (default: test)]))
|
||||
AC_ARG_WITH([opengl], AS_HELP_STRING([--with-opengl], [Build with the OpenGL library (default: test)]))
|
||||
AC_ARG_WITH([spirv-tools], AS_HELP_STRING([--with-spirv-tools],
|
||||
@@ -31,6 +33,11 @@ AC_PROG_MKDIR_P
|
||||
VKD3D_PROG_WIDL(3, 21)
|
||||
AS_IF([test "x$WIDL" = "xno"], [AC_MSG_WARN([widl is required to build header files.])])
|
||||
|
||||
AC_CHECK_PROGS([PERL], [perl], [none])
|
||||
AS_IF([test "$PERL" = "none"], [AC_MSG_ERROR([no suitable perl found. Please install the 'perl-base' package.])])
|
||||
VKD3D_CHECK_PERL_MODULE([JSON],
|
||||
[AC_MSG_ERROR([perl module 'JSON' not found. Please install the 'libjson-perl' package.])])
|
||||
|
||||
AC_CHECK_PROGS([FLEX], [flex], [none])
|
||||
AS_IF([test "$FLEX" = "none"], [AC_MSG_ERROR([no suitable flex found. Please install the 'flex' package.])])
|
||||
AC_ARG_VAR([LFLAGS], [extra flags for flex])
|
||||
@@ -134,6 +141,16 @@ AS_IF([test "x$SONAME_LIBDXCOMPILER" = "x"],
|
||||
[VKD3D_CHECK_SONAME([dxcompiler], [DxcCreateInstance], [HAVE_DXCOMPILER=yes], [HAVE_DXCOMPILER=no], [$DXCOMPILER_LIBS])],
|
||||
[AC_DEFINE_UNQUOTED([SONAME_LIBDXCOMPILER],["$SONAME_LIBDXCOMPILER"],[Define to the shared object name of the dxcompiler library.])])
|
||||
|
||||
AS_IF([test "x$with_metal" != "xno"],
|
||||
[AC_MSG_CHECKING([for Metal])]
|
||||
[AC_PREPROC_IFELSE([AC_LANG_PROGRAM([#include <Metal/Metal.h>])],
|
||||
[AC_MSG_RESULT([yes])
|
||||
AC_PROG_OBJC
|
||||
AC_DEFINE([HAVE_METAL], [1], [Define to 1 if you have Metal.])
|
||||
with_metal=yes],
|
||||
[AC_MSG_RESULT([no])
|
||||
AM_CONDITIONAL([am__fastdepOBJC], [false])
|
||||
with_metal=no])])
|
||||
AS_IF([test "x$with_ncurses" != "xno"],
|
||||
[PKG_CHECK_MODULES([NCURSES], [ncurses],
|
||||
[AC_DEFINE([HAVE_NCURSES], [1], [Define to 1 if you have ncurses.]) with_ncurses=yes],
|
||||
@@ -162,25 +179,32 @@ VKD3D_CHECK_FUNC([HAVE_SYNC_ADD_AND_FETCH], [__sync_add_and_fetch], [__sync_add_
|
||||
VKD3D_CHECK_FUNC([HAVE_SYNC_BOOL_COMPARE_AND_SWAP], [__sync_bool_compare_and_swap], [__sync_bool_compare_and_swap((int *)0, 0, 0)])
|
||||
VKD3D_CHECK_FUNC([HAVE_ATOMIC_EXCHANGE_N], [__atomic_exchange_n], [__atomic_exchange_n((int *)0, 0, 0)])
|
||||
AC_CHECK_FUNCS([gettid])
|
||||
AC_CHECK_FUNCS([pthread_threadid_np])
|
||||
|
||||
dnl Makefiles
|
||||
case $host_os in
|
||||
mingw32*)
|
||||
AC_SUBST([DEMO_LIBS],["-ld3d12 -ldxgi -lgdi32"])
|
||||
AC_SUBST([DEMO_LIBS],["-lgdi32"])
|
||||
AC_SUBST([DEMO_CFLAGS],["-municode"])
|
||||
;;
|
||||
darwin*)
|
||||
AC_SUBST([DEMO_LIBS],["-framework Foundation -framework AppKit -framework QuartzCore"])
|
||||
AC_SUBST([DEMO_CFLAGS],[""])
|
||||
;;
|
||||
*) AS_IF([test "x$enable_demos" = "xyes" -a "x$HAVE_XCB" != "xyes"],
|
||||
[AC_MSG_ERROR([libxcb is required for demos.])])
|
||||
AC_SUBST([DEMO_LIBS],[$XCB_LIBS])
|
||||
AC_SUBST([DEMO_CFLAGS],[$XCB_CFLAGS])
|
||||
;;
|
||||
esac
|
||||
VKD3D_CHECK_CFLAGS([-fno-lto], [DEMO_CFLAGS="$DEMO_CFLAGS -fno-lto"])
|
||||
AM_CONDITIONAL([BUILD_DEMOS], [test "x$enable_demos" = "xyes"])
|
||||
AM_CONDITIONAL([BUILD_DOC], [test $DX_FLAG_doc = 1])
|
||||
AM_CONDITIONAL([BUILD_TESTS], [test "x$enable_tests" != "xno"])
|
||||
AM_CONDITIONAL([HAVE_WIDL], [test "x$WIDL" != "xno"])
|
||||
AM_CONDITIONAL([HAVE_CROSSTARGET32], [test "x$CROSSTARGET32" != "xno"])
|
||||
AM_CONDITIONAL([HAVE_CROSSTARGET64], [test "x$CROSSTARGET64" != "xno"])
|
||||
AM_CONDITIONAL([HAVE_METAL], [test "${host_os#darwin}" != "$host_os"])
|
||||
|
||||
AC_CONFIG_FILES([Makefile])
|
||||
AC_OUTPUT
|
||||
@@ -197,11 +221,12 @@ AS_ECHO(["
|
||||
|
||||
widl: ${WIDL}
|
||||
|
||||
Have dxcompiler: ${HAVE_DXCOMPILER}
|
||||
Have Metal: ${with_metal}
|
||||
Have ncurses: ${with_ncurses}
|
||||
Have OpenGL: ${with_opengl}
|
||||
Have SPIRV-Tools: ${with_spirv_tools}
|
||||
Have xcb: ${HAVE_XCB}
|
||||
Have dxcompiler: ${HAVE_DXCOMPILER}
|
||||
|
||||
Building demos: ${enable_demos}
|
||||
Building tests: ${enable_tests}
|
||||
|
180
demos/demo.h
180
demos/demo.h
@@ -38,15 +38,69 @@
|
||||
#define COBJMACROS
|
||||
#include <vkd3d_d3d12.h>
|
||||
#include <inttypes.h>
|
||||
#include <math.h>
|
||||
|
||||
#ifdef __WIN32__
|
||||
#define DEMO_ASM_PUSHSECTION ".section rdata\n\t"
|
||||
#define DEMO_ASM_POPSECTION ".text\n\t"
|
||||
#define DEMO_ASM_OBJECT_TYPE(name)
|
||||
#elif defined(__APPLE__)
|
||||
#define DEMO_ASM_PUSHSECTION ".pushsection __TEXT,__const\n\t"
|
||||
#define DEMO_ASM_POPSECTION ".popsection\n\t"
|
||||
#define DEMO_ASM_OBJECT_TYPE(name)
|
||||
#else
|
||||
#define DEMO_ASM_PUSHSECTION ".pushsection .rodata\n\t"
|
||||
#define DEMO_ASM_POPSECTION ".popsection\n\t"
|
||||
#define DEMO_ASM_OBJECT_TYPE(name) ".type "name", @object\n\t"
|
||||
#endif
|
||||
|
||||
#if (defined(__WIN32__) && defined(__i386__)) || defined(__APPLE__)
|
||||
#define DEMO_ASM_NAME(name) "_"#name
|
||||
#else
|
||||
#define DEMO_ASM_NAME(name) #name
|
||||
#endif
|
||||
|
||||
#define DEMO_EMBED_ASM(name, file) \
|
||||
DEMO_ASM_PUSHSECTION \
|
||||
".global "name"\n\t" \
|
||||
DEMO_ASM_OBJECT_TYPE(name) \
|
||||
".balign 8\n\t" \
|
||||
name":\n\t" \
|
||||
".incbin \""file"\"\n\t" \
|
||||
name"_end:\n\t" \
|
||||
".global "name"_size\n\t" \
|
||||
DEMO_ASM_OBJECT_TYPE(name"_size") \
|
||||
".balign 8\n\t" \
|
||||
name"_size:\n\t" \
|
||||
".int "name"_end - "name"\n\t" \
|
||||
DEMO_ASM_POPSECTION
|
||||
|
||||
#define DEMO_EMBED(name, file) \
|
||||
extern const unsigned int name##_size; \
|
||||
extern const uint8_t name[]; \
|
||||
__asm__(DEMO_EMBED_ASM(DEMO_ASM_NAME(name), file))
|
||||
|
||||
#if defined(__GNUC__) || defined(__clang__)
|
||||
# ifdef __MINGW_PRINTF_FORMAT
|
||||
# define DEMO_PRINTF_FUNC(fmt, args) __attribute__((format(__MINGW_PRINTF_FORMAT, fmt, args)))
|
||||
# else
|
||||
# define DEMO_PRINTF_FUNC(fmt, args) __attribute__((format(printf, fmt, args)))
|
||||
# endif
|
||||
#else
|
||||
# define DEMO_PRINTF_FUNC(fmt, args)
|
||||
#endif
|
||||
|
||||
#define ARRAY_SIZE(x) (sizeof(x) / sizeof(*x))
|
||||
|
||||
#define DEMO_KEY_UNKNOWN 0x0000
|
||||
#define DEMO_KEY_ESCAPE 0xff1b
|
||||
#define DEMO_KEY_LEFT 0xff51
|
||||
#define DEMO_KEY_UP 0xff52
|
||||
#define DEMO_KEY_RIGHT 0xff53
|
||||
#define DEMO_KEY_DOWN 0xff54
|
||||
#define DEMO_KEY_UNKNOWN 0x0000
|
||||
#define DEMO_KEY_ESCAPE 0xff1b
|
||||
#define DEMO_KEY_LEFT 0xff51
|
||||
#define DEMO_KEY_UP 0xff52
|
||||
#define DEMO_KEY_RIGHT 0xff53
|
||||
#define DEMO_KEY_DOWN 0xff54
|
||||
#define DEMO_KEY_KP_ADD 0xffab
|
||||
#define DEMO_KEY_KP_SUBTRACT 0xffad
|
||||
#define DEMO_KEY_F1 0xffbe
|
||||
|
||||
struct demo_vec3
|
||||
{
|
||||
@@ -58,6 +112,26 @@ struct demo_vec4
|
||||
float x, y, z, w;
|
||||
};
|
||||
|
||||
struct demo_uvec2
|
||||
{
|
||||
uint32_t x, y;
|
||||
};
|
||||
|
||||
struct demo_uvec4
|
||||
{
|
||||
uint32_t x, y, z, w;
|
||||
};
|
||||
|
||||
struct demo_matrix
|
||||
{
|
||||
float m[4][4];
|
||||
};
|
||||
|
||||
struct demo_patch
|
||||
{
|
||||
uint16_t p[4][4];
|
||||
};
|
||||
|
||||
struct demo_swapchain_desc
|
||||
{
|
||||
unsigned int width;
|
||||
@@ -75,6 +149,36 @@ static inline void demo_vec3_set(struct demo_vec3 *v, float x, float y, float z)
|
||||
v->z = z;
|
||||
}
|
||||
|
||||
static inline void demo_vec3_subtract(struct demo_vec3 *v, const struct demo_vec3 *a, const struct demo_vec3 *b)
|
||||
{
|
||||
demo_vec3_set(v, a->x - b->x, a->y - b->y, a->z - b->z);
|
||||
}
|
||||
|
||||
static inline float demo_vec3_dot(const struct demo_vec3 *a, const struct demo_vec3 *b)
|
||||
{
|
||||
return a->x * b->x + a->y * b->y + a->z * b->z;
|
||||
}
|
||||
|
||||
static inline float demo_vec3_length(const struct demo_vec3 *v)
|
||||
{
|
||||
return sqrtf(demo_vec3_dot(v, v));
|
||||
}
|
||||
|
||||
static inline void demo_vec3_scale(struct demo_vec3 *v, const struct demo_vec3 *a, float s)
|
||||
{
|
||||
demo_vec3_set(v, a->x * s, a->y * s, a->z *s);
|
||||
}
|
||||
|
||||
static inline void demo_vec3_normalise(struct demo_vec3 *v, const struct demo_vec3 *a)
|
||||
{
|
||||
demo_vec3_scale(v, a, 1.0f / demo_vec3_length(a));
|
||||
}
|
||||
|
||||
static inline void demo_vec3_cross(struct demo_vec3 *v, const struct demo_vec3 *a, const struct demo_vec3 *b)
|
||||
{
|
||||
demo_vec3_set(v, a->y * b->z - a->z * b->y, a->z * b->x - a->x * b->z, a->x * b->y - a->y * b->x);
|
||||
}
|
||||
|
||||
static inline void demo_vec4_set(struct demo_vec4 *v, float x, float y, float z, float w)
|
||||
{
|
||||
v->x = x;
|
||||
@@ -83,6 +187,60 @@ static inline void demo_vec4_set(struct demo_vec4 *v, float x, float y, float z,
|
||||
v->w = w;
|
||||
}
|
||||
|
||||
static inline void demo_matrix_look_at_rh(struct demo_matrix *m, const struct demo_vec3 *eye,
|
||||
const struct demo_vec3 *ref, const struct demo_vec3 *up)
|
||||
{
|
||||
struct demo_vec3 f, s, t, u;
|
||||
|
||||
demo_vec3_subtract(&f, eye, ref);
|
||||
demo_vec3_normalise(&f, &f);
|
||||
demo_vec3_cross(&s, up, &f);
|
||||
demo_vec3_normalise(&s, &s);
|
||||
demo_vec3_cross(&u, &f, &s);
|
||||
demo_vec3_set(&t, demo_vec3_dot(&s, eye), demo_vec3_dot(&u, eye), demo_vec3_dot(&f, eye));
|
||||
|
||||
*m = (struct demo_matrix)
|
||||
{{
|
||||
{ s.x, u.x, f.x, 0.0f},
|
||||
{ s.y, u.y, f.y, 0.0f},
|
||||
{ s.z, u.z, f.z, 0.0f},
|
||||
{-t.x, -t.y, -t.z, 1.0f},
|
||||
}};
|
||||
}
|
||||
|
||||
static inline void demo_matrix_multiply(struct demo_matrix *out,
|
||||
const struct demo_matrix *a, const struct demo_matrix *b)
|
||||
{
|
||||
unsigned int i, j;
|
||||
|
||||
for (i = 0; i < 4; ++i)
|
||||
{
|
||||
for (j = 0; j < 4; ++j)
|
||||
{
|
||||
out->m[i][j] = a->m[i][0] * b->m[0][j]
|
||||
+ a->m[i][1] * b->m[1][j]
|
||||
+ a->m[i][2] * b->m[2][j]
|
||||
+ a->m[i][3] * b->m[3][j];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static inline void demo_matrix_perspective_rh(struct demo_matrix *m, float w, float h, float z_near, float z_far)
|
||||
{
|
||||
float sx = 2.0 * z_near / w;
|
||||
float sy = 2.0 * z_near / h;
|
||||
float sz = z_far / (z_near - z_far);
|
||||
float d = z_near * sz;
|
||||
|
||||
*m = (struct demo_matrix)
|
||||
{{
|
||||
{ sx, 0.0f, 0.0f, 0.0f},
|
||||
{0.0f, sy, 0.0f, 0.0f},
|
||||
{0.0f, 0.0f, sz, -1.0f},
|
||||
{0.0f, 0.0f, d, 0.0f},
|
||||
}};
|
||||
}
|
||||
|
||||
static inline void demo_rasterizer_desc_init_default(D3D12_RASTERIZER_DESC *desc)
|
||||
{
|
||||
desc->FillMode = D3D12_FILL_MODE_SOLID;
|
||||
@@ -138,9 +296,11 @@ static inline HRESULT demo_create_root_signature(ID3D12Device *device,
|
||||
return hr;
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "demo_win32.h"
|
||||
#ifdef VKD3D_CROSSTEST
|
||||
#include "demo_d3d12.h"
|
||||
#else
|
||||
#define INFINITE VKD3D_INFINITE
|
||||
#include "demo_xcb.h"
|
||||
# ifndef _WIN32
|
||||
# define INFINITE VKD3D_INFINITE
|
||||
# endif
|
||||
#include "demo_vkd3d.h"
|
||||
#endif
|
||||
|
261
demos/demo_d3d12.h
Normal file
261
demos/demo_d3d12.h
Normal file
@@ -0,0 +1,261 @@
|
||||
/*
|
||||
* Copyright 2016 Józef Kucia for CodeWeavers
|
||||
* Copyright 2016 Henri Verbeet for CodeWeavers
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <vkd3d_dxgi1_4.h>
|
||||
#include <vkd3d_d3dcompiler.h>
|
||||
#include <stdbool.h>
|
||||
#include <stdio.h>
|
||||
|
||||
struct demo_win32
|
||||
{
|
||||
UINT (*GetDpiForSystem)(void);
|
||||
};
|
||||
|
||||
struct demo
|
||||
{
|
||||
union
|
||||
{
|
||||
struct demo_win32 win32;
|
||||
} u;
|
||||
|
||||
size_t window_count;
|
||||
|
||||
void *user_data;
|
||||
void (*idle_func)(struct demo *demo, void *user_data);
|
||||
};
|
||||
|
||||
struct demo_window
|
||||
{
|
||||
struct demo *demo;
|
||||
|
||||
void *user_data;
|
||||
void (*expose_func)(struct demo_window *window, void *user_data);
|
||||
void (*key_press_func)(struct demo_window *window, demo_key key, void *user_data);
|
||||
};
|
||||
|
||||
static inline bool demo_window_init(struct demo_window *window, struct demo *demo, void *user_data)
|
||||
{
|
||||
window->demo = demo;
|
||||
window->user_data = user_data;
|
||||
window->expose_func = NULL;
|
||||
window->key_press_func = NULL;
|
||||
++demo->window_count;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static inline void demo_window_cleanup(struct demo_window *window)
|
||||
{
|
||||
--window->demo->window_count;
|
||||
}
|
||||
|
||||
#include "demo_win32.h"
|
||||
|
||||
struct demo_swapchain
|
||||
{
|
||||
IDXGISwapChain3 *swapchain;
|
||||
unsigned int buffer_count;
|
||||
char device_name[128];
|
||||
};
|
||||
|
||||
static inline void demo_cleanup(struct demo *demo)
|
||||
{
|
||||
demo_win32_cleanup(demo);
|
||||
}
|
||||
|
||||
static inline bool demo_init(struct demo *demo, void *user_data)
|
||||
{
|
||||
if (!demo_win32_init(&demo->u.win32))
|
||||
{
|
||||
fprintf(stderr, "Failed to initialise demo.\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
demo->window_count = 0;
|
||||
demo->user_data = user_data;
|
||||
demo->idle_func = NULL;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static inline void demo_get_dpi(struct demo *demo, double *dpi_x, double *dpi_y)
|
||||
{
|
||||
demo_win32_get_dpi(demo, dpi_x, dpi_y);
|
||||
}
|
||||
|
||||
static inline const char *demo_get_platform_name(void)
|
||||
{
|
||||
return "Direct3D 12";
|
||||
}
|
||||
|
||||
static inline void demo_process_events(struct demo *demo)
|
||||
{
|
||||
demo_win32_process_events(demo);
|
||||
}
|
||||
|
||||
static inline void demo_set_idle_func(struct demo *demo,
|
||||
void (*idle_func)(struct demo *demo, void *user_data))
|
||||
{
|
||||
demo->idle_func = idle_func;
|
||||
}
|
||||
|
||||
static inline void demo_window_destroy(struct demo_window *window)
|
||||
{
|
||||
demo_window_win32_destroy(window);
|
||||
}
|
||||
|
||||
static inline struct demo_window *demo_window_create(struct demo *demo, const char *title,
|
||||
unsigned int width, unsigned int height, void *user_data)
|
||||
{
|
||||
return demo_window_win32_create(demo, title, width, height, user_data);
|
||||
}
|
||||
|
||||
static inline void demo_window_set_expose_func(struct demo_window *window,
|
||||
void (*expose_func)(struct demo_window *window, void *user_data))
|
||||
{
|
||||
window->expose_func = expose_func;
|
||||
}
|
||||
|
||||
static inline void demo_window_set_key_press_func(struct demo_window *window,
|
||||
void (*key_press_func)(struct demo_window *window, demo_key key, void *user_data))
|
||||
{
|
||||
window->key_press_func = key_press_func;
|
||||
}
|
||||
|
||||
static inline struct demo_swapchain *demo_swapchain_create(ID3D12CommandQueue *command_queue,
|
||||
struct demo_window *window, const struct demo_swapchain_desc *desc)
|
||||
{
|
||||
struct demo_window_win32 *window_win32 = CONTAINING_RECORD(window, struct demo_window_win32, w);
|
||||
DXGI_SWAP_CHAIN_DESC1 swapchain_desc;
|
||||
struct demo_swapchain *swapchain;
|
||||
DXGI_ADAPTER_DESC adapter_desc;
|
||||
IDXGISwapChain1 *swapchain1;
|
||||
IDXGIFactory2 *factory;
|
||||
IDXGIAdapter *adapter;
|
||||
ID3D12Device *device;
|
||||
unsigned int i;
|
||||
HRESULT hr;
|
||||
LUID luid;
|
||||
|
||||
if (!(swapchain = malloc(sizeof(*swapchain))))
|
||||
return NULL;
|
||||
|
||||
if (FAILED(CreateDXGIFactory1(&IID_IDXGIFactory2, (void **)&factory)))
|
||||
goto fail;
|
||||
|
||||
if (FAILED(ID3D12CommandQueue_GetDevice(command_queue, &IID_ID3D12Device, (void **)&device)))
|
||||
goto fail;
|
||||
luid = ID3D12Device_GetAdapterLuid(device);
|
||||
ID3D12Device_Release(device);
|
||||
|
||||
sprintf(swapchain->device_name, "Unknown");
|
||||
for (i = 0; IDXGIFactory2_EnumAdapters(factory, i, &adapter) == S_OK; ++i)
|
||||
{
|
||||
hr = IDXGIAdapter_GetDesc(adapter, &adapter_desc);
|
||||
IDXGIAdapter_Release(adapter);
|
||||
if (FAILED(hr))
|
||||
continue;
|
||||
|
||||
if (adapter_desc.AdapterLuid.LowPart == luid.LowPart
|
||||
&& adapter_desc.AdapterLuid.HighPart == luid.HighPart)
|
||||
{
|
||||
snprintf(swapchain->device_name, ARRAY_SIZE(swapchain->device_name), "%ls", adapter_desc.Description);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
memset(&swapchain_desc, 0, sizeof(swapchain_desc));
|
||||
swapchain_desc.BufferCount = desc->buffer_count;
|
||||
swapchain_desc.Width = desc->width;
|
||||
swapchain_desc.Height = desc->height;
|
||||
swapchain_desc.Format = desc->format;
|
||||
swapchain_desc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT;
|
||||
swapchain_desc.SwapEffect = DXGI_SWAP_EFFECT_FLIP_DISCARD;
|
||||
swapchain_desc.SampleDesc.Count = 1;
|
||||
|
||||
hr = IDXGIFactory2_CreateSwapChainForHwnd(factory, (IUnknown *)command_queue,
|
||||
window_win32->window, &swapchain_desc, NULL, NULL, &swapchain1);
|
||||
IDXGIFactory2_Release(factory);
|
||||
if (FAILED(hr))
|
||||
goto fail;
|
||||
|
||||
swapchain->buffer_count = desc->buffer_count;
|
||||
hr = IDXGISwapChain1_QueryInterface(swapchain1, &IID_IDXGISwapChain3, (void **)&swapchain->swapchain);
|
||||
IDXGISwapChain1_Release(swapchain1);
|
||||
if (FAILED(hr))
|
||||
goto fail;
|
||||
|
||||
return swapchain;
|
||||
|
||||
fail:
|
||||
free(swapchain);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static inline const char *demo_swapchain_get_device_name(struct demo_swapchain *swapchain)
|
||||
{
|
||||
return swapchain->device_name;
|
||||
}
|
||||
|
||||
static inline unsigned int demo_swapchain_get_current_back_buffer_index(struct demo_swapchain *swapchain)
|
||||
{
|
||||
return IDXGISwapChain3_GetCurrentBackBufferIndex(swapchain->swapchain);
|
||||
}
|
||||
|
||||
static inline ID3D12Resource *demo_swapchain_get_back_buffer(struct demo_swapchain *swapchain, unsigned int index)
|
||||
{
|
||||
ID3D12Resource *buffer;
|
||||
|
||||
if (FAILED(IDXGISwapChain3_GetBuffer(swapchain->swapchain, index,
|
||||
&IID_ID3D12Resource, (void **)&buffer)))
|
||||
return NULL;
|
||||
|
||||
return buffer;
|
||||
}
|
||||
|
||||
static inline unsigned int demo_swapchain_get_back_buffer_count(struct demo_swapchain *swapchain)
|
||||
{
|
||||
return swapchain->buffer_count;
|
||||
}
|
||||
|
||||
static inline void demo_swapchain_present(struct demo_swapchain *swapchain)
|
||||
{
|
||||
IDXGISwapChain3_Present(swapchain->swapchain, 1, 0);
|
||||
}
|
||||
|
||||
static inline void demo_swapchain_destroy(struct demo_swapchain *swapchain)
|
||||
{
|
||||
IDXGISwapChain3_Release(swapchain->swapchain);
|
||||
free(swapchain);
|
||||
}
|
||||
|
||||
static inline HANDLE demo_create_event(void)
|
||||
{
|
||||
return CreateEventA(NULL, FALSE, FALSE, NULL);
|
||||
}
|
||||
|
||||
static inline unsigned int demo_wait_event(HANDLE event, unsigned int ms)
|
||||
{
|
||||
return WaitForSingleObject(event, ms);
|
||||
}
|
||||
|
||||
static inline void demo_destroy_event(HANDLE event)
|
||||
{
|
||||
CloseHandle(event);
|
||||
}
|
324
demos/demo_macos.h
Normal file
324
demos/demo_macos.h
Normal file
@@ -0,0 +1,324 @@
|
||||
/*
|
||||
* Copyright 2025 Henri Verbeet
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
typedef long NSInteger;
|
||||
typedef unsigned long NSUInteger;
|
||||
|
||||
typedef struct NSPoint
|
||||
{
|
||||
double x, y;
|
||||
} NSPoint;
|
||||
|
||||
typedef struct NSRect
|
||||
{
|
||||
double x, y;
|
||||
double w, h;
|
||||
} NSRect;
|
||||
|
||||
#define BOOL OBJC_BOOL
|
||||
#include "private/appkit.h"
|
||||
#include "private/foundation.h"
|
||||
#include "private/quartzcore.h"
|
||||
#undef BOOL
|
||||
|
||||
extern const id NSDefaultRunLoopMode;
|
||||
|
||||
enum NSBackingStoreType
|
||||
{
|
||||
NSBackingStoreBuffered = 2,
|
||||
};
|
||||
|
||||
enum NSEventType
|
||||
{
|
||||
NSEventTypeKeyDown = 0xa,
|
||||
NSEventTypeApplicationDefined = 0xf,
|
||||
};
|
||||
|
||||
enum NSWindowStyleMask
|
||||
{
|
||||
NSWindowStyleMaskBorderless = 0x0000,
|
||||
NSWindowStyleMaskTitled = 0x0001,
|
||||
NSWindowStyleMaskClosable = 0x0002,
|
||||
NSWindowStyleMaskMiniaturizable = 0x0004,
|
||||
NSWindowStyleMaskResizable = 0x0008,
|
||||
NSWindowStyleMaskUtilityWindow = 0x0010,
|
||||
NSWindowStyleMaskDocModalWindow = 0x0040,
|
||||
NSWindowStyleMaskNonactivatingPanel = 0x0080,
|
||||
NSWindowStyleMaskUnifiedTitleAndToolbar = 0x1000,
|
||||
NSWindowStyleMaskHUDWindow = 0x2000,
|
||||
NSWindowStyleMaskFullScreen = 0x4000,
|
||||
NSWindowStyleMaskFullSizeContentView = 0x8000,
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
DemoWindowDestroyed,
|
||||
};
|
||||
|
||||
struct demo_window_macos
|
||||
{
|
||||
struct demo_window w;
|
||||
id window;
|
||||
id layer;
|
||||
};
|
||||
|
||||
static struct demo_window_macos *demo_macos_find_macos_window(struct demo *demo, id window)
|
||||
{
|
||||
size_t i;
|
||||
|
||||
for (i = 0; i < demo->window_count; ++i)
|
||||
{
|
||||
struct demo_window_macos *window_macos = CONTAINING_RECORD(demo->windows[i], struct demo_window_macos, w);
|
||||
|
||||
if (window_macos->window == window)
|
||||
return window_macos;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static VkSurfaceKHR demo_window_macos_create_vk_surface(struct demo_window *window, VkInstance vk_instance)
|
||||
{
|
||||
struct demo_window_macos *window_macos = CONTAINING_RECORD(window, struct demo_window_macos, w);
|
||||
struct VkMetalSurfaceCreateInfoEXT surface_desc;
|
||||
VkSurfaceKHR vk_surface;
|
||||
id l, v;
|
||||
|
||||
l = window_macos->layer = CAMetalLayer_layer();
|
||||
CAMetalLayer_setContentsScale(l, NSScreen_backingScaleFactor(NSScreen_mainScreen()));
|
||||
v = NSWindow_contentView(window_macos->window);
|
||||
NSView_setLayer(v, l);
|
||||
NSView_setWantsLayer(v, true);
|
||||
|
||||
surface_desc.sType = VK_STRUCTURE_TYPE_METAL_SURFACE_CREATE_INFO_EXT;
|
||||
surface_desc.pNext = NULL;
|
||||
surface_desc.flags = 0;
|
||||
surface_desc.pLayer = l;
|
||||
if (vkCreateMetalSurfaceEXT(vk_instance, &surface_desc, NULL, &vk_surface) < 0)
|
||||
return VK_NULL_HANDLE;
|
||||
|
||||
return vk_surface;
|
||||
}
|
||||
|
||||
static void demo_window_macos_destroy(struct demo_window *window)
|
||||
{
|
||||
struct demo_window_macos *window_macos = CONTAINING_RECORD(window, struct demo_window_macos, w);
|
||||
|
||||
NSWindow_close(window_macos->window);
|
||||
}
|
||||
|
||||
static void demo_window_macos_destroyed(struct demo_window_macos *window_macos)
|
||||
{
|
||||
CAMetalLayer_release(window_macos->layer);
|
||||
NSWindow_release(window_macos->window);
|
||||
demo_window_cleanup(&window_macos->w);
|
||||
free(window_macos);
|
||||
}
|
||||
|
||||
static struct demo_window *demo_window_macos_create(struct demo *demo,
|
||||
const char *title, unsigned int width, unsigned int height, void *user_data)
|
||||
{
|
||||
unsigned long style = NSWindowStyleMaskTitled | NSWindowStyleMaskClosable;
|
||||
struct demo_window_macos *window_macos;
|
||||
NSRect r = {0, 0, width, height};
|
||||
double scale;
|
||||
id w, s;
|
||||
|
||||
if (!(window_macos = malloc(sizeof(*window_macos))))
|
||||
return NULL;
|
||||
|
||||
if (!demo_window_init(&window_macos->w, demo, user_data,
|
||||
demo_window_macos_create_vk_surface, demo_window_macos_destroy))
|
||||
{
|
||||
free(window_macos);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
s = NSScreen_mainScreen();
|
||||
scale = NSScreen_backingScaleFactor(s);
|
||||
r.w /= scale;
|
||||
r.h /= scale;
|
||||
|
||||
w = window_macos->window = class_createInstance(objc_getClass("DemoWindow"), 0);
|
||||
NSWindow_initWithContentRect(w, r, style, NSBackingStoreBuffered, true, s);
|
||||
NSWindow_setReleasedWhenClosed(w, false);
|
||||
NSWindow_setDelegate(w, w);
|
||||
NSWindow_center(w);
|
||||
NSWindow_setTitle(w, NSString_stringWithUTF8String(title));
|
||||
|
||||
NSWindow_makeKeyAndOrderFront(w, nil);
|
||||
window_macos->layer = nil;
|
||||
|
||||
return &window_macos->w;
|
||||
}
|
||||
|
||||
static void demo_macos_get_dpi(struct demo *demo, double *dpi_x, double *dpi_y)
|
||||
{
|
||||
*dpi_x = *dpi_y = 96.0 * NSScreen_backingScaleFactor(NSScreen_mainScreen());
|
||||
}
|
||||
|
||||
static demo_key demo_key_from_nsevent(id event)
|
||||
{
|
||||
enum vkey
|
||||
{
|
||||
kVK_ANSI_A = 0x00,
|
||||
kVK_ANSI_F = 0x03,
|
||||
kVK_ANSI_W = 0x0d,
|
||||
kVK_ANSI_Equal = 0x18,
|
||||
kVK_ANSI_Minus = 0x1b,
|
||||
kVK_Escape = 0x35,
|
||||
kVK_ANSI_KeypadPlus = 0x45,
|
||||
kVK_ANSI_KeypadMinus = 0x4e,
|
||||
kVK_F1 = 0x7a,
|
||||
kVK_LeftArrow = 0x7b,
|
||||
kVK_RightArrow = 0x7c,
|
||||
kVK_DownArrow = 0x7d,
|
||||
kVK_UpArrow = 0x7e,
|
||||
} vkey;
|
||||
size_t i;
|
||||
|
||||
static const struct
|
||||
{
|
||||
enum vkey vkey;
|
||||
demo_key demo_key;
|
||||
}
|
||||
lookup[] =
|
||||
{
|
||||
{kVK_ANSI_A, 'a'},
|
||||
{kVK_ANSI_F, 'f'},
|
||||
{kVK_ANSI_W, 'w'},
|
||||
{kVK_ANSI_Equal, '='},
|
||||
{kVK_ANSI_Minus, '-'},
|
||||
{kVK_Escape, DEMO_KEY_ESCAPE},
|
||||
{kVK_ANSI_KeypadPlus, DEMO_KEY_KP_ADD},
|
||||
{kVK_ANSI_KeypadMinus, DEMO_KEY_KP_SUBTRACT},
|
||||
{kVK_F1, DEMO_KEY_F1},
|
||||
{kVK_LeftArrow, DEMO_KEY_LEFT},
|
||||
{kVK_RightArrow, DEMO_KEY_RIGHT},
|
||||
{kVK_DownArrow, DEMO_KEY_DOWN},
|
||||
{kVK_UpArrow, DEMO_KEY_UP},
|
||||
};
|
||||
|
||||
vkey = NSEvent_keyCode(event);
|
||||
for (i = 0; i < ARRAY_SIZE(lookup); ++i)
|
||||
{
|
||||
if (lookup[i].vkey == vkey)
|
||||
return lookup[i].demo_key;
|
||||
}
|
||||
|
||||
return DEMO_KEY_UNKNOWN;
|
||||
}
|
||||
|
||||
static void demo_macos_process_events(struct demo *demo)
|
||||
{
|
||||
struct demo_window_macos *window_macos;
|
||||
struct demo_window *window;
|
||||
id a, event;
|
||||
size_t i;
|
||||
|
||||
for (i = 0; i < demo->window_count; ++i)
|
||||
{
|
||||
if ((window = demo->windows[i])->expose_func)
|
||||
window->expose_func(window, window->user_data);
|
||||
}
|
||||
|
||||
a = NSApplication_sharedApplication();
|
||||
while (demo->window_count)
|
||||
{
|
||||
if (!demo->idle_func)
|
||||
{
|
||||
if (!(event = NSApplication_nextEventMatchingMask(a, ~(uint64_t)0,
|
||||
NSDate_distantFuture(), NSDefaultRunLoopMode, true)))
|
||||
break;
|
||||
}
|
||||
else if (!(event = NSApplication_nextEventMatchingMask(a, ~(uint64_t)0, nil, NSDefaultRunLoopMode, true)))
|
||||
{
|
||||
demo->idle_func(demo, demo->user_data);
|
||||
continue;
|
||||
}
|
||||
|
||||
switch (NSEvent_type(event))
|
||||
{
|
||||
case NSEventTypeKeyDown:
|
||||
if (NSMenu_performKeyEquivalent(NSApplication_mainMenu(a), event))
|
||||
continue;
|
||||
if (!(window_macos = demo_macos_find_macos_window(demo, NSEvent_window(event)))
|
||||
|| !window_macos->w.key_press_func)
|
||||
break;
|
||||
window_macos->w.key_press_func(&window_macos->w,
|
||||
demo_key_from_nsevent(event), window_macos->w.user_data);
|
||||
continue;
|
||||
|
||||
case NSEventTypeApplicationDefined:
|
||||
if (NSEvent_subtype(event) != DemoWindowDestroyed
|
||||
|| !(window_macos = demo_macos_find_macos_window(demo, NSEvent_window(event))))
|
||||
break;
|
||||
demo_window_macos_destroyed(window_macos);
|
||||
continue;
|
||||
}
|
||||
|
||||
NSApplication_sendEvent(a, event);
|
||||
}
|
||||
}
|
||||
|
||||
static void DemoWindow_windowWillClose(id window, SEL sel, id notification)
|
||||
{
|
||||
id event;
|
||||
|
||||
event = NSEvent_otherEventWithType(NSEventTypeApplicationDefined, (NSPoint){0.0, 0.0},
|
||||
0, 0.0, NSWindow_windowNumber(window), nil, DemoWindowDestroyed, 0, 0);
|
||||
NSApplication_postEvent(NSApplication_sharedApplication(), event, true);
|
||||
}
|
||||
|
||||
static void demo_macos_cleanup(struct demo *demo)
|
||||
{
|
||||
}
|
||||
|
||||
static bool demo_macos_init(struct demo_macos *macos)
|
||||
{
|
||||
id application, item, menu, submenu;
|
||||
Class c;
|
||||
|
||||
if ((c = objc_allocateClassPair(objc_getClass("NSWindow"), "DemoWindow", 0)))
|
||||
{
|
||||
class_addMethod(c, sel_registerName("windowWillClose:"), (IMP)DemoWindow_windowWillClose, "v@:@");
|
||||
objc_registerClassPair(c);
|
||||
}
|
||||
|
||||
application = NSApplication_sharedApplication();
|
||||
NSApplication_setActivationPolicy(application, 0);
|
||||
|
||||
menu = NSMenu_new();
|
||||
|
||||
submenu = NSMenu_new();
|
||||
NSMenu_addItemWithTitle(submenu, NSString_stringWithUTF8String("Quit"),
|
||||
sel_registerName("terminate:"), NSString_stringWithUTF8String("q"));
|
||||
|
||||
item = NSMenuItem_new();
|
||||
NSMenuItem_setSubmenu(item, submenu);
|
||||
NSMenu_release(submenu);
|
||||
NSMenu_addItem(menu, item);
|
||||
NSMenuItem_release(item);
|
||||
|
||||
NSApplication_setMainMenu(application, menu);
|
||||
NSMenu_release(menu);
|
||||
|
||||
NSApplication_finishLaunching(application);
|
||||
|
||||
return true;
|
||||
}
|
640
demos/demo_vkd3d.h
Normal file
640
demos/demo_vkd3d.h
Normal file
File diff suppressed because it is too large
Load Diff
@@ -17,85 +17,108 @@
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <vkd3d_dxgi1_4.h>
|
||||
#include <vkd3d_d3dcompiler.h>
|
||||
#include <stdbool.h>
|
||||
#include <stdio.h>
|
||||
#define DEMO_WIN32_WINDOW_CLASS_NAME L"demo_wc"
|
||||
|
||||
#define DEMO_WINDOW_CLASS_NAME L"demo_wc"
|
||||
|
||||
struct demo
|
||||
struct demo_window_win32
|
||||
{
|
||||
size_t window_count;
|
||||
bool quit;
|
||||
struct demo_window w;
|
||||
|
||||
void *user_data;
|
||||
void (*idle_func)(struct demo *demo, void *user_data);
|
||||
};
|
||||
|
||||
struct demo_window
|
||||
{
|
||||
HINSTANCE instance;
|
||||
HWND hwnd;
|
||||
struct demo *demo;
|
||||
void *user_data;
|
||||
void (*expose_func)(struct demo_window *window, void *user_data);
|
||||
void (*key_press_func)(struct demo_window *window, demo_key key, void *user_data);
|
||||
HWND window;
|
||||
};
|
||||
|
||||
struct demo_swapchain
|
||||
#ifndef VKD3D_CROSSTEST
|
||||
static VkSurfaceKHR demo_window_win32_create_vk_surface(struct demo_window *window, VkInstance vk_instance)
|
||||
{
|
||||
IDXGISwapChain3 *swapchain;
|
||||
};
|
||||
struct demo_window_win32 *window_win32 = CONTAINING_RECORD(window, struct demo_window_win32, w);
|
||||
struct VkWin32SurfaceCreateInfoKHR surface_desc;
|
||||
VkSurfaceKHR vk_surface;
|
||||
|
||||
static inline struct demo_window *demo_window_create(struct demo *demo, const char *title,
|
||||
surface_desc.sType = VK_STRUCTURE_TYPE_WIN32_SURFACE_CREATE_INFO_KHR;
|
||||
surface_desc.pNext = NULL;
|
||||
surface_desc.flags = 0;
|
||||
surface_desc.hinstance = window_win32->instance;
|
||||
surface_desc.hwnd = window_win32->window;
|
||||
if (vkCreateWin32SurfaceKHR(vk_instance, &surface_desc, NULL, &vk_surface) < 0)
|
||||
return VK_NULL_HANDLE;
|
||||
|
||||
return vk_surface;
|
||||
}
|
||||
#endif
|
||||
|
||||
static void demo_window_win32_destroy(struct demo_window *window)
|
||||
{
|
||||
struct demo_window_win32 *window_win32 = CONTAINING_RECORD(window, struct demo_window_win32, w);
|
||||
|
||||
DestroyWindow(window_win32->window);
|
||||
}
|
||||
|
||||
static void demo_window_win32_destroyed(struct demo_window *window)
|
||||
{
|
||||
struct demo_window_win32 *window_win32 = CONTAINING_RECORD(window, struct demo_window_win32, w);
|
||||
|
||||
demo_window_cleanup(&window_win32->w);
|
||||
free(window_win32);
|
||||
}
|
||||
|
||||
static struct demo_window *demo_window_win32_create(struct demo *demo, const char *title,
|
||||
unsigned int width, unsigned int height, void *user_data)
|
||||
{
|
||||
struct demo_window_win32 *window_win32;
|
||||
RECT rect = {0, 0, width, height};
|
||||
struct demo_window *window;
|
||||
int title_size;
|
||||
WCHAR *title_w;
|
||||
DWORD style;
|
||||
|
||||
if (!(window = malloc(sizeof(*window))))
|
||||
if (!(window_win32 = malloc(sizeof(*window_win32))))
|
||||
return NULL;
|
||||
|
||||
#ifdef VKD3D_CROSSTEST
|
||||
if (!demo_window_init(&window_win32->w, demo, user_data))
|
||||
#else
|
||||
if (!demo_window_init(&window_win32->w, demo, user_data,
|
||||
demo_window_win32_create_vk_surface, demo_window_win32_destroy))
|
||||
#endif
|
||||
{
|
||||
free(window_win32);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
title_size = MultiByteToWideChar(CP_UTF8, 0, title, -1, NULL, 0);
|
||||
if (!(title_w = calloc(title_size, sizeof(*title_w))))
|
||||
{
|
||||
free(window);
|
||||
demo_window_cleanup(&window_win32->w);
|
||||
free(window_win32);
|
||||
return NULL;
|
||||
}
|
||||
MultiByteToWideChar(CP_UTF8, 0, title, -1, title_w, title_size);
|
||||
|
||||
window->instance = GetModuleHandle(NULL);
|
||||
window->user_data = user_data;
|
||||
window->expose_func = NULL;
|
||||
window->key_press_func = NULL;
|
||||
window_win32->instance = GetModuleHandle(NULL);
|
||||
|
||||
style = WS_OVERLAPPED | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_VISIBLE;
|
||||
AdjustWindowRect(&rect, style, FALSE);
|
||||
window->hwnd = CreateWindowExW(0, DEMO_WINDOW_CLASS_NAME, title_w, style, CW_USEDEFAULT, CW_USEDEFAULT,
|
||||
rect.right - rect.left, rect.bottom - rect.top, NULL, NULL, window->instance, NULL);
|
||||
window_win32->window = CreateWindowExW(0, DEMO_WIN32_WINDOW_CLASS_NAME, title_w, style, CW_USEDEFAULT,
|
||||
CW_USEDEFAULT, rect.right - rect.left, rect.bottom - rect.top, NULL, NULL, window_win32->instance, NULL);
|
||||
free(title_w);
|
||||
if (!window->hwnd)
|
||||
if (!window_win32->window)
|
||||
{
|
||||
free(window);
|
||||
demo_window_cleanup(&window_win32->w);
|
||||
free(window_win32);
|
||||
return NULL;
|
||||
}
|
||||
SetWindowLongPtrW(window->hwnd, GWLP_USERDATA, (LONG_PTR)window);
|
||||
window->demo = demo;
|
||||
++demo->window_count;
|
||||
SetWindowLongPtrW(window_win32->window, GWLP_USERDATA, (LONG_PTR)window_win32);
|
||||
|
||||
return window;
|
||||
return &window_win32->w;
|
||||
}
|
||||
|
||||
static inline void demo_window_destroy(struct demo_window *window)
|
||||
static void demo_win32_get_dpi(struct demo *demo, double *dpi_x, double *dpi_y)
|
||||
{
|
||||
DestroyWindow(window->hwnd);
|
||||
struct demo_win32 *win32 = &demo->u.win32;
|
||||
|
||||
*dpi_x = *dpi_y = win32->GetDpiForSystem();
|
||||
}
|
||||
|
||||
static inline demo_key demo_key_from_vkey(DWORD vkey)
|
||||
static demo_key demo_key_from_win32_vkey(DWORD vkey)
|
||||
{
|
||||
static const struct
|
||||
{
|
||||
@@ -104,18 +127,23 @@ static inline demo_key demo_key_from_vkey(DWORD vkey)
|
||||
}
|
||||
lookup[] =
|
||||
{
|
||||
{VK_ESCAPE, DEMO_KEY_ESCAPE},
|
||||
{VK_LEFT, DEMO_KEY_LEFT},
|
||||
{VK_RIGHT, DEMO_KEY_RIGHT},
|
||||
{VK_UP, DEMO_KEY_UP},
|
||||
{VK_DOWN, DEMO_KEY_DOWN},
|
||||
{VK_OEM_MINUS, '-'},
|
||||
{VK_OEM_PLUS, '='},
|
||||
{VK_ESCAPE, DEMO_KEY_ESCAPE},
|
||||
{VK_LEFT, DEMO_KEY_LEFT},
|
||||
{VK_UP, DEMO_KEY_UP},
|
||||
{VK_RIGHT, DEMO_KEY_RIGHT},
|
||||
{VK_DOWN, DEMO_KEY_DOWN},
|
||||
{VK_ADD, DEMO_KEY_KP_ADD},
|
||||
{VK_SUBTRACT, DEMO_KEY_KP_SUBTRACT},
|
||||
{VK_F1, DEMO_KEY_F1},
|
||||
};
|
||||
unsigned int i;
|
||||
|
||||
if (vkey >= '0' && vkey <= '9')
|
||||
return vkey;
|
||||
if (vkey >= 'A' && vkey <= 'Z')
|
||||
return vkey;
|
||||
return vkey + 0x20;
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(lookup); ++i)
|
||||
{
|
||||
@@ -126,46 +154,33 @@ static inline demo_key demo_key_from_vkey(DWORD vkey)
|
||||
return DEMO_KEY_UNKNOWN;
|
||||
}
|
||||
|
||||
static inline LRESULT CALLBACK demo_window_proc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam)
|
||||
static LRESULT CALLBACK demo_win32_window_proc(HWND window, UINT message, WPARAM wparam, LPARAM lparam)
|
||||
{
|
||||
struct demo_window *window = (void *)GetWindowLongPtrW(hwnd, GWLP_USERDATA);
|
||||
struct demo_window_win32 *window_win32 = (void *)GetWindowLongPtrW(window, GWLP_USERDATA);
|
||||
|
||||
switch (message)
|
||||
{
|
||||
case WM_PAINT:
|
||||
if (window && window->expose_func)
|
||||
window->expose_func(window, window->user_data);
|
||||
if (window_win32 && window_win32->w.expose_func)
|
||||
window_win32->w.expose_func(&window_win32->w, window_win32->w.user_data);
|
||||
return 0;
|
||||
|
||||
case WM_KEYDOWN:
|
||||
if (!window->key_press_func)
|
||||
if (!window_win32->w.key_press_func)
|
||||
break;
|
||||
window->key_press_func(window, demo_key_from_vkey(wparam), window->user_data);
|
||||
window_win32->w.key_press_func(&window_win32->w,
|
||||
demo_key_from_win32_vkey(wparam), window_win32->w.user_data);
|
||||
return 0;
|
||||
|
||||
case WM_DESTROY:
|
||||
if (!--window->demo->window_count)
|
||||
window->demo->quit = true;
|
||||
free(window);
|
||||
demo_window_win32_destroyed(&window_win32->w);
|
||||
return 0;
|
||||
}
|
||||
|
||||
return DefWindowProcW(hwnd, message, wparam, lparam);
|
||||
return DefWindowProcW(window, message, wparam, lparam);
|
||||
}
|
||||
|
||||
static inline void demo_window_set_key_press_func(struct demo_window *window,
|
||||
void (*key_press_func)(struct demo_window *window, demo_key key, void *user_data))
|
||||
{
|
||||
window->key_press_func = key_press_func;
|
||||
}
|
||||
|
||||
static inline void demo_window_set_expose_func(struct demo_window *window,
|
||||
void (*expose_func)(struct demo_window *window, void *user_data))
|
||||
{
|
||||
window->expose_func = expose_func;
|
||||
}
|
||||
|
||||
static inline void demo_process_events(struct demo *demo)
|
||||
static void demo_win32_process_events(struct demo *demo)
|
||||
{
|
||||
MSG msg = {0};
|
||||
|
||||
@@ -186,18 +201,28 @@ static inline void demo_process_events(struct demo *demo)
|
||||
break;
|
||||
TranslateMessage(&msg);
|
||||
DispatchMessageW(&msg);
|
||||
if (demo->quit)
|
||||
if (!demo->window_count)
|
||||
PostQuitMessage(0);
|
||||
}
|
||||
}
|
||||
|
||||
static inline bool demo_init(struct demo *demo, void *user_data)
|
||||
static void demo_win32_cleanup(struct demo *demo)
|
||||
{
|
||||
UnregisterClassW(DEMO_WIN32_WINDOW_CLASS_NAME, GetModuleHandle(NULL));
|
||||
}
|
||||
|
||||
static inline UINT demo_win32_GetDpiForSystem(void)
|
||||
{
|
||||
return 96;
|
||||
}
|
||||
|
||||
static bool demo_win32_init(struct demo_win32 *win32)
|
||||
{
|
||||
WNDCLASSEXW wc;
|
||||
|
||||
wc.cbSize = sizeof(wc);
|
||||
wc.style = CS_HREDRAW | CS_VREDRAW;
|
||||
wc.lpfnWndProc = demo_window_proc;
|
||||
wc.lpfnWndProc = demo_win32_window_proc;
|
||||
wc.cbClsExtra = 0;
|
||||
wc.cbWndExtra = 0;
|
||||
wc.hInstance = GetModuleHandle(NULL);
|
||||
@@ -205,110 +230,15 @@ static inline bool demo_init(struct demo *demo, void *user_data)
|
||||
wc.hCursor = LoadCursorW(NULL, IDC_ARROW);
|
||||
wc.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH);
|
||||
wc.lpszMenuName = NULL;
|
||||
wc.lpszClassName = DEMO_WINDOW_CLASS_NAME;
|
||||
wc.lpszClassName = DEMO_WIN32_WINDOW_CLASS_NAME;
|
||||
wc.hIconSm = LoadIconW(NULL, IDI_WINLOGO);
|
||||
if (!RegisterClassExW(&wc))
|
||||
return false;
|
||||
|
||||
demo->window_count = 0;
|
||||
demo->quit = false;
|
||||
demo->user_data = user_data;
|
||||
demo->idle_func = NULL;
|
||||
if ((win32->GetDpiForSystem = (void *)GetProcAddress(GetModuleHandleA("user32"), "GetDpiForSystem")))
|
||||
SetProcessDPIAware();
|
||||
else
|
||||
win32->GetDpiForSystem = demo_win32_GetDpiForSystem;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static inline void demo_cleanup(struct demo *demo)
|
||||
{
|
||||
UnregisterClassW(DEMO_WINDOW_CLASS_NAME, GetModuleHandle(NULL));
|
||||
}
|
||||
|
||||
static inline void demo_set_idle_func(struct demo *demo,
|
||||
void (*idle_func)(struct demo *demo, void *user_data))
|
||||
{
|
||||
demo->idle_func = idle_func;
|
||||
}
|
||||
|
||||
static inline struct demo_swapchain *demo_swapchain_create(ID3D12CommandQueue *command_queue,
|
||||
struct demo_window *window, const struct demo_swapchain_desc *desc)
|
||||
{
|
||||
DXGI_SWAP_CHAIN_DESC1 swapchain_desc;
|
||||
struct demo_swapchain *swapchain;
|
||||
IDXGISwapChain1 *swapchain1;
|
||||
IDXGIFactory2 *factory;
|
||||
HRESULT hr;
|
||||
|
||||
if (!(swapchain = malloc(sizeof(*swapchain))))
|
||||
return NULL;
|
||||
|
||||
if (FAILED(CreateDXGIFactory1(&IID_IDXGIFactory2, (void **)&factory)))
|
||||
goto fail;
|
||||
|
||||
memset(&swapchain_desc, 0, sizeof(swapchain_desc));
|
||||
swapchain_desc.BufferCount = desc->buffer_count;
|
||||
swapchain_desc.Width = desc->width;
|
||||
swapchain_desc.Height = desc->height;
|
||||
swapchain_desc.Format = desc->format;
|
||||
swapchain_desc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT;
|
||||
swapchain_desc.SwapEffect = DXGI_SWAP_EFFECT_FLIP_DISCARD;
|
||||
swapchain_desc.SampleDesc.Count = 1;
|
||||
|
||||
hr = IDXGIFactory2_CreateSwapChainForHwnd(factory, (IUnknown *)command_queue,
|
||||
window->hwnd, &swapchain_desc, NULL, NULL, &swapchain1);
|
||||
IDXGIFactory2_Release(factory);
|
||||
if (FAILED(hr))
|
||||
goto fail;
|
||||
|
||||
hr = IDXGISwapChain1_QueryInterface(swapchain1, &IID_IDXGISwapChain3, (void **)&swapchain->swapchain);
|
||||
IDXGISwapChain1_Release(swapchain1);
|
||||
if (FAILED(hr))
|
||||
goto fail;
|
||||
|
||||
return swapchain;
|
||||
|
||||
fail:
|
||||
free(swapchain);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static inline unsigned int demo_swapchain_get_current_back_buffer_index(struct demo_swapchain *swapchain)
|
||||
{
|
||||
return IDXGISwapChain3_GetCurrentBackBufferIndex(swapchain->swapchain);
|
||||
}
|
||||
|
||||
static inline ID3D12Resource *demo_swapchain_get_back_buffer(struct demo_swapchain *swapchain, unsigned int index)
|
||||
{
|
||||
ID3D12Resource *buffer;
|
||||
|
||||
if (FAILED(IDXGISwapChain3_GetBuffer(swapchain->swapchain, index,
|
||||
&IID_ID3D12Resource, (void **)&buffer)))
|
||||
return NULL;
|
||||
|
||||
return buffer;
|
||||
}
|
||||
|
||||
static inline void demo_swapchain_present(struct demo_swapchain *swapchain)
|
||||
{
|
||||
IDXGISwapChain3_Present(swapchain->swapchain, 1, 0);
|
||||
}
|
||||
|
||||
static inline void demo_swapchain_destroy(struct demo_swapchain *swapchain)
|
||||
{
|
||||
IDXGISwapChain3_Release(swapchain->swapchain);
|
||||
free(swapchain);
|
||||
}
|
||||
|
||||
static inline HANDLE demo_create_event(void)
|
||||
{
|
||||
return CreateEventA(NULL, FALSE, FALSE, NULL);
|
||||
}
|
||||
|
||||
static inline unsigned int demo_wait_event(HANDLE event, unsigned int ms)
|
||||
{
|
||||
return WaitForSingleObject(event, ms);
|
||||
}
|
||||
|
||||
static inline void demo_destroy_event(HANDLE event)
|
||||
{
|
||||
CloseHandle(event);
|
||||
}
|
||||
|
612
demos/demo_xcb.h
612
demos/demo_xcb.h
File diff suppressed because it is too large
Load Diff
145
demos/etl16-unicode.h
Normal file
145
demos/etl16-unicode.h
Normal file
@@ -0,0 +1,145 @@
|
||||
/*
|
||||
* Copyright 2025 Henri Verbeet
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/* The glyph data is derived from etl16-unicode.bdf as found on
|
||||
* ftp://ftp.ring.gr.jp/pub/X/opengroup/contrib/fonts/etl-unicode.tar.gz
|
||||
* with the following license:
|
||||
*
|
||||
* Public domain font. Share and enjoy.
|
||||
*/
|
||||
|
||||
/* Each line in etl16_unicode[] below contains the bitmap data for a single
|
||||
* 8x16 glyph, starting at ASCII 0x20 (space). Each byte corresponds to a
|
||||
* single line in the glyph.
|
||||
*
|
||||
* The BDF bitmap data is essentially the same format we're using here, so we
|
||||
* could have extracted the glyphs manually, or perhaps using a small script.
|
||||
* However, bdf2psf can do most of the work for us, by creating a PSF1 font
|
||||
* from the BDF.
|
||||
*
|
||||
* A PSF1 font has a 4 byte header, followed by at least 256 glyphs.
|
||||
* For a 8x16 font, each glyph consists of 16 bytes, one byte for each row.
|
||||
*
|
||||
* We're not interested in control characters or extended ASCII, so we skip
|
||||
* the first 0x4 (header) + 0x20 (control characters) * 0x10 = 516 bytes, and
|
||||
* extract the next (0x80 - 0x20) * 0x10 = 1536 bytes:
|
||||
*
|
||||
* bdf2psf etl16-unicode.bdf standard.equivalents ascii.set 256 /dev/stdout | xxd -i -c 16 -s 516 -l 1536
|
||||
*
|
||||
* and we're done.
|
||||
*/
|
||||
|
||||
static const uint8_t etl16_unicode[] =
|
||||
{
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, 0x08, 0x08, 0x00, 0x00,
|
||||
0x00, 0x00, 0x66, 0x22, 0x22, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x12, 0x12, 0x12, 0x7e, 0x24, 0x24, 0x7e, 0x48, 0x48, 0x48, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x08, 0x3e, 0x49, 0x48, 0x38, 0x0e, 0x09, 0x49, 0x3e, 0x08, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x31, 0x4a, 0x4a, 0x34, 0x08, 0x08, 0x16, 0x29, 0x29, 0x46, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x1c, 0x22, 0x22, 0x22, 0x1c, 0x39, 0x45, 0x42, 0x46, 0x39, 0x00, 0x00,
|
||||
0x00, 0x00, 0x18, 0x08, 0x08, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x04, 0x08, 0x08, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x08, 0x08, 0x04, 0x00,
|
||||
0x00, 0x00, 0x00, 0x20, 0x10, 0x10, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x10, 0x10, 0x20, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x49, 0x2a, 0x1c, 0x2a, 0x49, 0x08, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x08, 0x08, 0x7f, 0x08, 0x08, 0x08, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x08, 0x08, 0x10,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x02, 0x02, 0x04, 0x08, 0x08, 0x10, 0x10, 0x20, 0x40, 0x40, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x18, 0x24, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x24, 0x18, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x08, 0x18, 0x28, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x02, 0x0c, 0x10, 0x20, 0x40, 0x40, 0x7e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x02, 0x1c, 0x02, 0x02, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x04, 0x0c, 0x14, 0x24, 0x44, 0x44, 0x7e, 0x04, 0x04, 0x04, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7e, 0x40, 0x40, 0x40, 0x7c, 0x02, 0x02, 0x02, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x1c, 0x20, 0x40, 0x40, 0x7c, 0x42, 0x42, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7e, 0x02, 0x02, 0x04, 0x04, 0x04, 0x08, 0x08, 0x08, 0x08, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x42, 0x3c, 0x42, 0x42, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x42, 0x3e, 0x02, 0x02, 0x02, 0x04, 0x38, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x08, 0x08, 0x10, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x04, 0x08, 0x10, 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x20, 0x10, 0x08, 0x04, 0x08, 0x10, 0x20, 0x40, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x02, 0x04, 0x08, 0x08, 0x00, 0x08, 0x08, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x1c, 0x22, 0x4a, 0x56, 0x52, 0x52, 0x52, 0x4e, 0x20, 0x1e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x18, 0x24, 0x24, 0x42, 0x42, 0x7e, 0x42, 0x42, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7c, 0x42, 0x42, 0x42, 0x7c, 0x42, 0x42, 0x42, 0x42, 0x7c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x40, 0x40, 0x40, 0x40, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x78, 0x44, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x44, 0x78, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7e, 0x40, 0x40, 0x40, 0x7c, 0x40, 0x40, 0x40, 0x40, 0x7e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7e, 0x40, 0x40, 0x40, 0x7c, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x40, 0x40, 0x4e, 0x42, 0x42, 0x46, 0x3a, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x42, 0x42, 0x7e, 0x42, 0x42, 0x42, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3e, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x1f, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x44, 0x44, 0x38, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x42, 0x44, 0x48, 0x50, 0x60, 0x60, 0x50, 0x48, 0x44, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x7e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x66, 0x66, 0x5a, 0x5a, 0x42, 0x42, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x42, 0x62, 0x62, 0x52, 0x52, 0x4a, 0x4a, 0x46, 0x46, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7c, 0x42, 0x42, 0x42, 0x7c, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x5a, 0x66, 0x3c, 0x03, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7c, 0x42, 0x42, 0x42, 0x7c, 0x48, 0x44, 0x44, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x40, 0x30, 0x0c, 0x02, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7f, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x41, 0x41, 0x41, 0x22, 0x22, 0x22, 0x14, 0x14, 0x08, 0x08, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x42, 0x42, 0x5a, 0x5a, 0x66, 0x66, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x24, 0x24, 0x18, 0x18, 0x24, 0x24, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x41, 0x41, 0x22, 0x22, 0x14, 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x7e, 0x02, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x40, 0x7e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x0e, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x0e, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x40, 0x40, 0x20, 0x10, 0x10, 0x08, 0x08, 0x04, 0x02, 0x02, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x70, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x70, 0x00,
|
||||
0x00, 0x00, 0x18, 0x24, 0x42, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x00,
|
||||
0x00, 0x00, 0x18, 0x10, 0x10, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x02, 0x3e, 0x42, 0x42, 0x46, 0x3a, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x40, 0x40, 0x40, 0x5c, 0x62, 0x42, 0x42, 0x42, 0x42, 0x62, 0x5c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x40, 0x40, 0x40, 0x40, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x02, 0x02, 0x02, 0x3a, 0x46, 0x42, 0x42, 0x42, 0x42, 0x46, 0x3a, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x7e, 0x40, 0x40, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x0c, 0x10, 0x10, 0x10, 0x7c, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x3a, 0x44, 0x44, 0x44, 0x38, 0x20, 0x3c, 0x42, 0x42, 0x3c,
|
||||
0x00, 0x00, 0x00, 0x40, 0x40, 0x40, 0x5c, 0x62, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x08, 0x08, 0x00, 0x18, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x04, 0x04, 0x00, 0x0c, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x48, 0x30,
|
||||
0x00, 0x00, 0x00, 0x00, 0x40, 0x40, 0x44, 0x48, 0x50, 0x60, 0x50, 0x48, 0x44, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x18, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0x49, 0x49, 0x49, 0x49, 0x49, 0x49, 0x49, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x5c, 0x62, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x5c, 0x62, 0x42, 0x42, 0x42, 0x42, 0x62, 0x5c, 0x40, 0x40,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3a, 0x46, 0x42, 0x42, 0x42, 0x42, 0x46, 0x3a, 0x02, 0x02,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x5c, 0x62, 0x42, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x42, 0x40, 0x30, 0x0c, 0x02, 0x42, 0x3c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x10, 0x10, 0x7c, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x0c, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42, 0x46, 0x3a, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x42, 0x24, 0x24, 0x24, 0x18, 0x18, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x49, 0x49, 0x49, 0x49, 0x49, 0x49, 0x36, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x24, 0x18, 0x18, 0x24, 0x42, 0x42, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x42, 0x42, 0x42, 0x42, 0x26, 0x1a, 0x02, 0x02, 0x3c,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x7e, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x0c, 0x10, 0x10, 0x08, 0x08, 0x10, 0x10, 0x08, 0x08, 0x10, 0x10, 0x0c, 0x00,
|
||||
0x00, 0x00, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08,
|
||||
0x00, 0x00, 0x00, 0x30, 0x08, 0x08, 0x10, 0x10, 0x08, 0x08, 0x10, 0x10, 0x08, 0x08, 0x30, 0x00,
|
||||
0x00, 0x00, 0x00, 0x31, 0x49, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0xfc, 0x1b, 0x26, 0xef, 0xc8, 0xe0, 0x43, 0x20, 0x89, 0x58, 0x62, 0x5e, 0x79, 0xba, 0xee, 0x7e,
|
||||
};
|
138
demos/gears.c
138
demos/gears.c
@@ -45,10 +45,9 @@
|
||||
#include <sys/time.h>
|
||||
#include <assert.h>
|
||||
#include <stdio.h>
|
||||
#include <math.h>
|
||||
#include "demo.h"
|
||||
|
||||
#include "gears_hlsl.h"
|
||||
DEMO_EMBED(gears_hlsl, "gears.hlsl");
|
||||
|
||||
struct cxg_fence
|
||||
{
|
||||
@@ -59,7 +58,7 @@ struct cxg_fence
|
||||
|
||||
struct cxg_cb_data
|
||||
{
|
||||
float mvp_matrix[16];
|
||||
struct demo_matrix mvp_matrix;
|
||||
float normal_matrix[12];
|
||||
};
|
||||
|
||||
@@ -120,14 +119,17 @@ struct cx_gears
|
||||
ID3D12Device *device;
|
||||
ID3D12CommandQueue *command_queue;
|
||||
struct demo_swapchain *swapchain;
|
||||
struct
|
||||
{
|
||||
ID3D12Resource *render_target;
|
||||
ID3D12CommandAllocator *command_allocator;
|
||||
ID3D12GraphicsCommandList *command_list;
|
||||
} *swapchain_images;
|
||||
ID3D12DescriptorHeap *rtv_heap, *dsv_heap;
|
||||
unsigned int rtv_descriptor_size;
|
||||
ID3D12Resource *render_targets[3];
|
||||
ID3D12CommandAllocator *command_allocator[3];
|
||||
|
||||
ID3D12RootSignature *root_signature;
|
||||
ID3D12PipelineState *pipeline_state_smooth, *pipeline_state_flat;
|
||||
ID3D12GraphicsCommandList *command_list[3];
|
||||
ID3D12Resource *ds, *cb, *vb[2], *ib;
|
||||
D3D12_VERTEX_BUFFER_VIEW vbv[2];
|
||||
D3D12_INDEX_BUFFER_VIEW ibv;
|
||||
@@ -142,7 +144,7 @@ struct cx_gears
|
||||
|
||||
static void cxg_populate_command_list(struct cx_gears *cxg, unsigned int rt_idx)
|
||||
{
|
||||
ID3D12GraphicsCommandList *command_list = cxg->command_list[rt_idx];
|
||||
ID3D12GraphicsCommandList *command_list = cxg->swapchain_images[rt_idx].command_list;
|
||||
static const float clear_colour[] = {0.0f, 0.0f, 0.0f, 1.0f};
|
||||
|
||||
D3D12_CPU_DESCRIPTOR_HANDLE rtv_handle, dsv_handle;
|
||||
@@ -150,10 +152,11 @@ static void cxg_populate_command_list(struct cx_gears *cxg, unsigned int rt_idx)
|
||||
HRESULT hr;
|
||||
size_t i;
|
||||
|
||||
hr = ID3D12CommandAllocator_Reset(cxg->command_allocator[rt_idx]);
|
||||
hr = ID3D12CommandAllocator_Reset(cxg->swapchain_images[rt_idx].command_allocator);
|
||||
assert(SUCCEEDED(hr));
|
||||
|
||||
hr = ID3D12GraphicsCommandList_Reset(command_list, cxg->command_allocator[rt_idx], cxg->pipeline_state_flat);
|
||||
hr = ID3D12GraphicsCommandList_Reset(command_list,
|
||||
cxg->swapchain_images[rt_idx].command_allocator, cxg->pipeline_state_flat);
|
||||
assert(SUCCEEDED(hr));
|
||||
|
||||
ID3D12GraphicsCommandList_SetGraphicsRootSignature(command_list, cxg->root_signature);
|
||||
@@ -165,7 +168,7 @@ static void cxg_populate_command_list(struct cx_gears *cxg, unsigned int rt_idx)
|
||||
|
||||
barrier.Type = D3D12_RESOURCE_BARRIER_TYPE_TRANSITION;
|
||||
barrier.Flags = D3D12_RESOURCE_BARRIER_FLAG_NONE;
|
||||
barrier.Transition.pResource = cxg->render_targets[rt_idx];
|
||||
barrier.Transition.pResource = cxg->swapchain_images[rt_idx].render_target;
|
||||
barrier.Transition.Subresource = D3D12_RESOURCE_BARRIER_ALL_SUBRESOURCES;
|
||||
barrier.Transition.StateBefore = D3D12_RESOURCE_STATE_PRESENT;
|
||||
barrier.Transition.StateAfter = D3D12_RESOURCE_STATE_RENDER_TARGET;
|
||||
@@ -226,44 +229,24 @@ static void cxg_wait_for_previous_frame(struct cx_gears *cxg)
|
||||
|
||||
static void cxg_update_mvp(struct cx_gears *cxg)
|
||||
{
|
||||
struct demo_matrix projection, world;
|
||||
float s1 = sinf(cxg->theta);
|
||||
float c1 = cosf(cxg->theta);
|
||||
float s2 = sinf(cxg->phi);
|
||||
float c2 = cosf(cxg->phi);
|
||||
float z_offset = -40.0f;
|
||||
float z_max = 60.0f;
|
||||
float z_min = 5.0f;
|
||||
float sx = z_min;
|
||||
float sy = z_min * cxg->aspect_ratio;
|
||||
float sz = -((z_max + z_min) / (z_max - z_min));
|
||||
float d = (-2.0f * z_max * z_min) / (z_max - z_min);
|
||||
unsigned int i, j;
|
||||
float world[] =
|
||||
{
|
||||
c1, s2 * s1, c2 * -s1, 0.0f,
|
||||
0.0f, c2, s2, 0.0f,
|
||||
s1, -s2 * c1, c2 * c1, 0.0f,
|
||||
0.0f, 0.0f, z_offset, 1.0f,
|
||||
};
|
||||
float projection[] =
|
||||
{
|
||||
sx, 0.0f, 0.0f, 0.0f,
|
||||
0.0f, sy, 0.0f, 0.0f,
|
||||
0.0f, 0.0f, sz, -1.0f,
|
||||
0.0f, 0.0f, d, 0.0f,
|
||||
};
|
||||
|
||||
for (i = 0; i < 4; ++i)
|
||||
{
|
||||
for (j = 0; j < 4; ++j)
|
||||
{
|
||||
cxg->cb_data->mvp_matrix[i * 4 + j] = projection[j] * world[i * 4]
|
||||
+ projection[j + 4] * world[i * 4 + 1]
|
||||
+ projection[j + 8] * world[i * 4 + 2]
|
||||
+ projection[j + 12] * world[i * 4 + 3];
|
||||
}
|
||||
}
|
||||
memcpy(cxg->cb_data->normal_matrix, world, sizeof(cxg->cb_data->normal_matrix));
|
||||
world = (struct demo_matrix)
|
||||
{{
|
||||
{ c1, s2 * s1, c2 * -s1, 0.0f},
|
||||
{0.0f, c2, s2, 0.0f},
|
||||
{ s1, -s2 * c1, c2 * c1, 0.0f},
|
||||
{0.0f, 0.0f, z_offset, 1.0f},
|
||||
}};
|
||||
demo_matrix_perspective_rh(&projection, 2.0f, 2.0f / cxg->aspect_ratio, 5.0f, 60.0f);
|
||||
|
||||
demo_matrix_multiply(&cxg->cb_data->mvp_matrix, &world, &projection);
|
||||
memcpy(cxg->cb_data->normal_matrix, &world, sizeof(cxg->cb_data->normal_matrix));
|
||||
}
|
||||
|
||||
static void cxg_render_frame(struct cx_gears *cxg)
|
||||
@@ -295,7 +278,7 @@ static void cxg_render_frame(struct cx_gears *cxg)
|
||||
demo_vec4_set(&cxg->instance_data[2].transform, cosf(a), sinf(a), -3.1f, 4.2f);
|
||||
|
||||
ID3D12CommandQueue_ExecuteCommandLists(cxg->command_queue, 1,
|
||||
(ID3D12CommandList **)&cxg->command_list[cxg->rt_idx]);
|
||||
(ID3D12CommandList **)&cxg->swapchain_images[cxg->rt_idx].command_list);
|
||||
demo_swapchain_present(cxg->swapchain);
|
||||
cxg_wait_for_previous_frame(cxg);
|
||||
}
|
||||
@@ -304,16 +287,14 @@ static void cxg_destroy_pipeline(struct cx_gears *cxg)
|
||||
{
|
||||
unsigned int i;
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(cxg->command_allocator); ++i)
|
||||
{
|
||||
ID3D12CommandAllocator_Release(cxg->command_allocator[i]);
|
||||
}
|
||||
for (i = 0; i < ARRAY_SIZE(cxg->render_targets); ++i)
|
||||
{
|
||||
ID3D12Resource_Release(cxg->render_targets[i]);
|
||||
}
|
||||
ID3D12DescriptorHeap_Release(cxg->dsv_heap);
|
||||
ID3D12DescriptorHeap_Release(cxg->rtv_heap);
|
||||
for (i = 0; i < demo_swapchain_get_back_buffer_count(cxg->swapchain); ++i)
|
||||
{
|
||||
ID3D12CommandAllocator_Release(cxg->swapchain_images[i].command_allocator);
|
||||
ID3D12Resource_Release(cxg->swapchain_images[i].render_target);
|
||||
}
|
||||
free(cxg->swapchain_images);
|
||||
demo_swapchain_destroy(cxg->swapchain);
|
||||
ID3D12CommandQueue_Release(cxg->command_queue);
|
||||
ID3D12Device_Release(cxg->device);
|
||||
@@ -325,7 +306,7 @@ static void cxg_load_pipeline(struct cx_gears *cxg)
|
||||
D3D12_CPU_DESCRIPTOR_HANDLE rtv_handle;
|
||||
D3D12_DESCRIPTOR_HEAP_DESC heap_desc;
|
||||
D3D12_COMMAND_QUEUE_DESC queue_desc;
|
||||
unsigned int i;
|
||||
unsigned int i, rt_count;
|
||||
HRESULT hr;
|
||||
|
||||
hr = D3D12CreateDevice(NULL, D3D_FEATURE_LEVEL_11_0, &IID_ID3D12Device, (void **)&cxg->device);
|
||||
@@ -338,16 +319,19 @@ static void cxg_load_pipeline(struct cx_gears *cxg)
|
||||
&IID_ID3D12CommandQueue, (void **)&cxg->command_queue);
|
||||
assert(SUCCEEDED(hr));
|
||||
|
||||
swapchain_desc.buffer_count = ARRAY_SIZE(cxg->render_targets);
|
||||
swapchain_desc.buffer_count = 3;
|
||||
swapchain_desc.format = DXGI_FORMAT_B8G8R8A8_UNORM;
|
||||
swapchain_desc.width = cxg->width;
|
||||
swapchain_desc.height = cxg->height;
|
||||
cxg->swapchain = demo_swapchain_create(cxg->command_queue, cxg->window, &swapchain_desc);
|
||||
assert(cxg->swapchain);
|
||||
rt_count = demo_swapchain_get_back_buffer_count(cxg->swapchain);
|
||||
cxg->swapchain_images = calloc(rt_count, sizeof(*cxg->swapchain_images));
|
||||
assert(cxg->swapchain_images);
|
||||
cxg->rt_idx = demo_swapchain_get_current_back_buffer_index(cxg->swapchain);
|
||||
|
||||
memset(&heap_desc, 0, sizeof(heap_desc));
|
||||
heap_desc.NumDescriptors = ARRAY_SIZE(cxg->render_targets);
|
||||
heap_desc.NumDescriptors = rt_count;
|
||||
heap_desc.Type = D3D12_DESCRIPTOR_HEAP_TYPE_RTV;
|
||||
heap_desc.Flags = D3D12_DESCRIPTOR_HEAP_FLAG_NONE;
|
||||
hr = ID3D12Device_CreateDescriptorHeap(cxg->device, &heap_desc,
|
||||
@@ -357,10 +341,10 @@ static void cxg_load_pipeline(struct cx_gears *cxg)
|
||||
cxg->rtv_descriptor_size = ID3D12Device_GetDescriptorHandleIncrementSize(cxg->device,
|
||||
D3D12_DESCRIPTOR_HEAP_TYPE_RTV);
|
||||
rtv_handle = ID3D12DescriptorHeap_GetCPUDescriptorHandleForHeapStart(cxg->rtv_heap);
|
||||
for (i = 0; i < ARRAY_SIZE(cxg->render_targets); ++i)
|
||||
for (i = 0; i < rt_count; ++i)
|
||||
{
|
||||
cxg->render_targets[i] = demo_swapchain_get_back_buffer(cxg->swapchain, i);
|
||||
ID3D12Device_CreateRenderTargetView(cxg->device, cxg->render_targets[i], NULL, rtv_handle);
|
||||
cxg->swapchain_images[i].render_target = demo_swapchain_get_back_buffer(cxg->swapchain, i);
|
||||
ID3D12Device_CreateRenderTargetView(cxg->device, cxg->swapchain_images[i].render_target, NULL, rtv_handle);
|
||||
rtv_handle.ptr += cxg->rtv_descriptor_size;
|
||||
}
|
||||
|
||||
@@ -371,10 +355,10 @@ static void cxg_load_pipeline(struct cx_gears *cxg)
|
||||
&IID_ID3D12DescriptorHeap, (void **)&cxg->dsv_heap);
|
||||
assert(SUCCEEDED(hr));
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(cxg->command_allocator); ++i)
|
||||
for (i = 0; i < rt_count; ++i)
|
||||
{
|
||||
hr = ID3D12Device_CreateCommandAllocator(cxg->device, D3D12_COMMAND_LIST_TYPE_DIRECT,
|
||||
&IID_ID3D12CommandAllocator, (void **)&cxg->command_allocator[i]);
|
||||
&IID_ID3D12CommandAllocator, (void **)&cxg->swapchain_images[i].command_allocator);
|
||||
assert(SUCCEEDED(hr));
|
||||
}
|
||||
}
|
||||
@@ -397,8 +381,8 @@ static void cxg_destroy_assets(struct cx_gears *cxg)
|
||||
ID3D12Resource_Unmap(cxg->cb, 0, NULL);
|
||||
ID3D12Resource_Release(cxg->cb);
|
||||
ID3D12Resource_Release(cxg->ds);
|
||||
for (i = 0; i < ARRAY_SIZE(cxg->command_list); ++i)
|
||||
ID3D12GraphicsCommandList_Release(cxg->command_list[i]);
|
||||
for (i = 0; i < demo_swapchain_get_back_buffer_count(cxg->swapchain); ++i)
|
||||
ID3D12GraphicsCommandList_Release(cxg->swapchain_images[i].command_list);
|
||||
ID3D12PipelineState_Release(cxg->pipeline_state_smooth);
|
||||
ID3D12PipelineState_Release(cxg->pipeline_state_flat);
|
||||
ID3D12RootSignature_Release(cxg->root_signature);
|
||||
@@ -681,11 +665,14 @@ static void cxg_load_assets(struct cx_gears *cxg)
|
||||
hr = demo_create_root_signature(cxg->device, &root_signature_desc, &cxg->root_signature);
|
||||
assert(SUCCEEDED(hr));
|
||||
|
||||
hr = D3DCompile(gears_hlsl, strlen(gears_hlsl), NULL, NULL, NULL, "vs_main", "vs_5_0", 0, 0, &vs, NULL);
|
||||
hr = D3DCompile(gears_hlsl, gears_hlsl_size, "gears.hlsl",
|
||||
NULL, NULL, "vs_main", "vs_5_0", 0, 0, &vs, NULL);
|
||||
assert(SUCCEEDED(hr));
|
||||
hr = D3DCompile(gears_hlsl, strlen(gears_hlsl), NULL, NULL, NULL, "ps_main_flat", "ps_5_0", 0, 0, &ps_flat, NULL);
|
||||
hr = D3DCompile(gears_hlsl, gears_hlsl_size, "gears.hlsl",
|
||||
NULL, NULL, "ps_main_flat", "ps_5_0", 0, 0, &ps_flat, NULL);
|
||||
assert(SUCCEEDED(hr));
|
||||
hr = D3DCompile(gears_hlsl, strlen(gears_hlsl), NULL, NULL, NULL, "ps_main_smooth", "ps_5_0", 0, 0, &ps_smooth, NULL);
|
||||
hr = D3DCompile(gears_hlsl, gears_hlsl_size, "gears.hlsl",
|
||||
NULL, NULL, "ps_main_smooth", "ps_5_0", 0, 0, &ps_smooth, NULL);
|
||||
assert(SUCCEEDED(hr));
|
||||
|
||||
memset(&pso_desc, 0, sizeof(pso_desc));
|
||||
@@ -724,13 +711,13 @@ static void cxg_load_assets(struct cx_gears *cxg)
|
||||
ID3D10Blob_Release(ps_flat);
|
||||
ID3D10Blob_Release(ps_smooth);
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(cxg->command_list); ++i)
|
||||
for (i = 0; i < demo_swapchain_get_back_buffer_count(cxg->swapchain); ++i)
|
||||
{
|
||||
hr = ID3D12Device_CreateCommandList(cxg->device, 0, D3D12_COMMAND_LIST_TYPE_DIRECT,
|
||||
cxg->command_allocator[i], cxg->pipeline_state_flat,
|
||||
&IID_ID3D12GraphicsCommandList, (void **)&cxg->command_list[i]);
|
||||
cxg->swapchain_images[i].command_allocator, cxg->pipeline_state_flat,
|
||||
&IID_ID3D12GraphicsCommandList, (void **)&cxg->swapchain_images[i].command_list);
|
||||
assert(SUCCEEDED(hr));
|
||||
hr = ID3D12GraphicsCommandList_Close(cxg->command_list[i]);
|
||||
hr = ID3D12GraphicsCommandList_Close(cxg->swapchain_images[i].command_list);
|
||||
assert(SUCCEEDED(hr));
|
||||
}
|
||||
|
||||
@@ -805,7 +792,6 @@ static void cxg_key_press(struct demo_window *window, demo_key key, void *user_d
|
||||
switch (key)
|
||||
{
|
||||
case 'a':
|
||||
case 'A':
|
||||
cxg->animate = !cxg->animate;
|
||||
break;
|
||||
case DEMO_KEY_ESCAPE:
|
||||
@@ -846,12 +832,17 @@ static int cxg_main(void)
|
||||
{
|
||||
unsigned int width = 300, height = 300;
|
||||
struct cx_gears cxg;
|
||||
double dpi_x, dpi_y;
|
||||
size_t i;
|
||||
|
||||
memset(&cxg, 0, sizeof(cxg));
|
||||
if (!demo_init(&cxg.demo, &cxg))
|
||||
return EXIT_FAILURE;
|
||||
demo_set_idle_func(&cxg.demo, cxg_idle);
|
||||
|
||||
demo_get_dpi(&cxg.demo, &dpi_x, &dpi_y);
|
||||
width *= dpi_x / 96.0;
|
||||
height *= dpi_y / 96.0;
|
||||
cxg.window = demo_window_create(&cxg.demo, "Vkd3d Gears", width, height, &cxg);
|
||||
demo_window_set_key_press_func(cxg.window, cxg_key_press);
|
||||
demo_window_set_expose_func(cxg.window, cxg_expose);
|
||||
@@ -873,10 +864,13 @@ static int cxg_main(void)
|
||||
|
||||
cxg_load_pipeline(&cxg);
|
||||
cxg_load_assets(&cxg);
|
||||
cxg_populate_command_list(&cxg, 0);
|
||||
cxg_populate_command_list(&cxg, 1);
|
||||
cxg_populate_command_list(&cxg, 2);
|
||||
for (i = 0; i < demo_swapchain_get_back_buffer_count(cxg.swapchain); ++i)
|
||||
{
|
||||
cxg_populate_command_list(&cxg, i);
|
||||
}
|
||||
|
||||
printf("vkd3d-gears: Running on \"%s\" using %s.\n",
|
||||
demo_swapchain_get_device_name(cxg.swapchain), demo_get_platform_name());
|
||||
demo_process_events(&cxg.demo);
|
||||
|
||||
cxg_wait_for_previous_frame(&cxg);
|
||||
|
73
demos/gears.hlsl
Normal file
73
demos/gears.hlsl
Normal file
@@ -0,0 +1,73 @@
|
||||
/*
|
||||
* Copyright 2016 Henri Verbeet for CodeWeavers
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
cbuffer gear_block : register(b0)
|
||||
{
|
||||
float4x4 mvp_matrix;
|
||||
float3x3 normal_matrix;
|
||||
};
|
||||
|
||||
struct vs_in
|
||||
{
|
||||
float4 position : POSITION;
|
||||
float3 normal : NORMAL;
|
||||
float3 diffuse : DIFFUSE;
|
||||
float4 transform : TRANSFORM;
|
||||
};
|
||||
|
||||
struct vs_out
|
||||
{
|
||||
float4 position : SV_POSITION;
|
||||
float4 colour : COLOR;
|
||||
};
|
||||
|
||||
struct vs_out vs_main(struct vs_in i)
|
||||
{
|
||||
const float3 l_pos = float3(5.0, 5.0, 10.0);
|
||||
float3 dir, normal;
|
||||
float4 position;
|
||||
struct vs_out o;
|
||||
float att;
|
||||
|
||||
position.x = i.transform.x * i.position.x - i.transform.y * i.position.y + i.transform.z;
|
||||
position.y = i.transform.x * i.position.y + i.transform.y * i.position.x + i.transform.w;
|
||||
position.zw = i.position.zw;
|
||||
|
||||
o.position = mul(mvp_matrix, position);
|
||||
dir = normalize(l_pos - o.position.xyz / o.position.w);
|
||||
|
||||
normal.x = i.transform.x * i.normal.x - i.transform.y * i.normal.y;
|
||||
normal.y = i.transform.x * i.normal.y + i.transform.y * i.normal.x;
|
||||
normal.z = i.normal.z;
|
||||
att = 0.2 + dot(dir, normalize(mul(normal_matrix, normal)));
|
||||
|
||||
o.colour.xyz = i.diffuse.xyz * att;
|
||||
o.colour.w = 1.0;
|
||||
|
||||
return o;
|
||||
}
|
||||
|
||||
float4 ps_main_smooth(float4 position : SV_POSITION, float4 colour : COLOR) : SV_TARGET
|
||||
{
|
||||
return colour;
|
||||
}
|
||||
|
||||
float4 ps_main_flat(float4 position : SV_POSITION, nointerpolation float4 colour : COLOR) : SV_TARGET
|
||||
{
|
||||
return colour;
|
||||
}
|
@@ -1,56 +0,0 @@
|
||||
static const char gears_hlsl[] =
|
||||
"cbuffer gear_block : register(b0)\n"
|
||||
"{\n"
|
||||
" float4x4 mvp_matrix;\n"
|
||||
" float3x3 normal_matrix;\n"
|
||||
"};\n"
|
||||
"\n"
|
||||
"struct vs_in\n"
|
||||
"{\n"
|
||||
" float4 position : POSITION;\n"
|
||||
" float3 normal : NORMAL;\n"
|
||||
" float3 diffuse : DIFFUSE;\n"
|
||||
" float4 transform : TRANSFORM;\n"
|
||||
"};\n"
|
||||
"\n"
|
||||
"struct vs_out\n"
|
||||
"{\n"
|
||||
" float4 position : SV_POSITION;\n"
|
||||
" float4 colour : COLOR;\n"
|
||||
"};\n"
|
||||
"\n"
|
||||
"struct vs_out vs_main(struct vs_in i)\n"
|
||||
"{\n"
|
||||
" const float3 l_pos = float3(5.0, 5.0, 10.0);\n"
|
||||
" float3 dir, normal;\n"
|
||||
" float4 position;\n"
|
||||
" struct vs_out o;\n"
|
||||
" float att;\n"
|
||||
"\n"
|
||||
" position.x = i.transform.x * i.position.x - i.transform.y * i.position.y + i.transform.z;\n"
|
||||
" position.y = i.transform.x * i.position.y + i.transform.y * i.position.x + i.transform.w;\n"
|
||||
" position.zw = i.position.zw;\n"
|
||||
"\n"
|
||||
" o.position = mul(mvp_matrix, position);\n"
|
||||
" dir = normalize(l_pos - o.position.xyz / o.position.w);\n"
|
||||
"\n"
|
||||
" normal.x = i.transform.x * i.normal.x - i.transform.y * i.normal.y;\n"
|
||||
" normal.y = i.transform.x * i.normal.y + i.transform.y * i.normal.x;\n"
|
||||
" normal.z = i.normal.z;\n"
|
||||
" att = 0.2 + dot(dir, normalize(mul(normal_matrix, normal)));\n"
|
||||
"\n"
|
||||
" o.colour.xyz = i.diffuse.xyz * att;\n"
|
||||
" o.colour.w = 1.0;\n"
|
||||
"\n"
|
||||
" return o;\n"
|
||||
"}\n"
|
||||
"\n"
|
||||
"float4 ps_main_smooth(float4 position : SV_POSITION, float4 colour : COLOR) : SV_TARGET\n"
|
||||
"{\n"
|
||||
" return colour;\n"
|
||||
"}\n"
|
||||
"\n"
|
||||
"float4 ps_main_flat(float4 position : SV_POSITION, nointerpolation float4 colour : COLOR) : SV_TARGET\n"
|
||||
"{\n"
|
||||
" return colour;\n"
|
||||
"}\n";
|
151
demos/make_objc
Executable file
151
demos/make_objc
Executable file
@@ -0,0 +1,151 @@
|
||||
#!/usr/bin/perl -w
|
||||
#
|
||||
# Copyright 2025 Henri Verbeet
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License as published by the Free Software Foundation; either
|
||||
# version 2.1 of the License, or (at your option) any later version.
|
||||
#
|
||||
# This library is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use JSON;
|
||||
use open ':utf8';
|
||||
binmode STDOUT, ':utf8';
|
||||
|
||||
sub method_name($)
|
||||
{
|
||||
shift->{selector} =~ s/(:.*)//r;
|
||||
}
|
||||
|
||||
sub method_parameters($$)
|
||||
{
|
||||
my ($method, $method_type) = @_;
|
||||
|
||||
my $parameters = join ", ", $method_type eq "class" ? () : "id self",
|
||||
map {"$_->{type} $_->{name}"} @{$method->{parameters}};
|
||||
|
||||
length $parameters ? $parameters : "void";
|
||||
}
|
||||
|
||||
sub send_function($)
|
||||
{
|
||||
shift->{'return-float'} ? "vkd3d_objc_msgSend_fpret" : "objc_msgSend";
|
||||
}
|
||||
|
||||
sub invocation_type($$)
|
||||
{
|
||||
my ($method, $method_type) = @_;
|
||||
|
||||
"$method->{'return-type'} (*)(" . join(", ", $method_type eq "class" ? "Class" : "id", "SEL",
|
||||
map {$_->{type}} @{$method->{parameters}}) . ")";
|
||||
}
|
||||
|
||||
sub invocation_parameters($$$)
|
||||
{
|
||||
my ($method, $interface_name, $method_type) = @_;
|
||||
|
||||
join ", ", $method_type eq "class" ? "objc_getClass(\"$interface_name\")" : "self",
|
||||
"sel_registerName(\"$method->{selector}\")", map {$_->{name}} @{$method->{parameters}};
|
||||
}
|
||||
|
||||
sub invocation($$$)
|
||||
{
|
||||
my ($method, $interface_name, $method_type) = @_;
|
||||
|
||||
($method->{'return-type'} eq "void" ? "" : "return ")
|
||||
. "((${\invocation_type $method, $method_type})f)"
|
||||
. "(${\invocation_parameters $method, $interface_name, $method_type});";
|
||||
}
|
||||
|
||||
sub print_method($$$)
|
||||
{
|
||||
my ($method, $interface_name, $method_type) = @_;
|
||||
|
||||
print "static inline $method->{'return-type'} "
|
||||
. "${interface_name}_${\method_name $method}(${\method_parameters $method, $method_type})\n";
|
||||
print "{\n";
|
||||
print " void *f = ${\send_function $method};\n";
|
||||
print " ${\invocation $method, $interface_name, $method_type}\n";
|
||||
print "}\n\n";
|
||||
}
|
||||
|
||||
sub print_property($$)
|
||||
{
|
||||
my ($property, $interface_name) = @_;
|
||||
|
||||
my $method =
|
||||
{
|
||||
'return-type' => $property->{type},
|
||||
'return-float' => $property->{float},
|
||||
selector => $property->{getter} // $property->{name},
|
||||
};
|
||||
my $method_type = $property->{class} ? "class" : "instance";
|
||||
|
||||
print_method $method, $interface_name, $method_type;
|
||||
if (!$property->{readonly})
|
||||
{
|
||||
$method->{'return-type'} = "void";
|
||||
$method->{'return-float'} = 0;
|
||||
$method->{selector} = "set${\ucfirst $property->{name}}:";
|
||||
$method->{parameters} = [$property];
|
||||
print_method $method, $interface_name, $method_type;
|
||||
}
|
||||
}
|
||||
|
||||
sub print_interface(_)
|
||||
{
|
||||
my ($interface) = @_;
|
||||
|
||||
print_method $_, $interface->{name}, "class" foreach (@{$interface->{'class-methods'}});
|
||||
print_method $_, $interface->{name}, "instance" foreach (@{$interface->{'instance-methods'}});
|
||||
print_property $_, $interface->{name} foreach (@{$interface->{properties}});
|
||||
}
|
||||
|
||||
sub print_header($)
|
||||
{
|
||||
my ($grammar) = @_;
|
||||
|
||||
my $guard = "__VKD3D_${\uc $grammar->{name}}_H__";
|
||||
|
||||
print "/*\n";
|
||||
print " * This file is automatically generated.\n";
|
||||
print " * The original source is covered by the following license:\n";
|
||||
print " *\n";
|
||||
print map {" * $_" =~ s/ +$//r . "\n"} @{$grammar->{copyright}};
|
||||
print " */\n\n";
|
||||
|
||||
print "#ifndef $guard\n";
|
||||
print "#define $guard\n\n";
|
||||
|
||||
print "#include <objc/objc-runtime.h>\n\n";
|
||||
|
||||
print "#ifdef __arm64__\n";
|
||||
print "# define vkd3d_objc_msgSend_fpret objc_msgSend\n";
|
||||
print "#else\n";
|
||||
print "# define vkd3d_objc_msgSend_fpret objc_msgSend_fpret\n";
|
||||
print "#endif /* __arm64__ */\n\n";
|
||||
|
||||
print_interface foreach (@{$grammar->{interfaces}});
|
||||
|
||||
print "#undef vkd3d_objc_msgSend_fpret\n\n";
|
||||
|
||||
print "#endif /* $guard */\n";
|
||||
}
|
||||
|
||||
die "No input file specified.\n" unless @ARGV;
|
||||
print_header do
|
||||
{
|
||||
local $/;
|
||||
open my $fh, '<', $ARGV[0] or die $!;
|
||||
decode_json <$fh>;
|
||||
};
|
1083
demos/teapot.c
Normal file
1083
demos/teapot.c
Normal file
File diff suppressed because it is too large
Load Diff
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user