mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
Compare commits
1429 Commits
vkd3d-1.13
...
vkd3d-1.16
Author | SHA1 | Date | |
---|---|---|---|
|
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
|
Andrew Eikum
|
||||||
Andrey Gusev
|
Andrey Gusev
|
||||||
Anna (navi) Figueiredo Gomes
|
Anna (navi) Figueiredo Gomes
|
||||||
|
Arkadiusz Hiler
|
||||||
Atharva Nimbalkar
|
Atharva Nimbalkar
|
||||||
Biswapriyo Nath
|
Biswapriyo Nath
|
||||||
Brendan Shanks
|
Brendan Shanks
|
||||||
@@ -15,6 +16,7 @@ Elizabeth Figura
|
|||||||
Ethan Lee
|
Ethan Lee
|
||||||
Evan Tang
|
Evan Tang
|
||||||
Fabian Maurer
|
Fabian Maurer
|
||||||
|
Feifan He
|
||||||
Florian Weimer
|
Florian Weimer
|
||||||
Francisco Casas
|
Francisco Casas
|
||||||
Francois Gouget
|
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)
|
complete list)
|
||||||
|
|
||||||
Vkd3d is free software; you can redistribute it and/or modify it under
|
Vkd3d is free software; you can redistribute it and/or modify it under
|
||||||
|
312
ChangeLog.md
312
ChangeLog.md
@@ -1,3 +1,315 @@
|
|||||||
|
# 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)
|
# What's new in vkd3d 1.13 (29 August 2024)
|
||||||
|
|
||||||
### libvkd3d
|
### libvkd3d
|
||||||
|
@@ -10,6 +10,7 @@ OPTIMIZE_OUTPUT_FOR_C = YES
|
|||||||
EXTRACT_STATIC = YES
|
EXTRACT_STATIC = YES
|
||||||
QUIET = YES
|
QUIET = YES
|
||||||
WARN_IF_UNDOCUMENTED = NO
|
WARN_IF_UNDOCUMENTED = NO
|
||||||
|
WARN_IF_INCOMPLETE_DOC = NO
|
||||||
LATEX_BATCHMODE = YES
|
LATEX_BATCHMODE = YES
|
||||||
|
|
||||||
INPUT = @srcdir@/include/vkd3d.h \
|
INPUT = @srcdir@/include/vkd3d.h \
|
||||||
|
125
Makefile.am
125
Makefile.am
@@ -2,6 +2,12 @@ ACLOCAL_AMFLAGS = -I m4
|
|||||||
AM_CFLAGS = @VKD3D_CFLAGS@
|
AM_CFLAGS = @VKD3D_CFLAGS@
|
||||||
AM_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/private -I$(builddir)/include/private
|
AM_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/private -I$(builddir)/include/private
|
||||||
AM_LDFLAGS = -no-undefined
|
AM_LDFLAGS = -no-undefined
|
||||||
|
VKD3D_PERL = $(PERL) -w
|
||||||
|
|
||||||
|
objc_headers = \
|
||||||
|
include/private/appkit.h \
|
||||||
|
include/private/foundation.h \
|
||||||
|
include/private/quartzcore.h
|
||||||
|
|
||||||
widl_headers = \
|
widl_headers = \
|
||||||
include/vkd3d_d3d12.h \
|
include/vkd3d_d3d12.h \
|
||||||
@@ -50,7 +56,6 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/all.shader_test \
|
tests/hlsl/all.shader_test \
|
||||||
tests/hlsl/alpha-test.shader_test \
|
tests/hlsl/alpha-test.shader_test \
|
||||||
tests/hlsl/angle-unit.shader_test \
|
tests/hlsl/angle-unit.shader_test \
|
||||||
tests/hlsl/annotations.shader_test \
|
|
||||||
tests/hlsl/any.shader_test \
|
tests/hlsl/any.shader_test \
|
||||||
tests/hlsl/arithmetic-float-uniform.shader_test \
|
tests/hlsl/arithmetic-float-uniform.shader_test \
|
||||||
tests/hlsl/arithmetic-float.shader_test \
|
tests/hlsl/arithmetic-float.shader_test \
|
||||||
@@ -64,6 +69,7 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/asint.shader_test \
|
tests/hlsl/asint.shader_test \
|
||||||
tests/hlsl/asuint.shader_test \
|
tests/hlsl/asuint.shader_test \
|
||||||
tests/hlsl/attributes.shader_test \
|
tests/hlsl/attributes.shader_test \
|
||||||
|
tests/hlsl/barriers.shader_test \
|
||||||
tests/hlsl/bitwise-assignment.shader_test \
|
tests/hlsl/bitwise-assignment.shader_test \
|
||||||
tests/hlsl/bitwise.shader_test \
|
tests/hlsl/bitwise.shader_test \
|
||||||
tests/hlsl/bool-cast.shader_test \
|
tests/hlsl/bool-cast.shader_test \
|
||||||
@@ -81,25 +87,35 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/ceil.shader_test \
|
tests/hlsl/ceil.shader_test \
|
||||||
tests/hlsl/cf-cond-types.shader_test \
|
tests/hlsl/cf-cond-types.shader_test \
|
||||||
tests/hlsl/clamp.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/clip.shader_test \
|
||||||
tests/hlsl/combined-samplers.shader_test \
|
tests/hlsl/combined-samplers.shader_test \
|
||||||
tests/hlsl/comma.shader_test \
|
tests/hlsl/comma.shader_test \
|
||||||
tests/hlsl/compute.shader_test \
|
tests/hlsl/compute.shader_test \
|
||||||
tests/hlsl/conditional.shader_test \
|
tests/hlsl/conditional.shader_test \
|
||||||
tests/hlsl/const.shader_test \
|
tests/hlsl/const.shader_test \
|
||||||
|
tests/hlsl/constructgswithso.shader_test \
|
||||||
tests/hlsl/coverage.shader_test \
|
tests/hlsl/coverage.shader_test \
|
||||||
tests/hlsl/cross.shader_test \
|
tests/hlsl/cross.shader_test \
|
||||||
tests/hlsl/d3dcolor-to-ubyte4.shader_test \
|
tests/hlsl/d3dcolor-to-ubyte4.shader_test \
|
||||||
tests/hlsl/ddxddy.shader_test \
|
tests/hlsl/ddxddy.shader_test \
|
||||||
tests/hlsl/default-values.shader_test \
|
tests/hlsl/default-values.shader_test \
|
||||||
|
tests/hlsl/depth-bounds.shader_test \
|
||||||
tests/hlsl/depth-out.shader_test \
|
tests/hlsl/depth-out.shader_test \
|
||||||
tests/hlsl/determinant.shader_test \
|
tests/hlsl/determinant.shader_test \
|
||||||
tests/hlsl/discard.shader_test \
|
tests/hlsl/discard.shader_test \
|
||||||
tests/hlsl/distance.shader_test \
|
tests/hlsl/distance.shader_test \
|
||||||
tests/hlsl/dot.shader_test \
|
tests/hlsl/dot.shader_test \
|
||||||
tests/hlsl/duplicate-modifiers.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-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-pass-states-fx_5.shader_test \
|
||||||
tests/hlsl/effect-shader-objects-fx_2.shader_test \
|
tests/hlsl/effect-shader-objects-fx_2.shader_test \
|
||||||
tests/hlsl/effect-shader-objects-fx_5.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-technique-fx_5.shader_test \
|
||||||
tests/hlsl/effect-variables-fx_2.shader_test \
|
tests/hlsl/effect-variables-fx_2.shader_test \
|
||||||
tests/hlsl/effect-variables-fx_4.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/effect-variables-fx_5.shader_test \
|
||||||
tests/hlsl/entry-point-semantics.shader_test \
|
tests/hlsl/entry-point-semantics.shader_test \
|
||||||
|
tests/hlsl/eval-attrib.shader_test \
|
||||||
tests/hlsl/exp.shader_test \
|
tests/hlsl/exp.shader_test \
|
||||||
tests/hlsl/expr-indexing.shader_test \
|
tests/hlsl/expr-indexing.shader_test \
|
||||||
tests/hlsl/f16tof32.shader_test \
|
tests/hlsl/f16tof32.shader_test \
|
||||||
|
tests/hlsl/f32tof16.shader_test \
|
||||||
tests/hlsl/faceforward.shader_test \
|
tests/hlsl/faceforward.shader_test \
|
||||||
|
tests/hlsl/ffp-point-size.shader_test \
|
||||||
tests/hlsl/float-comparison.shader_test \
|
tests/hlsl/float-comparison.shader_test \
|
||||||
tests/hlsl/floor.shader_test \
|
tests/hlsl/floor.shader_test \
|
||||||
tests/hlsl/fmod.shader_test \
|
tests/hlsl/fmod.shader_test \
|
||||||
|
tests/hlsl/fog.shader_test \
|
||||||
tests/hlsl/for.shader_test \
|
tests/hlsl/for.shader_test \
|
||||||
tests/hlsl/frac.shader_test \
|
tests/hlsl/frac.shader_test \
|
||||||
tests/hlsl/function-cast.shader_test \
|
tests/hlsl/function-cast.shader_test \
|
||||||
@@ -125,13 +146,17 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/function.shader_test \
|
tests/hlsl/function.shader_test \
|
||||||
tests/hlsl/fwidth.shader_test \
|
tests/hlsl/fwidth.shader_test \
|
||||||
tests/hlsl/fxgroup-syntax.shader_test \
|
tests/hlsl/fxgroup-syntax.shader_test \
|
||||||
|
tests/hlsl/gather-cmp.shader_test \
|
||||||
tests/hlsl/gather-offset.shader_test \
|
tests/hlsl/gather-offset.shader_test \
|
||||||
tests/hlsl/gather.shader_test \
|
tests/hlsl/gather.shader_test \
|
||||||
|
tests/hlsl/geometry-shader-syntax.shader_test \
|
||||||
tests/hlsl/geometry.shader_test \
|
tests/hlsl/geometry.shader_test \
|
||||||
tests/hlsl/get-sample-pos.shader_test \
|
tests/hlsl/get-sample-pos.shader_test \
|
||||||
tests/hlsl/getdimensions.shader_test \
|
tests/hlsl/getdimensions.shader_test \
|
||||||
tests/hlsl/half.shader_test \
|
tests/hlsl/half.shader_test \
|
||||||
tests/hlsl/hard-copy-prop.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-flatten.shader_test \
|
||||||
tests/hlsl/initializer-implicit-array.shader_test \
|
tests/hlsl/initializer-implicit-array.shader_test \
|
||||||
tests/hlsl/initializer-invalid-arg-count.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-static-array.shader_test \
|
||||||
tests/hlsl/initializer-struct.shader_test \
|
tests/hlsl/initializer-struct.shader_test \
|
||||||
tests/hlsl/instance-id.shader_test \
|
tests/hlsl/instance-id.shader_test \
|
||||||
|
tests/hlsl/interface-packing.shader_test \
|
||||||
tests/hlsl/intrinsic-override.shader_test \
|
tests/hlsl/intrinsic-override.shader_test \
|
||||||
tests/hlsl/invalid.shader_test \
|
tests/hlsl/invalid.shader_test \
|
||||||
tests/hlsl/inverse-trig.shader_test \
|
tests/hlsl/inverse-trig.shader_test \
|
||||||
tests/hlsl/is-front-face.shader_test \
|
tests/hlsl/is-front-face.shader_test \
|
||||||
|
tests/hlsl/isinf.shader_test \
|
||||||
tests/hlsl/ldexp.shader_test \
|
tests/hlsl/ldexp.shader_test \
|
||||||
|
tests/hlsl/length-property.shader_test \
|
||||||
tests/hlsl/length.shader_test \
|
tests/hlsl/length.shader_test \
|
||||||
tests/hlsl/lerp.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/lit.shader_test \
|
||||||
tests/hlsl/load-level.shader_test \
|
tests/hlsl/load-level.shader_test \
|
||||||
tests/hlsl/log.shader_test \
|
tests/hlsl/log.shader_test \
|
||||||
@@ -164,6 +194,7 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/matrix-semantics.shader_test \
|
tests/hlsl/matrix-semantics.shader_test \
|
||||||
tests/hlsl/max-min.shader_test \
|
tests/hlsl/max-min.shader_test \
|
||||||
tests/hlsl/minimum-precision.shader_test \
|
tests/hlsl/minimum-precision.shader_test \
|
||||||
|
tests/hlsl/modf.shader_test \
|
||||||
tests/hlsl/mul.shader_test \
|
tests/hlsl/mul.shader_test \
|
||||||
tests/hlsl/multiple-rt.shader_test \
|
tests/hlsl/multiple-rt.shader_test \
|
||||||
tests/hlsl/nested-arrays.shader_test \
|
tests/hlsl/nested-arrays.shader_test \
|
||||||
@@ -177,6 +208,9 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/object-field-offsets.shader_test \
|
tests/hlsl/object-field-offsets.shader_test \
|
||||||
tests/hlsl/object-parameters.shader_test \
|
tests/hlsl/object-parameters.shader_test \
|
||||||
tests/hlsl/object-references.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/pointer-cast.shader_test \
|
||||||
tests/hlsl/pow.shader_test \
|
tests/hlsl/pow.shader_test \
|
||||||
tests/hlsl/precise-modifier.shader_test \
|
tests/hlsl/precise-modifier.shader_test \
|
||||||
@@ -191,27 +225,35 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/return-implicit-conversion.shader_test \
|
tests/hlsl/return-implicit-conversion.shader_test \
|
||||||
tests/hlsl/return.shader_test \
|
tests/hlsl/return.shader_test \
|
||||||
tests/hlsl/round.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/rt-get-sample-info.shader_test \
|
||||||
tests/hlsl/sample-bias.shader_test \
|
tests/hlsl/sample-bias.shader_test \
|
||||||
tests/hlsl/sample-cmp.shader_test \
|
tests/hlsl/sample-cmp.shader_test \
|
||||||
tests/hlsl/sample-grad.shader_test \
|
tests/hlsl/sample-grad.shader_test \
|
||||||
tests/hlsl/sample-level.shader_test \
|
tests/hlsl/sample-level.shader_test \
|
||||||
tests/hlsl/sampler-offset.shader_test \
|
tests/hlsl/sampler-offset.shader_test \
|
||||||
|
tests/hlsl/sampler-state.shader_test \
|
||||||
tests/hlsl/sampler.shader_test \
|
tests/hlsl/sampler.shader_test \
|
||||||
tests/hlsl/saturate.shader_test \
|
tests/hlsl/saturate.shader_test \
|
||||||
|
tests/hlsl/scope.shader_test \
|
||||||
tests/hlsl/shade-mode.shader_test \
|
tests/hlsl/shade-mode.shader_test \
|
||||||
tests/hlsl/shader-interstage-interface.shader_test \
|
tests/hlsl/shader-interstage-interface.shader_test \
|
||||||
|
tests/hlsl/shader-point-size.shader_test \
|
||||||
tests/hlsl/shape.shader_test \
|
tests/hlsl/shape.shader_test \
|
||||||
tests/hlsl/side-effects.shader_test \
|
tests/hlsl/side-effects.shader_test \
|
||||||
tests/hlsl/sign.shader_test \
|
tests/hlsl/sign.shader_test \
|
||||||
tests/hlsl/single-numeric-initializer.shader_test \
|
tests/hlsl/single-numeric-initializer.shader_test \
|
||||||
tests/hlsl/sm1-const-allocation.shader_test \
|
tests/hlsl/sm1-const-allocation.shader_test \
|
||||||
tests/hlsl/sm1-const-folding.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-ternary.shader_test \
|
||||||
tests/hlsl/sm6-uav-rwtexture.shader_test \
|
tests/hlsl/sm6-uav-rwtexture.shader_test \
|
||||||
tests/hlsl/smoothstep.shader_test \
|
tests/hlsl/smoothstep.shader_test \
|
||||||
tests/hlsl/sqrt.shader_test \
|
tests/hlsl/sqrt.shader_test \
|
||||||
tests/hlsl/srv-buffers.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-function-syntax.shader_test \
|
||||||
tests/hlsl/state-block-syntax.shader_test \
|
tests/hlsl/state-block-syntax.shader_test \
|
||||||
tests/hlsl/static-initializer.shader_test \
|
tests/hlsl/static-initializer.shader_test \
|
||||||
@@ -220,12 +262,15 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/strings.shader_test \
|
tests/hlsl/strings.shader_test \
|
||||||
tests/hlsl/struct-array.shader_test \
|
tests/hlsl/struct-array.shader_test \
|
||||||
tests/hlsl/struct-assignment.shader_test \
|
tests/hlsl/struct-assignment.shader_test \
|
||||||
|
tests/hlsl/struct-inheritance.shader_test \
|
||||||
tests/hlsl/struct-semantics.shader_test \
|
tests/hlsl/struct-semantics.shader_test \
|
||||||
|
tests/hlsl/struct-syntax.shader_test \
|
||||||
tests/hlsl/switch.shader_test \
|
tests/hlsl/switch.shader_test \
|
||||||
tests/hlsl/swizzle-constant-prop.shader_test \
|
tests/hlsl/swizzle-constant-prop.shader_test \
|
||||||
tests/hlsl/swizzle-matrix.shader_test \
|
tests/hlsl/swizzle-matrix.shader_test \
|
||||||
tests/hlsl/swizzles.shader_test \
|
tests/hlsl/swizzles.shader_test \
|
||||||
tests/hlsl/ternary.shader_test \
|
tests/hlsl/ternary.shader_test \
|
||||||
|
tests/hlsl/tessellation-patch-vars.shader_test \
|
||||||
tests/hlsl/tessellation.shader_test \
|
tests/hlsl/tessellation.shader_test \
|
||||||
tests/hlsl/texture-load-offset.shader_test \
|
tests/hlsl/texture-load-offset.shader_test \
|
||||||
tests/hlsl/texture-load-typed.shader_test \
|
tests/hlsl/texture-load-typed.shader_test \
|
||||||
@@ -247,6 +292,8 @@ vkd3d_shader_tests = \
|
|||||||
tests/hlsl/unbounded-array-5.1.shader_test \
|
tests/hlsl/unbounded-array-5.1.shader_test \
|
||||||
tests/hlsl/uniform-parameters.shader_test \
|
tests/hlsl/uniform-parameters.shader_test \
|
||||||
tests/hlsl/uniform-semantics.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/unroll.shader_test \
|
||||||
tests/hlsl/unsigned.shader_test \
|
tests/hlsl/unsigned.shader_test \
|
||||||
tests/hlsl/vector-indexing-uniform.shader_test \
|
tests/hlsl/vector-indexing-uniform.shader_test \
|
||||||
@@ -273,7 +320,8 @@ vkd3d_test_headers = \
|
|||||||
tests/dxcompiler.h \
|
tests/dxcompiler.h \
|
||||||
tests/shader_runner.h \
|
tests/shader_runner.h \
|
||||||
tests/utils.h \
|
tests/utils.h \
|
||||||
tests/vulkan_procs.h
|
tests/vulkan_procs.h \
|
||||||
|
tests/vulkan_utils.h
|
||||||
|
|
||||||
vkd3d_demos = \
|
vkd3d_demos = \
|
||||||
demos/vkd3d-gears \
|
demos/vkd3d-gears \
|
||||||
@@ -281,10 +329,14 @@ vkd3d_demos = \
|
|||||||
|
|
||||||
vkd3d_demos_headers = \
|
vkd3d_demos_headers = \
|
||||||
demos/demo.h \
|
demos/demo.h \
|
||||||
|
demos/demo_d3d12.h \
|
||||||
|
demos/demo_macos.h \
|
||||||
|
demos/demo_vkd3d.h \
|
||||||
demos/demo_win32.h \
|
demos/demo_win32.h \
|
||||||
demos/demo_xcb.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
|
include/private/vkd3d_version.h
|
||||||
|
|
||||||
noinst_LTLIBRARIES = libvkd3d-common.la
|
noinst_LTLIBRARIES = libvkd3d-common.la
|
||||||
@@ -343,6 +395,7 @@ nodist_libvkd3d_shader_la_SOURCES = $(vkd3d_shader_yyfiles)
|
|||||||
libvkd3d_shader_la_SOURCES = \
|
libvkd3d_shader_la_SOURCES = \
|
||||||
include/private/list.h \
|
include/private/list.h \
|
||||||
include/private/rbtree.h \
|
include/private/rbtree.h \
|
||||||
|
include/private/spirv_grammar.h \
|
||||||
include/private/vkd3d_common.h \
|
include/private/vkd3d_common.h \
|
||||||
include/private/vkd3d_memory.h \
|
include/private/vkd3d_memory.h \
|
||||||
include/vkd3d_shader.h \
|
include/vkd3d_shader.h \
|
||||||
@@ -358,6 +411,7 @@ libvkd3d_shader_la_SOURCES = \
|
|||||||
libs/vkd3d-shader/hlsl_codegen.c \
|
libs/vkd3d-shader/hlsl_codegen.c \
|
||||||
libs/vkd3d-shader/hlsl_constant_ops.c \
|
libs/vkd3d-shader/hlsl_constant_ops.c \
|
||||||
libs/vkd3d-shader/ir.c \
|
libs/vkd3d-shader/ir.c \
|
||||||
|
libs/vkd3d-shader/msl.c \
|
||||||
libs/vkd3d-shader/preproc.h \
|
libs/vkd3d-shader/preproc.h \
|
||||||
libs/vkd3d-shader/spirv.c \
|
libs/vkd3d-shader/spirv.c \
|
||||||
libs/vkd3d-shader/tpf.c \
|
libs/vkd3d-shader/tpf.c \
|
||||||
@@ -365,7 +419,7 @@ libvkd3d_shader_la_SOURCES = \
|
|||||||
libs/vkd3d-shader/vkd3d_shader_main.c \
|
libs/vkd3d-shader/vkd3d_shader_main.c \
|
||||||
libs/vkd3d-shader/vkd3d_shader_private.h
|
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_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 15:0:14
|
||||||
libvkd3d_shader_la_LIBADD = libvkd3d-common.la @SPIRV_TOOLS_LIBS@ -lm
|
libvkd3d_shader_la_LIBADD = libvkd3d-common.la @SPIRV_TOOLS_LIBS@ -lm
|
||||||
if HAVE_LD_VERSION_SCRIPT
|
if HAVE_LD_VERSION_SCRIPT
|
||||||
libvkd3d_shader_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d-shader/vkd3d_shader.map
|
libvkd3d_shader_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d-shader/vkd3d_shader.map
|
||||||
@@ -400,7 +454,7 @@ libvkd3d_la_SOURCES = \
|
|||||||
libs/vkd3d/vkd3d_shaders.h \
|
libs/vkd3d/vkd3d_shaders.h \
|
||||||
libs/vkd3d/vulkan_procs.h
|
libs/vkd3d/vulkan_procs.h
|
||||||
libvkd3d_la_CFLAGS = $(AM_CFLAGS) -DLIBVKD3D_SOURCE
|
libvkd3d_la_CFLAGS = $(AM_CFLAGS) -DLIBVKD3D_SOURCE
|
||||||
libvkd3d_la_LDFLAGS = $(AM_LDFLAGS) -version-info 14:0:13
|
libvkd3d_la_LDFLAGS = $(AM_LDFLAGS) -version-info 17:0:16
|
||||||
libvkd3d_la_LIBADD = libvkd3d-common.la libvkd3d-shader.la @DL_LIBS@ @PTHREAD_LIBS@
|
libvkd3d_la_LIBADD = libvkd3d-common.la libvkd3d-shader.la @DL_LIBS@ @PTHREAD_LIBS@
|
||||||
if HAVE_LD_VERSION_SCRIPT
|
if HAVE_LD_VERSION_SCRIPT
|
||||||
libvkd3d_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d/vkd3d.map
|
libvkd3d_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d/vkd3d.map
|
||||||
@@ -413,7 +467,7 @@ libvkd3d_utils_la_SOURCES = \
|
|||||||
libs/vkd3d-utils/vkd3d_utils_main.c \
|
libs/vkd3d-utils/vkd3d_utils_main.c \
|
||||||
libs/vkd3d-utils/vkd3d_utils_private.h
|
libs/vkd3d-utils/vkd3d_utils_private.h
|
||||||
libvkd3d_utils_la_CFLAGS = $(AM_CFLAGS) -DLIBVKD3D_UTILS_SOURCE
|
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:2:6
|
||||||
libvkd3d_utils_la_LIBADD = libvkd3d-common.la libvkd3d-shader.la libvkd3d.la @PTHREAD_LIBS@
|
libvkd3d_utils_la_LIBADD = libvkd3d-common.la libvkd3d-shader.la libvkd3d.la @PTHREAD_LIBS@
|
||||||
if HAVE_LD_VERSION_SCRIPT
|
if HAVE_LD_VERSION_SCRIPT
|
||||||
libvkd3d_utils_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d-utils/vkd3d_utils.map
|
libvkd3d_utils_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libs/vkd3d-utils/vkd3d_utils.map
|
||||||
@@ -445,15 +499,20 @@ LDADD = libvkd3d.la libvkd3d-shader.la libvkd3d-utils.la
|
|||||||
AM_DEFAULT_SOURCE_EXT = .c
|
AM_DEFAULT_SOURCE_EXT = .c
|
||||||
|
|
||||||
TEST_EXTENSIONS = .shader_test
|
TEST_EXTENSIONS = .shader_test
|
||||||
|
TEST_CPPFLAGS = -I$(builddir)/tests
|
||||||
|
|
||||||
if BUILD_TESTS
|
if BUILD_TESTS
|
||||||
check_PROGRAMS = $(vkd3d_tests) $(vkd3d_cross_tests) tests/shader_runner
|
check_PROGRAMS = $(vkd3d_tests) $(vkd3d_cross_tests) tests/shader_runner
|
||||||
dist_check_SCRIPTS = tests/test-driver.sh
|
dist_check_SCRIPTS = tests/test-driver.sh
|
||||||
TESTS = $(vkd3d_tests) $(vkd3d_cross_tests) $(vkd3d_shader_tests)
|
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_LDADD = $(LDADD) @PTHREAD_LIBS@ @DL_LIBS@
|
||||||
|
tests_d3d12_invalid_usage_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||||
tests_d3d12_invalid_usage_LDADD = $(LDADD) @DL_LIBS@
|
tests_d3d12_invalid_usage_LDADD = $(LDADD) @DL_LIBS@
|
||||||
|
tests_hlsl_d3d12_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
|
||||||
tests_hlsl_d3d12_LDADD = $(LDADD) @DL_LIBS@
|
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_LDADD = $(LDADD) @OPENGL_LIBS@ @DL_LIBS@
|
||||||
tests_shader_runner_SOURCES = \
|
tests_shader_runner_SOURCES = \
|
||||||
tests/shader_runner.c \
|
tests/shader_runner.c \
|
||||||
@@ -462,9 +521,18 @@ tests_shader_runner_SOURCES = \
|
|||||||
tests/shader_runner_d3d12.c \
|
tests/shader_runner_d3d12.c \
|
||||||
tests/shader_runner_gl.c \
|
tests/shader_runner_gl.c \
|
||||||
tests/shader_runner_vulkan.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_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_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_COMPILER = tests/shader_runner
|
||||||
SHADER_TEST_LOG_DRIVER = $(srcdir)/tests/test-driver.sh
|
SHADER_TEST_LOG_DRIVER = $(srcdir)/tests/test-driver.sh
|
||||||
endif
|
endif
|
||||||
@@ -472,20 +540,33 @@ endif
|
|||||||
EXTRA_DIST += $(vkd3d_shader_tests)
|
EXTRA_DIST += $(vkd3d_shader_tests)
|
||||||
|
|
||||||
if BUILD_DEMOS
|
if BUILD_DEMOS
|
||||||
DEMOS_LDADD = $(LDADD) libvkd3d-shader.la @DL_LIBS@ @DEMO_LIBS@
|
DEMOS_LDADD = $(LDADD) @DL_LIBS@ @DEMO_LIBS@
|
||||||
DEMOS_CFLAGS = $(AM_CFLAGS) @DEMO_CFLAGS@
|
DEMOS_CFLAGS = $(AM_CFLAGS) @DEMO_CFLAGS@ -I$(srcdir)/demos -Wa,-I$(srcdir)/demos
|
||||||
bin_PROGRAMS += $(vkd3d_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_CFLAGS = $(DEMOS_CFLAGS)
|
||||||
demos_vkd3d_gears_LDADD = $(DEMOS_LDADD) -lm
|
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
|
demos_vkd3d_triangle_SOURCES = demos/triangle.c demos/triangle.hlsl
|
||||||
demos_vkd3d_triangle_CFLAGS = $(DEMOS_CFLAGS)
|
demos_vkd3d_triangle_CFLAGS = $(DEMOS_CFLAGS)
|
||||||
demos_vkd3d_triangle_LDADD = $(DEMOS_LDADD)
|
demos_vkd3d_triangle_LDADD = $(DEMOS_LDADD)
|
||||||
|
demos/vkd3d_triangle-triangle.$(OBJEXT): demos/triangle.hlsl
|
||||||
endif
|
endif
|
||||||
|
|
||||||
noinst_HEADERS = $(vkd3d_test_headers) $(vkd3d_demos_headers)
|
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_V@)
|
||||||
vkd3d_v_widl_ = $(vkd3d_v_widl_@AM_DEFAULT_V@)
|
vkd3d_v_widl_ = $(vkd3d_v_widl_@AM_DEFAULT_V@)
|
||||||
@@ -495,7 +576,11 @@ vkd3d_v_widl_1 =
|
|||||||
if HAVE_WIDL
|
if HAVE_WIDL
|
||||||
CLEANFILES += $(widl_headers)
|
CLEANFILES += $(widl_headers)
|
||||||
endif
|
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
|
$(widl_headers): %.h: %.idl
|
||||||
if HAVE_WIDL
|
if HAVE_WIDL
|
||||||
$(VKD3D_V_WIDL)$(WIDL) -I$(srcdir)/include -h -o $@ $<
|
$(VKD3D_V_WIDL)$(WIDL) -I$(srcdir)/include -h -o $@ $<
|
||||||
@@ -527,6 +612,10 @@ libvkd3d.pc: $(srcdir)/libs/vkd3d/libvkd3d.pc.in Makefile
|
|||||||
-e 's![@]PACKAGE_VERSION[@]!$(PACKAGE_VERSION)!g' \
|
-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
|
include/private/vkd3d_version.h: dummy-vkd3d-version
|
||||||
@$(MKDIR_P) include/private
|
@$(MKDIR_P) include/private
|
||||||
version=`(GIT_DIR=$(top_srcdir)/.git git rev-parse --short HEAD 2>/dev/null || echo '') \
|
version=`(GIT_DIR=$(top_srcdir)/.git git rev-parse --short HEAD 2>/dev/null || echo '') \
|
||||||
@@ -535,7 +624,7 @@ include/private/vkd3d_version.h: dummy-vkd3d-version
|
|||||||
&& (echo $$version | cmp -s - $@) \
|
&& (echo $$version | cmp -s - $@) \
|
||||||
|| echo $$version >$@ || ($(RM) $@ && exit 1)
|
|| echo $$version >$@ || ($(RM) $@ && exit 1)
|
||||||
.SILENT: include/private/vkd3d_version.h
|
.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
|
.PHONY: dummy-vkd3d-version
|
||||||
dummy-vkd3d-version:
|
dummy-vkd3d-version:
|
||||||
@@ -543,7 +632,7 @@ dummy-vkd3d-version:
|
|||||||
## Cross-compile tests
|
## Cross-compile tests
|
||||||
cross_implibs = crosslibs/d3d12
|
cross_implibs = crosslibs/d3d12
|
||||||
CROSS_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/private -I$(builddir)/include -I$(builddir)/tests
|
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
|
-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 += $(cross_implibs:=.cross32.def) $(cross_implibs:=.cross64.def)
|
||||||
EXTRA_DIST += tests/driver.c tests/shader_runner_d3d11.c tests/shader_runner_d3d9.c
|
EXTRA_DIST += tests/driver.c tests/shader_runner_d3d11.c tests/shader_runner_d3d9.c
|
||||||
@@ -567,6 +656,8 @@ CROSS32_EXEFILES += $(vkd3d_cross_tests:=.cross32.exe)
|
|||||||
endif
|
endif
|
||||||
if BUILD_DEMOS
|
if BUILD_DEMOS
|
||||||
CROSS32_EXEFILES += $(vkd3d_demos:demos/vkd3d-%=demos/%.cross32.exe)
|
CROSS32_EXEFILES += $(vkd3d_demos:demos/vkd3d-%=demos/%.cross32.exe)
|
||||||
|
demos/gears.cross32.exe: demos/gears.hlsl
|
||||||
|
demos/triangle.cross32.exe: demos/triangle.hlsl
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CROSS32_FILES = $(CROSS32_EXEFILES)
|
CROSS32_FILES = $(CROSS32_EXEFILES)
|
||||||
@@ -614,6 +705,8 @@ CROSS64_EXEFILES += $(vkd3d_cross_tests:=.cross64.exe)
|
|||||||
endif
|
endif
|
||||||
if BUILD_DEMOS
|
if BUILD_DEMOS
|
||||||
CROSS64_EXEFILES += $(vkd3d_demos:demos/vkd3d-%=demos/%.cross64.exe)
|
CROSS64_EXEFILES += $(vkd3d_demos:demos/vkd3d-%=demos/%.cross64.exe)
|
||||||
|
demos/gears.cross64.exe: demos/gears.hlsl
|
||||||
|
demos/triangle.cross64.exe: demos/triangle.hlsl
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CROSS64_FILES = $(CROSS64_EXEFILES)
|
CROSS64_FILES = $(CROSS64_EXEFILES)
|
||||||
|
79
README
79
README
@@ -9,7 +9,8 @@ similar, but not identical, to Direct3D 12.
|
|||||||
Building vkd3d
|
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
|
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
|
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
|
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"'.
|
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
|
For release builds, you may want to disable debug log messages defining
|
||||||
messages, you may also consider VKD3D_NO_TRACE_MESSAGES and
|
preprocessor macros VKD3D_NO_TRACE_MESSAGES and VKD3D_NO_DEBUG_MESSAGES.
|
||||||
VKD3D_NO_DEBUG_MESSAGES. For example, you can pass `CPPFLAGS="-DNDEBUG
|
See the `Preprocessor definitions' section below for more details.
|
||||||
-DVKD3D_NO_TRACE_MESSAGES"' to configure.
|
|
||||||
|
================
|
||||||
|
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
|
Using vkd3d
|
||||||
@@ -39,8 +50,8 @@ Environment variables
|
|||||||
=====================
|
=====================
|
||||||
|
|
||||||
Most of the environment variables used by vkd3d are for debugging purposes. The
|
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
|
environment variables are not considered a stable interface and might be changed
|
||||||
removed in the future versions of vkd3d.
|
or removed in future versions of vkd3d.
|
||||||
|
|
||||||
Some of debug variables are lists of elements. Elements must be separated by
|
Some of debug variables are lists of elements. Elements must be separated by
|
||||||
commas or semicolons.
|
commas or semicolons.
|
||||||
@@ -65,6 +76,14 @@ commas or semicolons.
|
|||||||
* VKD3D_DISABLE_EXTENSIONS - a list of Vulkan extensions that libvkd3d should
|
* VKD3D_DISABLE_EXTENSIONS - a list of Vulkan extensions that libvkd3d should
|
||||||
not use even if available.
|
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
|
* VKD3D_SHADER_CONFIG - a list of options that change the behavior of
|
||||||
libvkd3d-shader.
|
libvkd3d-shader.
|
||||||
* force_validation - Enable (additional) validation of libvkd3d-shader's
|
* 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:
|
from:
|
||||||
https://github.com/microsoft/DirectXShaderCompiler/releases
|
https://github.com/microsoft/DirectXShaderCompiler/releases
|
||||||
|
|
||||||
================
|
========================
|
||||||
Developing vkd3d
|
Preprocessor definitions
|
||||||
================
|
========================
|
||||||
|
|
||||||
Development of vkd3d happens on the Wine GitLab instance
|
A number of preprocessor definitions can be used at compilation time to control
|
||||||
(https://gitlab.winehq.org/wine/vkd3d/). Contributors are encouraged
|
the behaviour of the generated binary. You can pass something like
|
||||||
to submit their patches using the merge request tool.
|
`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
|
* VKD3D_NO_TRACE_MESSAGES - do not emit trace messages in the debug log; this
|
||||||
system. See gitlab/README in the Git tree for more details.
|
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
|
Testing with the Agility SDK
|
||||||
|
31
configure.ac
31
configure.ac
@@ -1,13 +1,15 @@
|
|||||||
AC_PREREQ([2.69])
|
AC_PREREQ([2.69])
|
||||||
AC_INIT([vkd3d],[1.13])
|
AC_INIT([vkd3d],[1.16])
|
||||||
|
|
||||||
AC_CONFIG_AUX_DIR([bin])
|
AC_CONFIG_AUX_DIR([bin])
|
||||||
AC_CONFIG_MACRO_DIR([m4])
|
AC_CONFIG_MACRO_DIR([m4])
|
||||||
AC_CONFIG_HEADERS(include/config.h)
|
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([WIDL], [widl IDL compiler])
|
||||||
AC_ARG_VAR([CROSSCC32], [32-bit Windows cross compiler])
|
AC_ARG_VAR([CROSSCC32], [32-bit Windows cross compiler])
|
||||||
AC_ARG_VAR([CROSSCC64], [64-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([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([opengl], AS_HELP_STRING([--with-opengl], [Build with the OpenGL library (default: test)]))
|
||||||
AC_ARG_WITH([spirv-tools], AS_HELP_STRING([--with-spirv-tools],
|
AC_ARG_WITH([spirv-tools], AS_HELP_STRING([--with-spirv-tools],
|
||||||
@@ -31,6 +33,11 @@ AC_PROG_MKDIR_P
|
|||||||
VKD3D_PROG_WIDL(3, 21)
|
VKD3D_PROG_WIDL(3, 21)
|
||||||
AS_IF([test "x$WIDL" = "xno"], [AC_MSG_WARN([widl is required to build header files.])])
|
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])
|
AC_CHECK_PROGS([FLEX], [flex], [none])
|
||||||
AS_IF([test "$FLEX" = "none"], [AC_MSG_ERROR([no suitable flex found. Please install the 'flex' package.])])
|
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])
|
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])],
|
[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.])])
|
[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"],
|
AS_IF([test "x$with_ncurses" != "xno"],
|
||||||
[PKG_CHECK_MODULES([NCURSES], [ncurses],
|
[PKG_CHECK_MODULES([NCURSES], [ncurses],
|
||||||
[AC_DEFINE([HAVE_NCURSES], [1], [Define to 1 if you have ncurses.]) with_ncurses=yes],
|
[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_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)])
|
VKD3D_CHECK_FUNC([HAVE_ATOMIC_EXCHANGE_N], [__atomic_exchange_n], [__atomic_exchange_n((int *)0, 0, 0)])
|
||||||
AC_CHECK_FUNCS([gettid])
|
AC_CHECK_FUNCS([gettid])
|
||||||
|
AC_CHECK_FUNCS([pthread_threadid_np])
|
||||||
|
|
||||||
dnl Makefiles
|
dnl Makefiles
|
||||||
case $host_os in
|
case $host_os in
|
||||||
mingw32*)
|
mingw32*)
|
||||||
AC_SUBST([DEMO_LIBS],["-ld3d12 -ldxgi -lgdi32"])
|
AC_SUBST([DEMO_LIBS],["-lgdi32"])
|
||||||
AC_SUBST([DEMO_CFLAGS],["-municode"])
|
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"],
|
*) AS_IF([test "x$enable_demos" = "xyes" -a "x$HAVE_XCB" != "xyes"],
|
||||||
[AC_MSG_ERROR([libxcb is required for demos.])])
|
[AC_MSG_ERROR([libxcb is required for demos.])])
|
||||||
AC_SUBST([DEMO_LIBS],[$XCB_LIBS])
|
AC_SUBST([DEMO_LIBS],[$XCB_LIBS])
|
||||||
AC_SUBST([DEMO_CFLAGS],[$XCB_CFLAGS])
|
AC_SUBST([DEMO_CFLAGS],[$XCB_CFLAGS])
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
VKD3D_CHECK_CFLAGS([-fno-lto], [DEMO_CFLAGS="$DEMO_CFLAGS -fno-lto"])
|
||||||
AM_CONDITIONAL([BUILD_DEMOS], [test "x$enable_demos" = "xyes"])
|
AM_CONDITIONAL([BUILD_DEMOS], [test "x$enable_demos" = "xyes"])
|
||||||
AM_CONDITIONAL([BUILD_DOC], [test $DX_FLAG_doc = 1])
|
AM_CONDITIONAL([BUILD_DOC], [test $DX_FLAG_doc = 1])
|
||||||
AM_CONDITIONAL([BUILD_TESTS], [test "x$enable_tests" != "xno"])
|
AM_CONDITIONAL([BUILD_TESTS], [test "x$enable_tests" != "xno"])
|
||||||
AM_CONDITIONAL([HAVE_WIDL], [test "x$WIDL" != "xno"])
|
AM_CONDITIONAL([HAVE_WIDL], [test "x$WIDL" != "xno"])
|
||||||
AM_CONDITIONAL([HAVE_CROSSTARGET32], [test "x$CROSSTARGET32" != "xno"])
|
AM_CONDITIONAL([HAVE_CROSSTARGET32], [test "x$CROSSTARGET32" != "xno"])
|
||||||
AM_CONDITIONAL([HAVE_CROSSTARGET64], [test "x$CROSSTARGET64" != "xno"])
|
AM_CONDITIONAL([HAVE_CROSSTARGET64], [test "x$CROSSTARGET64" != "xno"])
|
||||||
|
AM_CONDITIONAL([HAVE_METAL], [test "${host_os#darwin}" != "$host_os"])
|
||||||
|
|
||||||
AC_CONFIG_FILES([Makefile])
|
AC_CONFIG_FILES([Makefile])
|
||||||
AC_OUTPUT
|
AC_OUTPUT
|
||||||
@@ -197,11 +221,12 @@ AS_ECHO(["
|
|||||||
|
|
||||||
widl: ${WIDL}
|
widl: ${WIDL}
|
||||||
|
|
||||||
|
Have dxcompiler: ${HAVE_DXCOMPILER}
|
||||||
|
Have Metal: ${with_metal}
|
||||||
Have ncurses: ${with_ncurses}
|
Have ncurses: ${with_ncurses}
|
||||||
Have OpenGL: ${with_opengl}
|
Have OpenGL: ${with_opengl}
|
||||||
Have SPIRV-Tools: ${with_spirv_tools}
|
Have SPIRV-Tools: ${with_spirv_tools}
|
||||||
Have xcb: ${HAVE_XCB}
|
Have xcb: ${HAVE_XCB}
|
||||||
Have dxcompiler: ${HAVE_DXCOMPILER}
|
|
||||||
|
|
||||||
Building demos: ${enable_demos}
|
Building demos: ${enable_demos}
|
||||||
Building tests: ${enable_tests}
|
Building tests: ${enable_tests}
|
||||||
|
50
demos/demo.h
50
demos/demo.h
@@ -39,6 +39,46 @@
|
|||||||
#include <vkd3d_d3d12.h>
|
#include <vkd3d_d3d12.h>
|
||||||
#include <inttypes.h>
|
#include <inttypes.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))
|
||||||
|
|
||||||
#define ARRAY_SIZE(x) (sizeof(x) / sizeof(*x))
|
#define ARRAY_SIZE(x) (sizeof(x) / sizeof(*x))
|
||||||
|
|
||||||
#define DEMO_KEY_UNKNOWN 0x0000
|
#define DEMO_KEY_UNKNOWN 0x0000
|
||||||
@@ -138,9 +178,11 @@ static inline HRESULT demo_create_root_signature(ID3D12Device *device,
|
|||||||
return hr;
|
return hr;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef VKD3D_CROSSTEST
|
||||||
#include "demo_win32.h"
|
#include "demo_d3d12.h"
|
||||||
#else
|
#else
|
||||||
#define INFINITE VKD3D_INFINITE
|
# ifndef _WIN32
|
||||||
#include "demo_xcb.h"
|
# define INFINITE VKD3D_INFINITE
|
||||||
|
# endif
|
||||||
|
#include "demo_vkd3d.h"
|
||||||
#endif
|
#endif
|
||||||
|
217
demos/demo_d3d12.h
Normal file
217
demos/demo_d3d12.h
Normal file
@@ -0,0 +1,217 @@
|
|||||||
|
/*
|
||||||
|
* 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;
|
||||||
|
};
|
||||||
|
|
||||||
|
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 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;
|
||||||
|
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_win32->window, &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);
|
||||||
|
}
|
310
demos/demo_macos.h
Normal file
310
demos/demo_macos.h
Normal file
@@ -0,0 +1,310 @@
|
|||||||
|
/*
|
||||||
|
* 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_Escape = 0x35,
|
||||||
|
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_Escape, DEMO_KEY_ESCAPE},
|
||||||
|
{kVK_LeftArrow, DEMO_KEY_LEFT},
|
||||||
|
{kVK_RightArrow, DEMO_KEY_RIGHT},
|
||||||
|
{kVK_UpArrow, DEMO_KEY_UP},
|
||||||
|
{kVK_DownArrow, DEMO_KEY_DOWN},
|
||||||
|
};
|
||||||
|
|
||||||
|
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;
|
||||||
|
}
|
617
demos/demo_vkd3d.h
Normal file
617
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
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <vkd3d_dxgi1_4.h>
|
#define DEMO_WIN32_WINDOW_CLASS_NAME L"demo_wc"
|
||||||
#include <vkd3d_d3dcompiler.h>
|
|
||||||
#include <stdbool.h>
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#define DEMO_WINDOW_CLASS_NAME L"demo_wc"
|
struct demo_window_win32
|
||||||
|
|
||||||
struct demo
|
|
||||||
{
|
{
|
||||||
size_t window_count;
|
struct demo_window w;
|
||||||
bool quit;
|
|
||||||
|
|
||||||
void *user_data;
|
|
||||||
void (*idle_func)(struct demo *demo, void *user_data);
|
|
||||||
};
|
|
||||||
|
|
||||||
struct demo_window
|
|
||||||
{
|
|
||||||
HINSTANCE instance;
|
HINSTANCE instance;
|
||||||
HWND hwnd;
|
HWND 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);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
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)
|
unsigned int width, unsigned int height, void *user_data)
|
||||||
{
|
{
|
||||||
|
struct demo_window_win32 *window_win32;
|
||||||
RECT rect = {0, 0, width, height};
|
RECT rect = {0, 0, width, height};
|
||||||
struct demo_window *window;
|
|
||||||
int title_size;
|
int title_size;
|
||||||
WCHAR *title_w;
|
WCHAR *title_w;
|
||||||
DWORD style;
|
DWORD style;
|
||||||
|
|
||||||
if (!(window = malloc(sizeof(*window))))
|
if (!(window_win32 = malloc(sizeof(*window_win32))))
|
||||||
return NULL;
|
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);
|
title_size = MultiByteToWideChar(CP_UTF8, 0, title, -1, NULL, 0);
|
||||||
if (!(title_w = calloc(title_size, sizeof(*title_w))))
|
if (!(title_w = calloc(title_size, sizeof(*title_w))))
|
||||||
{
|
{
|
||||||
free(window);
|
demo_window_cleanup(&window_win32->w);
|
||||||
|
free(window_win32);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
MultiByteToWideChar(CP_UTF8, 0, title, -1, title_w, title_size);
|
MultiByteToWideChar(CP_UTF8, 0, title, -1, title_w, title_size);
|
||||||
|
|
||||||
window->instance = GetModuleHandle(NULL);
|
window_win32->instance = GetModuleHandle(NULL);
|
||||||
window->user_data = user_data;
|
|
||||||
window->expose_func = NULL;
|
|
||||||
window->key_press_func = NULL;
|
|
||||||
|
|
||||||
style = WS_OVERLAPPED | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_VISIBLE;
|
style = WS_OVERLAPPED | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_VISIBLE;
|
||||||
AdjustWindowRect(&rect, style, FALSE);
|
AdjustWindowRect(&rect, style, FALSE);
|
||||||
window->hwnd = CreateWindowExW(0, DEMO_WINDOW_CLASS_NAME, title_w, style, CW_USEDEFAULT, CW_USEDEFAULT,
|
window_win32->window = CreateWindowExW(0, DEMO_WIN32_WINDOW_CLASS_NAME, title_w, style, CW_USEDEFAULT,
|
||||||
rect.right - rect.left, rect.bottom - rect.top, NULL, NULL, window->instance, NULL);
|
CW_USEDEFAULT, rect.right - rect.left, rect.bottom - rect.top, NULL, NULL, window_win32->instance, NULL);
|
||||||
free(title_w);
|
free(title_w);
|
||||||
if (!window->hwnd)
|
if (!window_win32->window)
|
||||||
{
|
{
|
||||||
free(window);
|
demo_window_cleanup(&window_win32->w);
|
||||||
|
free(window_win32);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
SetWindowLongPtrW(window->hwnd, GWLP_USERDATA, (LONG_PTR)window);
|
SetWindowLongPtrW(window_win32->window, GWLP_USERDATA, (LONG_PTR)window_win32);
|
||||||
window->demo = demo;
|
|
||||||
++demo->window_count;
|
|
||||||
|
|
||||||
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
|
static const struct
|
||||||
{
|
{
|
||||||
@@ -126,46 +149,33 @@ static inline demo_key demo_key_from_vkey(DWORD vkey)
|
|||||||
return DEMO_KEY_UNKNOWN;
|
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)
|
switch (message)
|
||||||
{
|
{
|
||||||
case WM_PAINT:
|
case WM_PAINT:
|
||||||
if (window && window->expose_func)
|
if (window_win32 && window_win32->w.expose_func)
|
||||||
window->expose_func(window, window->user_data);
|
window_win32->w.expose_func(&window_win32->w, window_win32->w.user_data);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
case WM_KEYDOWN:
|
case WM_KEYDOWN:
|
||||||
if (!window->key_press_func)
|
if (!window_win32->w.key_press_func)
|
||||||
break;
|
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;
|
return 0;
|
||||||
|
|
||||||
case WM_DESTROY:
|
case WM_DESTROY:
|
||||||
if (!--window->demo->window_count)
|
demo_window_win32_destroyed(&window_win32->w);
|
||||||
window->demo->quit = true;
|
|
||||||
free(window);
|
|
||||||
return 0;
|
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,
|
static void demo_win32_process_events(struct demo *demo)
|
||||||
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)
|
|
||||||
{
|
{
|
||||||
MSG msg = {0};
|
MSG msg = {0};
|
||||||
|
|
||||||
@@ -186,18 +196,28 @@ static inline void demo_process_events(struct demo *demo)
|
|||||||
break;
|
break;
|
||||||
TranslateMessage(&msg);
|
TranslateMessage(&msg);
|
||||||
DispatchMessageW(&msg);
|
DispatchMessageW(&msg);
|
||||||
if (demo->quit)
|
if (!demo->window_count)
|
||||||
PostQuitMessage(0);
|
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;
|
WNDCLASSEXW wc;
|
||||||
|
|
||||||
wc.cbSize = sizeof(wc);
|
wc.cbSize = sizeof(wc);
|
||||||
wc.style = CS_HREDRAW | CS_VREDRAW;
|
wc.style = CS_HREDRAW | CS_VREDRAW;
|
||||||
wc.lpfnWndProc = demo_window_proc;
|
wc.lpfnWndProc = demo_win32_window_proc;
|
||||||
wc.cbClsExtra = 0;
|
wc.cbClsExtra = 0;
|
||||||
wc.cbWndExtra = 0;
|
wc.cbWndExtra = 0;
|
||||||
wc.hInstance = GetModuleHandle(NULL);
|
wc.hInstance = GetModuleHandle(NULL);
|
||||||
@@ -205,110 +225,15 @@ static inline bool demo_init(struct demo *demo, void *user_data)
|
|||||||
wc.hCursor = LoadCursorW(NULL, IDC_ARROW);
|
wc.hCursor = LoadCursorW(NULL, IDC_ARROW);
|
||||||
wc.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH);
|
wc.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH);
|
||||||
wc.lpszMenuName = NULL;
|
wc.lpszMenuName = NULL;
|
||||||
wc.lpszClassName = DEMO_WINDOW_CLASS_NAME;
|
wc.lpszClassName = DEMO_WIN32_WINDOW_CLASS_NAME;
|
||||||
wc.hIconSm = LoadIconW(NULL, IDI_WINLOGO);
|
wc.hIconSm = LoadIconW(NULL, IDI_WINLOGO);
|
||||||
if (!RegisterClassExW(&wc))
|
if (!RegisterClassExW(&wc))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
demo->window_count = 0;
|
if ((win32->GetDpiForSystem = (void *)GetProcAddress(GetModuleHandleA("user32"), "GetDpiForSystem")))
|
||||||
demo->quit = false;
|
SetProcessDPIAware();
|
||||||
demo->user_data = user_data;
|
else
|
||||||
demo->idle_func = NULL;
|
win32->GetDpiForSystem = demo_win32_GetDpiForSystem;
|
||||||
|
|
||||||
return true;
|
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
@@ -48,7 +48,7 @@
|
|||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include "demo.h"
|
#include "demo.h"
|
||||||
|
|
||||||
#include "gears_hlsl.h"
|
DEMO_EMBED(gears_hlsl, "gears.hlsl");
|
||||||
|
|
||||||
struct cxg_fence
|
struct cxg_fence
|
||||||
{
|
{
|
||||||
@@ -681,11 +681,14 @@ static void cxg_load_assets(struct cx_gears *cxg)
|
|||||||
hr = demo_create_root_signature(cxg->device, &root_signature_desc, &cxg->root_signature);
|
hr = demo_create_root_signature(cxg->device, &root_signature_desc, &cxg->root_signature);
|
||||||
assert(SUCCEEDED(hr));
|
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));
|
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));
|
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));
|
assert(SUCCEEDED(hr));
|
||||||
|
|
||||||
memset(&pso_desc, 0, sizeof(pso_desc));
|
memset(&pso_desc, 0, sizeof(pso_desc));
|
||||||
@@ -846,12 +849,16 @@ static int cxg_main(void)
|
|||||||
{
|
{
|
||||||
unsigned int width = 300, height = 300;
|
unsigned int width = 300, height = 300;
|
||||||
struct cx_gears cxg;
|
struct cx_gears cxg;
|
||||||
|
double dpi_x, dpi_y;
|
||||||
|
|
||||||
memset(&cxg, 0, sizeof(cxg));
|
memset(&cxg, 0, sizeof(cxg));
|
||||||
if (!demo_init(&cxg.demo, &cxg))
|
if (!demo_init(&cxg.demo, &cxg))
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
demo_set_idle_func(&cxg.demo, cxg_idle);
|
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);
|
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_key_press_func(cxg.window, cxg_key_press);
|
||||||
demo_window_set_expose_func(cxg.window, cxg_expose);
|
demo_window_set_expose_func(cxg.window, cxg_expose);
|
||||||
|
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>;
|
||||||
|
};
|
@@ -45,7 +45,7 @@
|
|||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
#include "demo.h"
|
#include "demo.h"
|
||||||
|
|
||||||
#include "triangle_hlsl.h"
|
DEMO_EMBED(triangle_hlsl, "triangle.hlsl");
|
||||||
|
|
||||||
struct cxt_fence
|
struct cxt_fence
|
||||||
{
|
{
|
||||||
@@ -285,9 +285,11 @@ static void cxt_load_assets(struct cx_triangle *cxt)
|
|||||||
hr = demo_create_root_signature(cxt->device, &root_signature_desc, &cxt->root_signature);
|
hr = demo_create_root_signature(cxt->device, &root_signature_desc, &cxt->root_signature);
|
||||||
assert(SUCCEEDED(hr));
|
assert(SUCCEEDED(hr));
|
||||||
|
|
||||||
hr = D3DCompile(triangle_hlsl, strlen(triangle_hlsl), NULL, NULL, NULL, "vs_main", "vs_5_0", 0, 0, &vs, NULL);
|
hr = D3DCompile(triangle_hlsl, triangle_hlsl_size, "triangle.hlsl",
|
||||||
|
NULL, NULL, "vs_main", "vs_5_0", 0, 0, &vs, NULL);
|
||||||
assert(SUCCEEDED(hr));
|
assert(SUCCEEDED(hr));
|
||||||
hr = D3DCompile(triangle_hlsl, strlen(triangle_hlsl), NULL, NULL, NULL, "ps_main", "ps_5_0", 0, 0, &ps, NULL);
|
hr = D3DCompile(triangle_hlsl, triangle_hlsl_size, "triangle.hlsl",
|
||||||
|
NULL, NULL, "ps_main", "ps_5_0", 0, 0, &ps, NULL);
|
||||||
assert(SUCCEEDED(hr));
|
assert(SUCCEEDED(hr));
|
||||||
|
|
||||||
memset(&pso_desc, 0, sizeof(pso_desc));
|
memset(&pso_desc, 0, sizeof(pso_desc));
|
||||||
@@ -366,12 +368,16 @@ static int cxt_main(void)
|
|||||||
{
|
{
|
||||||
unsigned int width = 640, height = 480;
|
unsigned int width = 640, height = 480;
|
||||||
struct cx_triangle cxt;
|
struct cx_triangle cxt;
|
||||||
|
double dpi_x, dpi_y;
|
||||||
|
|
||||||
memset(&cxt, 0, sizeof(cxt));
|
memset(&cxt, 0, sizeof(cxt));
|
||||||
|
|
||||||
if (!demo_init(&cxt.demo, NULL))
|
if (!demo_init(&cxt.demo, NULL))
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
|
|
||||||
|
demo_get_dpi(&cxt.demo, &dpi_x, &dpi_y);
|
||||||
|
width *= dpi_x / 96.0;
|
||||||
|
height *= dpi_y / 96.0;
|
||||||
cxt.window = demo_window_create(&cxt.demo, "Vkd3d Triangle", width, height, &cxt);
|
cxt.window = demo_window_create(&cxt.demo, "Vkd3d Triangle", width, height, &cxt);
|
||||||
demo_window_set_expose_func(cxt.window, cxt_render_frame);
|
demo_window_set_expose_func(cxt.window, cxt_render_frame);
|
||||||
demo_window_set_key_press_func(cxt.window, cxt_key_press);
|
demo_window_set_key_press_func(cxt.window, cxt_key_press);
|
||||||
|
63
demos/triangle.hlsl
Normal file
63
demos/triangle.hlsl
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
/*
|
||||||
|
* 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
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This application contains code derived from Microsoft's "HelloTriangle"
|
||||||
|
* demo, the license for which follows:
|
||||||
|
*
|
||||||
|
* Copyright (c) 2015 Microsoft
|
||||||
|
*
|
||||||
|
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
* copy of this software and associated documentation files (the "Software"),
|
||||||
|
* to deal in the Software without restriction, including without limitation
|
||||||
|
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
* and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
* Software is furnished to do so, subject to the following conditions:
|
||||||
|
*
|
||||||
|
* The above copyright notice and this permission notice shall be included in
|
||||||
|
* all copies or substantial portions of the Software.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
* DEALINGS IN THE SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
struct ps_in
|
||||||
|
{
|
||||||
|
float4 position : SV_POSITION;
|
||||||
|
float4 colour : COLOR;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct ps_in vs_main(float4 position : POSITION, float4 colour : COLOR)
|
||||||
|
{
|
||||||
|
struct ps_in o;
|
||||||
|
|
||||||
|
o.position = position;
|
||||||
|
o.colour = colour;
|
||||||
|
|
||||||
|
return o;
|
||||||
|
}
|
||||||
|
|
||||||
|
float4 ps_main(struct ps_in i) : SV_TARGET
|
||||||
|
{
|
||||||
|
return i.colour;
|
||||||
|
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user