Compare commits
738 Commits
texman_0_1
...
mesa-6_5-2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
59cfd3cd3f | ||
|
|
d8bb5ea967 | ||
|
|
c04bb519e1 | ||
|
|
c60bcc8966 | ||
|
|
c0eb777cd8 | ||
|
|
17b5063c6f | ||
|
|
aead688e7f | ||
|
|
bbe197ec1d | ||
|
|
85b4ae0654 | ||
|
|
b9920ba7b7 | ||
|
|
27908d2bcb | ||
|
|
04f43226a8 | ||
|
|
8c140c9c37 | ||
|
|
3ae1905744 | ||
|
|
218ba1ff54 | ||
|
|
5906acad08 | ||
|
|
1ff8daf21e | ||
|
|
1ad914575a | ||
|
|
525eb0b621 | ||
|
|
f385cf115a | ||
|
|
c6e1784062 | ||
|
|
2922aa236f | ||
|
|
77afb43519 | ||
|
|
46c1419c93 | ||
|
|
bf35d70635 | ||
|
|
69f31f5475 | ||
|
|
bfb2729f9e | ||
|
|
a6c72b67f6 | ||
|
|
527cd2544f | ||
|
|
be9282bf0b | ||
|
|
0cdf2d7413 | ||
|
|
f63623779a | ||
|
|
2893072967 | ||
|
|
66c9be06f9 | ||
|
|
c7e164f091 | ||
|
|
d179e16501 | ||
|
|
9f6798d6e1 | ||
|
|
7c583f5d11 | ||
|
|
f7f5b2c415 | ||
|
|
ff3a5b1842 | ||
|
|
8ca6250d72 | ||
|
|
ff5b590382 | ||
|
|
787f4965a2 | ||
|
|
b10ea9843b | ||
|
|
6c33475424 | ||
|
|
7a7aa2aabb | ||
|
|
4063b1730d | ||
|
|
291fd257eb | ||
|
|
caf0176472 | ||
|
|
4e0617849c | ||
|
|
9671548424 | ||
|
|
199729ff27 | ||
|
|
78a6000cf2 | ||
|
|
0deb088cf0 | ||
|
|
3cb56804ca | ||
|
|
0e794a1bc6 | ||
|
|
b4517527eb | ||
|
|
5fb9f80e37 | ||
|
|
942b5b7bc0 | ||
|
|
feb0ff11e5 | ||
|
|
4cd9e5c3c9 | ||
|
|
bd0bfd1dc2 | ||
|
|
c28834bfbb | ||
|
|
1ec9ed4f25 | ||
|
|
4afcd8aa8b | ||
|
|
161de10ce8 | ||
|
|
11fceb19d3 | ||
|
|
16d1024f27 | ||
|
|
e6a17b6052 | ||
|
|
385f23edf9 | ||
|
|
c0168fabed | ||
|
|
65897c04c8 | ||
|
|
c97c5f0b6b | ||
|
|
c3c64383ca | ||
|
|
be906fe05e | ||
|
|
2d77b25c27 | ||
|
|
9960ddcd66 | ||
|
|
0b994ef589 | ||
|
|
d048b7d36e | ||
|
|
4f68411e77 | ||
|
|
62e1fae858 | ||
|
|
62dc134771 | ||
|
|
3c18d49607 | ||
|
|
ee06106082 | ||
|
|
2d087480b4 | ||
|
|
e49aea9cef | ||
|
|
f9d88c8204 | ||
|
|
4df010b296 | ||
|
|
34a3779aae | ||
|
|
7dfdf3a5b7 | ||
|
|
44b82dffe8 | ||
|
|
5c7c5a762e | ||
|
|
1c546ae552 | ||
|
|
8bc00c2047 | ||
|
|
212d7e8369 | ||
|
|
73e73ffdd5 | ||
|
|
bd1e587ebe | ||
|
|
0395cc01fd | ||
|
|
c25eb99f95 | ||
|
|
18d0efb555 | ||
|
|
9853aac495 | ||
|
|
a3feff414f | ||
|
|
48c03d7c9f | ||
|
|
d2fb24a671 | ||
|
|
f2ce358331 | ||
|
|
c8f8fbecd7 | ||
|
|
0e0e3b05ab | ||
|
|
050d39b3f4 | ||
|
|
ee34e6ef71 | ||
|
|
6254d59043 | ||
|
|
51eb359ea9 | ||
|
|
5b90cf2f2f | ||
|
|
da4b01211b | ||
|
|
4812a59754 | ||
|
|
6acc6dd0c4 | ||
|
|
52c5d9c5b7 | ||
|
|
5dbd0a400a | ||
|
|
11ea8cb0a2 | ||
|
|
ee7e58e111 | ||
|
|
a0daa1220f | ||
|
|
3ebf0418a9 | ||
|
|
0bc09bdace | ||
|
|
0c65604eeb | ||
|
|
d6213e6023 | ||
|
|
808809b061 | ||
|
|
37474eca68 | ||
|
|
9248882ca2 | ||
|
|
9ba2006594 | ||
|
|
2f42558050 | ||
|
|
4cb9fffa7e | ||
|
|
3696f0ee1d | ||
|
|
6f172f7aba | ||
|
|
98c791b543 | ||
|
|
65ced47453 | ||
|
|
21fbdb14e9 | ||
|
|
79d8db77b9 | ||
|
|
2b04dd9d2c | ||
|
|
b302419abe | ||
|
|
5377ac80dc | ||
|
|
fe57ed4f25 | ||
|
|
4d3ab19abf | ||
|
|
1ec9b5a5a9 | ||
|
|
e689a7fc6a | ||
|
|
49db174df5 | ||
|
|
9efe17ed91 | ||
|
|
fe94d0b335 | ||
|
|
b18191cf30 | ||
|
|
9400550c16 | ||
|
|
55ad3cc055 | ||
|
|
a8c4242395 | ||
|
|
e4cb9cd167 | ||
|
|
8333012b56 | ||
|
|
1d0fa45bc1 | ||
|
|
6be8127ea4 | ||
|
|
51fec69ea6 | ||
|
|
4decba90be | ||
|
|
23b7c7dc14 | ||
|
|
44d5c8668a | ||
|
|
b20cdf1d28 | ||
|
|
919f6a070c | ||
|
|
76b6e88e56 | ||
|
|
8a61821057 | ||
|
|
04fa003a50 | ||
|
|
65a51c0d62 | ||
|
|
5a67af97fa | ||
|
|
1798d9a8a4 | ||
|
|
0c1cbd5805 | ||
|
|
d9736db667 | ||
|
|
f5a2ac95c3 | ||
|
|
fe9026d04a | ||
|
|
a6f7f10efa | ||
|
|
b8f2f6fee1 | ||
|
|
acc9566b86 | ||
|
|
17befff800 | ||
|
|
8065c120c4 | ||
|
|
64da16146f | ||
|
|
5ddc53f899 | ||
|
|
7e3fa7e837 | ||
|
|
b0b6d1abe5 | ||
|
|
226d0187b5 | ||
|
|
04d5d16415 | ||
|
|
89ffca52ac | ||
|
|
7ac5b7b934 | ||
|
|
b52f02121b | ||
|
|
2eb88c1752 | ||
|
|
cbb19930b3 | ||
|
|
20e11b2332 | ||
|
|
4e470db0b9 | ||
|
|
5ec34f0ff9 | ||
|
|
083f8111aa | ||
|
|
68bc7df638 | ||
|
|
fd02ca7711 | ||
|
|
e35b9058ce | ||
|
|
d44248ca00 | ||
|
|
6a74f65c58 | ||
|
|
d2e5598cd3 | ||
|
|
e2db790a46 | ||
|
|
3c30b35134 | ||
|
|
23a5c57cee | ||
|
|
0ca9082cbd | ||
|
|
787fd58186 | ||
|
|
5e51ebd8eb | ||
|
|
0d957ca400 | ||
|
|
3d8a791ff9 | ||
|
|
c717ffa146 | ||
|
|
7d848c3308 | ||
|
|
9cc115e417 | ||
|
|
4c6319db9c | ||
|
|
b99c801f73 | ||
|
|
cea0c74bcb | ||
|
|
601c02f783 | ||
|
|
bd4256acfd | ||
|
|
0b9d7e477a | ||
|
|
969c43108e | ||
|
|
b4c5905549 | ||
|
|
b6e92d090c | ||
|
|
563f8ad50a | ||
|
|
21ef956e9a | ||
|
|
a67330d157 | ||
|
|
d1b40400d6 | ||
|
|
ecf2e5b0a1 | ||
|
|
d2b9e1c560 | ||
|
|
d88c67fd81 | ||
|
|
a1a02e6203 | ||
|
|
32c2f939e6 | ||
|
|
2ca741ad4b | ||
|
|
5e2e96b6f0 | ||
|
|
c8ea111166 | ||
|
|
20215ecc7d | ||
|
|
d77a165eac | ||
|
|
ed875a4cb3 | ||
|
|
ad7805dfee | ||
|
|
f1dbacc6ad | ||
|
|
5d7ab75b02 | ||
|
|
88cf5aa783 | ||
|
|
fa489dd043 | ||
|
|
aecd02b391 | ||
|
|
932c2fc291 | ||
|
|
bb2dd388d0 | ||
|
|
1e7d84e258 | ||
|
|
700359ca5a | ||
|
|
adc0490420 | ||
|
|
452be7e7ef | ||
|
|
2b3aab0717 | ||
|
|
ab13ec10eb | ||
|
|
791e7b385a | ||
|
|
008ed1df83 | ||
|
|
5e4c39dc0e | ||
|
|
a546769733 | ||
|
|
c3c19be8e0 | ||
|
|
5999c5b620 | ||
|
|
c93c18abf1 | ||
|
|
71b2504e03 | ||
|
|
960973b2ec | ||
|
|
85bc17495b | ||
|
|
ca8b235188 | ||
|
|
8a1848bf99 | ||
|
|
0c7cbf0a7c | ||
|
|
efbf170cfb | ||
|
|
9b20b68af1 | ||
|
|
6717a7aca0 | ||
|
|
86740f1593 | ||
|
|
2364d9abd3 | ||
|
|
ab377ce414 | ||
|
|
6e2ab82f5c | ||
|
|
ee251d4313 | ||
|
|
bea7fe57c1 | ||
|
|
698b04c735 | ||
|
|
0157624557 | ||
|
|
ae7f22f1ef | ||
|
|
0174d894ef | ||
|
|
c5b3343e65 | ||
|
|
9ecd280f33 | ||
|
|
6a769d97e3 | ||
|
|
49a80ca2bc | ||
|
|
c4fe46f0b8 | ||
|
|
444cd293fd | ||
|
|
e814d5e89f | ||
|
|
edc16a5f7a | ||
|
|
e440bcf41a | ||
|
|
d44c3e647f | ||
|
|
a4ebd5f684 | ||
|
|
65dccf377d | ||
|
|
faee3f0f1e | ||
|
|
901ac21938 | ||
|
|
9c4fd26bca | ||
|
|
2486267dda | ||
|
|
6acf1e93a2 | ||
|
|
cb0ae25a4e | ||
|
|
94b30dc390 | ||
|
|
5bdc6fdebc | ||
|
|
095c6699f4 | ||
|
|
f12ea2d402 | ||
|
|
9cd1cc0535 | ||
|
|
263fff44b4 | ||
|
|
44a22a2c28 | ||
|
|
a55842b9b3 | ||
|
|
95cc7a6dac | ||
|
|
aa93b4ced0 | ||
|
|
2f92adb9e0 | ||
|
|
e60ce392d8 | ||
|
|
ca98203cd9 | ||
|
|
b87957d59a | ||
|
|
ba999b1a3f | ||
|
|
a95dd106e3 | ||
|
|
fb87976ef6 | ||
|
|
8743d00571 | ||
|
|
34ba50522a | ||
|
|
8a97946e0a | ||
|
|
45e05dccd9 | ||
|
|
3538f81513 | ||
|
|
34b3b40af9 | ||
|
|
b5d76b6858 | ||
|
|
6e542f11c9 | ||
|
|
53f8b7190e | ||
|
|
5beff7c6c1 | ||
|
|
12ad488e59 | ||
|
|
b3282a3b9d | ||
|
|
e34bf25d2d | ||
|
|
2f8496b565 | ||
|
|
d55de658b5 | ||
|
|
fcdc6a7d24 | ||
|
|
28bc3cdfba | ||
|
|
3adee0829b | ||
|
|
1e1af99132 | ||
|
|
6bef5e7621 | ||
|
|
9326962f06 | ||
|
|
a76c216b37 | ||
|
|
780155ab31 | ||
|
|
730b26556b | ||
|
|
61608ecfa7 | ||
|
|
767ffdcc9f | ||
|
|
ee4e75bd6f | ||
|
|
1d886a81ad | ||
|
|
da238ee06a | ||
|
|
564b2aa2ef | ||
|
|
13abf91b42 | ||
|
|
ad38681a00 | ||
|
|
56e0ee8efe | ||
|
|
cbed2f8061 | ||
|
|
294d9abf6f | ||
|
|
cb32dcfa33 | ||
|
|
fe14cf6951 | ||
|
|
ecc0d10d2d | ||
|
|
a186c80788 | ||
|
|
09c8e41955 | ||
|
|
c4a4864210 | ||
|
|
c82eadd157 | ||
|
|
68ad7ca3ba | ||
|
|
da21ca988a | ||
|
|
ba23f699f0 | ||
|
|
ea2b711061 | ||
|
|
c6f8ae1085 | ||
|
|
342d1de38c | ||
|
|
bb38cadb1c | ||
|
|
d90ad3fd87 | ||
|
|
3ed16bd9cc | ||
|
|
6c419be402 | ||
|
|
3a5ec72125 | ||
|
|
8c3d15ce28 | ||
|
|
83a43aca23 | ||
|
|
ff2b910dd1 | ||
|
|
9073c40c7e | ||
|
|
1936019cd1 | ||
|
|
9f3bcd87db | ||
|
|
e2af1da1d3 | ||
|
|
9d3de643d1 | ||
|
|
d25ad506f2 | ||
|
|
03593f53e7 | ||
|
|
0a605f93db | ||
|
|
51faca1270 | ||
|
|
f51a32e82a | ||
|
|
05529fefa4 | ||
|
|
f4d5b1da7b | ||
|
|
0dcab2a86a | ||
|
|
789eb27870 | ||
|
|
c1c954e81b | ||
|
|
a1a9858ca3 | ||
|
|
e099ce85ca | ||
|
|
dc32eb8f93 | ||
|
|
a9bcf75103 | ||
|
|
762c3618f5 | ||
|
|
5722338ea5 | ||
|
|
32cd166971 | ||
|
|
f08f233d6f | ||
|
|
59ebe1ff77 | ||
|
|
e80b9c24f4 | ||
|
|
2e7af79f48 | ||
|
|
c87809c9ed | ||
|
|
1979b6b2de | ||
|
|
900da88dae | ||
|
|
9ebe3b6d36 | ||
|
|
28b014ee25 | ||
|
|
027bb77e02 | ||
|
|
f8ca99d697 | ||
|
|
6a9f0a27c3 | ||
|
|
7473d17268 | ||
|
|
b7339d7023 | ||
|
|
b4e9750bf4 | ||
|
|
607b61a994 | ||
|
|
1a5fecb4d6 | ||
|
|
ae76be49eb | ||
|
|
3c327c9f3a | ||
|
|
76a0797c32 | ||
|
|
a9cc078b0e | ||
|
|
ac619f4912 | ||
|
|
edd2702287 | ||
|
|
225148ea07 | ||
|
|
a824813d22 | ||
|
|
5bb5a1908f | ||
|
|
a951c80ae4 | ||
|
|
808a678d85 | ||
|
|
d61c1cc7c9 | ||
|
|
cf69d09202 | ||
|
|
b927a75979 | ||
|
|
5ab5517ba8 | ||
|
|
05ddc4a6c5 | ||
|
|
b3208c2de9 | ||
|
|
1ee92f984b | ||
|
|
75f81ad5f9 | ||
|
|
b100484145 | ||
|
|
278736ff6f | ||
|
|
57b61638af | ||
|
|
09b6b9e9c3 | ||
|
|
482d9dd21d | ||
|
|
9e8659f346 | ||
|
|
e3f41ce611 | ||
|
|
3a3e63dc4f | ||
|
|
3a46dff27d | ||
|
|
29d833bd52 | ||
|
|
9305cba6a7 | ||
|
|
f2ad1b60c0 | ||
|
|
df3d4e0bb9 | ||
|
|
6652dc8aac | ||
|
|
7da1daf0a2 | ||
|
|
18b72d184c | ||
|
|
ef5b48dea1 | ||
|
|
2cd4056fae | ||
|
|
fb0175db93 | ||
|
|
aa70d92a13 | ||
|
|
aba4967150 | ||
|
|
174ce730c6 | ||
|
|
48547ee129 | ||
|
|
823c581f7c | ||
|
|
8982697981 | ||
|
|
9542537cee | ||
|
|
c3f2c287ce | ||
|
|
9e81d6ae3a | ||
|
|
94d6bf883b | ||
|
|
84c5d0a789 | ||
|
|
dd7074736f | ||
|
|
ef8b89faee | ||
|
|
159ca321cb | ||
|
|
ec83f38e2e | ||
|
|
197d725601 | ||
|
|
693a66aea9 | ||
|
|
8ea3353ec3 | ||
|
|
87af12dbdc | ||
|
|
a8c9ecfab0 | ||
|
|
4ecb9f0532 | ||
|
|
8b186e3695 | ||
|
|
e43edd3c70 | ||
|
|
20e15f9381 | ||
|
|
75a8383e8d | ||
|
|
920023240c | ||
|
|
62c325af3f | ||
|
|
32244ac7e9 | ||
|
|
3a6d968f37 | ||
|
|
cec74532bf | ||
|
|
f331bb0312 | ||
|
|
c3051df8e1 | ||
|
|
db79d2abac | ||
|
|
c19de0b7f6 | ||
|
|
e5b6eee15d | ||
|
|
006e183b6e | ||
|
|
180b0dab8b | ||
|
|
a85fbb1d36 | ||
|
|
555478fed6 | ||
|
|
2742c4e4db | ||
|
|
2b430ef56a | ||
|
|
b7a5a9db88 | ||
|
|
888ab86f85 | ||
|
|
2526152a10 | ||
|
|
519a2e7cb7 | ||
|
|
b687531f69 | ||
|
|
54b65e080e | ||
|
|
3076557ca3 | ||
|
|
4f21180416 | ||
|
|
c61763b5d2 | ||
|
|
08e62a1476 | ||
|
|
0e26ca0834 | ||
|
|
e44499480f | ||
|
|
9f6ff49650 | ||
|
|
c7a5d528c7 | ||
|
|
b8915340ea | ||
|
|
1155f64cc0 | ||
|
|
255e8ebd58 | ||
|
|
95174c4eb2 | ||
|
|
f76ff7e4a7 | ||
|
|
96aa403cee | ||
|
|
004673d4d1 | ||
|
|
0ad1bda7a1 | ||
|
|
e72b745f32 | ||
|
|
ea4fe661d7 | ||
|
|
4cbd16ed3f | ||
|
|
06049e2416 | ||
|
|
753af3a206 | ||
|
|
70207b70c5 | ||
|
|
1bbc203c6e | ||
|
|
6494541eaa | ||
|
|
590cd26006 | ||
|
|
ed4ab13cef | ||
|
|
af8d39861d | ||
|
|
c4f2710f9d | ||
|
|
436d72e994 | ||
|
|
d76ef5867d | ||
|
|
0a6040dc2d | ||
|
|
eab896cc21 | ||
|
|
f756924fa5 | ||
|
|
4fafe6390b | ||
|
|
6fc864b9e6 | ||
|
|
daffbe99dc | ||
|
|
8995544bc9 | ||
|
|
071357096e | ||
|
|
519b23b21f | ||
|
|
4991888fa0 | ||
|
|
34bd1233a9 | ||
|
|
457fb0e128 | ||
|
|
7275d4d097 | ||
|
|
f1038f81e4 | ||
|
|
c27c382acc | ||
|
|
5319ed0e53 | ||
|
|
070f280895 | ||
|
|
096dd541bd | ||
|
|
77174f0072 | ||
|
|
21a4fb4137 | ||
|
|
19b05d5009 | ||
|
|
2d2af2dcf7 | ||
|
|
eec33cc310 | ||
|
|
0f1d98c422 | ||
|
|
724df02073 | ||
|
|
2b17741e1b | ||
|
|
c6c0f94714 | ||
|
|
ef8653a838 | ||
|
|
514a15cea1 | ||
|
|
ac8b07b3ae | ||
|
|
e660690985 | ||
|
|
30655c211c | ||
|
|
59e0faaa5c | ||
|
|
eccb6a0698 | ||
|
|
10f08cc202 | ||
|
|
b7e3e0d64e | ||
|
|
19b8322169 | ||
|
|
2a0d441ebb | ||
|
|
15e74a6441 | ||
|
|
0f618b7eb7 | ||
|
|
8af48fc4d6 | ||
|
|
e9484e4085 | ||
|
|
a0cf4ceb36 | ||
|
|
5042778449 | ||
|
|
9c32af5bb2 | ||
|
|
841a823d6d | ||
|
|
0d57301ba2 | ||
|
|
12d51beb7e | ||
|
|
e294d938f2 | ||
|
|
f1b431b265 | ||
|
|
9fc897af7a | ||
|
|
d97ab9a7bd | ||
|
|
d9894e0d72 | ||
|
|
dba9c0bafd | ||
|
|
ba7ea2e697 | ||
|
|
50f319242b | ||
|
|
ca007cb449 | ||
|
|
d75963d258 | ||
|
|
8ee311d36d | ||
|
|
2e01918b55 | ||
|
|
168a7516b1 | ||
|
|
c107058e7e | ||
|
|
3bca4f679a | ||
|
|
9d881ea718 | ||
|
|
448d23331d | ||
|
|
66df1731e6 | ||
|
|
5820f7998a | ||
|
|
780d270312 | ||
|
|
e1e03b32ab | ||
|
|
f8ba07a77d | ||
|
|
5e01f9a114 | ||
|
|
f4ab5654d0 | ||
|
|
da16813f43 | ||
|
|
9227bca103 | ||
|
|
81b8aa9ecd | ||
|
|
14d3ab9662 | ||
|
|
904ab0c22c | ||
|
|
afa1df5871 | ||
|
|
c241d3b06a | ||
|
|
93da673904 | ||
|
|
cf6be2d5bd | ||
|
|
dbfd246db8 | ||
|
|
190e5595bc | ||
|
|
68edf28df6 | ||
|
|
9b8059e536 | ||
|
|
6d4284e2bf | ||
|
|
9974540c73 | ||
|
|
2c61fdafd6 | ||
|
|
1eca891dbe | ||
|
|
a231097609 | ||
|
|
fbe48ef01f | ||
|
|
71932ef85c | ||
|
|
6754e17138 | ||
|
|
f71fd439f5 | ||
|
|
147f5091a1 | ||
|
|
176dac684a | ||
|
|
34b60b001d | ||
|
|
3073cf21d2 | ||
|
|
d1d4121682 | ||
|
|
9ac9605de1 | ||
|
|
c56f2c49a5 | ||
|
|
be42f53020 | ||
|
|
a764b7eae0 | ||
|
|
4e77669926 | ||
|
|
2aabdc743f | ||
|
|
ee2339f673 | ||
|
|
228d4a6de7 | ||
|
|
1aad408b5a | ||
|
|
44a2e96729 | ||
|
|
5b2ee9c1e9 | ||
|
|
956fff6345 | ||
|
|
7b6fd8a0c6 | ||
|
|
cebad151a1 | ||
|
|
4f8b59d59b | ||
|
|
49ad2d4ed1 | ||
|
|
cc1591667d | ||
|
|
8986e36f36 | ||
|
|
fcbbdf9991 | ||
|
|
97a3023c9f | ||
|
|
3654193a4d | ||
|
|
e94be8d5c0 | ||
|
|
8da9f448f4 | ||
|
|
555b5fac4f | ||
|
|
a176bc6c17 | ||
|
|
ee40c4fb34 | ||
|
|
a584e846d4 | ||
|
|
dd02edf381 | ||
|
|
88d994c3b2 | ||
|
|
50092f8f33 | ||
|
|
870ebefb3b | ||
|
|
a663931204 | ||
|
|
5bc35a823a | ||
|
|
dc3a922cf3 | ||
|
|
0c8e578a38 | ||
|
|
3699751b0b | ||
|
|
d5aca8bf0c | ||
|
|
0c1438d331 | ||
|
|
a5033a0421 | ||
|
|
2189d9c96e | ||
|
|
e7ffe4619f | ||
|
|
8a54fad6cd | ||
|
|
ebcbf2f853 | ||
|
|
41eeae5fb1 | ||
|
|
02eb9acc5e | ||
|
|
44e9ccc708 | ||
|
|
adef42c88d | ||
|
|
7d376c76c9 | ||
|
|
a2ea606377 | ||
|
|
2363fff347 | ||
|
|
c92e688e15 | ||
|
|
170f08d4b1 | ||
|
|
91c30771b6 | ||
|
|
f236300e3a | ||
|
|
a73094cc6a | ||
|
|
42447365b2 | ||
|
|
b77a225250 | ||
|
|
d93615fc1e | ||
|
|
42725d6f54 | ||
|
|
4cd0e24f86 | ||
|
|
640ef7f890 | ||
|
|
63b852f4f9 | ||
|
|
ea970da0b6 | ||
|
|
e7276b7fa5 | ||
|
|
16a14510c4 | ||
|
|
725740c7c8 | ||
|
|
5951aab823 | ||
|
|
865ad82bb8 | ||
|
|
3b6f62fc73 | ||
|
|
111281f1fc | ||
|
|
663138a951 | ||
|
|
a45f23bed1 | ||
|
|
4b4cc650e1 | ||
|
|
781c54a5b8 | ||
|
|
6a36407a00 | ||
|
|
7905b19ec9 | ||
|
|
bd8c742762 | ||
|
|
9dc8bce88e | ||
|
|
b2006a40eb | ||
|
|
daf3093f28 | ||
|
|
5e9d73153c | ||
|
|
0b3c2a9a24 | ||
|
|
5594ddbcfe | ||
|
|
58e4aa0ec9 | ||
|
|
0fcfa1c5b0 | ||
|
|
e797bc8bbe | ||
|
|
7d82d284e3 | ||
|
|
a7bd2563c3 | ||
|
|
875df252a7 | ||
|
|
e804370014 | ||
|
|
32551222bc | ||
|
|
77667266a7 | ||
|
|
32a6468014 | ||
|
|
e65ad47a8f | ||
|
|
edc98df891 | ||
|
|
fbcb37cac5 | ||
|
|
3a5bb1729d | ||
|
|
2219a15b06 | ||
|
|
74235b1cf1 | ||
|
|
f3cf636e57 | ||
|
|
166b0ff973 | ||
|
|
7f1274fa8b | ||
|
|
99da2d30eb | ||
|
|
8b1dc68662 | ||
|
|
4dd8a8907e | ||
|
|
65573edd1b | ||
|
|
f3134ca7ad | ||
|
|
f7360cd42d | ||
|
|
39c492bb14 | ||
|
|
acd1f16b35 | ||
|
|
c6f35dd8db | ||
|
|
f087d60f18 | ||
|
|
41a874f486 | ||
|
|
ef073b7a75 | ||
|
|
c90b569238 | ||
|
|
93a7605b1d | ||
|
|
b42d5bcaff | ||
|
|
37e86254c1 | ||
|
|
216f729a95 | ||
|
|
38da697546 | ||
|
|
f93a228c38 | ||
|
|
1096eae18d | ||
|
|
361bccb4ec |
32
Makefile
32
Makefile
@@ -33,8 +33,9 @@ realclean:
|
||||
|
||||
|
||||
install:
|
||||
@echo "Installing"
|
||||
$(TOP)/bin/installmesa $(DESTDIR)
|
||||
@for dir in $(SUBDIRS) ; do \
|
||||
(cd $$dir ; $(MAKE) install) || exit 1 ; \
|
||||
done
|
||||
|
||||
# DirectFBGL module installation
|
||||
linux-directfb-install:
|
||||
@@ -55,11 +56,14 @@ $(TOP)/configs/current:
|
||||
# Rules to set/install a specific build configuration
|
||||
aix \
|
||||
aix-64 \
|
||||
aix-64-static \
|
||||
aix-gcc \
|
||||
aix-static \
|
||||
beos \
|
||||
darwin \
|
||||
darwin-static \
|
||||
darwin-static-x86ppc \
|
||||
darwin-x86ppc \
|
||||
freebsd \
|
||||
freebsd-dri \
|
||||
freebsd-dri-amd64 \
|
||||
@@ -72,6 +76,8 @@ hpux11-32-static \
|
||||
hpux11-32-static-nothreads \
|
||||
hpux11-64 \
|
||||
hpux11-64-static \
|
||||
hpux11-ia64 \
|
||||
hpux11-ia64-static \
|
||||
hpux9 \
|
||||
hpux9-gcc \
|
||||
irix6-64 \
|
||||
@@ -89,11 +95,15 @@ linux-dri \
|
||||
linux-dri-x86 \
|
||||
linux-dri-x86-64 \
|
||||
linux-dri-ppc \
|
||||
linux-dri-xcb \
|
||||
linux-indirect \
|
||||
linux-fbdev \
|
||||
linux-glide \
|
||||
linux-ia64-icc \
|
||||
linux-ia64-icc-static \
|
||||
linux-icc \
|
||||
linux-icc-static \
|
||||
linux-osmesa \
|
||||
linux-osmesa16 \
|
||||
linux-osmesa16-static \
|
||||
linux-osmesa32 \
|
||||
@@ -113,20 +123,26 @@ linux-x86-32 \
|
||||
linux-x86-64 \
|
||||
linux-x86-64-debug \
|
||||
linux-x86-64-static \
|
||||
linux-x86-xcb \
|
||||
linux-x86-glide \
|
||||
linux-x86-static \
|
||||
netbsd \
|
||||
openbsd \
|
||||
osf1 \
|
||||
osf1-static \
|
||||
solaris-x86 \
|
||||
solaris-x86-gcc \
|
||||
solaris-x86-gcc-static \
|
||||
sunos4 \
|
||||
sunos4-gcc \
|
||||
sunos4-static \
|
||||
sunos5 \
|
||||
sunos5-gcc \
|
||||
sunos5-64-gcc \
|
||||
sunos5-smp \
|
||||
sunos5-v8 \
|
||||
sunos5-v8-static \
|
||||
sunos5-v9 \
|
||||
sunos5-v9-static \
|
||||
ultrix-gcc:
|
||||
(cd configs && rm -f current && ln -s $@ current)
|
||||
$(MAKE) default
|
||||
@@ -134,10 +150,10 @@ ultrix-gcc:
|
||||
|
||||
# Rules for making release tarballs
|
||||
|
||||
DIRECTORY = Mesa-6.5
|
||||
LIB_NAME = MesaLib-6.5
|
||||
DEMO_NAME = MesaDemos-6.5
|
||||
GLUT_NAME = MesaGLUT-6.5
|
||||
DIRECTORY = Mesa-6.5.1
|
||||
LIB_NAME = MesaLib-6.5.1
|
||||
DEMO_NAME = MesaDemos-6.5.1
|
||||
GLUT_NAME = MesaGLUT-6.5.1
|
||||
|
||||
MAIN_FILES = \
|
||||
$(DIRECTORY)/Makefile* \
|
||||
@@ -166,6 +182,7 @@ MAIN_FILES = \
|
||||
$(DIRECTORY)/include/GL/glx.h \
|
||||
$(DIRECTORY)/include/GL/glxext.h \
|
||||
$(DIRECTORY)/include/GL/glx_mangle.h \
|
||||
$(DIRECTORY)/include/GL/glfbdev.h \
|
||||
$(DIRECTORY)/include/GL/mesa_wgl.h \
|
||||
$(DIRECTORY)/include/GL/mglmesa.h \
|
||||
$(DIRECTORY)/include/GL/osmesa.h \
|
||||
@@ -364,6 +381,7 @@ GLUT_FILES = \
|
||||
|
||||
DEPEND_FILES = \
|
||||
$(TOP)/src/mesa/depend \
|
||||
$(TOP)/src/glx/x11/depend \
|
||||
$(TOP)/src/glw/depend \
|
||||
$(TOP)/src/glut/glx/depend \
|
||||
$(TOP)/src/glu/sgi/depend
|
||||
|
||||
11
Makefile.DJ
11
Makefile.DJ
@@ -20,9 +20,9 @@
|
||||
# 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.
|
||||
|
||||
# DOS/DJGPP makefile v1.6 for Mesa
|
||||
# DOS/DJGPP makefile for Mesa
|
||||
#
|
||||
# Copyright (C) 2002 - Daniel Borca
|
||||
# Author: Daniel Borca
|
||||
# Email : dborca@users.sourceforge.net
|
||||
# Web : http://www.geocities.com/dborca
|
||||
|
||||
@@ -31,9 +31,6 @@
|
||||
# Available options:
|
||||
#
|
||||
# Environment variables:
|
||||
# GLU=[mesa|sgi] specify GLU directory; can be `sgi' (requires GNU/C++)
|
||||
# or `mesa'.
|
||||
# default = mesa
|
||||
# GLIDE path to Glide3 SDK; used with FX.
|
||||
# default = $(TOP)/glide3
|
||||
# FX=1 build for 3dfx Glide3. Note that this disables
|
||||
@@ -57,8 +54,6 @@
|
||||
|
||||
.PHONY : all libgl libglu libglut clean realclean
|
||||
|
||||
GLU ?= mesa
|
||||
|
||||
CFLAGS = -Wall -W -pedantic
|
||||
CFLAGS += -O2 -ffast-math
|
||||
|
||||
@@ -75,7 +70,7 @@ all: libgl libglu libglut
|
||||
libgl: lib
|
||||
$(MAKE) -f Makefile.DJ -C src/mesa
|
||||
libglu: lib
|
||||
$(MAKE) -f Makefile.DJ -C src/glu/$(GLU)
|
||||
$(MAKE) -f Makefile.DJ -C src/glu/sgi
|
||||
libglut: lib
|
||||
$(MAKE) -f Makefile.DJ -C src/glut/dos
|
||||
|
||||
|
||||
@@ -53,6 +53,8 @@ if [ `uname` = "FreeBSD" ] ; then
|
||||
CP_FLAGS="-f"
|
||||
elif [ `uname` = "Darwin" ] ; then
|
||||
CP_FLAGS="-f"
|
||||
elif [ `uname` = "AIX" ] ; then
|
||||
CP_FLAGS="-fh"
|
||||
else
|
||||
CP_FLAGS="-fd"
|
||||
fi
|
||||
@@ -62,7 +64,7 @@ set -v
|
||||
|
||||
mkdir ${INCLUDE_DIR}
|
||||
mkdir ${INCLUDE_DIR}/GL
|
||||
mkdir ${INCLUDE_DIR}/GLES
|
||||
# NOT YET: mkdir ${INCLUDE_DIR}/GLES
|
||||
mkdir ${LIB_DIR}
|
||||
cp -f ${TOP}/include/GL/*.h ${INCLUDE_DIR}/GL
|
||||
cp -f ${TOP}/src/glw/*.h ${INCLUDE_DIR}/GL
|
||||
|
||||
182
bin/mklib
182
bin/mklib
@@ -5,7 +5,7 @@
|
||||
# Improvements/fixes are welcome.
|
||||
|
||||
|
||||
# Copyright (C) 1999-2005 Brian Paul All Rights Reserved.
|
||||
# Copyright (C) 1999-2006 Brian Paul All Rights Reserved.
|
||||
#
|
||||
# Permission is hereby granted, free of charge, to any person obtaining a
|
||||
# copy of this software and associated documentation files (the "Software"),
|
||||
@@ -36,6 +36,7 @@ DEPS=""
|
||||
LINK=""
|
||||
CPLUSPLUS=0
|
||||
STATIC=0
|
||||
DLOPEN=0
|
||||
INSTALLDIR="."
|
||||
ARCH="auto"
|
||||
ARCHOPT=""
|
||||
@@ -64,6 +65,7 @@ do
|
||||
echo ' Not observed on all systems at this time.'
|
||||
echo ' -cplusplus link with C++ runtime'
|
||||
echo ' -static make a static library (default is dynamic/shared)'
|
||||
echo ' -dlopen make a shared library suitable for dynamic loading'
|
||||
echo ' -install DIR put resulting library file(s) in DIR'
|
||||
echo ' -arch ARCH override using `uname` to determine host system'
|
||||
echo ' -archopt OPT specify an extra achitecture-specific option OPT'
|
||||
@@ -104,6 +106,9 @@ do
|
||||
'-static')
|
||||
STATIC=1
|
||||
;;
|
||||
'-dlopen')
|
||||
DLOPEN=1
|
||||
;;
|
||||
'-install')
|
||||
shift 1;
|
||||
INSTALLDIR=$1
|
||||
@@ -175,7 +180,7 @@ fi
|
||||
#
|
||||
case $ARCH in
|
||||
|
||||
'Linux' | 'OpenBSD')
|
||||
'Linux' | 'OpenBSD' | 'GNU' | GNU/*)
|
||||
# we assume gcc
|
||||
|
||||
if [ "x$LINK" = "x" ] ; then
|
||||
@@ -209,18 +214,22 @@ case $ARCH in
|
||||
elif [ $STATIC = 1 ] ; then
|
||||
LIBNAME="lib${LIBNAME}" # prefix with "lib"
|
||||
echo "mklib: Making" $ARCH "static library: " ${LIBNAME}.a
|
||||
rm -f ${LIBNAME}.a
|
||||
ar -ru ${LIBNAME}.a ${OBJECTS}
|
||||
LINK="ar"
|
||||
OPTS="-ru"
|
||||
# make lib
|
||||
${LINK} ${OPTS} ${LIBNAME}.a ${OBJECTS}
|
||||
ranlib ${LIBNAME}.a
|
||||
# finish up
|
||||
FINAL_LIBS=${LIBNAME}.a
|
||||
else
|
||||
LIBNAME="lib${LIBNAME}" # prefix with "lib"
|
||||
if [ $ARCH = 'Linux' ] ; then
|
||||
case $ARCH in 'Linux' | 'GNU' | GNU/*)
|
||||
OPTS="-Xlinker -Bsymbolic -shared -Wl,-soname,${LIBNAME}.so.${MAJOR}"
|
||||
else
|
||||
;;
|
||||
*)
|
||||
OPTS="-shared -Wl,-soname,${LIBNAME}.so.${MAJOR}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
if [ $EXPORTS ] ; then
|
||||
#OPTS="${OPTS} -Xlinker --retain-symbols-file ${EXPORTS}"
|
||||
# Make the 'exptmp' file for --version-script option
|
||||
@@ -276,9 +285,7 @@ case $ARCH in
|
||||
else
|
||||
LIBNAME="lib${LIBNAME}.so"
|
||||
echo "mklib: Making SunOS shared library: " ${LIBNAME}
|
||||
# XXX OPTS for gcc should be -shared, but that doesn't work.
|
||||
# Using -G does work though.
|
||||
OPTS="-G"
|
||||
|
||||
if [ "x$LINK" = "x" ] ; then
|
||||
# -linker was not specified, choose default linker now
|
||||
if [ $CPLUSPLUS = 1 ] ; then
|
||||
@@ -298,7 +305,34 @@ case $ARCH in
|
||||
LINK="ld"
|
||||
fi
|
||||
fi
|
||||
echo "mklib: linker is" ${LINK} ${OPTS}
|
||||
|
||||
# linker options
|
||||
if [ ${LINK} = "ld" -o ${LINK} = "cc" -o ${LINK} = "CC" ] ; then
|
||||
# SunOS tools, -G to make shared libs
|
||||
OPTS="-G"
|
||||
else
|
||||
# gcc linker
|
||||
# Check if objects are 32-bit and we're running in 64-bit
|
||||
# environment. If so, pass -m32 flag to linker.
|
||||
set ${OBJECTS}
|
||||
ABI32=`file $1 | grep 32-bit`
|
||||
if [ "${ABI32}" ] ; then
|
||||
OPTS="-m32 -shared -Wl,-Bdynamic"
|
||||
else
|
||||
OPTS="-m64 -shared -Wl,-Bdynamic"
|
||||
fi
|
||||
fi
|
||||
|
||||
# Check if objects are SPARC v9
|
||||
# file says: ELF 64-bit MSB relocatable SPARCV9 Version 1
|
||||
set ${OBJECTS}
|
||||
SPARCV9=`file $1 | grep SPARCV9`
|
||||
if [ "${SPARCV9}" ] ; then
|
||||
OPTS="${OPTS} -xarch=v9"
|
||||
fi
|
||||
|
||||
# for debug:
|
||||
#echo "mklib: linker is" ${LINK} ${OPTS}
|
||||
rm -f ${LIBNAME}.${MAJOR} ${LIBNAME}
|
||||
${LINK} ${OPTS} -o ${LIBNAME}.${MAJOR} ${OBJECTS} ${DEPS}
|
||||
ln -s ${LIBNAME}.${MAJOR} ${LIBNAME}
|
||||
@@ -368,26 +402,33 @@ case $ARCH in
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
else
|
||||
LIBNAME="lib${LIBNAME}.so" # prefix with "lib", suffix with ".so"
|
||||
# XXX we should run 'file' on the first object file to determine
|
||||
# if it's o32, n32 or 64 format, as we do for Linux above.
|
||||
if [ $ARCHOPT = "64" ] ; then
|
||||
# 64-bit ABI
|
||||
OPTS="-64 -shared -all"
|
||||
echo "mklib: Making IRIX 64-bit shared library: " ${LIBNAME}
|
||||
elif [ $ARCHOPT = "o32" ] ; then
|
||||
# old 32-bit ABI
|
||||
|
||||
# examine first object to determine ABI
|
||||
set ${OBJECTS}
|
||||
ABI_O32=`file $1 | grep 'ELF 32-bit'`
|
||||
ABI_N32=`file $1 | grep 'ELF N32'`
|
||||
ABI_N64=`file $1 | grep 'ELF 64-bit'`
|
||||
if [ "${ABI_O32}" ] ; then
|
||||
OPTS="-32 -shared -all"
|
||||
echo "mklib: Making IRIX o32-bit shared library: " ${LIBNAME}
|
||||
else
|
||||
# new 32-bit ABI
|
||||
ABI="o32-bit"
|
||||
elif [ "${ABI_N32}" ] ; then
|
||||
OPTS="-n32 -shared -all"
|
||||
echo "mklib: Making IRIX n32-bit shared library: " ${LIBNAME}
|
||||
ABI="n32-bit"
|
||||
elif [ "${ABI_N64}" ] ; then
|
||||
OPTS="-64 -shared -all"
|
||||
ABI="64-bit"
|
||||
else
|
||||
echo "Error: Unexpected IRIX ABI!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ $CPLUSPLUS = 1 ] ; then
|
||||
LINK="CC"
|
||||
else
|
||||
LINK="ld"
|
||||
fi
|
||||
|
||||
echo "mklib: Making IRIX " ${ABI} " shared library: " ${LIBNAME}
|
||||
${LINK} ${OPTS} -o ${LIBNAME} ${OBJECTS} ${DEPS}
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
fi
|
||||
@@ -409,6 +450,10 @@ case $ARCH in
|
||||
ar -ruv ${LIBNAME} ${OBJECTS}
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
else
|
||||
# HP uses a .2 for their current GL/GLU libraries
|
||||
if [ ${LIBNAME} = "GL" -o ${LIBNAME} = "GLU" ] ; then
|
||||
MAJOR=2
|
||||
fi
|
||||
RUNLIB="lib${LIBNAME}.${MAJOR}"
|
||||
DEVLIB="lib${LIBNAME}.sl"
|
||||
echo "mklib: Making HP-UX shared library: " ${RUNLIB} ${DEVLIB}
|
||||
@@ -418,26 +463,27 @@ case $ARCH in
|
||||
fi
|
||||
;;
|
||||
|
||||
'AIX' | 'AIX64')
|
||||
if [ $ARCH = "AIX64" ] ; then
|
||||
'AIX' )
|
||||
# examine first object to determine ABI
|
||||
set ${OBJECTS}
|
||||
ABI_64=`file $1 | grep '64-bit'`
|
||||
if [ "${ABI_64}" ] ; then
|
||||
X64="-X64"
|
||||
Q64="-q64"
|
||||
OFILE=shr_64.o
|
||||
else
|
||||
OFILE=shr.o #Want to be consistent with the IBM libGL.a
|
||||
fi
|
||||
|
||||
if [ $STATIC = 1 ] ; then
|
||||
LIBNAME="lib${LIBNAME}.a"
|
||||
echo "mklib: Making AIX static library: " ${LIBNAME}
|
||||
rm -f ${LIBNAME}
|
||||
ar -ruv ${X64} ${LIBNAME} ${OBJECTS}
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
else
|
||||
if [ $STATIC = 1 ] ; then
|
||||
LIBNAME="lib${LIBNAME}.a"
|
||||
echo "mklib: Making AIX static library: " ${LIBNAME}
|
||||
ar -ruv ${X64} ${LIBNAME} ${OBJECTS}
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
else
|
||||
EXPFILE="lib${LIBNAME}.exp"
|
||||
OFILE=shr.o #Want to be consistent with the IBM libGL.a
|
||||
LIBNAME="lib${LIBNAME}.a" # shared objects are still stored in the .a libraries
|
||||
if [ $ARCH = "AIX64" ] ; then
|
||||
OPTS="-bE:${EXPFILE} -bM:SRE -bnoentry -q64"
|
||||
else
|
||||
OPTS="-bE:${EXPFILE} -bM:SRE -bnoentry"
|
||||
fi
|
||||
OPTS="-bE:${EXPFILE} -bM:SRE -bnoentry ${Q64}"
|
||||
rm -f ${EXPFILE} ${OFILE}
|
||||
NM="/bin/nm -eC ${X64}"
|
||||
echo "#! /usr/lib/${LIBNAME}" > ${EXPFILE}
|
||||
@@ -455,8 +501,16 @@ case $ARCH in
|
||||
}
|
||||
}
|
||||
}' | sort -u >> ${EXPFILE}
|
||||
cc ${OPTS} -o ${OFILE} ${OBJECTS} ${DEPS}
|
||||
ar ${X64} -r ${LIBNAME} ${OFILE}
|
||||
|
||||
# On AIX a shared library is linked differently when
|
||||
# you want to dlopen the file
|
||||
if [ $DLOPEN = "1" ] ; then
|
||||
cc -G ${OPTS} -o ${LIBNAME} ${OBJECTS} ${DEPS}
|
||||
else
|
||||
cc ${OPTS} -o ${OFILE} ${OBJECTS} ${DEPS}
|
||||
ar ${X64} -r ${LIBNAME} ${OFILE}
|
||||
fi
|
||||
|
||||
FINAL_LIBS="${LIBNAME}"
|
||||
fi
|
||||
;;
|
||||
@@ -498,20 +552,46 @@ case $ARCH in
|
||||
LIBNAME="lib${LIBNAME}.a"
|
||||
echo "mklib: Making Darwin static library: " ${LIBNAME}
|
||||
LINK="ar"
|
||||
OPTS="-ruv"
|
||||
OPTS="-ruvs"
|
||||
${LINK} ${OPTS} ${LIBNAME} ${OBJECTS}
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
else
|
||||
LIBNAME="lib${LIBNAME}.dylib"
|
||||
echo "mklib: Making Darwin shared library: " ${LIBNAME}
|
||||
FLAGS="-dynamiclib -multiply_defined suppress -current_version ${MAJOR}.${MINOR}.0 -compatibility_version ${MAJOR}.${MINOR}.0"
|
||||
# On Darwin a .bundle is used for a library that you want to dlopen
|
||||
if [ $DLOPEN = "1" ] ; then
|
||||
LIBSUFFIX="bundle"
|
||||
OPTS="${ARCHOPT} -bundle -multiply_defined suppress"
|
||||
else
|
||||
LIBSUFFIX="dylib"
|
||||
OPTS="${ARCHOPT} -dynamiclib -multiply_defined suppress -current_version ${MAJOR}.${MINOR}.0 -compatibility_version ${MAJOR}.${MINOR}.0 -install_name lib${LIBNAME}.${MAJOR}.${LIBSUFFIX}"
|
||||
fi
|
||||
LINKNAME="lib${LIBNAME}.${LIBSUFFIX}"
|
||||
LIBNAME="lib${LIBNAME}.${MAJOR}.${LIBSUFFIX}"
|
||||
|
||||
# examine first object to determine ABI
|
||||
set ${OBJECTS}
|
||||
ABI_PPC=`file $1 | grep 'object ppc'`
|
||||
ABI_I386=`file $1 | grep 'object i386'`
|
||||
if [ "${ABI_PPC}" ] ; then
|
||||
OPTS="${OPTS} -arch ppc"
|
||||
fi
|
||||
if [ "${ABI_I386}" ] ; then
|
||||
OPTS="${OPTS} -arch i386"
|
||||
fi
|
||||
|
||||
# XXX can we always add -isysroot /Developer/SDKs/MacOSX10.4u.sdk
|
||||
# to OPTS here?
|
||||
|
||||
# determine linker
|
||||
if [ $CPLUSPLUS = 1 ] ; then
|
||||
LINK="g++"
|
||||
else
|
||||
LINK="cc"
|
||||
fi
|
||||
${LINK} ${FLAGS} -o ${LIBNAME} ${OBJECTS} ${DEPS}
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
|
||||
echo "mklib: Making Darwin shared library: " ${LIBNAME}
|
||||
${LINK} ${OPTS} -o ${LIBNAME} ${OBJECTS} ${DEPS}
|
||||
ln -s ${LIBNAME} ${LINKNAME}
|
||||
FINAL_LIBS="${LIBNAME} ${LINKNAME}"
|
||||
fi
|
||||
;;
|
||||
|
||||
@@ -553,7 +633,7 @@ case $ARCH in
|
||||
FINAL_LIBS="${LIBNAME}"
|
||||
;;
|
||||
|
||||
'icc')
|
||||
'icc' | 'icc-istatic')
|
||||
# Intel C compiler
|
||||
# This should get merged into the Linux code, above, since this isn't
|
||||
# really a different architecture.
|
||||
@@ -568,12 +648,16 @@ case $ARCH in
|
||||
# finish up
|
||||
FINAL_LIBS="${LIBNAME}.a"
|
||||
else
|
||||
OPTS="-shared"
|
||||
if [ $ARCH = icc-istatic ] ; then
|
||||
OPTS="-shared -i-static -cxxlib-icc"
|
||||
else
|
||||
OPTS="-shared"
|
||||
fi
|
||||
VERSION="${MAJOR}.${MINOR}.${PATCH}"
|
||||
echo "mklib: Making Intel ICC shared library: " ${LIBNAME}.so.${VERSION}
|
||||
|
||||
if [ $CPLUSPLUS = 1 ] ; then
|
||||
LINK="icc"
|
||||
LINK="icpc"
|
||||
else
|
||||
LINK="icc"
|
||||
fi
|
||||
|
||||
13
configs/aix
13
configs/aix
@@ -8,9 +8,12 @@ CONFIG_NAME = aix
|
||||
CC = cc
|
||||
CXX = xlC
|
||||
|
||||
CFLAGS = -O -DAIXV3
|
||||
CXXFLAGS = -O -DAIXV3
|
||||
CFLAGS = -O -DAIXV3 -DPTHREADS
|
||||
CXXFLAGS = -O -DAIXV3 -DPTHREADS
|
||||
|
||||
# Misc tools and flags
|
||||
MKLIB_OPTIONS =
|
||||
COPY_LIBS = cp -f -h
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
@@ -19,10 +22,10 @@ GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
GL_LIB_DEPS = -lX11 -lXext -lm
|
||||
GL_LIB_DEPS = -lX11 -lXext -lpthread -lm
|
||||
GLU_LIB_DEPS = -L$(TOP)/lib -l$(GL_LIB) -lm -lC
|
||||
GLUT_LIB_DEPS = -L$(TOP)/lib -l$(GLU_LIB) -l$(GL_LIB) -lXi -lXmu -lX11 -lm
|
||||
GLW_LIB_DEPS = -L$(TOP)/lib -l$(GL_LIB) -lXt -lX11
|
||||
GLW_LIB_DEPS = -L$(TOP)/lib -l$(GL_LIB) -lXm -lXt -lX11
|
||||
OSMESA_LIB_DEPS = -L$(TOP)/lib -l$(GL_LIB)
|
||||
APP_LIB_DEPS = -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm -lC
|
||||
APP_LIB_DEPS = -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lpthread -lm -lC
|
||||
|
||||
|
||||
@@ -8,9 +8,9 @@ CONFIG_NAME = aix-64
|
||||
CC = xlc
|
||||
CXX = xlC
|
||||
|
||||
CFLAGS = -q64 -qmaxmem=16384 -O -DAIXV3
|
||||
CXXFLAGS = -q64 -qmaxmem=16384 -O -DAIXV3
|
||||
MKLIB_OPTIONS = -arch AIX64
|
||||
CFLAGS = -q64 -qmaxmem=16384 -O -DAIXV3 -DPTHREADS
|
||||
CXXFLAGS = -q64 -qmaxmem=16384 -O -DAIXV3 -DPTHREADS
|
||||
LIB_DIR=$(TOP)/lib64
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
@@ -19,10 +19,9 @@ GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
GL_LIB_DEPS = -lX11 -lXext -lm
|
||||
GLU_LIB_DEPS = -L$(TOP)/lib -l$(GL_LIB) -lm -lC
|
||||
GLUT_LIB_DEPS = -L$(TOP)/lib -l$(GLU_LIB) -l$(GL_LIB) -lXi -lXmu -lX11 -lm
|
||||
GLW_LIB_DEPS = -L$(TOP)/lib -l$(GL_LIB) -lXt -lX11
|
||||
OSMESA_LIB_DEPS = -L$(TOP)/lib -l$(GL_LIB)
|
||||
APP_LIB_DEPS = -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm -lC
|
||||
GL_LIB_DEPS = -lX11 -lXext -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm -lC
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lXi -lXmu -lX11 -lm
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lXm -lXt -lX11
|
||||
APP_LIB_DEPS = -L$(TOP)/lib64 -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm -lpthread -lC
|
||||
|
||||
|
||||
25
configs/aix-64-static
Normal file
25
configs/aix-64-static
Normal file
@@ -0,0 +1,25 @@
|
||||
# Configuration for AIX, static libs
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = aix-64-static
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = xlC
|
||||
|
||||
CFLAGS = -q64 -O -DAIXV3 -DPTHREADS
|
||||
CXXFLAGS = -q64 -O -DAIXV3 -DPTHREADS
|
||||
MKLIB_OPTIONS = -static
|
||||
LIB_DIR=$(TOP)/lib64
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
APP_LIB_DEPS = -q64 -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) \
|
||||
-lX11 -lXext -lXmu -lXi -lm -lpthread -lC
|
||||
|
||||
@@ -14,6 +14,6 @@ CXXFLAGS = -O2 -DAIXV3
|
||||
MKLIB_OPTIONS = -arch aix-gcc
|
||||
GL_LIB_DEPS = -lX11 -lXext -lm
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR -l$(GLU_LIB) -l$(GL_LIB) -lXi -lXmu
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lXi -lXmu
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -Wl,-brtl -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm -lX11 -lXext -lXmu -lXi
|
||||
|
||||
|
||||
@@ -8,8 +8,8 @@ CONFIG_NAME = aix-static
|
||||
CC = cc
|
||||
CXX = xlC
|
||||
|
||||
CFLAGS = -O -DAIXV3
|
||||
CXXFLAGS = -O -DAIXV3
|
||||
CFLAGS = -O -DAIXV3 -DPTHREADS
|
||||
CXXFLAGS = -O -DAIXV3 -DPTHREADS
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
# Library names (actual file names)
|
||||
@@ -19,5 +19,7 @@ GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -lX11 -lXext -lXmu -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) \
|
||||
-lX11 -lXext -lXmu -lXi -lm -lpthread -lC
|
||||
|
||||
|
||||
|
||||
@@ -5,13 +5,11 @@ include $(TOP)/configs/default
|
||||
CONFIG_NAME = darwin
|
||||
|
||||
# Compiler and flags
|
||||
CC = c++
|
||||
CXX = c++
|
||||
CC = cc
|
||||
CXX = cc
|
||||
CFLAGS = -I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
|
||||
CXXFLAGS = -I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
|
||||
|
||||
MKLIB_OPTIONS = -cplusplus
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.dylib
|
||||
GLU_LIB_NAME = libGLU.dylib
|
||||
|
||||
@@ -16,9 +16,9 @@ GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread
|
||||
GL_LIB_DEPS =
|
||||
OSMESA_LIB_DEPS =
|
||||
GLU_LIB_DEPS =
|
||||
GLUT_LIB_DEPS =
|
||||
GLW_LIB_DEPS =
|
||||
APP_LIB_DEPS = -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
|
||||
APP_LIB_DEPS = -Wl,-search_paths_first -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lstdc++ -lgcc_s.1 -lm
|
||||
|
||||
26
configs/darwin-static-x86ppc
Normal file
26
configs/darwin-static-x86ppc
Normal file
@@ -0,0 +1,26 @@
|
||||
# Configuration for Darwin / MacOS X, making static libs
|
||||
|
||||
include $(TOP)/configs/darwin
|
||||
|
||||
CONFIG_NAME = darwin-static
|
||||
|
||||
# Compiler and flags
|
||||
CFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
|
||||
-I/usr/X11R6/include -O3 -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
|
||||
CXXFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
|
||||
-I/usr/X11R6/include -O3 -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
|
||||
MKLIB_OPTIONS = -static -archopt "-isysroot /Developer/SDKs/MacOSX10.4u.sdk"
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
GL_LIB_DEPS =
|
||||
OSMESA_LIB_DEPS =
|
||||
GLU_LIB_DEPS =
|
||||
GLUT_LIB_DEPS =
|
||||
GLW_LIB_DEPS =
|
||||
APP_LIB_DEPS = -Wl,-search_paths_first -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lstdc++ -lgcc_s.1 -lm
|
||||
33
configs/darwin-x86ppc
Normal file
33
configs/darwin-x86ppc
Normal file
@@ -0,0 +1,33 @@
|
||||
# Configuration for Darwin / MacOS X, making dynamic libs
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = darwin
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = cc
|
||||
CFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
|
||||
-I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
|
||||
CXXFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
|
||||
-I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
|
||||
|
||||
MKLIB_OPTIONS = -archopt "-isysroot /Developer/SDKs/MacOSX10.4u.sdk"
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.dylib
|
||||
GLU_LIB_NAME = libGLU.dylib
|
||||
GLUT_LIB_NAME = libglut.dylib
|
||||
GLW_LIB_NAME = libGLw.dylib
|
||||
OSMESA_LIB_NAME = libOSMesa.dylib
|
||||
|
||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread
|
||||
OSMESA_LIB_DEPS = -L$(LIB_DIR) -lGL
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -lGL
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -lGL -lGLU -L/usr/X11R6/lib -lX11 -lXmu -lXi -lXext
|
||||
GLW_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXt $(TOP)/lib/GL.dylib
|
||||
APP_LIB_DEPS = -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
|
||||
|
||||
# omit glw lib for now:
|
||||
SRC_DIRS = mesa glu glut/glx
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
|
||||
# This is included by other config files which may override some
|
||||
# of these variables.
|
||||
# Think of this as a base class from which configs are derived.
|
||||
|
||||
|
||||
CONFIG_NAME = default
|
||||
|
||||
@@ -25,6 +27,8 @@ MKLIB_OPTIONS =
|
||||
MKDEP = makedepend
|
||||
MKDEP_OPTIONS = -fdepend
|
||||
MAKE = make
|
||||
INSTALL = install
|
||||
COPY_LIBS = cp -f -d
|
||||
|
||||
# Python and flags (generally only needed by the developers)
|
||||
PYTHON2 = python
|
||||
@@ -54,9 +58,8 @@ ASM_SOURCES =
|
||||
GLW_SOURCES = GLwDrawA.c
|
||||
|
||||
|
||||
# Directories
|
||||
# Directories to build
|
||||
LIB_DIR = $(TOP)/lib
|
||||
INSTALL_PREFIX = /usr/local
|
||||
SRC_DIRS = mesa glu glut/glx glw
|
||||
GLU_DIRS = sgi
|
||||
DRIVER_DIRS = x11 osmesa
|
||||
@@ -72,3 +75,9 @@ GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) $(EXTRA_LIB_PATH) -lX11 -lXmu -lXt -lXi -lm
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) $(EXTRA_LIB_PATH) -lXt -lX11
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm
|
||||
|
||||
|
||||
|
||||
# Installation directories (for make install)
|
||||
INSTALL_DIR = /usr/local
|
||||
DRI_DRIVER_INSTALL_DIR = /usr/X11R6/lib/modules/dri
|
||||
|
||||
@@ -5,13 +5,25 @@ include $(TOP)/configs/default
|
||||
CONFIG_NAME = FreeBSD
|
||||
|
||||
# Compiler and flags
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
CC = cc
|
||||
CXX = c++
|
||||
MAKE = gmake
|
||||
|
||||
CFLAGS = -O2 -fPIC -pedantic -I/usr/X11R6/include -DUSE_XSHM -DHZ=100 \
|
||||
$(ASM_FLAGS)
|
||||
CXXFLAGS = -O2 -fPIC -pedantic
|
||||
# cp -d not supported on FreeBSD (see bug 4435)
|
||||
COPY_LIBS = cp -f
|
||||
|
||||
OPT_FLAGS = -O2
|
||||
PIC_FLAGS = -fPIC
|
||||
|
||||
DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_BSD_SOURCE -DUSE_XSHM -DHZ=100
|
||||
|
||||
X11_INCLUDES = -I/usr/X11R6/include
|
||||
|
||||
CFLAGS += $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(DEFINES) $(X11_INCLUDES) -ffast-math -pedantic
|
||||
|
||||
CXXFLAGS += $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(DEFINES) $(X11_INCLUDES)
|
||||
|
||||
GLUT_CFLAGS = -fexceptions
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -L/usr/X11R6/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lXext -lXmu -lXi -lX11 -lm
|
||||
EXTRA_LIB_PATH = -L/usr/X11R6/lib
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) $(EXTRA_LIB_PATH) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lXext -lXmu -lXi -lX11 -lm
|
||||
|
||||
@@ -15,14 +15,16 @@ EXPAT_INCLUDES = -I/usr/local/include
|
||||
X11_INCLUDES = -I/usr/X11R6/include
|
||||
DEFINES = -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER \
|
||||
-DGLX_DIRECT_RENDERING -DHAVE_ALIAS
|
||||
CFLAGS = $(DEFINES) -Wmissing-prototypes -g -std=c99 -Wundef -fPIC \
|
||||
-ffast-math $(ASM_FLAGS) $(X11_INCLUDES)
|
||||
|
||||
CFLAGS = -Wmissing-prototypes -g -std=c99 -Wundef -fPIC -ffast-math \
|
||||
$(ASM_FLAGS) $(X11_INCLUDES) $(DEFINES)
|
||||
|
||||
CXXFLAGS = $(DEFINES) -Wall -g -ansi -pedantic -fPIC
|
||||
|
||||
ASM_SOURCES =
|
||||
|
||||
# Library/program dependencies
|
||||
LIBDRM_LIB = `pkg-config --libs libdrm` -ldrm
|
||||
LIBDRM_LIB = `pkg-config --libs libdrm`
|
||||
DRI_LIB_DEPS = -L/usr/local/lib -lm -lpthread -lexpat $(LIBDRM_LIB)
|
||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lXxf86vm -lm -lpthread $(LIBDRM_LIB)
|
||||
|
||||
@@ -40,6 +42,6 @@ DRM_SOURCE_PATH=$(TOP)/../drm
|
||||
|
||||
# ffb and gamma are missing because they have not been converted to use the new
|
||||
# interface.
|
||||
DRI_DIRS = i810 i830 i915 mach64 mga r128 r200 r300 radeon tdfx \
|
||||
DRI_DIRS = i810 i915 mach64 mga r128 r200 r300 radeon tdfx \
|
||||
unichrome savage sis
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ CXX = aCC
|
||||
|
||||
CFLAGS = +z -Ae +O2 +Onolimit +Oaggressive -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
|
||||
CXXFLAGS = +z -Aa +O2 +Onolimit +Oaggressive -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include
|
||||
CXXFLAGS = +z -Aa +O2 +Onolimit +Oaggressive -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DPTHREADS
|
||||
|
||||
MKLIB_OPTIONS =
|
||||
|
||||
@@ -23,4 +23,8 @@ GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
# Library/program dependencies
|
||||
APP_LIB_DEPS = -L/usr/lib/X11R6 -L/usr/contrib/X11R6/lib -lXext -lXmu -lXi -lX11 -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB)
|
||||
GL_LIB_DEPS = -L/usr/lib/X11R6/ -L/usr/contrib/X11R6/lib/ -lXext -lXt -lXi -lX11 -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm -lCsup -lcl
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) $(GL_LIB_DEPS)
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) $(GL_LIB_DEPS)
|
||||
|
||||
@@ -8,9 +8,9 @@ CONFIG_NAME = hpux11-32-static
|
||||
CC = cc
|
||||
CXX = aCC
|
||||
|
||||
CFLAGS = +O3 +DA2.0 -Aa -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
CFLAGS = +O3 +DA2.0 -Ae -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
|
||||
CXXFLAGS = +O3 +DA2.0 -Aa -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include
|
||||
CXXFLAGS = +O3 +DA2.0 -Aa -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DPTHREADS
|
||||
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
@@ -23,4 +23,5 @@ GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
# Library/program dependencies
|
||||
APP_LIB_DEPS = -L/usr/lib/X11R6 -L/usr/contrib/X11R6/lib -lXext -lXmu -lXi -lX11 -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/lib/X11R6/ -L/usr/contrib/X11R6/lib/ -lXext -lXmu -lXt -lXi -lX11 -lm -lpthread -lCsup -lcl
|
||||
|
||||
|
||||
@@ -10,11 +10,11 @@ CXX = aCC
|
||||
|
||||
CFLAGS = +z -Ae +DD64 +O2 +Onolimit +Oaggressive -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
|
||||
CXXFLAGS = +z -Aa +DD64 +O2 +Onolimit +Oaggressive -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include
|
||||
CXXFLAGS = +z -Aa +DD64 +O2 +Onolimit +Oaggressive -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DPTHREADS
|
||||
|
||||
MKLIB_OPTIONS =
|
||||
|
||||
LIBDIR = $(TOP)/lib64
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
@@ -24,4 +24,8 @@ GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
# Library/program dependencies
|
||||
APP_LIB_DEPS = -L/usr/lib/X11R6 -L/usr/contrib/X11R6/lib -lXext -lXmu -lXi -lX11 -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB)
|
||||
GL_LIB_DEPS = -L/usr/lib/X11R6/pa20_64 -L/usr/contrib/X11R6/lib/pa20_64 -lXext -lXmu -lXt -lXi -lX11 -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm -lCsup -lcl
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) $(GL_LIB_DEPS)
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) $(GL_LIB_DEPS)
|
||||
|
||||
@@ -8,13 +8,13 @@ CONFIG_NAME = hpux11-64-static
|
||||
CC = cc
|
||||
CXX = aCC
|
||||
|
||||
CFLAGS = +O3 +DA2.0W -Aa -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
CFLAGS = +O3 +DA2.0W -Ae -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
|
||||
CXXFLAGS = +O3 +DA2.0W -Aa -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include
|
||||
CXXFLAGS = +O3 +DA2.0W -Aa -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DPTHREADS
|
||||
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
LIBDIR = $(TOP)/lib64
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
@@ -24,4 +24,4 @@ GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
# Library/program dependencies
|
||||
APP_LIB_DEPS = -L/usr/lib/X11R6 -L/usr/contrib/X11R6/lib -lXext -lXmu -lXi -lX11 -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/lib/X11R6/pa20_64 -L/usr/contrib/X11R6/lib/pa20_64 -lXext -lXmu -lXt -lXi -lX11 -lm -lpthread -lCsup -lcl
|
||||
|
||||
30
configs/hpux11-ia64
Normal file
30
configs/hpux11-ia64
Normal file
@@ -0,0 +1,30 @@
|
||||
# Configuration for HPUX IA64 v11, 64-bit
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = hpux11-ia64
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = aCC
|
||||
|
||||
CFLAGS = +z -Ae +DD64 +O3 +DSmckinley -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
|
||||
CXXFLAGS = +z -Aa +DD64 +O3 +DSmckinley -D_HPUX_SOURCE -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DPTHREADS
|
||||
|
||||
MKLIB_OPTIONS =
|
||||
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.so
|
||||
GLU_LIB_NAME = libGLU.so
|
||||
GLUT_LIB_NAME = libglut.so
|
||||
GLW_LIB_NAME = libGLw.so
|
||||
OSMESA_LIB_NAME = libOSMesa.so
|
||||
|
||||
# Library/program dependencies
|
||||
GL_LIB_DEPS = -L/usr/lib/X11R6/ -L/usr/contrib/X11R6/lib/ -lXext -lXmu -lXt -lXi -lX11 -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm -lCsup -lcl
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) $(GL_LIB_DEPS)
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) $(GL_LIB_DEPS)
|
||||
27
configs/hpux11-ia64-static
Normal file
27
configs/hpux11-ia64-static
Normal file
@@ -0,0 +1,27 @@
|
||||
# Configuration for HPUX v11, 64-bit, static libs
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = hpux11-ia64-static
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = aCC
|
||||
|
||||
CFLAGS = +O3 +DD64 -Aa -D_HPUX_SOURCE +DSmckinley -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DUSE_XSHM -DPTHREADS
|
||||
|
||||
CXXFLAGS = +O3 +DD64 -Aa -D_HPUX_SOURCE +DSmckinley -I/usr/include/X11R6 -I/usr/contrib/X11R6/include -DPTHREADS
|
||||
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
# Library/program dependencies
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/lib/X11R6 -L/usr/contrib/X11R6/lib -lXext -lXmu -lXi -lXt -lX11 -lpthread -lm -lCsup -lcl
|
||||
@@ -7,12 +7,11 @@ CONFIG_NAME = irix6-64
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -64 -O3 -ansi -woff 1068,1069,1174,1185,1209,1474,1552 -DUSE_XSHM
|
||||
CXXFLAGS = -64 -O3 -ansi -woff 1174
|
||||
MKLIB_OPTIONS = -archopt 64
|
||||
CFLAGS = -64 -O3 -ansi -woff 1068,1069,1174,1185,1209,1474,1552 -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -64 -O3 -ansi -woff 1174 -DPTHREADS
|
||||
|
||||
GLW_SOURCES = GLwDrawA.c GLwMDrawA.c
|
||||
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -64 -rpath $(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXmu -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -64 -rpath $(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXmu -lXi -lpthread -lm
|
||||
|
||||
@@ -7,15 +7,15 @@ CONFIG_NAME = irix6-64-static
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -64 -O3 -ansi -woff 1068,1069,1174,1185,1209,1474,1552 -DUSE_XSHM
|
||||
CXXFLAGS = -64 -O3 -ansi -woff 1174
|
||||
MKLIB_OPTIONS = -archopt 64 -static
|
||||
CFLAGS = -64 -O3 -ansi -woff 1068,1069,1174,1185,1209,1474,1552 -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -64 -O3 -ansi -woff 1174 -DPTHREADS
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
GLW_SOURCES = GLwDrawA.c GLwMDrawA.c
|
||||
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -64 -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -64 -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lpthread -lm -lC
|
||||
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
@@ -23,3 +23,4 @@ GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
|
||||
|
||||
@@ -7,12 +7,11 @@ CONFIG_NAME = irix6-n32
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -n32 -mips3 -O3 -ansi -woff 1174,1521,1552 -DUSE_XSHM
|
||||
CXXFLAGS = -n32 -mips3 -O3 -ansi -woff 1174,1552
|
||||
MKLIB_OPTIONS = -archopt n32
|
||||
CFLAGS = -n32 -mips3 -O3 -ansi -woff 1174,1521,1552 -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -n32 -mips3 -O3 -ansi -woff 1174,1552 -DPTHREADS
|
||||
|
||||
GLW_SOURCES = GLwDrawA.c GLwMDrawA.c
|
||||
|
||||
LIB_DIR = $(TOP)/lib32
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -n32 -rpath $(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXmu -lXi -lfpe -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -n32 -rpath $(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXmu -lXi -lfpe -lpthread -lm
|
||||
|
||||
@@ -7,15 +7,15 @@ CONFIG_NAME = irix6-n32-static
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -n32 -mips2 -O2 -ansi -woff 1521,1552 -DUSE_XSHM
|
||||
CXXFLAGS = -n32 -mips2 -O2 -ansi -woff 3262,3666
|
||||
MKLIB_OPTIONS = -archopt n32 -static
|
||||
CFLAGS = -n32 -mips2 -O2 -ansi -woff 1521,1552 -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -n32 -mips2 -O2 -ansi -woff 3262,3666 -DPTHREADS
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
GLW_SOURCES = GLwDrawA.c GLwMDrawA.c
|
||||
|
||||
LIB_DIR = $(TOP)/lib32
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -n32 -glut -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -n32 -glut -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lpthread -lm -lC
|
||||
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
|
||||
@@ -9,7 +9,6 @@ CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -32 -mips2 -O2 -ansi -woff 1521,1552 -DUSE_XSHM
|
||||
CXXFLAGS = -32 -mips2 -O2 -ansi -woff 3262,3666
|
||||
MKLIB_OPTIONS = -archopt o32
|
||||
|
||||
GLW_SOURCES = GLwDrawA.c GLwMDrawA.c
|
||||
|
||||
|
||||
@@ -9,13 +9,13 @@ CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -32 -mips2 -O2 -ansi -woff 1521,1552 -DUSE_XSHM
|
||||
CXXFLAGS = -32 -mips2 -O2 -ansi -woff 3262,3666
|
||||
MKLIB_OPTIONS = -archopt o32 -static
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
GLW_SOURCES = GLwDrawA.c GLwMDrawA.c
|
||||
|
||||
LIB_DIR = $(TOP)/lib32
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -32 -glut -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -32 -glut -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm -lC
|
||||
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
|
||||
@@ -4,5 +4,5 @@ include $(TOP)/configs/linux
|
||||
|
||||
CONFIG_NAME = linux-debug
|
||||
|
||||
OPT_FLAGS = -g
|
||||
OPT_FLAGS = -g -ansi -pedantic
|
||||
DEFINES += -DDEBUG -DDEBUG_MATH
|
||||
|
||||
@@ -22,9 +22,13 @@ ifeq ($(HAVE_X86), yes)
|
||||
endif
|
||||
|
||||
# Directories
|
||||
SRC_DIRS = mesa glu
|
||||
SRC_DIRS = mesa glu glut/directfb
|
||||
GLU_DIRS = sgi
|
||||
DRIVER_DIRS = directfb
|
||||
PROGRAM_DIRS = # disabled
|
||||
PROGRAM_DIRS = demos directfb
|
||||
|
||||
# Library/program dependencies
|
||||
GL_LIB_DEPS = -lm -lpthread
|
||||
GL_LIB_DEPS = -lm -lpthread
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -l$(GLU_LIB)
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -l$(GLU_LIB) -l$(GLUT_LIB)
|
||||
|
||||
|
||||
@@ -9,11 +9,11 @@ CONFIG_NAME = linux-dri
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
|
||||
MKDEP = /usr/X11R6/bin/makedepend
|
||||
#MKDEP = /usr/X11R6/bin/makedepend
|
||||
#MKDEP = gcc -M
|
||||
#MKDEP_OPTIONS = -MF depend
|
||||
|
||||
OPT_FLAGS = -g
|
||||
OPT_FLAGS = -O -g
|
||||
PIC_FLAGS = -fPIC
|
||||
|
||||
# Add '-DGLX_USE_TLS' to ARCH_FLAGS to enable TLS support.
|
||||
@@ -26,8 +26,8 @@ DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
|
||||
|
||||
X11_INCLUDES = -I/usr/X11R6/include
|
||||
|
||||
CFLAGS = -Wall -Wmissing-prototypes $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
|
||||
$(DEFINES) $(ASM_FLAGS) -std=c99 -ffast-math
|
||||
CFLAGS = -Wall -Wmissing-prototypes -std=c99 -ffast-math \
|
||||
$(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) $(ASM_FLAGS)
|
||||
|
||||
CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
|
||||
|
||||
@@ -37,7 +37,7 @@ ASM_SOURCES =
|
||||
# Library/program dependencies
|
||||
EXTRA_LIB_PATH=-L/usr/X11R6/lib
|
||||
|
||||
LIBDRM_LIB = `pkg-config --libs libdrm` -ldrm
|
||||
LIBDRM_LIB = `pkg-config --libs libdrm`
|
||||
DRI_LIB_DEPS = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
|
||||
GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lm -lpthread -ldl \
|
||||
$(LIBDRM_LIB)
|
||||
@@ -63,5 +63,5 @@ WINDOW_SYSTEM=dri
|
||||
|
||||
# gamma are missing because they have not been converted to use the new
|
||||
# interface.
|
||||
DRI_DIRS = i810 i830 i915 mach64 mga r128 r200 r300 radeon s3v \
|
||||
DRI_DIRS = i810 i915 mach64 mga r128 r200 r300 radeon s3v \
|
||||
savage sis tdfx trident unichrome ffb
|
||||
|
||||
@@ -17,7 +17,7 @@ LIB_DIR = $(TOP)/lib64
|
||||
EXTRA_LIB_PATH=-L/usr/X11R6/lib64
|
||||
|
||||
# ffb, gamma, and sis are missing because they have not be converted to use
|
||||
# the new interface. i810 and i830 are missing because there is no x86-64
|
||||
# the new interface. i810 are missing because there is no x86-64
|
||||
# system where they could *ever* be used.
|
||||
#
|
||||
DRI_DIRS = i915 mach64 mga r128 r200 radeon tdfx unichrome savage r300
|
||||
|
||||
67
configs/linux-dri-xcb
Normal file
67
configs/linux-dri-xcb
Normal file
@@ -0,0 +1,67 @@
|
||||
# -*-makefile-*-
|
||||
# Configuration for linux-dri: Linux DRI hardware drivers for XFree86 & others
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = linux-dri-xcb
|
||||
|
||||
# Compiler and flags
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
|
||||
#MKDEP = /usr/X11R6/bin/makedepend
|
||||
#MKDEP = gcc -M
|
||||
#MKDEP_OPTIONS = -MF depend
|
||||
|
||||
OPT_FLAGS = -g
|
||||
PIC_FLAGS = -fPIC
|
||||
|
||||
# Add '-DGLX_USE_TLS' to ARCH_FLAGS to enable TLS support.
|
||||
ARCH_FLAGS ?=
|
||||
|
||||
DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
|
||||
-D_BSD_SOURCE -D_GNU_SOURCE \
|
||||
-DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER \
|
||||
-DGLX_DIRECT_RENDERING -DHAVE_ALIAS -DUSE_XCB
|
||||
|
||||
X11_INCLUDES = `pkg-config --cflags-only-I x11` `pkg-config --cflags-only-I xcb` `pkg-config --cflags-only-I xcb-glx`
|
||||
|
||||
CFLAGS = -Wall -Wmissing-prototypes $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
|
||||
$(DEFINES) $(ASM_FLAGS) -std=c99 -ffast-math
|
||||
|
||||
CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
|
||||
|
||||
|
||||
ASM_SOURCES =
|
||||
|
||||
# Library/program dependencies
|
||||
EXTRA_LIB_PATH=`pkg-config --libs-only-L x11`
|
||||
|
||||
LIBDRM_LIB = `pkg-config --libs libdrm`
|
||||
DRI_LIB_DEPS = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
|
||||
GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lm -lpthread -ldl \
|
||||
$(LIBDRM_LIB) `pkg-config --libs xcb` `pkg-config --libs xcb-glx`
|
||||
|
||||
|
||||
# This is now 0 by default since it seems to confuse the hell out of people
|
||||
# and generate a lot of extra noise on bugzilla. If you need to build with
|
||||
# EGL, do 'make linux-dri USING_EGL=1'
|
||||
|
||||
USING_EGL=0
|
||||
|
||||
# Directories
|
||||
ifeq ($(USING_EGL), 1)
|
||||
SRC_DIRS = egl glx/x11 mesa glu glut/glx glw
|
||||
PROGRAM_DIRS = egl
|
||||
else
|
||||
SRC_DIRS = glx/x11 mesa glu glut/glx glw
|
||||
PROGRAM_DIRS =
|
||||
endif
|
||||
|
||||
DRIVER_DIRS = dri
|
||||
WINDOW_SYSTEM=dri
|
||||
|
||||
# gamma are missing because they have not been converted to use the new
|
||||
# interface.
|
||||
DRI_DIRS = i810 i915 mach64 mga r128 r200 r300 radeon s3v \
|
||||
savage sis tdfx trident unichrome ffb
|
||||
21
configs/linux-ia64-icc
Normal file
21
configs/linux-ia64-icc
Normal file
@@ -0,0 +1,21 @@
|
||||
# Configuration for Linux with Intel C compiler
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = linux-icc
|
||||
|
||||
# Compiler and flags
|
||||
CC = icc
|
||||
CXX = icpc
|
||||
CFLAGS = -O3 -ansi -KPIC -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DPTHREADS -I/usr/X11R6/include
|
||||
CXXFLAGS = -O3 -ansi -KPIC -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DPTHREADS -I/usr/X11R6/include
|
||||
GLUT_CFLAGS = -fexceptions
|
||||
MKLIB_OPTIONS = -arch icc-istatic
|
||||
|
||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB)
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) $(GL_LIB_DEPS)
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB)
|
||||
|
||||
|
||||
27
configs/linux-ia64-icc-static
Normal file
27
configs/linux-ia64-icc-static
Normal file
@@ -0,0 +1,27 @@
|
||||
# Configuration for Linux with Intel C compiler, static libs
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = linux-icc-static
|
||||
|
||||
# Compiler and flags
|
||||
CC = icc
|
||||
CXX = icpc
|
||||
CFLAGS = -O3 -ansi -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DPTHREADS -I/usr/X11R6/include
|
||||
CXXFLAGS = -O3 -ansi -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DPTHREADS -I/usr/X11R6/include
|
||||
GLUT_CFLAGS = -fexceptions
|
||||
MKLIB_OPTIONS = -static -arch icc-istatic
|
||||
|
||||
# Library names (actual file names)
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
GL_LIB_DEPS =
|
||||
GLU_LIB_DEPS =
|
||||
GLUT_LIB_DEPS =
|
||||
GLW_LIB_DEPS =
|
||||
APP_LIB_DEPS = -i-static -cxxlib-icc -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lpthread -lm -lcxa -lunwind
|
||||
|
||||
@@ -6,9 +6,9 @@ CONFIG_NAME = linux-icc-static
|
||||
|
||||
# Compiler and flags
|
||||
CC = icc
|
||||
CXX = g++
|
||||
CXX = icpc
|
||||
CFLAGS = -O3 -tpp6 -axK -D_GCC_LIMITS_H_ -D__GNUC__ -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM -DPTHREADS -I/usr/X11R6/include
|
||||
CXXFLAGS = -O3
|
||||
CXXFLAGS = -O3 -tpp6 -axK -DPTHREADS
|
||||
GLUT_CFLAGS = -fexceptions
|
||||
MKLIB_OPTIONS = -static -arch icc
|
||||
|
||||
@@ -19,12 +19,9 @@ GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
|
||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
|
||||
MKLIB_OPTIONS = -arch icc
|
||||
GL_LIB_DEPS =
|
||||
GLUT_LIB_DEPS =
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm -lpthread -lcxa -lunwind
|
||||
|
||||
ASM_SOURCES = $(X86_SOURCES)
|
||||
ASM_API = $(X86_API)
|
||||
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ CONFIG_NAME = linux-dri
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
|
||||
MKDEP = /usr/X11R6/bin/makedepend
|
||||
#MKDEP = /usr/X11R6/bin/makedepend
|
||||
#MKDEP = gcc -M
|
||||
#MKDEP_OPTIONS = -MF depend
|
||||
|
||||
|
||||
25
configs/linux-osmesa
Normal file
25
configs/linux-osmesa
Normal file
@@ -0,0 +1,25 @@
|
||||
# Configuration for building only libOSMesa on Linux, no Xlib driver
|
||||
# This doesn't really have any Linux dependencies, so it should be usable
|
||||
# on other (gcc-based) systems.
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = linux-osmesa
|
||||
|
||||
# Compiler and flags
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
CFLAGS = -O3 -ansi -pedantic -fPIC -ffast-math -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DPTHREADS
|
||||
CXXFLAGS = -O3 -ansi -pedantic -fPIC -ffast-math -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE
|
||||
|
||||
|
||||
# Directories
|
||||
SRC_DIRS = mesa glu
|
||||
DRIVER_DIRS = osmesa
|
||||
PROGRAM_DIRS = osdemos
|
||||
|
||||
|
||||
# Dependencies
|
||||
OSMESA_LIB_DEPS = -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(OSMESA_LIB)
|
||||
APP_LIB_DEPS = -lOSMesa -lGLU
|
||||
@@ -24,4 +24,5 @@ PROGRAM_DIRS =
|
||||
|
||||
# Dependencies
|
||||
OSMESA_LIB_DEPS = -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(OSMESA_LIB)
|
||||
APP_LIB_DEPS = -lOSMesa16
|
||||
|
||||
@@ -24,4 +24,5 @@ PROGRAM_DIRS =
|
||||
|
||||
# Dependencies
|
||||
OSMESA_LIB_DEPS = -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(OSMESA_LIB)
|
||||
APP_LIB_DEPS = -lOSMesa32
|
||||
|
||||
@@ -40,4 +40,4 @@ DRIVER_DIRS = dri
|
||||
PROGRAM_DIRS = miniglx
|
||||
|
||||
#DRI_DIRS = ffb gamma sis savage
|
||||
DRI_DIRS = i810 i830 i915 mach64 mga r128 r200 radeon tdfx unichrome fb
|
||||
DRI_DIRS = i810 i915 mach64 mga r128 r200 radeon tdfx unichrome fb
|
||||
|
||||
@@ -19,3 +19,5 @@ OSMESA_LIB_DEPS =
|
||||
GLU_LIB_DEPS =
|
||||
GLUT_LIB_DEPS =
|
||||
GLW_LIB_DEPS =
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) \
|
||||
$(EXTRA_LIB_PATH) -lX11 -lXmu -lXt -lXi -lpthread -lstdc++ -lm
|
||||
|
||||
@@ -19,3 +19,5 @@ OSMESA_LIB_DEPS =
|
||||
GLU_LIB_DEPS =
|
||||
GLUT_LIB_DEPS =
|
||||
GLW_LIB_DEPS =
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) \
|
||||
$(EXTRA_LIB_PATH) -lX11 -lXmu -lXt -lXi -lpthread -lstdc++ -lm
|
||||
|
||||
@@ -1,25 +0,0 @@
|
||||
# Configuration for Linux with x86 optimizations
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = linux-x86-xcb
|
||||
|
||||
# Compiler and flags
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
|
||||
CFLAGS = -Wall -O3 -ansi -pedantic -fPIC -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM -DPTHREADS -DUSE_XCB -I/usr/X11R6/include
|
||||
|
||||
CXXFLAGS = -Wall -O3 -ansi -pedantic -fPIC -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XCB
|
||||
|
||||
GLUT_CFLAGS = -fexceptions
|
||||
|
||||
|
||||
ASM_SOURCES = $(X86_SOURCES)
|
||||
ASM_API = $(X86_API)
|
||||
|
||||
# Library/program dependencies
|
||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread -lXCB
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -L/usr/X11R6/lib -lXt -lX11
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm
|
||||
@@ -7,10 +7,10 @@ CONFIG_NAME = osf1
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = cxx
|
||||
CFLAGS = -O0 -std1 -ieee_with_no_inexact -DUSE_XSHM
|
||||
CXXFLAGS = -O2 -std ansi -ieee
|
||||
CFLAGS = -O0 -std1 -ieee_with_no_inexact -DUSE_XSHM -DPTHREADS -D_REENTRANT
|
||||
CXXFLAGS = -O2 -std ansi -ieee -DPTHREADS -D_REENTRANT
|
||||
|
||||
GL_LIB_DEPS = -lX11 -lXext -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXmu -lXt -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXext -lXmu -lXi -lpthread -lm
|
||||
|
||||
17
configs/osf1-static
Normal file
17
configs/osf1-static
Normal file
@@ -0,0 +1,17 @@
|
||||
# Configuration for OSF/1
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = osf1
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = cxx
|
||||
CFLAGS = -O2 -std1 -ieee_with_no_inexact -DUSE_XSHM -DPTHREADS -D_REENTRANT
|
||||
CXXFLAGS = -O2 -std ansi -ieee -DPTHREADS -D_REENTRANT
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
GL_LIB_DEPS =
|
||||
GLU_LIB_DEPS =
|
||||
GLUT_LIB_DEPS =
|
||||
APP_LIB_DEPS = -noso -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -so_archive -lX11 -lXext -lXmu -lXi -lpthread -lm -lcxx
|
||||
@@ -1,4 +1,4 @@
|
||||
# Configuration for Solaris on x86 with gcc, static libs
|
||||
# Configuration for Solaris on x86 with gcc, dynamic libs
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
@@ -7,18 +7,11 @@ CONFIG_NAME = solaris-x86-gcc
|
||||
# Compiler and flags
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
CFLAGS = -O3 -m486 -fPIC -I/usr/openwin/include -DUSE_XSHM
|
||||
CXXFLAGS = -O3 -m486 -fPIC
|
||||
CFLAGS = -O3 -march=i486 -fPIC -I/usr/openwin/include -DUSE_XSHM
|
||||
CXXFLAGS = -O3 -march=i486 -fPIC
|
||||
GLUT_CFLAGS = -fexceptions
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
GL_LIB_DEPS = -L/usr/openwin/lib -lX11 -lXext -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/openwin/lib -lX11 -lXmu -lXt -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -L/usr/openwin/lib -R/usr/openwin/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm
|
||||
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -L/usr/openwin/lib -R/usr/openwin/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm -lX11 -lXext -lXi -lXmu
|
||||
|
||||
24
configs/solaris-x86-gcc-static
Normal file
24
configs/solaris-x86-gcc-static
Normal file
@@ -0,0 +1,24 @@
|
||||
# Configuration for Solaris on x86 with gcc, static libs
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = solaris-x86-gcc
|
||||
|
||||
# Compiler and flags
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
CFLAGS = -O3 -march=i486 -fPIC -I/usr/openwin/include -DUSE_XSHM
|
||||
CXXFLAGS = -O3 -march=i486 -fPIC
|
||||
GLUT_CFLAGS = -fexceptions
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
GL_LIB_DEPS = -L/usr/openwin/lib -lX11 -lXext -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/openwin/lib -lX11 -lXmu -lXt -lXi -lm
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -L/usr/openwin/lib -R/usr/openwin/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm -lX11 -lXext -lXi -lXmu
|
||||
|
||||
GL_LIB_NAME = libGL.a
|
||||
GLU_LIB_NAME = libGLU.a
|
||||
GLUT_LIB_NAME = libglut.a
|
||||
GLW_LIB_NAME = libGLw.a
|
||||
OSMESA_LIB_NAME = libOSMesa.a
|
||||
11
configs/sunos5-64-gcc
Normal file
11
configs/sunos5-64-gcc
Normal file
@@ -0,0 +1,11 @@
|
||||
# Configuration for 64-bit SunOS 5, with gcc
|
||||
|
||||
include $(TOP)/configs/sunos5-gcc
|
||||
|
||||
CONFIG_NAME = sunos5-64-gcc
|
||||
|
||||
# only set vars that differ from sunos5-gcc config
|
||||
|
||||
OPT_FLAGS = -O3 -m64 -mcpu=ultrasparc -mv8plus -mvis -g -fomit-frame-pointer -pipe
|
||||
|
||||
ARCH_FLAGS = -m64
|
||||
18
configs/sunos5-v8
Normal file
18
configs/sunos5-v8
Normal file
@@ -0,0 +1,18 @@
|
||||
# Configuration for SunOS 5
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = sunos5-v8
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -xarch=v8 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -xarch=v8 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DPTHREADS
|
||||
GLUT_CFLAGS = -DSOLARIS_2_4_BUG
|
||||
|
||||
GL_LIB_DEPS = -L/usr/openwin/lib -L/usr/dt/lib -lX11 -lXext -lXmu -lXi -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm -lCstd -lCrun
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lm
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -L/usr/openwin/lib -lXt -lX11
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -lX11 -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm
|
||||
16
configs/sunos5-v8-static
Normal file
16
configs/sunos5-v8-static
Normal file
@@ -0,0 +1,16 @@
|
||||
# Configuration for SunOS 5
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = sunos5-v8-static
|
||||
|
||||
MKLIB_OPTIONS = -static
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -xarch=v8 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -xarch=v8 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DPTHREADS
|
||||
GLUT_CFLAGS = -DSOLARIS_2_4_BUG
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/openwin/lib -lXt -lX11 -lXext -lXmu -lXi -lpthread -lm -lCstd -lCrun
|
||||
23
configs/sunos5-v9
Normal file
23
configs/sunos5-v9
Normal file
@@ -0,0 +1,23 @@
|
||||
# Configuration for SunOS 5, SPARC V9
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = sunos5-v9
|
||||
|
||||
MKLIB_OPTIONS = -cplusplus
|
||||
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -xarch=v9 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -xarch=v9 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DPTHREADS
|
||||
GLUT_CFLAGS = -DSOLARIS_2_4_BUG
|
||||
|
||||
GL_LIB_DEPS = -L/usr/openwin/lib -L/usr/dt/lib -lX11 -lXext -lXmu -lXi -lm -lpthread
|
||||
GLU_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -lm -lCstd -lCrun
|
||||
GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lm
|
||||
GLW_LIB_DEPS = -L$(LIB_DIR) -l$(GL_LIB) -L/usr/openwin/lib -lXt -lX11
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -lX11 -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm
|
||||
|
||||
18
configs/sunos5-v9-static
Normal file
18
configs/sunos5-v9-static
Normal file
@@ -0,0 +1,18 @@
|
||||
# Configuration for SunOS 5, SPARC V9, static libs
|
||||
|
||||
include $(TOP)/configs/default
|
||||
|
||||
CONFIG_NAME = sunos5-v9-static
|
||||
|
||||
MKLIB_OPTIONS = -static -cplusplus
|
||||
|
||||
LIB_DIR = $(TOP)/lib64
|
||||
|
||||
# Compiler and flags
|
||||
CC = cc
|
||||
CXX = CC
|
||||
CFLAGS = -xarch=v9 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DUSE_XSHM -DPTHREADS
|
||||
CXXFLAGS = -xarch=v9 -KPIC -O -I/usr/openwin/include -I/usr/dt/include -DPTHREADS
|
||||
GLUT_CFLAGS = -DSOLARIS_2_4_BUG
|
||||
|
||||
APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/openwin/lib -lXt -lX11 -lXext -lXmu -lXi -lpthread -lm -lCstd -lCrun
|
||||
194
docs/MESA_shader_debug.spec
Normal file
194
docs/MESA_shader_debug.spec
Normal file
@@ -0,0 +1,194 @@
|
||||
Name
|
||||
|
||||
MESA_shader_debug
|
||||
|
||||
Name Strings
|
||||
|
||||
GL_MESA_shader_debug
|
||||
|
||||
Contact
|
||||
|
||||
Brian Paul (brian.paul 'at' tungstengraphics.com)
|
||||
Michal Krol (mjkrol 'at' gmail.com)
|
||||
|
||||
Status
|
||||
|
||||
XXX - Not complete yet!!!
|
||||
|
||||
Version
|
||||
|
||||
Last Modified Date: May 29, 2006
|
||||
Author Revision: 0.1
|
||||
$Date: 2006/05/30 09:35:36 $ $Revision: 1.1 $
|
||||
|
||||
Number
|
||||
|
||||
TBD
|
||||
|
||||
Dependencies
|
||||
|
||||
OpenGL 1.5 is required.
|
||||
The extension is written against the OpenGL 1.5 specification.
|
||||
ARB_shading_language_100 is required.
|
||||
ARB_shader_objects is required.
|
||||
The extension is written against the OpenGL Shading Language
|
||||
1.10 Specification.
|
||||
|
||||
Overview
|
||||
|
||||
TBD
|
||||
|
||||
IP Status
|
||||
|
||||
None
|
||||
|
||||
Issues
|
||||
|
||||
None
|
||||
|
||||
New Procedures and Functions
|
||||
|
||||
TBD
|
||||
|
||||
New Types
|
||||
|
||||
None
|
||||
|
||||
New Tokens
|
||||
|
||||
TBD
|
||||
|
||||
Additions to Chapter 2 of the OpenGL 1.5 Specification
|
||||
(OpenGL Operation)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 3 of the OpenGL 1.5 Specification (Rasterization)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 4 of the OpenGL 1.5 Specification (Per-Fragment
|
||||
Operations and the Frame Buffer)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 5 of the OpenGL 1.5 Specification
|
||||
(Special Functions)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 6 of the OpenGL 1.5 Specification (State and State
|
||||
Requests)
|
||||
|
||||
None
|
||||
|
||||
Additions to Appendix A of the OpenGL 1.5 Specification (Invariance)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 1 of the OpenGL Shading Language 1.10 Specification
|
||||
(Introduction)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 2 of the OpenGL Shading Language 1.10 Specification
|
||||
(Overview of OpenGL Shading)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 3 of the OpenGL Shading Language 1.10 Specification
|
||||
(Basics)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 4 of the OpenGL Shading Language 1.10 Specification
|
||||
(Variables and Types)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 5 of the OpenGL Shading Language 1.10 Specification
|
||||
(Operators and Expressions)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 6 of the OpenGL Shading Language 1.10 Specification
|
||||
(Statements and Structure)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 7 of the OpenGL Shading Language 1.10 Specification
|
||||
(Built-in Variables)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 8 of the OpenGL Shading Language 1.10 Specification
|
||||
(Built-in Functions)
|
||||
|
||||
Add a new section 8.10 "Debug Functions":
|
||||
|
||||
Debug functions are available to both fragment and vertex shaders.
|
||||
They are used to track the execution of a shader by logging
|
||||
passed-in arguments to the shader's info log. That values can be
|
||||
retrieved and validated by the application after shader execution
|
||||
is complete.
|
||||
|
||||
void printMESA(const float value);
|
||||
void printMESA(const int value);
|
||||
void printMESA(const bool value);
|
||||
void printMESA(const vec2 value);
|
||||
void printMESA(const vec3 value);
|
||||
void printMESA(const vec4 value);
|
||||
void printMESA(const ivec2 value);
|
||||
void printMESA(const ivec3 value);
|
||||
void printMESA(const ivec4 value);
|
||||
void printMESA(const bvec2 value);
|
||||
void printMESA(const bvec3 value);
|
||||
void printMESA(const bvec4 value);
|
||||
void printMESA(const mat2 value);
|
||||
void printMESA(const mat3 value);
|
||||
void printMESA(const mat4 value);
|
||||
void printMESA(const sampler1D value);
|
||||
void printMESA(const sampler2D value);
|
||||
void printMESA(const sampler3D value);
|
||||
void printMESA(const samplerCube value);
|
||||
void printMESA(const sampler1DShadow value);
|
||||
void printMESA(const sampler2DShadow value);
|
||||
|
||||
Additions to Chapter 9 of the OpenGL Shading Language 1.10 Specification
|
||||
(Shading Language Grammar)
|
||||
|
||||
None
|
||||
|
||||
Additions to Chapter 10 of the OpenGL Shading Language 1.10
|
||||
Specification (Issues)
|
||||
|
||||
None
|
||||
|
||||
Additions to the AGL/EGL/GLX/WGL Specifications
|
||||
|
||||
None
|
||||
|
||||
GLX Protocol
|
||||
|
||||
None
|
||||
|
||||
Errors
|
||||
|
||||
TBD
|
||||
|
||||
New State
|
||||
|
||||
TBD
|
||||
|
||||
New Implementation Dependent State
|
||||
|
||||
TBD
|
||||
|
||||
Sample Code
|
||||
|
||||
TBD
|
||||
|
||||
Revision History
|
||||
|
||||
29 May 2006
|
||||
Initial draft. (Michal Krol)
|
||||
@@ -32,7 +32,7 @@ Dependencies
|
||||
|
||||
Overview
|
||||
|
||||
This extension allows an application to deterine what portion of the
|
||||
This extension allows an application to determine what portion of the
|
||||
swap period has elapsed since the last swap operation completed. The
|
||||
"usage" value is a floating point value on the range [0,max] which is
|
||||
calculated as follows:
|
||||
@@ -59,7 +59,7 @@ Overview
|
||||
is taken from the completion of one swap to the issuance of the next.
|
||||
This representation may not be as useful as measuring between
|
||||
completions, as a significant amount of time may pass between the
|
||||
issuance of a swap and the swap actually occuring.
|
||||
issuance of a swap and the swap actually occurring.
|
||||
|
||||
There is also a mechanism to determine whether a frame swap was
|
||||
missed.
|
||||
@@ -110,7 +110,7 @@ Additions to Chapter 6 of the 1.4 GL Specification (State and State Requests)
|
||||
Additions to the GLX 1.3 Specification
|
||||
|
||||
The frame usage is measured as the percentage of the swap period elapsed
|
||||
between two buffer-swap operations being commited. In unextened GLX the
|
||||
between two buffer-swap operations being committed. In unextended GLX the
|
||||
swap period is the vertical refresh time. If SGI_swap_control or
|
||||
MESA_swap_control are supported, the swap period is the vertical refresh
|
||||
time multiplied by the swap interval (or one if the swap interval is set
|
||||
@@ -119,7 +119,7 @@ Additions to the GLX 1.3 Specification
|
||||
If OML_sync_control is supported, the swap period is the vertical
|
||||
refresh time multiplied by the divisor parameter to
|
||||
glXSwapBuffersMscOML. The frame usage in this case is less than 1.0 if
|
||||
the swap is commited before target_msc, and is greater than or equal to
|
||||
the swap is committed before target_msc, and is greater than or equal to
|
||||
1.0 otherwise. The actual usage value is based on the divisor and is
|
||||
never less than 0.0.
|
||||
|
||||
@@ -143,7 +143,7 @@ Additions to the GLX 1.3 Specification
|
||||
|
||||
The current missed frame count and total number of swaps since
|
||||
the last call to glXBeginFrameTrackingMESA can be obtained by
|
||||
callling the following function:
|
||||
calling the following function:
|
||||
|
||||
int glXQueryFrameTrackingMESA(Display *dpy,
|
||||
GLXDrawable drawable,
|
||||
@@ -152,7 +152,7 @@ Additions to the GLX 1.3 Specification
|
||||
float *lastMissedUsage)
|
||||
|
||||
The location pointed to by <swapCount> will be updated with the
|
||||
number of swaps that have been commited. This value may not match the
|
||||
number of swaps that have been committed. This value may not match the
|
||||
number of swaps that have been requested since swaps may be
|
||||
queued by the implementation. This function can be called at any
|
||||
time and does not synchronize to vertical blank.
|
||||
@@ -171,7 +171,7 @@ Additions to the GLX 1.3 Specification
|
||||
application can call glXQueryFrameTrackingMESA for a final swap and
|
||||
missed frame count.
|
||||
|
||||
If these functions are succesful, zero is returned. If the context
|
||||
If these functions are successful, zero is returned. If the context
|
||||
associated with dpy and drawable is not a direct context,
|
||||
GLX_BAD_CONTEXT is returned.
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
Mesa 6.3 DOS/DJGPP Port v1.7
|
||||
Mesa 6.5 DOS/DJGPP Port v1.8
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
||||
@@ -6,17 +6,16 @@
|
||||
Description:
|
||||
~~~~~~~~~~~~
|
||||
|
||||
Well, guess what... this is the DOS port of Mesa 6.3, for DJGPP fans... Whoa!
|
||||
The driver has its origins in ddsample.c, written by Brian Paul and found by me
|
||||
in Mesa 3.4.2.
|
||||
Well, guess what... this is the DOS port of Mesa 6.5, for DJGPP fans... Whoa!
|
||||
The driver uses OSMesa to draw off screen, and then blits the buffer. This is
|
||||
not terribly efficient, and has some drawbacks, but saves maintenance costs.
|
||||
|
||||
|
||||
|
||||
Legal:
|
||||
~~~~~~
|
||||
|
||||
Mesa copyright applies, provided this package is used within Mesa. For anything
|
||||
else, see GPL.
|
||||
Mesa copyright applies.
|
||||
|
||||
|
||||
|
||||
@@ -32,9 +31,6 @@ Available options:
|
||||
Environment variables:
|
||||
CPU optimize for the given processor.
|
||||
default = pentium
|
||||
GLU=[mesa|sgi] specify GLU directory; can be `sgi' (requires GNU/C++)
|
||||
or `mesa'.
|
||||
default = mesa
|
||||
GLIDE path to Glide3 SDK; used with FX.
|
||||
default = $(TOP)/glide3
|
||||
FX=1 build for 3dfx Glide3. Note that this disables
|
||||
@@ -56,11 +52,9 @@ Available options:
|
||||
|
||||
|
||||
Tested on:
|
||||
CPU: AMD Athlon XP 1800+
|
||||
Mainboard: GA-7VTXE w/ 512 MB DDRAM
|
||||
Video card: Voodoo5 6000 AGP w/ 128 MB SDRAM
|
||||
DJGPP: djdev 2.04 + gcc v3.4.3 + make v3.80
|
||||
OS: DOS and Win98SE
|
||||
Video card: Radeon 9500
|
||||
DJGPP: djdev 2.04 + gcc v4.1.0 + make v3.80
|
||||
OS: DOS, Win98SE, WinXP (using Videoport driver)
|
||||
|
||||
|
||||
|
||||
@@ -98,7 +92,7 @@ FAQ:
|
||||
Q) DMesa is so SLOOOW! The Win32 OpenGL performs so much better...
|
||||
A) Is that a question? If you have a 3dfx Voodoo (any model), you're
|
||||
lucky (check http://sourceforge.net/projects/glide for the DJGPP port).
|
||||
If you haven't, sorry; everything is done in software. Suggestions?
|
||||
If you haven't, sorry; everything is done in software.
|
||||
|
||||
Q) I tried to set refresh rate w/ DMesa, but without success.
|
||||
A) Refresh rate control works only for VESA 3.0 and the 3dfx driver (in
|
||||
@@ -107,7 +101,8 @@ FAQ:
|
||||
|
||||
Q) I made a simple application and it does nothing. It exits right away. Not
|
||||
even a blank screen.
|
||||
A) Pure software drivers (VESA/VGA/NUL) support only double-buffered modes.
|
||||
A) Software drivers (VESA/VGA/NUL) must to be constructed as single-buffered
|
||||
visuals. However, DMesaSwapBuffers must be called to get any output.
|
||||
A) Another weird "feature" is that buffer width must be multiple of 8 (I'm a
|
||||
lazy programmer and I found that the easiest way to keep buffer handling
|
||||
at peak performance ;-).
|
||||
@@ -265,6 +260,11 @@ v1.7 (???-2005)
|
||||
* no more GLX sources in DOS GLUT
|
||||
* made GLUT timer callbacks less accurate but safer
|
||||
|
||||
v1.8 (apr-2006)
|
||||
* killed lots of code, the driver is now a front-end to OSMesa
|
||||
* fixed problem with WinNT (http://www.volny.cz/martin.sulak/)
|
||||
- removed 3dfx Glide3 support (temporarily?)
|
||||
|
||||
|
||||
|
||||
Contact:
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
File: docs/README.WIN32
|
||||
|
||||
Last updated: Jul 01, 2005 - Karl Schultz - kschultz@users.sourceforge.net
|
||||
Last updated: Mar 31, 2006 - Karl Schultz - kschultz@users.sourceforge.net
|
||||
|
||||
Quick Start
|
||||
----- -----
|
||||
|
||||
Unzip both ZIP files (MesaLib and MesaDemos) into the same directory.
|
||||
The libs and demos build separately, so if you do not care about the
|
||||
demos, you do not have to unzip that zip file. But if you do, it does
|
||||
need to be unzipped into the same directory as the lib zip file
|
||||
because the demos depend on the libs.
|
||||
Unzip the MesaLib, MesaGLUT, and MesaDemos ZIP files into the same
|
||||
directory. The libs and demos build separately, so if you do not care
|
||||
about the demos or GLUT, you only need to unzip MesaLib. If you unzip
|
||||
more than one ZIP file, they all need to be unzipped into the same
|
||||
directory. Don't worry, you will not overwrite anything.
|
||||
|
||||
The Windows build system uses Microsoft Visual Studio. Project files
|
||||
for a specific version of Visual Studio are in their own directory in
|
||||
@@ -22,6 +22,10 @@ of Version 8 and it runs on 64-bit Windows. If you want to try this,
|
||||
start by importing the VC7 files and create the 64-bit targets in the
|
||||
configuration manager.
|
||||
|
||||
It is likely that the new and free Visual Studio Express can be used
|
||||
to build Mesa, but it hasn't been tried yet. Start with the VC7
|
||||
project files.
|
||||
|
||||
The project files to build the core Mesa library, Windows Mesa
|
||||
drivers, OSMesa, and GLU are in the mesa directory. The project files
|
||||
to build GLUT and some demo programs are in the progs directory.
|
||||
@@ -33,10 +37,11 @@ from the projects using Visual Studio.
|
||||
Windows Drivers
|
||||
------- -------
|
||||
|
||||
At this time, only the GDI driver is known to work, as it has been
|
||||
ported and rewritten to the latest Mesa DD interfaces. Source code
|
||||
also exists in the tree for other drivers in src/mesa/drivers/windows,
|
||||
but the status of this code is unknown.
|
||||
At this time, only the GDI driver is known to work. Most of the demos
|
||||
in progs/demos should work with this driver.
|
||||
|
||||
Source code also exists in the tree for other drivers in
|
||||
src/mesa/drivers/windows, but the status of this code is unknown.
|
||||
|
||||
The GDI driver operates basically by writing pixel spans into a DIB
|
||||
section and then blitting the DIB to the window. The driver was
|
||||
@@ -86,6 +91,14 @@ simply run the demo executables from the demo directory.
|
||||
If you want to run the demos from the Visual Studio, you may have to
|
||||
change the startup directory and explicitly state where the executables are.
|
||||
|
||||
You may also build all the demo programs by using a makefile. Go to
|
||||
the progs/demos directory and make sure you have executed VCVARS32.BAT
|
||||
or whatever setup script is appropriate for your compiler. Then,
|
||||
|
||||
nmake -f Makefile.win
|
||||
|
||||
should build all the demos.
|
||||
|
||||
|
||||
Build System Notes
|
||||
----- ------ -----
|
||||
@@ -98,6 +111,9 @@ language files, without a lot of unnatural tweaking. So, the VC6
|
||||
build process uses custom build steps to compile these files in the
|
||||
GLU library.
|
||||
|
||||
Two additional configurations are provided, Debug x86 and Release x86
|
||||
that activate the shader code compilation by defining SLANG_86. It is
|
||||
unknown if and how this works.
|
||||
|
||||
VC7
|
||||
---
|
||||
|
||||
314
docs/README.X11
314
docs/README.X11
@@ -1,314 +0,0 @@
|
||||
|
||||
Mesa Unix/X11 Information
|
||||
|
||||
|
||||
|
||||
Installation
|
||||
============
|
||||
|
||||
There are two ways to compile Mesa on Unix/X11 systems:
|
||||
|
||||
1. The old way:
|
||||
First type 'make' alone to see the list of system
|
||||
configurations currently supported. If you see your configuration on the
|
||||
list, type 'make <config>'. Most popular Unix/X workstations are currently
|
||||
supported.
|
||||
|
||||
If your system configuration is not listed by 'make', you'll have to modify
|
||||
the top-level Makefile and Make-config files. There are instructions in
|
||||
each file.
|
||||
|
||||
When finished, the Mesa libraries will be in the Mesa-x.y/lib/ directory.
|
||||
|
||||
|
||||
2. The new way:
|
||||
Type './configure' and then 'make'. This uses GNU autoconfig.
|
||||
Run 'make check' to build the demos.
|
||||
See docs/INSTALL for more details.
|
||||
When finished, the Mesa libraries will be in the Mesa-x.y/src/.libs/,
|
||||
Mesa-x.y/si-glu/.libs, etc directories.
|
||||
|
||||
|
||||
Notes on assembly language optimizations:
|
||||
|
||||
When using the old-style Makefiles, you can specify a configuration
|
||||
that uses X86 assembly language optimizations (linux-3dnow for example).
|
||||
|
||||
The detection of MMX, 3DNow!, PIII/SSE, etc capability is done at
|
||||
runtime. That means you can compile Mesa for 3DNow! optimizations
|
||||
even if you don't have an AMD CPU.
|
||||
|
||||
However, your Linux binutils and assembler must understand the
|
||||
special instructions in order to compile them. If you have
|
||||
compilation problems, try upgrading your binutils.
|
||||
|
||||
|
||||
Header and library files:
|
||||
After you've compiled Mesa and tried the demos I recommend the following
|
||||
procedure for "installing" Mesa.
|
||||
|
||||
Copy the Mesa include/GL directory to /usr/local/include:
|
||||
cp -r include/GL /usr/local/include
|
||||
|
||||
Copy the Mesa library files to /usr/local/lib:
|
||||
cp lib/* /usr/local/lib
|
||||
|
||||
(actually, use "cp -d" on Linux to preserve symbolic links)
|
||||
|
||||
|
||||
Xt/Motif widgets:
|
||||
If you want to use Mesa or OpenGL in your Xt/Motif program you can build
|
||||
the widgets found in either the widgets-mesa or widgets-sgi directories.
|
||||
The former were written for Mesa and the later are the original SGI
|
||||
widgets. Look in those directories for more information.
|
||||
|
||||
|
||||
Notes:
|
||||
HP users: a Mesa user reports that the HP-UX 10.01 C compiler has
|
||||
a bug which effects glReadPixels. A patch for the compiler (PHSS_5743) is
|
||||
available. Otherwise be sure your compiler is version 10.13 or later.
|
||||
|
||||
QNX users: if you have problems running the demos try setting the
|
||||
stack size to 200K or larger with -N200K, for example.
|
||||
|
||||
SunOS 5.x users: The X shared memory extension may not work
|
||||
correctly. If Mesa prints an error message to the effect of "Shared memory
|
||||
error" then you'll have to append the following three lines to the end of
|
||||
your /etc/system file then reboot:
|
||||
set shmsys:shminfo_shmmax = 0x2000000
|
||||
set shmsys:shminfo_shmmni = 0x1000
|
||||
set shmsys:shminfo_shmseg = 0x100
|
||||
|
||||
|
||||
|
||||
Using the library
|
||||
=================
|
||||
|
||||
Configuration options:
|
||||
The file src/mesa/main/config.h has many parameters which you can adjust
|
||||
such as maximum number of lights, clipping planes, maximum texture size,
|
||||
etc. In particular, you may want to change DEPTH_BITS from 16 to 32
|
||||
if a 16-bit depth buffer isn't precise enough for your application.
|
||||
|
||||
|
||||
Shared libraries:
|
||||
If you compile shared libraries you may have to set an environment
|
||||
variable to specify where the Mesa libraries are located. On Linux and
|
||||
Sun systems for example, set the LD_LIBRARY_PATH variable to include
|
||||
/your-dir/Mesa-2.6/lib. Otherwise, when you try to run a demo it
|
||||
may fail with a message saying that one or more libraries couldn't be
|
||||
found.
|
||||
|
||||
|
||||
Remote display of OpenGL/GLX programs:
|
||||
As of version 1.2.3, Mesa's header files use the same GLenum and GLUenum
|
||||
values as SGI's (and most/all other vendor's) OpenGL headers. This means
|
||||
you can freely mix object files compiled with OpenGL or Mesa headers.
|
||||
In fact, on systems with dynamic runtime linkers it's possible to dynam-
|
||||
ically link with Mesa or OpenGL shared libraries at runtime, without
|
||||
recompiling or relinking anything!
|
||||
|
||||
Using IRIX 5.x as an example, you can run SGI's OpenGL demos with the
|
||||
Mesa shared libraries as follows. Let's assume you're installing Mesa
|
||||
in /usr/local/Mesa and using the C-shell:
|
||||
% cd /usr/local/Mesa
|
||||
% make irix5-dso
|
||||
% setenv _RLD_LIST "/usr/local/Mesa/lib/libGL.so:DEFAULT"
|
||||
% /usr/demos/bin/ideas_ogl // this is a test
|
||||
|
||||
You can now run OpenGL executables on almost any X display! There may
|
||||
be some problems from the fact that Mesa supports many X visual types
|
||||
that an OpenGL client may not expect (grayscale for example). In this
|
||||
case the application may abort, print error messages, or just behave
|
||||
strangely. You may have to experiment with the MESA_RGB_VISUAL envi-
|
||||
ronment variable.
|
||||
|
||||
|
||||
Xt/Motif Widgets:
|
||||
Two versions of the Xt/Motif OpenGL drawing area widgets are included:
|
||||
|
||||
widgets-sgi/ SGI's stock widgets
|
||||
widgets-mesa/ Mesa-tuned widgets
|
||||
|
||||
Look in those directories for details
|
||||
|
||||
|
||||
Togl:
|
||||
Togl is an OpenGL/Mesa widget for Tcl/Tk.
|
||||
See http://togl.sourceforge.net for more information.
|
||||
|
||||
|
||||
|
||||
X Display Modes:
|
||||
Mesa supports RGB(A) rendering into almost any X visual type and depth.
|
||||
|
||||
The glXChooseVisual function tries its best to pick an appropriate visual
|
||||
for the given attribute list. However, if this doesn't suit your needs
|
||||
you can force Mesa to use any X visual you want (any supported by your
|
||||
X server that is) by setting the MESA_RGB_VISUAL and MESA_CI_VISUAL
|
||||
environment variables. When an RGB visual is requested, glXChooseVisual
|
||||
will first look if the MESA_RGB_VISUAL variable is defined. If so, it
|
||||
will try to use the specified visual. Similarly, when a color index
|
||||
visual is requested, glXChooseVisual will look for the MESA_CI_VISUAL
|
||||
variable.
|
||||
|
||||
The format of accepted values is: <visual-class> <depth>
|
||||
Here are some examples:
|
||||
|
||||
using the C-shell:
|
||||
% setenv MESA_RGB_VISUAL "TrueColor 8" // 8-bit TrueColor
|
||||
% setenv MESA_CI_VISUAL "PseudoColor 12" // 12-bit PseudoColor
|
||||
% setenv MESA_RGB_VISUAL "PseudoColor 8" // 8-bit PseudoColor
|
||||
|
||||
using the KornShell:
|
||||
$ export MESA_RGB_VISUAL="TrueColor 8"
|
||||
$ export MESA_CI_VISUAL="PseudoColor 12"
|
||||
$ export MESA_RGB_VISUAL="PseudoColor 8"
|
||||
|
||||
|
||||
Double buffering:
|
||||
Mesa can use either an X Pixmap or XImage as the backbuffer when in
|
||||
double buffer mode. Using GLX, the default is to use an XImage. The
|
||||
MESA_BACK_BUFFER environment variable can override this. The valid
|
||||
values for MESA_BACK_BUFFER are: Pixmap and XImage (only the first
|
||||
letter is checked, case doesn't matter).
|
||||
|
||||
A pixmap is faster when drawing simple lines and polygons while an
|
||||
XImage is faster when Mesa has to do pixel-by-pixel rendering. If you
|
||||
need depth buffering the XImage will almost surely be faster. Exper-
|
||||
iment with the MESA_BACK_BUFFER variable to see which is faster for
|
||||
your application.
|
||||
|
||||
|
||||
Colormaps:
|
||||
When using Mesa directly or with GLX, it's up to the application writer
|
||||
to create a window with an appropriate colormap. The aux, tk, and GLUT
|
||||
toolkits try to minimize colormap "flashing" by sharing colormaps when
|
||||
possible. Specifically, if the visual and depth of the window matches
|
||||
that of the root window, the root window's colormap will be shared by
|
||||
the Mesa window. Otherwise, a new, private colormap will be allocated.
|
||||
|
||||
When sharing the root colormap, Mesa may be unable to allocate the colors
|
||||
it needs, resulting in poor color quality. This can happen when a
|
||||
large number of colorcells in the root colormap are already allocated.
|
||||
To prevent colormap sharing in aux, tk and GLUT, define the environment
|
||||
variable MESA_PRIVATE_CMAP. The value isn't significant.
|
||||
|
||||
|
||||
Gamma correction:
|
||||
To compensate for the nonlinear relationship between pixel values
|
||||
and displayed intensities, there is a gamma correction feature in
|
||||
Mesa. Some systems, such as Silicon Graphics, support gamma
|
||||
correction in hardware (man gamma) so you won't need to use Mesa's
|
||||
gamma facility. Other systems, however, may need gamma adjustment
|
||||
to produce images which look correct. If in the past you thought
|
||||
Mesa's images were too dim, read on.
|
||||
|
||||
Gamma correction is controlled with the MESA_GAMMA environment
|
||||
variable. Its value is of the form "Gr Gg Gb" or just "G" where
|
||||
Gr is the red gamma value, Gg is the green gamma value, Gb is the
|
||||
blue gamma value and G is one gamma value to use for all three
|
||||
channels. Each value is a positive real number typically in the
|
||||
range 1.0 to 2.5. The defaults are all 1.0, effectively disabling
|
||||
gamma correction. Examples using csh:
|
||||
|
||||
% setenv MESA_GAMMA "2.3 2.2 2.4" // separate R,G,B values
|
||||
% setenv MESA_GAMMA "2.0" // same gamma for R,G,B
|
||||
|
||||
The demos/gamma.c program may help you to determine reasonable gamma
|
||||
value for your display. With correct gamma values, the color intensities
|
||||
displayed in the top row (drawn by dithering) should nearly match those
|
||||
in the bottom row (drawn as grays).
|
||||
|
||||
Alex De Bruyn reports that gamma values of 1.6, 1.6 and 1.9 work well
|
||||
on HP displays using the HP-ColorRecovery technology.
|
||||
|
||||
Mesa implements gamma correction with a lookup table which translates
|
||||
a "linear" pixel value to a gamma-corrected pixel value. There is a
|
||||
small performance penalty. Gamma correction only works in RGB mode.
|
||||
Also be aware that pixel values read back from the frame buffer will
|
||||
not be "un-corrected" so glReadPixels may not return the same data
|
||||
drawn with glDrawPixels.
|
||||
|
||||
For more information about gamma correction see:
|
||||
http://www.inforamp.net/~poynton/notes/colour_and_gamma/GammaFAQ.html
|
||||
|
||||
|
||||
Overlay Planes
|
||||
|
||||
Overlay planes in the frame buffer are supported by Mesa but require
|
||||
hardware and X server support. To determine if your X server has
|
||||
overlay support you can test for the SERVER_OVERLAY_VISUALS property:
|
||||
|
||||
xprop -root | grep SERVER_OVERLAY_VISUALS
|
||||
|
||||
|
||||
HPCR glClear(GL_COLOR_BUFFER_BIT) dithering
|
||||
|
||||
If you set the MESA_HPCR_CLEAR environment variable then dithering
|
||||
will be used when clearing the color buffer. This is only applicable
|
||||
to HP systems with the HPCR (Color Recovery) system.
|
||||
|
||||
|
||||
Extensions
|
||||
==========
|
||||
There are three Mesa-specific GLX extensions at this time.
|
||||
|
||||
GLX_MESA_pixmap_colormap
|
||||
|
||||
This extension adds the GLX function:
|
||||
|
||||
GLXPixmap glXCreateGLXPixmapMESA( Display *dpy, XVisualInfo *visual,
|
||||
Pixmap pixmap, Colormap cmap )
|
||||
|
||||
It is an alternative to the standard glXCreateGLXPixmap() function.
|
||||
Since Mesa supports RGB rendering into any X visual, not just True-
|
||||
Color or DirectColor, Mesa needs colormap information to convert RGB
|
||||
values into pixel values. An X window carries this information but a
|
||||
pixmap does not. This function associates a colormap to a GLX pixmap.
|
||||
See the xdemos/glxpixmap.c file for an example of how to use this
|
||||
extension.
|
||||
|
||||
GLX_MESA_release_buffers
|
||||
|
||||
Mesa associates a set of ancillary (depth, accumulation, stencil and
|
||||
alpha) buffers with each X window it draws into. These ancillary
|
||||
buffers are allocated for each X window the first time the X window
|
||||
is passed to glXMakeCurrent(). Mesa, however, can't detect when an
|
||||
X window has been destroyed in order to free the ancillary buffers.
|
||||
|
||||
The best it can do is to check for recently destroyed windows whenever
|
||||
the client calls the glXCreateContext() or glXDestroyContext()
|
||||
functions. This may not be sufficient in all situations though.
|
||||
|
||||
The GLX_MESA_release_buffers extension allows a client to explicitly
|
||||
deallocate the ancillary buffers by calling glxReleaseBuffersMESA()
|
||||
just before an X window is destroyed. For example:
|
||||
|
||||
#ifdef GLX_MESA_release_buffers
|
||||
glXReleaseBuffersMESA( dpy, window );
|
||||
#endif
|
||||
XDestroyWindow( dpy, window );
|
||||
|
||||
This extension is new in Mesa 2.0.
|
||||
|
||||
GLX_MESA_copy_sub_buffer
|
||||
|
||||
This extension adds the glXCopySubBufferMESA() function. It works
|
||||
like glXSwapBuffers() but only copies a sub-region of the window
|
||||
instead of the whole window.
|
||||
|
||||
This extension is new in Mesa version 2.6
|
||||
|
||||
|
||||
|
||||
Summary of X-related environment variables:
|
||||
MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode (X only)
|
||||
MESA_CI_VISUAL - specifies the X visual and depth for CI mode (X only)
|
||||
MESA_BACK_BUFFER - specifies how to implement the back color buffer (X only)
|
||||
MESA_PRIVATE_CMAP - force aux/tk libraries to use private colormaps (X only)
|
||||
MESA_GAMMA - gamma correction coefficients (X only)
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: README.X11,v 3.11 2003/12/17 15:14:31 brianp Exp $
|
||||
47
docs/RELNOTES-6.4.1
Normal file
47
docs/RELNOTES-6.4.1
Normal file
@@ -0,0 +1,47 @@
|
||||
|
||||
Mesa 6.4.1 Release Notes
|
||||
|
||||
|
||||
Introduction
|
||||
------------
|
||||
|
||||
Mesa uses an even/odd version number scheme like the Linux kernel.
|
||||
Odd numbered versions (such as 6.3) designate new developmental releases.
|
||||
Even numbered versions (such as 6.4) designate stable releases.
|
||||
|
||||
|
||||
6.4.1 is a bug-fix release. See the VERSIONS file for details.
|
||||
|
||||
|
||||
|
||||
GLUT tarball
|
||||
------------
|
||||
|
||||
Starting with 6.4, the GLUT library sources are distributed in a separate
|
||||
tarball. This was done at the request of Linux distro vendors who prefer
|
||||
to use freeglut.
|
||||
|
||||
|
||||
|
||||
|
||||
Driver Status
|
||||
---------------------- ----------------------
|
||||
DRI drivers varies with the driver
|
||||
XMesa (Xlib) implements OpenGL 1.5
|
||||
OSMesa (off-screen) implements OpenGL 1.5
|
||||
Windows/Win32 implements OpenGL 1.5
|
||||
Glide (3dfx Voodoo1/2) requires updates
|
||||
SVGA requires updates
|
||||
DJGPP requires updates
|
||||
GGI requires updates
|
||||
BeOS requires updates
|
||||
Allegro requires updates
|
||||
D3D requires updates
|
||||
|
||||
The drivers which require updates mostly need to be updated to work
|
||||
with the new gl_renderbuffer / gl_framebuffer infrastructure introduced
|
||||
in Mesa 6.3.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.4.1,v 3.1 2006/02/03 17:21:54 brianp Exp $
|
||||
47
docs/RELNOTES-6.4.2
Normal file
47
docs/RELNOTES-6.4.2
Normal file
@@ -0,0 +1,47 @@
|
||||
|
||||
Mesa 6.4.2 Release Notes
|
||||
|
||||
|
||||
Introduction
|
||||
------------
|
||||
|
||||
Mesa uses an even/odd version number scheme like the Linux kernel.
|
||||
Odd numbered versions (such as 6.3) designate new developmental releases.
|
||||
Even numbered versions (such as 6.4) designate stable releases.
|
||||
|
||||
|
||||
6.4.2 is a minor bug-fix release. See the VERSIONS file for details.
|
||||
|
||||
|
||||
|
||||
GLUT tarball
|
||||
------------
|
||||
|
||||
Starting with 6.4, the GLUT library sources are distributed in a separate
|
||||
tarball. This was done at the request of Linux distro vendors who prefer
|
||||
to use freeglut.
|
||||
|
||||
|
||||
|
||||
|
||||
Driver Status
|
||||
---------------------- ----------------------
|
||||
DRI drivers varies with the driver
|
||||
XMesa (Xlib) implements OpenGL 1.5
|
||||
OSMesa (off-screen) implements OpenGL 1.5
|
||||
Windows/Win32 implements OpenGL 1.5
|
||||
Glide (3dfx Voodoo1/2) requires updates
|
||||
SVGA requires updates
|
||||
DJGPP requires updates
|
||||
GGI requires updates
|
||||
BeOS requires updates
|
||||
Allegro requires updates
|
||||
D3D requires updates
|
||||
|
||||
The drivers which require updates mostly need to be updated to work
|
||||
with the new gl_renderbuffer / gl_framebuffer infrastructure introduced
|
||||
in Mesa 6.3.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.4.2,v 3.1 2006/02/03 17:21:54 brianp Exp $
|
||||
@@ -1,7 +1,5 @@
|
||||
|
||||
Mesa 6.5 Release Notes
|
||||
|
||||
month, day, 2005
|
||||
Mesa 6.5 Release Notes
|
||||
|
||||
|
||||
|
||||
@@ -17,23 +15,29 @@ Even numbered versions (such as 6.4) designate stable releases.
|
||||
New Features
|
||||
------------
|
||||
|
||||
GL_EXT_timer_query - used to get elapsed time information from the renderer.
|
||||
OpenGL Shading language support
|
||||
This includes the GL_ARB_shader_objects, GL_ARB_shading_language_100,
|
||||
GL_ARB_vertex_shader and GL_ARB_fragment_shader extensions. Most of
|
||||
the work was done by Michal Krol.
|
||||
There's probably a fair number of bugs since this is a pretty large,
|
||||
complicated body of code.
|
||||
|
||||
The OpenGL 2.0 interface to these features will be implemented in a
|
||||
future version of Mesa,
|
||||
|
||||
GL_EXT_timer_query
|
||||
Used to measure the time of OpenGL operations at high precision.
|
||||
Only supported in the software/Xlib driver at this time.
|
||||
|
||||
Driver Interface Changes
|
||||
------------------------
|
||||
GL_EXT_packed_depth_stencil
|
||||
Defines a new GL_DEPTH_STENCIL_EXT pixel format.
|
||||
|
||||
Stencil: The Driver.StencilOp/Func/Mask() functions have been replaced by
|
||||
the two-sided versions: Driver.Stencil*Separate().
|
||||
|
||||
|
||||
|
||||
To Do
|
||||
-----
|
||||
Fix linux-glide target/driver.
|
||||
Fix lambda calculation for frag progs.
|
||||
GL_EXT_framebuffer_blit
|
||||
A simplified glCopyPixels-like feature for copying pixel rectangles.
|
||||
|
||||
GL_ARB_half_float_pixel
|
||||
Adds a new half-precision floating point format for image transfers,
|
||||
such as for glDrawPixels, glReadPixels, glTexImage, etc.
|
||||
|
||||
|
||||
|
||||
@@ -46,18 +50,37 @@ The following extensions have been removed:
|
||||
|
||||
|
||||
|
||||
Known Issues
|
||||
------------
|
||||
|
||||
Rendering to depth textures will not work. Rendering to GL_DEPTH_STENCIL
|
||||
textures should work.
|
||||
|
||||
|
||||
|
||||
Driver Interface Changes
|
||||
------------------------
|
||||
|
||||
Stencil: The Driver.StencilOp/Func/Mask() functions have been replaced by
|
||||
the two-sided versions: Driver.Stencil*Separate().
|
||||
|
||||
Render-to-texture: The functions for rendering to textures have changed.
|
||||
|
||||
|
||||
|
||||
To Do (someday) items
|
||||
---------------------
|
||||
Switch to freeglut
|
||||
Increase MAX_DRAWBUFFERS
|
||||
|
||||
Fix linux-glide target/driver.
|
||||
Fix lambda calculation for frag progs.
|
||||
|
||||
|
||||
|
||||
Driver Status
|
||||
---------------------- ----------------------
|
||||
DRI drivers varies with the driver
|
||||
XMesa (Xlib) implements OpenGL 1.5
|
||||
XMesa/GLX (on Xlib) implements OpenGL 1.5
|
||||
OSMesa (off-screen) implements OpenGL 1.5
|
||||
Glide (3dfx Voodoo1/2) implements OpenGL 1.3
|
||||
SVGA implements OpenGL 1.3
|
||||
@@ -71,4 +94,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.5,v 3.1 2005/09/14 14:34:54 brianp Exp $
|
||||
$Id: RELNOTES-6.5,v 3.4 2006/03/29 04:53:02 brianp Exp $
|
||||
|
||||
@@ -1407,10 +1407,42 @@ Mesa Version History
|
||||
- fragment programs that wrote result.depth.z didn't work
|
||||
|
||||
|
||||
6.5 month, day, 2005
|
||||
6.4.1 November 30, 2005
|
||||
Bug fixes:
|
||||
- redefining a vertex program string didn't take effect in TNL module
|
||||
- fixed occasional segfault upon vertex/fragment parsing error
|
||||
- vertex program LIT instruction didn't handle 0^0=1 correctly
|
||||
- fragment program fog option didn't work with glDrawPixels, glBitmap
|
||||
- USE_MGL_NAMESPACE didn't work for x86-64
|
||||
- OSMesa demos were missing from previous release tarballs
|
||||
- fixed problem with float->ushort conversion in glClear (bug 4992)
|
||||
- popping of GL_EYE_PLANE texgen state was broken (bug 4996)
|
||||
- popping of GL_SPOT_DIRECTION light state was broken (bug 5005)
|
||||
- fixed occasional triangle color interpolation problem on VMS
|
||||
- work around invalid free() call (bug 5131)
|
||||
- fixed BSD X server compilation problem by including stdint.h
|
||||
|
||||
|
||||
6.4.2 February 2, 2006
|
||||
New:
|
||||
- added OSMesaColorClamp() function/feature
|
||||
- added wglGetExtensionStringARB() function
|
||||
Bug fixes:
|
||||
- fixed some problems when building on Windows
|
||||
- GLw header files weren't installed by installmesa script (bug 5396)
|
||||
- GL/glfbdev.h file was missing from tarballs
|
||||
- fixed TNL initialization bug which could lead to crash (bug 5791)
|
||||
|
||||
|
||||
6.5 March 31, 2006
|
||||
New:
|
||||
- OpenGL Shading Language support through GL_ARB_shader_objects,
|
||||
GL_ARB_shading_language_100, GL_ARB_vertex_shader and
|
||||
GL_ARB_fragment_shader (done by Michal Krol)
|
||||
- GL_EXT_packed_depth_stencil extension
|
||||
- GL_EXT_timer_query extension
|
||||
- GL_EXT_framebuffer_blit extension
|
||||
- GL_ARB_half_float_pixel
|
||||
- reflect demo improved to support multiple windows
|
||||
- singlebuffer demo (shows no/little-flicker single-buffered rendering)
|
||||
- r200: enable GL_ARB_texture_env_crossbar, separate the texture
|
||||
@@ -1420,8 +1452,46 @@ Mesa Version History
|
||||
- radeon: add support for all 3 tmus, GL_ARB_texture_cube_map
|
||||
and GL_EXT_fog_coord
|
||||
- MESA_GLX_ALPHA_BITS env var for xlib driver
|
||||
- many DRI driver updates (including screen rotation support
|
||||
for the Intel DRI driver)
|
||||
Changes:
|
||||
- removed GL_HP_occlusion_test (use GL_ARB_occlusion_query instead)
|
||||
- removed GL_SGIX/SGIS_pixel_texture extensions
|
||||
Bug fixes:
|
||||
- fixed glxcontextmodes.c datatype problem (bug 5835)
|
||||
- fixed aix-gcc build/install bugs (bug 5874)
|
||||
- fixed some bugs in texture env program generation
|
||||
- glXCopyContext() didn't handle texture object bindings properly
|
||||
- glXCopyContext() didn't copy all lighting state
|
||||
- fixed FreeBSD config (Pedro Giffuni)
|
||||
- fixed some minor framebuffer object bugs
|
||||
- replaced dprintf() with _glu_printf() in GLU (bug 6244)
|
||||
- fixed a number of thread safety bugs/regressions
|
||||
- fixed a number of GLU tesselator bugs (John Shell, bug 6339)
|
||||
- paletted texturing was broken w/ floating point palettes (K. Schultz)
|
||||
- lots of assorted framebuffer object bug fixes
|
||||
|
||||
6.5.1 month, day, 2006
|
||||
New:
|
||||
- GL_APPLE_vertex_array_object extension (Ian Romanick)
|
||||
Changes:
|
||||
- The glVertexAttribARB functions no longer alias the conventional
|
||||
vertex attributes.
|
||||
- glxinfo program prints more info with -l option
|
||||
Bug fixes:
|
||||
- fixed broken texture border handling for depth textures (bug 6498)
|
||||
- removed the test for duplicated framebuffer attachments, per
|
||||
version 117 of the GL_EXT_framebuffer_object specification
|
||||
- fixed a few render-to-texture bugs, including render to depth texture
|
||||
- clipping of lines against user-defined clip planes was broken (6512)
|
||||
- assembly language dispatch for SPARC was broken (bug 6484)
|
||||
- assorted compilation fixes on various Unix platforms (Dan Schikore)
|
||||
- glPopAttrib could restore an invalid value for GL_DRAW_BUFFER
|
||||
- assorted minor fixes for 16 and 32 bit/channel modes
|
||||
- fixed assorted bugs in texture compression paths
|
||||
- fixed indirect rendering vertex array crashes (bug 6863)
|
||||
- glDrawPixels GL_INDEX_OFFSET didn't always work
|
||||
- fixed convolution memory leak (bug 7077)
|
||||
- rectangular depth textures didn't work
|
||||
- invalid mode to glBegin didn't generate an error (bug 7142)
|
||||
- 'normalized' parameter to glVertexAttribPointerARB didn't work
|
||||
|
||||
@@ -40,14 +40,14 @@ Here are the basic instructions for Unix systems:
|
||||
Version 1.9.28 is known to work.
|
||||
<li>Login as an anonymous user:
|
||||
<pre>
|
||||
cvs -d:pserver:anonymous@pdx.freedesktop.org:/cvs/mesa login
|
||||
cvs -d:pserver:anonymous@anoncvs.freedesktop.org:/cvs/mesa login
|
||||
</pre>
|
||||
Just press Enter/Return when prompted for a password.
|
||||
<br>
|
||||
<br>
|
||||
<li>Check out the code:
|
||||
<pre>
|
||||
cvs -d:pserver:anonymous@pdx.freedesktop.org:/cvs/mesa co Mesa
|
||||
cvs -d:pserver:anonymous@anoncvs.freedesktop.org:/cvs/mesa co Mesa
|
||||
</pre>
|
||||
</ol>
|
||||
|
||||
@@ -56,7 +56,7 @@ Here are the basic instructions for Unix systems:
|
||||
|
||||
<ol>
|
||||
<li><code>cd Mesa</code>
|
||||
<li><code>cvs -z3 -d:pserver:anonymous@pdx.freedesktop.org:/cvs/mesa update</code>
|
||||
<li><code>cvs -z3 -d:pserver:anonymous@anoncvs.freedesktop.org:/cvs/mesa update</code>
|
||||
</ol>
|
||||
|
||||
|
||||
@@ -86,7 +86,7 @@ with:
|
||||
</pre>
|
||||
followed by:
|
||||
<pre>
|
||||
cvs -d:ext:yourusername@pdx.freedesktop.org:/cvs/mesa co Mesa
|
||||
cvs -d:ext:yourusername@cvs.freedesktop.org:/cvs/mesa co Mesa
|
||||
</pre>
|
||||
|
||||
<p>
|
||||
|
||||
@@ -83,7 +83,7 @@ Brace example:
|
||||
Here's the GNU indent command which will best approximate my preferred style:
|
||||
</p>
|
||||
<pre>
|
||||
indent -br -i3 -npcs infile.c -o outfile.c
|
||||
indent -br -i3 -npcs --no-tabs infile.c -o outfile.c
|
||||
</pre>
|
||||
|
||||
|
||||
@@ -145,7 +145,7 @@ DEMO_NAME are correct.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Update the docs/news.html file and docs/contents.html files.
|
||||
Update the docs/news.html file and docs/download.html files.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
|
||||
@@ -9,11 +9,11 @@
|
||||
<H1>Downloading</H1>
|
||||
|
||||
<p>
|
||||
Last development release: <b>6.3.2</b>
|
||||
Last development release: <b>6.5</b>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Last stable release: <b>6.2.1</b>
|
||||
Last stable release: <b>6.4.2</b>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
@@ -32,10 +32,10 @@ Mesa is distributed in several parts:
|
||||
</li>
|
||||
<li><b>MesaDemos-x.y.z</b> - OpenGL demonstration and test programs.
|
||||
Most of the programs require GLUT (either the
|
||||
<a href="http://www.opengl.org/resources/libraries/glut.html"
|
||||
<a href="http://www.opengl.org/resources/libraries/glut"
|
||||
target="_parent">original GLUT by Mark Kilgard</a> or
|
||||
<a href="http://freeglut.sourceforge.net" target="_parent">freeglut</a> or
|
||||
<a href="http://freeglut.sourceforge.net" target="_parent">OpenGLUT</a>).
|
||||
<a href="http://openglut.sourceforge.net" target="_parent">OpenGLUT</a>).
|
||||
</li>
|
||||
<li><b>MesaGLUT-x.y.z</b> - Mark Kilgard's GLUT, easily compiled and used
|
||||
with Mesa. Plus, other implementation of GLUT for DOS, OS/2, BeOS, etc.
|
||||
|
||||
@@ -20,19 +20,25 @@ Mesa supports the following environment variables:
|
||||
If the value of MESA_DEBUG is "FP" floating point arithmetic errors will
|
||||
generate exceptions.
|
||||
<li>MESA_NO_DITHER - if set, disables dithering, overriding glEnable(GL_DITHER)
|
||||
<li>MESA_TEX_PROG - if set, implement conventional texture env modes with
|
||||
fragment programs (intended for developers only)
|
||||
<li>MESA_TNL_PROG - if set, implement conventional vertex transformation
|
||||
operations with vertex programs (intended for developers only).
|
||||
Setting this variable automatically sets the MESA_TEX_PROG variable as well.
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
The following environment variables are only applicable to the Xlib/X11
|
||||
software driver:
|
||||
The following are only applicable to the Xlib software driver.
|
||||
See <A HREF="README.X11">README.X11</A> for details.
|
||||
</p>
|
||||
<ul>
|
||||
<li>MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode (X only)
|
||||
<li>MESA_CI_VISUAL - specifies the X visual and depth for CI mode (X only)
|
||||
<li>MESA_BACK_BUFFER - specifies how to implement the back color buffer (X only)
|
||||
<li>MESA_GAMMA - gamma correction coefficients (X only)
|
||||
<li>MESA_XSYNC - enable synchronous X behavior (for X debugging only)
|
||||
<li>MESA_GLX_FORCE_CI - if set, force GLX to treak 8bpp visuals as CI visuals
|
||||
<li>MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode
|
||||
<li>MESA_CI_VISUAL - specifies the X visual and depth for CI mode
|
||||
<li>MESA_BACK_BUFFER - specifies how to implement the back color buffer,
|
||||
either "pixmap" or "ximage"
|
||||
<li>MESA_GAMMA - gamma correction coefficients for red, green, blue channels
|
||||
<li>MESA_XSYNC - enable synchronous X behavior (for debugging only)
|
||||
<li>MESA_GLX_FORCE_CI - if set, force GLX to treat 8bpp visuals as CI visuals
|
||||
<li>MESA_GLX_FX - set to either "fullscreen" for full-screen rendering,
|
||||
"window" to render into a window, or "disable" to disable the Glide driver.
|
||||
<li>MESA_GLX_FORCE_ALPHA - if set, forces RGB windows to have an alpha channel.
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
<center>
|
||||
<h1>Mesa Frequently Asked Questions</h1>
|
||||
Last updated: 21 October 2004
|
||||
Last updated: 8 June 2006
|
||||
</center>
|
||||
|
||||
<br>
|
||||
@@ -159,6 +159,12 @@ but it does export the OpenGL API. It allows tiled rendering, sort-last
|
||||
rendering, etc.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<a href="http://www.ticalc.org/archives/files/fileinfo/361/36173.html"
|
||||
target="_parent">ClosedGL</a> is an OpenGL subset library for TI
|
||||
graphing calculators.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
There may be other open OpenGL implementations, but Mesa is the most
|
||||
popular and feature-complete.
|
||||
@@ -373,7 +379,7 @@ the archives) is a good way to get information.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>4.3 Why isn't GL_EXT_texture_compression_s3tc implemented in Mesa and/or the DRI drivers?</h2>
|
||||
<h2>4.3 Why isn't GL_EXT_texture_compression_s3tc implemented in Mesa?</h2>
|
||||
<p>
|
||||
The <a href="http://oss.sgi.com/projects/ogl-sample/registry/EXT/texture_compression_s3tc.txt" target="_parent">specification for the extension</a>
|
||||
indicates that there are intellectual property (IP) and/or patent issues
|
||||
@@ -385,8 +391,9 @@ implement the extension (specifically the compression/decompression
|
||||
algorithms).
|
||||
</p>
|
||||
<p>
|
||||
Until we can get official permission to do so, this extension will not
|
||||
be implemented in Mesa.
|
||||
In the mean time, a 3rd party <a href=
|
||||
"http://homepage.hispeed.ch/rscheidegger/dri_experimental/s3tc_index.html"
|
||||
target="_parent">plug-in library</a> is available.
|
||||
</p>
|
||||
|
||||
|
||||
|
||||
@@ -70,13 +70,13 @@ They're found in a module of the DRI CVS tree.
|
||||
To obtain the code do the following:
|
||||
</p>
|
||||
<pre>
|
||||
cvs -d:pserver:anonymous@pdx.freedesktop.org:/cvs/dri login
|
||||
cvs -d:pserver:anonymous@anoncvs.freedesktop.org:/cvs/dri login
|
||||
</pre>
|
||||
<p>
|
||||
Press Enter/Return when prompted for a password. Then,
|
||||
</p>
|
||||
<pre>
|
||||
cvs -d:pserver:anonymous@pdx.freedesktop.org:/cvs/dri co drm
|
||||
cvs -d:pserver:anonymous@anoncvs.freedesktop.org:/cvs/dri co drm
|
||||
</pre>
|
||||
|
||||
<p>
|
||||
|
||||
@@ -27,9 +27,11 @@
|
||||
Mesa may be compiled in several different ways:
|
||||
</p>
|
||||
<ul>
|
||||
<li><b><em>Stand-alone/Xlib mode</em></b> - Mesa is compiled as
|
||||
<li><b><em>Stand-alone/Xlib mode</em></b> - Mesa will be compiled as
|
||||
a software renderer using Xlib to do all rendering.
|
||||
libGL.so is a self-contained rendering library.
|
||||
The libGL.so library will be a self-contained rendering library that will
|
||||
allow you to run OpenGL/GLX applications on any X server (regardless of
|
||||
whether it supports the GLX X server extension).
|
||||
<p>
|
||||
To compile stand-alone Mesa type <b>make</b> in the top-level directory.
|
||||
You'll see a list of supported system configurations.
|
||||
@@ -41,49 +43,73 @@ Choose one from the list (such as linux-x86), and type:
|
||||
<p>This will produce libGL.so and several other libraries</p>
|
||||
</li>
|
||||
|
||||
<li><b><em>DRI/accelerated</em></b> - The DRI hardware drivers (for ATI,
|
||||
Intel, Matrox, etc) are built.
|
||||
libGL.so implements the GLX extension and dynamically loads the DRI drivers.
|
||||
<li><b><em>DRI/accelerated</em></b> - The DRI hardware drivers for
|
||||
accelerated OpenGL rendering (for ATI, Intel, Matrox, etc) will be built.
|
||||
The libGL.so library will support the GLX extension and will load/use
|
||||
the DRI hardware drivers.
|
||||
|
||||
<p>
|
||||
To build the DRI drivers you'll first need to have the DRM (Direct
|
||||
Rendering Manager) kernel drivers and header files.
|
||||
They're available from the <a href="http://dri.sf.net/" target="_parent">DRI</a> project.
|
||||
<b>Prerequisites:</b>
|
||||
</p>
|
||||
|
||||
<ol>
|
||||
|
||||
<li>
|
||||
<p>
|
||||
You can get them from CVS by doing:
|
||||
<pre>
|
||||
cvs -d:pserver:anonymous@pds.freedesktop.org:/cvs/dri login
|
||||
(hit enter when prompted for a password)
|
||||
cvs -z3 -d:pserver:anonymous@pdx.freedesktop.org:/cvs/dri co drm
|
||||
</pre>
|
||||
<p>
|
||||
Make note of the directory in which the drm files are placed.
|
||||
</p>
|
||||
<p>
|
||||
See the <a href="http://dri.freedesktop.org/wiki/Building" target="_parent">
|
||||
DRI Building Instructions</a> for the steps to build the DRM modules.
|
||||
</p>
|
||||
<p>
|
||||
Next, in the <code>Mesa-x.y.z/configs/default</code> file, set the
|
||||
<code>DRM_SOURCE_PATH</code> variable to indicate where the DRM files
|
||||
are located.
|
||||
</p>
|
||||
<p>
|
||||
Now build Mesa and the DRI drivers by running
|
||||
</p>
|
||||
<pre>
|
||||
make linux-dri
|
||||
</pre>
|
||||
<p>
|
||||
There are also <code>linux-dri-x86</code>, <code>linux-dri-x86-64</code>,
|
||||
and <code>linux-ppc</code> configurations, optimized for those architectures.
|
||||
DRM kernel modules and header files from the
|
||||
<a href="http://dri.sf.net/" target="_parent">DRI</a> project.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Finally, you'll need a DRI-enabled X server from
|
||||
If you don't already have the DRM file, you can get the sources from
|
||||
CVS by doing:
|
||||
<pre>
|
||||
cvs -z3 -d:pserver:anonymous@anoncvs.freedesktop.org:/cvs/dri co drm
|
||||
</pre>
|
||||
<p>
|
||||
See the <a href="http://dri.freedesktop.org/wiki/Building" target="_parent">
|
||||
DRI Building Instructions</a> for the steps to build the DRM modules. Mesa
|
||||
6.5 requires at least libdrm 2.0.1 or greater.
|
||||
</p>
|
||||
<p>
|
||||
You can verify that the DRM files have been properly installed by
|
||||
running <code>pkg-config --modversion libdrm</code>
|
||||
|
||||
</li>
|
||||
|
||||
<li>
|
||||
Recent /usr/include/GL/glxproto.h file.
|
||||
<p>You'll need this if you get any errors about _GLXvop_BindTexImageEXT
|
||||
being undefined.
|
||||
</p>
|
||||
<p>The latest version can be
|
||||
obtained from <A href="http://webcvs.freedesktop.org/*checkout*/xorg/proto/GL/glxproto.h?rev=1.9&content-type=text%2Fplain">freedesktop.org CVS</a>
|
||||
</p>
|
||||
</li>
|
||||
|
||||
<li>DRI-enabled X server.
|
||||
<p>Visit
|
||||
<a href="http://www.xfree86.org" target="_parent">XFree86</a>
|
||||
or
|
||||
<a href="http://freedesktop.org/wiki/Software_2fXserver" target="_parent">
|
||||
X.org</a> or <a href="http://www.xfree86.org" target="_parent">XFree86</a>.
|
||||
Visit those projects' home pages for more information.
|
||||
X.org</a>
|
||||
for more information.
|
||||
</p>
|
||||
</li>
|
||||
|
||||
</ol>
|
||||
|
||||
|
||||
<p>
|
||||
Build Mesa and the DRI hardware drivers by running
|
||||
</p>
|
||||
<pre>
|
||||
make linux-dri
|
||||
</pre>
|
||||
<p>
|
||||
There are also <code>linux-dri-x86</code>, <code>linux-dri-x86-64</code>,
|
||||
and <code>linux-ppc</code> configurations which are optimized for those
|
||||
architectures.
|
||||
</p>
|
||||
|
||||
</li>
|
||||
@@ -137,10 +163,15 @@ lrwxrwxrwx 1 brian users 23 Mar 26 07:53 libOSMesa.so.6 -> libOSM
|
||||
If you built the DRI hardware drivers, you'll also see the DRI drivers:
|
||||
</p>
|
||||
<pre>
|
||||
-rwxr-xr-x 1 brian users 15607851 Jul 21 12:11 ffb_dri.so*
|
||||
-rwxr-xr-x 1 brian users 15148747 Jul 21 12:11 i810_dri.so*
|
||||
-rwxr-xr-x 1 brian users 14497814 Jul 21 12:11 i830_dri.so*
|
||||
-rwxr-xr-x 1 brian users 16895413 Jul 21 12:11 i915_dri.so*
|
||||
-rwxr-xr-x 1 brian users 11320803 Jul 21 12:11 mach64_dri.so
|
||||
-rwxr-xr-x 1 brian users 11418014 Jul 21 12:12 mga_dri.so
|
||||
-rwxr-xr-x 1 brian users 11064426 Jul 21 12:12 r128_dri.so
|
||||
-rwxr-xr-x 1 brian users 11849858 Jul 21 12:12 r200_dri.so
|
||||
-rwxr-xr-x 1 brian users 16050488 Jul 21 12:11 r300_dri.so*
|
||||
-rwxr-xr-x 1 brian users 11757388 Jul 21 12:12 radeon_dri.so
|
||||
-rwxr-xr-x 1 brian users 11232304 Jul 21 12:13 s3v_dri.so
|
||||
-rwxr-xr-x 1 brian users 11062970 Jul 21 12:13 savage_dri.so
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<li><a href="http://math.nist.gov/f90gl" target="_parent">Fortran77/90 bindings for OpenGL and Mesa</a> - by William Mitchell
|
||||
<li><a href="http://glow.sourceforge.net/" target="_parent">GLOW</a> - a GUI toolkit for GLUT and OpenGL
|
||||
<li><a href="http://www.nigels.com/glt/">Glt</a> - an OpenGL C++ toolkit
|
||||
<li><a href="http://www.opengl.org/developers/documentation/glut/" target="_parent">GLUT (GL Utility Toolkit)</a> - by Mark Kilgard
|
||||
<li><a href="http://www.opengl.org/resources/libraries/glut.html" target="_parent">GLUT (GL Utility Toolkit)</a> - by Mark Kilgard
|
||||
<li><a href="http://atrey.karlin.mff.cuni.cz/%7E0rfelyus/guileGL/" target="_parent">GuileGL</a> - OpenGL and GtkGLArea language bindings for Guile
|
||||
<li><a href="http://www.rsinc.com/" target="_parent">IDL</a> - Interactive Data Language
|
||||
<li><a href="http://www.newplanetsoftware.com/jx/" target="_parent">JX</a> - C++ application framework and GUI library
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
</li><li><a href="http://mesa3d.sourceforge.net/notfound.html">ARCAD</a> - CAD program
|
||||
</li><li><a href="http://www.mediascape.com/" target="_parent">Artstream</a> - provides
|
||||
functionality like Corel Draw and Illustrator
|
||||
</li><li><a href="http://www.blender.nl/" target="_parent">Blender</a> - 3-D animation
|
||||
</li><li><a href="http://www.blender.org/" target="_parent">Blender</a> - 3-D animation
|
||||
software
|
||||
</li><li><a href="http://www.arq.net/%7Ekasten/demtools/" target="_parent">Demtools</a>
|
||||
- Map viewer
|
||||
|
||||
126
docs/news.html
126
docs/news.html
@@ -11,6 +11,130 @@
|
||||
<H1>News</H1>
|
||||
|
||||
|
||||
<h2>March 31, 2006</h2>
|
||||
<p>
|
||||
Mesa 6.5 has been released. This is a new development release.
|
||||
</p>
|
||||
<pre>
|
||||
New:
|
||||
- OpenGL Shading Language support through GL_ARB_shader_objects,
|
||||
GL_ARB_shading_language_100, GL_ARB_vertex_shader and
|
||||
GL_ARB_fragment_shader (done by Michal Krol)
|
||||
- GL_EXT_packed_depth_stencil extension
|
||||
- GL_EXT_timer_query extension
|
||||
- GL_EXT_framebuffer_blit extension
|
||||
- GL_ARB_half_float_pixel
|
||||
- GLX_MESA_copy_sub_buffer for DRI drivers (Dave Reveman)
|
||||
- reflect demo improved to support multiple windows
|
||||
- singlebuffer demo (shows no/little-flicker single-buffered rendering)
|
||||
- r200: enable GL_ARB_texture_env_crossbar, separate the texture
|
||||
sampling unit bits from the texture env combine enable bits
|
||||
- r200: add support for GL_ATI_fragment_shader
|
||||
- added fast XOR-mode line drawing optimization
|
||||
- radeon: add support for all 3 tmus, GL_ARB_texture_cube_map
|
||||
and GL_EXT_fog_coord
|
||||
- MESA_GLX_ALPHA_BITS env var for xlib driver
|
||||
- many DRI driver updates (including screen rotation support
|
||||
for the Intel DRI driver)
|
||||
Changes:
|
||||
- removed GL_HP_occlusion_test (use GL_ARB_occlusion_query instead)
|
||||
- removed GL_SGIX/SGIS_pixel_texture extensions
|
||||
Bug fixes:
|
||||
- fixed glxcontextmodes.c datatype problem (bug 5835)
|
||||
- fixed aix-gcc build/install bugs (bug 5874)
|
||||
- fixed some bugs in texture env program generation
|
||||
- glXCopyContext() didn't handle texture object bindings properly
|
||||
- glXCopyContext() didn't copy all lighting state
|
||||
- fixed FreeBSD config (Pedro Giffuni)
|
||||
- fixed some minor framebuffer object bugs
|
||||
- replaced dprintf() with _glu_printf() in GLU (bug 6244)
|
||||
- fixed a number of thread safety bugs/regressions
|
||||
- fixed a number of GLU tesselator bugs (John Shell, bug 6339)
|
||||
- paletted texturing was broken w/ floating point palettes (K. Schultz)
|
||||
- lots of assorted framebuffer object bug fixes
|
||||
</pre>
|
||||
<p>
|
||||
The MD5 checksums are:
|
||||
</p>
|
||||
<pre>
|
||||
657be3b92f6dabc78a67ed9cb8d67813 MesaLib-6.5.tar.gz
|
||||
61beda590bfc5b4a12e979d5f2d70d7a MesaLib-6.5.tar.bz2
|
||||
19d48b872d579d4f91466060804a59ac MesaLib-6.5.zip
|
||||
694ad3a7007010c7418a9c72d1cba5b7 MesaDemos-6.5.tar.gz
|
||||
ab95b590dcd640726a2d89e62068c66e MesaDemos-6.5.tar.bz2
|
||||
b792c303fefd87294488e2b7eab976e5 MesaDemos-6.5.zip
|
||||
ac1d585483617db0c91e5c15cb5ec3a3 MesaGLUT-6.5.tar.gz
|
||||
59f0bf2b2ffb67fe23ee479f9b044f31 MesaGLUT-6.5.tar.bz2
|
||||
005decb2136718e22222ac1c4805cd15 MesaGLUT-6.5.zip
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>February 2, 2006</h2>
|
||||
<p>
|
||||
Mesa 6.4.2 has been released. This is primarily a bug-fix release.
|
||||
</p>
|
||||
<pre>
|
||||
New items:
|
||||
- added OSMesaColorClamp() function/feature
|
||||
- added wglGetExtensionStringARB() function
|
||||
Bug fixes:
|
||||
- fixed some problems when building on Windows
|
||||
- GLw header files weren't installed by installmesa script (bug 5396)
|
||||
- GL/glfbdev.h file was missing from tarballs
|
||||
</pre>
|
||||
<p>
|
||||
The MD5 checksums are:
|
||||
</p>
|
||||
<pre>
|
||||
cb0d745d520fa7c2bb9178058b763544 MesaLib-6.4.2.tar.gz
|
||||
7674d2c603b5834259e4e5a820cefd5b MesaLib-6.4.2.tar.bz2
|
||||
d224e1325b33ff71a0f3893fc6b4d594 MesaLib-6.4.2.zip
|
||||
d4b345d4588fc750cd3d34f3ac26673e MesaDemos-6.4.2.tar.gz
|
||||
9cae1ab874af533ce356bd7dfe2e0bb0 MesaDemos-6.4.2.tar.bz2
|
||||
2da6e1d1245e441d27813595c6ba50de MesaDemos-6.4.2.zip
|
||||
84427d18c3453f0ea52388eeba7169b5 MesaGLUT-6.4.2.tar.gz
|
||||
b157ba8ad1ea63260cf5339132e7aac6 MesaGLUT-6.4.2.tar.bz2
|
||||
fe1523744fc05edc3811dfc6a1bf4181 MesaGLUT-6.4.2.zip
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>November 29, 2005</h2>
|
||||
<p>
|
||||
Mesa 6.4.1 has been released. This is a stable, bug-fix release.
|
||||
</p>
|
||||
<pre>
|
||||
Bug fixes:
|
||||
- redefining a vertex program string didn't take effect in TNL module
|
||||
- fixed occasional segfault upon vertex/fragment parsing error
|
||||
- vertex program LIT instruction didn't handle 0^0=1 correctly
|
||||
- fragment program fog option didn't work with glDrawPixels, glBitmap
|
||||
- USE_MGL_NAMESPACE didn't work for x86-64
|
||||
- OSMesa demos were missing from previous release tarballs
|
||||
- fixed problem with float->ushort conversion in glClear (bug 4992)
|
||||
- popping of GL_EYE_PLANE texgen state was broken (bug 4996)
|
||||
- popping of GL_SPOT_DIRECTION light state was broken (bug 5005)
|
||||
- fixed occasional triangle color interpolation problem on VMS
|
||||
- work around invalid free() call (bug 5131)
|
||||
- fixed BSD X server compilation problem by including stdint.h
|
||||
</pre>
|
||||
<p>
|
||||
The MD5 checksums are:
|
||||
</p>
|
||||
<pre>
|
||||
698ceb574cf882b0226761f5913c0da9 MesaLib-6.4.1.tar.gz
|
||||
ea148c828ec6f645526451db1b8556f1 MesaLib-6.4.1.tar.bz2
|
||||
42e93279468975ed2bf3111b8721e5d9 MesaLib-6.4.1.zip
|
||||
e3b0d50807fd2bdcd1a95aaddd786f13 MesaDemos-6.4.1.tar.gz
|
||||
99df1fdcb98d391666b476ca6f1dda8a MesaDemos-6.4.1.tar.bz2
|
||||
b999d2c6d92fb4b7740a3dbd889348e3 MesaDemos-6.4.1.zip
|
||||
eadfe01fe5ddfb1eb8227dd567b31635 MesaGLUT-6.4.1.tar.gz
|
||||
bd003bb4f981a4f91dee4c38644d4f3f MesaGLUT-6.4.1.tar.bz2
|
||||
71c401c037088bf688a88afdaeb3420f MesaGLUT-6.4.1.zip
|
||||
</pre>
|
||||
|
||||
|
||||
|
||||
|
||||
<h2>October 24, 2005</h2>
|
||||
<p>
|
||||
Mesa 6.4 has been released. This is a stable, bug-fix release.
|
||||
@@ -1102,6 +1226,6 @@ source code</a>.</p>
|
||||
|
||||
|
||||
<hr>
|
||||
$Id: news.html,v 3.25 2005/10/24 23:33:27 brianp Exp $
|
||||
$Id: news.html,v 3.28 2006/04/01 02:29:40 brianp Exp $
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -10,46 +10,57 @@
|
||||
|
||||
|
||||
<p>
|
||||
Mesa 1.2.4 introduced off-screen rendering, a facility for generating
|
||||
3-D imagery without having to open a window on your display. Mesa's
|
||||
simple off-screen rendering interface is completely operating system
|
||||
and window system independent so programs which use off-screen
|
||||
rendering should be very portable. This feature effectively
|
||||
enables you to use Mesa as an off-line, batch-oriented renderer.
|
||||
Mesa's off-screen rendering interface is used for rendering into
|
||||
user-allocated blocks of memory.
|
||||
That is, the GL_FRONT colorbuffer is actually a buffer in main memory,
|
||||
rather than a window on your display.
|
||||
There are no window system or operating system dependencies.
|
||||
One potential application is to use Mesa as an off-line, batch-style renderer.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
The "OSMesa" API provides 3 functions for making off-screen
|
||||
The <B>OSMesa</B> API provides three basic functions for making off-screen
|
||||
renderings: OSMesaCreateContext(), OSMesaMakeCurrent(), and
|
||||
OSMesaDestroyContext(). See the Mesa/include/GL/osmesa.h header for
|
||||
more information. See the demos/osdemo.c file for an example program.
|
||||
There is no facility for writing images to files. That's up to you.
|
||||
more information about the API functions.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
If you want to generate large images (larger than 1280x1024) you'll
|
||||
have to edit the src/config.h file to change MAX_WIDTH and MAX_HEIGHT
|
||||
then recompile Mesa. Image size should only be limited by available
|
||||
memory.
|
||||
There are several examples of OSMesa in the <code>progs/osdemo/</code>
|
||||
directory.
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Deep color channels</H2>
|
||||
|
||||
<p>
|
||||
For some applications 8-bit color channels don't have sufficient
|
||||
accuracy (film and IBR, for example). If you're in this situation
|
||||
you'll be happy to know that Mesa supports 16-bit and 32-bit color
|
||||
channels through the OSMesa interface. When using 16-bit channels,
|
||||
channels are GLushorts and RGBA pixels occupy 8 bytes. When using 32-bit
|
||||
channels, channels are GLfloats and RGBA pixels occupy 16 bytes.
|
||||
For some applications 8-bit color channels don't have sufficient
|
||||
precision.
|
||||
OSMesa supports 16-bit and 32-bit color channels through the OSMesa interface.
|
||||
When using 16-bit channels, channels are GLushorts and RGBA pixels occupy
|
||||
8 bytes.
|
||||
When using 32-bit channels, channels are GLfloats and RGBA pixels occupy
|
||||
16 bytes.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
To build Mesa/OSMesa with 16-bit color channels:
|
||||
Before version 6.5.1, Mesa had to be recompiled to support exactly
|
||||
one of 8, 16 or 32-bit channels.
|
||||
With Mesa 6.5.1, Mesa can be compiled for either 8, 16 or 32-bit channels
|
||||
and render into any of the smaller size channels.
|
||||
For example, if Mesa's compiled for 32-bit channels, you can also render
|
||||
16 and 8-bit channel images.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
To build Mesa/OSMesa for 16 and 8-bit color channel support:
|
||||
<pre>
|
||||
make realclean
|
||||
make linux-osmesa16
|
||||
</pre>
|
||||
|
||||
For 32-bit channels:
|
||||
<p>
|
||||
To build Mesa/OSMesa for 32, 16 and 8-bit color channel support:
|
||||
<pre>
|
||||
make realclean
|
||||
make linux-osmesa32
|
||||
@@ -57,6 +68,13 @@ memory.
|
||||
|
||||
<p>
|
||||
You'll wind up with a library named libOSMesa16.so or libOSMesa32.so.
|
||||
Otherwise, most Mesa configurations build an 8-bit/channel libOSMesa.so library
|
||||
by default.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
If performance is important, compile Mesa for the channel size you're
|
||||
most interested in.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
@@ -66,12 +84,5 @@ the top-level Makefile. Send a patch to the Mesa developers too, if you're
|
||||
inclined.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
BE WARNED: 16 and 32-bit channel support has not been exhaustively
|
||||
tested and there may be some bugs. However, a number of people have
|
||||
been using this feature successfully so it can't be too broken.
|
||||
</p>
|
||||
|
||||
|
||||
</BODY>
|
||||
</HTML>
|
||||
|
||||
@@ -13,6 +13,9 @@ The release notes summarize what's new or changed in each Mesa release.
|
||||
</p>
|
||||
|
||||
<UL>
|
||||
<LI><A HREF="RELNOTES-6.5">RELNOTES-6.5</A>
|
||||
<LI><A HREF="RELNOTES-6.4.2">RELNOTES-6.4.2</A>
|
||||
<LI><A HREF="RELNOTES-6.4.1">RELNOTES-6.4.1</A>
|
||||
<LI><A HREF="RELNOTES-6.4">RELNOTES-6.4</A>
|
||||
<LI><A HREF="RELNOTES-6.3.2">RELNOTES-6.3.2</A>
|
||||
<LI><A HREF="RELNOTES-6.3">RELNOTES-6.3</A>
|
||||
|
||||
@@ -32,7 +32,7 @@ Be warned that some drivers may be out of date and no longer function.
|
||||
</p>
|
||||
|
||||
<UL>
|
||||
<LI>Xlib driver for the X Window System <A HREF="README.X11">(README.X11)</A>
|
||||
<LI><a href="xlibdriver.html">Xlib driver</a> for the X Window System
|
||||
<li><a href="http://dri.freedesktop.org/" target="_parent">
|
||||
DRI hardware drivers</a> for the X window system
|
||||
<LI>Microsoft Windows <A HREF="README.WIN32">(README.WIN32)</A>
|
||||
|
||||
275
docs/xlibdriver.html
Normal file
275
docs/xlibdriver.html
Normal file
@@ -0,0 +1,275 @@
|
||||
<HTML>
|
||||
|
||||
<TITLE>Xlib Software Driver</TITLE>
|
||||
|
||||
<link rel="stylesheet" type="text/css" href="mesa.css"></head>
|
||||
|
||||
<BODY>
|
||||
|
||||
<H1>Xlib Software Driver</H1>
|
||||
|
||||
<p>
|
||||
Mesa's Xlib driver provides an emulation of the GLX interface so that
|
||||
OpenGL programs which use the GLX API can render to any X display, even
|
||||
those that don't support the GLX extension.
|
||||
Effectively, the Xlib driver converts all OpenGL rendering into Xlib calls.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
The Xlib driver is the oldest Mesa driver and the most mature of Mesa's
|
||||
software-only drivers.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Since the Xlib driver <em>emulates</em> the GLX extension, it's not
|
||||
totally conformant with a true GLX implementation.
|
||||
The differences are fairly obscure, however.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
The unique features of the Xlib driver follows.
|
||||
</p>
|
||||
|
||||
|
||||
<H2>X Visual Selection</H2>
|
||||
<p>
|
||||
Mesa supports RGB(A) rendering into almost any X visual type and depth.
|
||||
</p>
|
||||
<p>
|
||||
The glXChooseVisual function tries to choose the best X visual
|
||||
for the given attribute list. However, if this doesn't suit your needs
|
||||
you can force Mesa to use any X visual you want (any supported by your
|
||||
X server that is) by setting the <b>MESA_RGB_VISUAL</b> and
|
||||
<b>MESA_CI_VISUAL</b>
|
||||
environment variables.
|
||||
When an RGB visual is requested, glXChooseVisual
|
||||
will first look if the MESA_RGB_VISUAL variable is defined.
|
||||
If so, it will try to use the specified visual.
|
||||
Similarly, when a color index visual is requested, glXChooseVisual will
|
||||
look for the MESA_CI_VISUAL variable.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
The format of accepted values is: <code>visual-class depth</code>
|
||||
</p>
|
||||
<p>
|
||||
Here are some examples:
|
||||
</p>
|
||||
<pre>
|
||||
using csh:
|
||||
% setenv MESA_RGB_VISUAL "TrueColor 8" // 8-bit TrueColor
|
||||
% setenv MESA_CI_VISUAL "PseudoColor 12" // 12-bit PseudoColor
|
||||
% setenv MESA_RGB_VISUAL "PseudoColor 8" // 8-bit PseudoColor
|
||||
|
||||
using bash:
|
||||
$ export MESA_RGB_VISUAL="TrueColor 8"
|
||||
$ export MESA_CI_VISUAL="PseudoColor 12"
|
||||
$ export MESA_RGB_VISUAL="PseudoColor 8"
|
||||
</pre>
|
||||
|
||||
|
||||
<H2>Double Buffering</H2>
|
||||
<p>
|
||||
Mesa can use either an X Pixmap or XImage as the back color buffer when in
|
||||
double-buffer mode.
|
||||
The default is to use an XImage.
|
||||
The <b>MESA_BACK_BUFFER</b> environment variable can override this.
|
||||
The valid values for <b>MESA_BACK_BUFFER</b> are: <b>Pixmap</b> and
|
||||
<b>XImage</b> (only the first letter is checked, case doesn't matter).
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Using XImage is almost always faster than a Pixmap since it resides in
|
||||
the application's address space.
|
||||
When glXSwapBuffers() is called, XPutImage() or XShmPutImage() is used
|
||||
to transfer the XImage to the on-screen window.
|
||||
</p>
|
||||
<p>
|
||||
A Pixmap may be faster when doing remote rendering of a simple scene.
|
||||
Some OpenGL features will be very slow with a Pixmap (for example, blending
|
||||
will require a round-trip message for pixel readback.)
|
||||
</p>
|
||||
<p>
|
||||
Experiment with the MESA_BACK_BUFFER variable to see which is faster
|
||||
for your application.
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Colormaps</H2>
|
||||
<p>
|
||||
When using Mesa directly or with GLX, it's up to the application
|
||||
writer to create a window with an appropriate colormap. The GLUT
|
||||
toolkit tris to minimize colormap <em>flashing</em> by sharing
|
||||
colormaps when possible. Specifically, if the visual and depth of the
|
||||
window matches that of the root window, the root window's colormap
|
||||
will be shared by the Mesa window. Otherwise, a new, private colormap
|
||||
will be allocated.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
When sharing the root colormap, Mesa may be unable to allocate the colors
|
||||
it needs, resulting in poor color quality. This can happen when a
|
||||
large number of colorcells in the root colormap are already allocated.
|
||||
To prevent colormap sharing in GLUT, set the
|
||||
<b>MESA_PRIVATE_CMAP</b> environment variable. The value isn't
|
||||
significant.
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Gamma Correction</H2>
|
||||
<p>
|
||||
To compensate for the nonlinear relationship between pixel values
|
||||
and displayed intensities, there is a gamma correction feature in
|
||||
Mesa. Some systems, such as Silicon Graphics, support gamma
|
||||
correction in hardware (man gamma) so you won't need to use Mesa's
|
||||
gamma facility. Other systems, however, may need gamma adjustment
|
||||
to produce images which look correct. If you believe that
|
||||
Mesa's images are too dim, read on.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Gamma correction is controlled with the <b>MESA_GAMMA</b> environment
|
||||
variable. Its value is of the form <b>Gr Gg Gb</b> or just <b>G</b> where
|
||||
Gr is the red gamma value, Gg is the green gamma value, Gb is the
|
||||
blue gamma value and G is one gamma value to use for all three
|
||||
channels. Each value is a positive real number typically in the
|
||||
range 1.0 to 2.5.
|
||||
The defaults are all 1.0, effectively disabling gamma correction.
|
||||
Examples:
|
||||
</p>
|
||||
<pre>
|
||||
% export MESA_GAMMA="2.3 2.2 2.4" // separate R,G,B values
|
||||
% export MESA_GAMMA="2.0" // same gamma for R,G,B
|
||||
</pre>
|
||||
<p>
|
||||
The progs/demos/gamma.c program may help you to determine reasonable gamma
|
||||
value for your display. With correct gamma values, the color intensities
|
||||
displayed in the top row (drawn by dithering) should nearly match those
|
||||
in the bottom row (drawn as grays).
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Alex De Bruyn reports that gamma values of 1.6, 1.6 and 1.9 work well
|
||||
on HP displays using the HP-ColorRecovery technology.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Mesa implements gamma correction with a lookup table which translates
|
||||
a "linear" pixel value to a gamma-corrected pixel value. There is a
|
||||
small performance penalty. Gamma correction only works in RGB mode.
|
||||
Also be aware that pixel values read back from the frame buffer will
|
||||
not be "un-corrected" so glReadPixels may not return the same data
|
||||
drawn with glDrawPixels.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
For more information about gamma correction see:
|
||||
<a href="http://www.inforamp.net/~poynton/notes/colour_and_gamma/GammaFAQ.html"
|
||||
the Gamma FAQ</a>
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Overlay Planes</H2>
|
||||
<p>
|
||||
Hardware overlay planes are supported by the Xlib driver. To
|
||||
determine if your X server has overlay support you can test for the
|
||||
SERVER_OVERLAY_VISUALS property:
|
||||
</p>
|
||||
<pre>
|
||||
xprop -root | grep SERVER_OVERLAY_VISUALS
|
||||
</pre>
|
||||
|
||||
|
||||
<H2>HPCR Dithering</H2>
|
||||
<p>
|
||||
If you set the <b>MESA_HPCR_CLEAR</b> environment variable then dithering
|
||||
will be used when clearing the color buffer. This is only applicable
|
||||
to HP systems with the HPCR (Color Recovery) feature.
|
||||
This incurs a small performance penalty.
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Extensions</H2>
|
||||
<p>
|
||||
The following MESA-specific extensions are implemented in the Xlib driver.
|
||||
</p>
|
||||
|
||||
<h3>GLX_MESA_pixmap_colormap</h3>
|
||||
|
||||
<p>
|
||||
This extension adds the GLX function:
|
||||
</p>
|
||||
<pre>
|
||||
GLXPixmap glXCreateGLXPixmapMESA( Display *dpy, XVisualInfo *visual,
|
||||
Pixmap pixmap, Colormap cmap )
|
||||
</pre>
|
||||
<p>
|
||||
It is an alternative to the standard glXCreateGLXPixmap() function.
|
||||
Since Mesa supports RGB rendering into any X visual, not just True-
|
||||
Color or DirectColor, Mesa needs colormap information to convert RGB
|
||||
values into pixel values. An X window carries this information but a
|
||||
pixmap does not. This function associates a colormap to a GLX pixmap.
|
||||
See the xdemos/glxpixmap.c file for an example of how to use this
|
||||
extension.
|
||||
</p>
|
||||
<p>
|
||||
<a href="MESA_pixmap_colormap.spec">GLX_MESA_pixmap_colormap specification</a>
|
||||
</p>
|
||||
|
||||
|
||||
<h3>GLX_MESA_release_buffers</h3>
|
||||
<p>
|
||||
Mesa associates a set of ancillary (depth, accumulation, stencil and
|
||||
alpha) buffers with each X window it draws into. These ancillary
|
||||
buffers are allocated for each X window the first time the X window
|
||||
is passed to glXMakeCurrent(). Mesa, however, can't detect when an
|
||||
X window has been destroyed in order to free the ancillary buffers.
|
||||
</p>
|
||||
<p>
|
||||
The best it can do is to check for recently destroyed windows whenever
|
||||
the client calls the glXCreateContext() or glXDestroyContext()
|
||||
functions. This may not be sufficient in all situations though.
|
||||
</p>
|
||||
<p>
|
||||
The GLX_MESA_release_buffers extension allows a client to explicitly
|
||||
deallocate the ancillary buffers by calling glxReleaseBuffersMESA()
|
||||
just before an X window is destroyed. For example:
|
||||
</p>
|
||||
<pre>
|
||||
#ifdef GLX_MESA_release_buffers
|
||||
glXReleaseBuffersMESA( dpy, window );
|
||||
#endif
|
||||
XDestroyWindow( dpy, window );
|
||||
</pre>
|
||||
<p>
|
||||
<a href="MESA_release_buffers.spec">GLX_MESA_release_buffers specification</a>
|
||||
</p>
|
||||
<p>
|
||||
This extension was added in Mesa 2.0.
|
||||
</p>
|
||||
|
||||
<H3>GLX_MESA_copy_sub_buffer</H3>
|
||||
<p>
|
||||
This extension adds the glXCopySubBufferMESA() function. It works
|
||||
like glXSwapBuffers() but only copies a sub-region of the window
|
||||
instead of the whole window.
|
||||
</p>
|
||||
<p>
|
||||
<a href="MESA_copy_sub_buffer.spec">GLX_MESA_copy_sub_buffer specification</a>
|
||||
</p>
|
||||
<p>
|
||||
This extension was added in Mesa 2.6
|
||||
</p>
|
||||
|
||||
<h2>Summary of X-related environment variables</H2>
|
||||
<pre>
|
||||
MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode (X only)
|
||||
MESA_CI_VISUAL - specifies the X visual and depth for CI mode (X only)
|
||||
MESA_BACK_BUFFER - specifies how to implement the back color buffer (X only)
|
||||
MESA_PRIVATE_CMAP - force aux/tk libraries to use private colormaps (X only)
|
||||
MESA_GAMMA - gamma correction coefficients (X only)
|
||||
</pre>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -23,9 +23,9 @@
|
||||
*/
|
||||
|
||||
/*
|
||||
* DOS/DJGPP device driver v1.7 for Mesa
|
||||
* DOS/DJGPP device driver for Mesa
|
||||
*
|
||||
* Copyright (C) 2002 - Daniel Borca
|
||||
* Author: Daniel Borca
|
||||
* Email : dborca@users.sourceforge.net
|
||||
* Web : http://www.geocities.com/dborca
|
||||
*/
|
||||
@@ -35,7 +35,7 @@
|
||||
#define DMESA_H_included
|
||||
|
||||
#define DMESA_MAJOR_VERSION 6
|
||||
#define DMESA_MINOR_VERSION 3
|
||||
#define DMESA_MINOR_VERSION 5
|
||||
|
||||
/* Sample Usage:
|
||||
*
|
||||
@@ -138,7 +138,7 @@ void DMesaSetCI (int ndx, GLfloat red, GLfloat green, GLfloat blue);
|
||||
/*
|
||||
* DMesa functions
|
||||
*/
|
||||
typedef void (*DMesaProc) (void);
|
||||
typedef void (*DMesaProc) ();
|
||||
DMesaProc DMesaGetProcAddress (const char *name);
|
||||
|
||||
/*
|
||||
@@ -149,8 +149,8 @@ DMesaProc DMesaGetProcAddress (const char *name);
|
||||
#define DMESA_GET_VIDEO_MODES 0x0300
|
||||
#define DMESA_GET_BUFFER_ADDR 0x0400
|
||||
|
||||
#define DMESA_DRIVER_SWDB_BIT 0x1 /* software double-buffered */
|
||||
#define DMESA_DRIVER_LLWO_BIT 0x2 /* lower-left window origin */
|
||||
#define DMESA_DRIVER_DBL_BIT 0x1 /* double-buffered */
|
||||
#define DMESA_DRIVER_YUP_BIT 0x2 /* lower-left window origin */
|
||||
int DMesaGetIntegerv (GLenum pname, GLint *params);
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
/*
|
||||
* Mesa 3-D graphics library
|
||||
* Version: 6.3
|
||||
* Version: 6.5.1
|
||||
*
|
||||
* Copyright (C) 1999-2005 Brian Paul All Rights Reserved.
|
||||
* Copyright (C) 1999-2006 Brian Paul All Rights Reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and associated documentation files (the "Software"),
|
||||
@@ -441,16 +441,16 @@ typedef double GLclampd; /* double precision float in [0,1] */
|
||||
#define GL_OR_INVERTED 0x150D
|
||||
|
||||
/* Stencil */
|
||||
#define GL_STENCIL_TEST 0x0B90
|
||||
#define GL_STENCIL_WRITEMASK 0x0B98
|
||||
#define GL_STENCIL_BITS 0x0D57
|
||||
#define GL_STENCIL_TEST 0x0B90
|
||||
#define GL_STENCIL_CLEAR_VALUE 0x0B91
|
||||
#define GL_STENCIL_FUNC 0x0B92
|
||||
#define GL_STENCIL_VALUE_MASK 0x0B93
|
||||
#define GL_STENCIL_REF 0x0B97
|
||||
#define GL_STENCIL_FAIL 0x0B94
|
||||
#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96
|
||||
#define GL_STENCIL_PASS_DEPTH_FAIL 0x0B95
|
||||
#define GL_STENCIL_CLEAR_VALUE 0x0B91
|
||||
#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96
|
||||
#define GL_STENCIL_REF 0x0B97
|
||||
#define GL_STENCIL_WRITEMASK 0x0B98
|
||||
#define GL_STENCIL_INDEX 0x1901
|
||||
#define GL_KEEP 0x1E00
|
||||
#define GL_REPLACE 0x1E01
|
||||
@@ -500,16 +500,16 @@ typedef double GLclampd; /* double precision float in [0,1] */
|
||||
|
||||
/* Implementation limits */
|
||||
#define GL_MAX_LIST_NESTING 0x0B31
|
||||
#define GL_MAX_ATTRIB_STACK_DEPTH 0x0D35
|
||||
#define GL_MAX_MODELVIEW_STACK_DEPTH 0x0D36
|
||||
#define GL_MAX_NAME_STACK_DEPTH 0x0D37
|
||||
#define GL_MAX_PROJECTION_STACK_DEPTH 0x0D38
|
||||
#define GL_MAX_TEXTURE_STACK_DEPTH 0x0D39
|
||||
#define GL_MAX_EVAL_ORDER 0x0D30
|
||||
#define GL_MAX_LIGHTS 0x0D31
|
||||
#define GL_MAX_CLIP_PLANES 0x0D32
|
||||
#define GL_MAX_TEXTURE_SIZE 0x0D33
|
||||
#define GL_MAX_PIXEL_MAP_TABLE 0x0D34
|
||||
#define GL_MAX_ATTRIB_STACK_DEPTH 0x0D35
|
||||
#define GL_MAX_MODELVIEW_STACK_DEPTH 0x0D36
|
||||
#define GL_MAX_NAME_STACK_DEPTH 0x0D37
|
||||
#define GL_MAX_PROJECTION_STACK_DEPTH 0x0D38
|
||||
#define GL_MAX_TEXTURE_STACK_DEPTH 0x0D39
|
||||
#define GL_MAX_VIEWPORT_DIMS 0x0D3A
|
||||
#define GL_MAX_CLIENT_ATTRIB_STACK_DEPTH 0x0D3B
|
||||
|
||||
@@ -567,22 +567,22 @@ typedef double GLclampd; /* double precision float in [0,1] */
|
||||
#define GL_MAP2_GRID_DOMAIN 0x0DD2
|
||||
#define GL_MAP2_GRID_SEGMENTS 0x0DD3
|
||||
#define GL_COEFF 0x0A00
|
||||
#define GL_DOMAIN 0x0A02
|
||||
#define GL_ORDER 0x0A01
|
||||
#define GL_DOMAIN 0x0A02
|
||||
|
||||
/* Hints */
|
||||
#define GL_FOG_HINT 0x0C54
|
||||
#define GL_LINE_SMOOTH_HINT 0x0C52
|
||||
#define GL_PERSPECTIVE_CORRECTION_HINT 0x0C50
|
||||
#define GL_POINT_SMOOTH_HINT 0x0C51
|
||||
#define GL_LINE_SMOOTH_HINT 0x0C52
|
||||
#define GL_POLYGON_SMOOTH_HINT 0x0C53
|
||||
#define GL_FOG_HINT 0x0C54
|
||||
#define GL_DONT_CARE 0x1100
|
||||
#define GL_FASTEST 0x1101
|
||||
#define GL_NICEST 0x1102
|
||||
|
||||
/* Scissor box */
|
||||
#define GL_SCISSOR_TEST 0x0C11
|
||||
#define GL_SCISSOR_BOX 0x0C10
|
||||
#define GL_SCISSOR_TEST 0x0C11
|
||||
|
||||
/* Pixel Mode / Transfer */
|
||||
#define GL_MAP_COLOR 0x0D10
|
||||
@@ -687,8 +687,8 @@ typedef double GLclampd; /* double precision float in [0,1] */
|
||||
|
||||
/* Errors */
|
||||
#define GL_NO_ERROR 0x0
|
||||
#define GL_INVALID_VALUE 0x0501
|
||||
#define GL_INVALID_ENUM 0x0500
|
||||
#define GL_INVALID_VALUE 0x0501
|
||||
#define GL_INVALID_OPERATION 0x0502
|
||||
#define GL_STACK_OVERFLOW 0x0503
|
||||
#define GL_STACK_UNDERFLOW 0x0504
|
||||
@@ -2260,6 +2260,28 @@ typedef void (APIENTRYP PFNGLGETQUERYOBJECTUI64VEXTPROC) (GLuint id, GLenum pnam
|
||||
|
||||
|
||||
|
||||
#ifndef GL_EXT_framebuffer_blit
|
||||
#define GL_EXT_framebuffer_blit 1
|
||||
|
||||
#define GL_READ_FRAMEBUFFER_EXT 0x8CA8
|
||||
#define GL_DRAW_FRAMEBUFFER_EXT 0x8CA9
|
||||
#define GL_DRAW_FRAMEBUFFER_BINDING_EXT 0x8CA6
|
||||
#define GL_READ_FRAMEBUFFER_BINDING_EXT 0x8CAA
|
||||
|
||||
GLAPI void GLAPIENTRY
|
||||
glBlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
|
||||
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
|
||||
GLbitfield mask, GLenum filter);
|
||||
|
||||
typedef void (APIENTRYP PFNGLBLITFRAMEBUFFEREXTPROC)
|
||||
(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
|
||||
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
|
||||
GLbitfield mask, GLenum filter);
|
||||
|
||||
#endif /* GL_EXT_framebuffer_blit */
|
||||
|
||||
|
||||
|
||||
#ifndef GL_EXT_packed_depth_stencil
|
||||
#define GL_EXT_packed_depth_stencil 1
|
||||
|
||||
|
||||
@@ -6154,12 +6154,12 @@ typedef void (APIENTRYP PFNGLFINISHOBJECTAPPLEPROC) (GLenum object, GLint name);
|
||||
#ifdef GL_GLEXT_PROTOTYPES
|
||||
GLAPI void APIENTRY glBindVertexArrayAPPLE (GLuint);
|
||||
GLAPI void APIENTRY glDeleteVertexArraysAPPLE (GLsizei, const GLuint *);
|
||||
GLAPI void APIENTRY glGenVertexArraysAPPLE (GLsizei, const GLuint *);
|
||||
GLAPI void APIENTRY glGenVertexArraysAPPLE (GLsizei, GLuint *);
|
||||
GLAPI GLboolean APIENTRY glIsVertexArrayAPPLE (GLuint);
|
||||
#endif /* GL_GLEXT_PROTOTYPES */
|
||||
typedef void (APIENTRYP PFNGLBINDVERTEXARRAYAPPLEPROC) (GLuint array);
|
||||
typedef void (APIENTRYP PFNGLDELETEVERTEXARRAYSAPPLEPROC) (GLsizei n, const GLuint *arrays);
|
||||
typedef void (APIENTRYP PFNGLGENVERTEXARRAYSAPPLEPROC) (GLsizei n, const GLuint *arrays);
|
||||
typedef void (APIENTRYP PFNGLGENVERTEXARRAYSAPPLEPROC) (GLsizei n, GLuint *arrays);
|
||||
typedef GLboolean (APIENTRYP PFNGLISVERTEXARRAYAPPLEPROC) (GLuint array);
|
||||
#endif
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* Mesa 3-D graphics library
|
||||
* Version: 6.5
|
||||
*
|
||||
* Copyright (C) 1999-2005 Brian Paul All Rights Reserved.
|
||||
* Copyright (C) 1999-2006 Brian Paul All Rights Reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and associated documentation files (the "Software"),
|
||||
@@ -379,6 +379,97 @@ extern Bool glXDrawableAttribARB(Display *dpy, GLXDrawable draw, const int *attr
|
||||
#endif /* GLX_NV_float_buffer */
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* #?. GLX_MESA_swap_frame_usage
|
||||
*/
|
||||
#ifndef GLX_MESA_swap_frame_usage
|
||||
#define GLX_MESA_swap_frame_usage 1
|
||||
|
||||
extern int glXGetFrameUsageMESA(Display *dpy, GLXDrawable drawable, float *usage);
|
||||
extern int glXBeginFrameTrackingMESA(Display *dpy, GLXDrawable drawable);
|
||||
extern int glXEndFrameTrackingMESA(Display *dpy, GLXDrawable drawable);
|
||||
extern int glXQueryFrameTrackingMESA(Display *dpy, GLXDrawable drawable, int64_t *swapCount, int64_t *missedFrames, float *lastMissedUsage);
|
||||
|
||||
typedef int (*PFNGLXGETFRAMEUSAGEMESAPROC) (Display *dpy, GLXDrawable drawable, float *usage);
|
||||
typedef int (*PFNGLXBEGINFRAMETRACKINGMESAPROC)(Display *dpy, GLXDrawable drawable);
|
||||
typedef int (*PFNGLXENDFRAMETRACKINGMESAPROC)(Display *dpy, GLXDrawable drawable);
|
||||
typedef int (*PFNGLXQUERYFRAMETRACKINGMESAPROC)(Display *dpy, GLXDrawable drawable, int64_t *swapCount, int64_t *missedFrames, float *lastMissedUsage);
|
||||
|
||||
#endif /* GLX_MESA_swap_frame_usage */
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* #?. GLX_MESA_swap_control
|
||||
*/
|
||||
#ifndef GLX_MESA_swap_control
|
||||
#define GLX_MESA_swap_control 1
|
||||
|
||||
extern int glXSwapIntervalMESA(unsigned int interval);
|
||||
extern int glXGetSwapIntervalMESA(void);
|
||||
|
||||
typedef int (*PFNGLXSWAPINTERVALMESAPROC)(unsigned int interval);
|
||||
typedef int (*PFNGLXGETSWAPINTERVALMESAPROC)(void);
|
||||
|
||||
#endif /* GLX_MESA_swap_control */
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* #?. GLX_EXT_texture_from_pixmap
|
||||
* XXX not finished?
|
||||
*/
|
||||
#ifndef GLX_EXT_texture_from_pixmap
|
||||
#define GLX_EXT_texture_from_pixmap 1
|
||||
|
||||
#define GLX_BIND_TO_TEXTURE_RGB_EXT 0x20D0
|
||||
#define GLX_BIND_TO_TEXTURE_RGBA_EXT 0x20D1
|
||||
#define GLX_BIND_TO_MIPMAP_TEXTURE_EXT 0x20D2
|
||||
#define GLX_BIND_TO_TEXTURE_TARGETS_EXT 0x20D3
|
||||
#define GLX_Y_INVERTED_EXT 0x20D4
|
||||
|
||||
#define GLX_TEXTURE_FORMAT_EXT 0x20D5
|
||||
#define GLX_TEXTURE_TARGET_EXT 0x20D6
|
||||
#define GLX_MIPMAP_TEXTURE_EXT 0x20D7
|
||||
|
||||
#define GLX_TEXTURE_FORMAT_NONE_EXT 0x20D8
|
||||
#define GLX_TEXTURE_FORMAT_RGB_EXT 0x20D9
|
||||
#define GLX_TEXTURE_FORMAT_RGBA_EXT 0x20DA
|
||||
|
||||
#define GLX_TEXTURE_1D_BIT_EXT 0x00000001
|
||||
#define GLX_TEXTURE_2D_BIT_EXT 0x00000002
|
||||
#define GLX_TEXTURE_RECTANGLE_BIT_EXT 0x00000004
|
||||
|
||||
#define GLX_TEXTURE_1D_EXT 0x20DB
|
||||
#define GLX_TEXTURE_2D_EXT 0x20DC
|
||||
#define GLX_TEXTURE_RECTANGLE_EXT 0x20DD
|
||||
|
||||
#define GLX_FRONT_LEFT_EXT 0x20DE
|
||||
#define GLX_FRONT_RIGHT_EXT 0x20DF
|
||||
#define GLX_BACK_LEFT_EXT 0x20E0
|
||||
#define GLX_BACK_RIGHT_EXT 0x20E1
|
||||
#define GLX_FRONT_EXT GLX_FRONT_LEFT_EXT
|
||||
#define GLX_BACK_EXT GLX_BACK_LEFT_EXT
|
||||
#define GLX_AUX0_EXT 0x20E2
|
||||
#define GLX_AUX1_EXT 0x20E3
|
||||
#define GLX_AUX2_EXT 0x20E4
|
||||
#define GLX_AUX3_EXT 0x20E5
|
||||
#define GLX_AUX4_EXT 0x20E6
|
||||
#define GLX_AUX5_EXT 0x20E7
|
||||
#define GLX_AUX6_EXT 0x20E8
|
||||
#define GLX_AUX7_EXT 0x20E9
|
||||
#define GLX_AUX8_EXT 0x20EA
|
||||
#define GLX_AUX9_EXT 0x20EB
|
||||
|
||||
extern void glXBindTexImageEXT(Display *dpy, GLXDrawable drawable, int buffer, const int *attrib_list);
|
||||
extern void glXReleaseTexImageEXT(Display *dpy, GLXDrawable drawable, int buffer);
|
||||
|
||||
#endif /* GLX_EXT_texture_from_pixmap */
|
||||
|
||||
|
||||
|
||||
|
||||
/*** Should these go here, or in another header? */
|
||||
/*
|
||||
** GLX Events
|
||||
|
||||
@@ -331,7 +331,7 @@ typedef struct {
|
||||
} GLXBufferClobberEventSGIX;
|
||||
#endif
|
||||
|
||||
#if defined(__sun__)
|
||||
#if defined(__sun__) || defined(__osf__)
|
||||
#include <inttypes.h>
|
||||
#if defined(__STDC__)
|
||||
#if defined(__arch64__)
|
||||
|
||||
@@ -472,6 +472,14 @@ struct __DRIdrawableRec {
|
||||
* \since Internal API version 20030317.
|
||||
*/
|
||||
unsigned swap_interval;
|
||||
|
||||
/**
|
||||
* Used by drivers that implement the GLX_MESA_copy_sub_buffer extension.
|
||||
*
|
||||
* \since Internal API version 20060314.
|
||||
*/
|
||||
void (*copySubBuffer)(__DRInativeDisplay *dpy, void *drawablePrivate,
|
||||
int x, int y, int w, int h);
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -137,6 +137,13 @@ typedef struct __GLcontextModesRec {
|
||||
GLint swapMethod;
|
||||
|
||||
GLint screen;
|
||||
|
||||
/* EXT_texture_from_pixmap */
|
||||
GLint bindToTextureRgb;
|
||||
GLint bindToTextureRgba;
|
||||
GLint bindToMipmapTexture;
|
||||
GLint bindToTextureTargets;
|
||||
GLint yInverted;
|
||||
} __GLcontextModes;
|
||||
|
||||
/* Several fields of __GLcontextModes can take these as values. Since
|
||||
@@ -166,6 +173,17 @@ typedef struct __GLcontextModesRec {
|
||||
#define GLX_PIXMAP_BIT 0x00000002
|
||||
#define GLX_PBUFFER_BIT 0x00000004
|
||||
|
||||
#define GLX_BIND_TO_TEXTURE_RGB_EXT 0x20D0
|
||||
#define GLX_BIND_TO_TEXTURE_RGBA_EXT 0x20D1
|
||||
#define GLX_BIND_TO_MIPMAP_TEXTURE_EXT 0x20D2
|
||||
#define GLX_BIND_TO_TEXTURE_TARGETS_EXT 0x20D3
|
||||
#define GLX_Y_INVERTED_EXT 0x20D4
|
||||
|
||||
#define GLX_TEXTURE_1D_BIT_EXT 0x00000001
|
||||
#define GLX_TEXTURE_2D_BIT_EXT 0x00000002
|
||||
#define GLX_TEXTURE_RECTANGLE_BIT_EXT 0x00000004
|
||||
|
||||
|
||||
/************************************************************************/
|
||||
|
||||
/*
|
||||
|
||||
@@ -111,6 +111,15 @@ WGLAPI int GLAPIENTRY DescribePixelFormat(HDC,int,unsigned int,LPPIXELFORMATDE
|
||||
WGLAPI int GLAPIENTRY GetPixelFormat(HDC);
|
||||
WGLAPI int GLAPIENTRY SetPixelFormat(HDC,int,const PIXELFORMATDESCRIPTOR *);
|
||||
|
||||
|
||||
#ifndef WGL_ARB_extensions_string
|
||||
#define WGL_ARB_extensions_string 1
|
||||
|
||||
WGLAPI const char * GLAPIENTRY wglGetExtensionsStringARB(HDC hdc);
|
||||
|
||||
#endif /* WGL_ARB_extensions_string */
|
||||
|
||||
|
||||
#ifdef _MSC_VER
|
||||
# pragma warning( pop )
|
||||
#endif
|
||||
|
||||
@@ -100,15 +100,14 @@ extern WMesaContext WMesaCreateContext(HDC hDC,HPALETTE* pPal,
|
||||
/*
|
||||
* Destroy a rendering context as returned by WMesaCreateContext()
|
||||
*/
|
||||
/*extern void WMesaDestroyContext( WMesaContext ctx );*/
|
||||
extern void WMesaDestroyContext( void );
|
||||
extern void WMesaDestroyContext( WMesaContext ctx );
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Make the specified context the current one.
|
||||
*/
|
||||
extern void WMesaMakeCurrent( WMesaContext ctx );
|
||||
extern void WMesaMakeCurrent( WMesaContext ctx, HDC hdc );
|
||||
|
||||
|
||||
/*
|
||||
@@ -121,7 +120,7 @@ extern WMesaContext WMesaGetCurrentContext( void );
|
||||
* Swap the front and back buffers for the current context. No action
|
||||
* taken if the context is not double buffered.
|
||||
*/
|
||||
extern void WMesaSwapBuffers(void);
|
||||
extern void WMesaSwapBuffers(HDC hdc);
|
||||
|
||||
|
||||
/*
|
||||
|
||||
@@ -64,6 +64,7 @@ typedef XColor XMesaColor;
|
||||
|
||||
#define XMesaDrawPoint XDrawPoint
|
||||
#define XMesaDrawPoints XDrawPoints
|
||||
#define XMesaDrawLine XDrawLine
|
||||
#define XMesaFillRectangle XFillRectangle
|
||||
#define XMesaPutImage XPutImage
|
||||
#define XMesaCopyArea XCopyArea
|
||||
|
||||
@@ -95,6 +95,18 @@ do { \
|
||||
(*gc->ops->PolyPoint)(__b, __gc, __m, __n, __p); \
|
||||
} while (0)
|
||||
|
||||
#define XMesaDrawLine(__d, __b, __gc, __x0, __y0, __x1, __y1) \
|
||||
do { \
|
||||
XMesaPoint __p[2]; \
|
||||
(void) __d; \
|
||||
__p[0].x = __x0; \
|
||||
__p[0].y = __y0; \
|
||||
__p[1].x = __x1; \
|
||||
__p[1].y = __y1; \
|
||||
ValidateGC(__b, __gc); \
|
||||
(*gc->ops->PolyLines)(__b, __gc, CoordModeOrigin, 2, __p); \
|
||||
} while (0)
|
||||
|
||||
#define XMesaFillRectangle(__d,__b,__gc,__x,__y,__w,__h) \
|
||||
do { \
|
||||
xRectangle __r[1]; \
|
||||
|
||||
@@ -64,9 +64,7 @@
|
||||
** Versioning and extensions
|
||||
*/
|
||||
#define EGL_VERSION_1_0 1
|
||||
#if 0
|
||||
#define EGL_VERSION_1_1 1
|
||||
#endif
|
||||
|
||||
/*
|
||||
** Boolean
|
||||
@@ -269,6 +267,56 @@ GLAPI EGLBoolean APIENTRY eglCopyContextMESA(EGLDisplay dpy, EGLContext source,
|
||||
#endif /* EGL_MESA_copy_context */
|
||||
|
||||
|
||||
/* XXX this is preliminary! */
|
||||
#ifndef EGL_VERSION_1_2
|
||||
#define EGL_VERSION_1_2 1
|
||||
|
||||
typedef int EGLenum;
|
||||
typedef int EGLClientBuffer;
|
||||
|
||||
#define EGL_DISPLAY_SCALING 10000
|
||||
#define EGL_UNKNOWN ((EGLint)-1)
|
||||
|
||||
#define EGL_OPENGL_ES_BIT 0x1
|
||||
#define EGL_OPENVG_BIT 0x2
|
||||
|
||||
#define EGL_OPENGL_ES_API 0x30A0
|
||||
#define EGL_OPENVG_API 0x30A1
|
||||
|
||||
#define EGL_LUMINANCE_SIZE 0x303D
|
||||
#define EGL_ALPHA_MASK_SIZE 0x303E
|
||||
#define EGL_COLOR_BUFFER_TYPE 0x303F
|
||||
#define EGL_RENDERABLE_TYPE 0x3040
|
||||
|
||||
#define EGL_SINGLE_BUFFER 0x3085
|
||||
#define EGL_RENDER_BUFFER 0x3086
|
||||
#define EGL_COLORSPACE 0x3087
|
||||
#define EGL_ALPHA_FORMAT 0x3088
|
||||
#define EGL_COLORSPACE_sRGB 0x3089
|
||||
#define EGL_COLORSPACE_LINEAR 0x308A
|
||||
#define EGL_ALPHA_FORMAT_NONPRE 0x308B
|
||||
#define EGL_ALPHA_FORMAT_PRE 0x308C
|
||||
#define EGL_CLIENT_APIS 0x308D
|
||||
#define EGL_RGB_BUFFER 0x308E
|
||||
#define EGL_LUMINANCE_BUFFER 0x308F
|
||||
#define EGL_HORIZONTAL_RESOLUTION 0x3090
|
||||
#define EGL_VERTICAL_RESOLUTION 0x3091
|
||||
#define EGL_PIXEL_ASPECT_RATIO 0x3092
|
||||
#define EGL_SWAP_BEHAVIOR 0x3093
|
||||
#define EGL_BUFFER_PRESERVED 0x3094
|
||||
#define EGL_BUFFER_DESTROYED 0x3095
|
||||
#define EGL_OPENVG_IMAGE 0x3096
|
||||
#define EGL_CONTEXT_CLIENT_TYPE 0x3097
|
||||
|
||||
GLAPI EGLBoolean APIENTRY eglBindAPI(EGLenum api);
|
||||
GLAPI EGLenum APIENTRY eglQueryAPI(void);
|
||||
GLAPI EGLBoolean APIENTRY eglWaitClient(void);
|
||||
GLAPI EGLBoolean APIENTRY eglReleaseThread(void);
|
||||
GLAPI EGLSurface APIENTRY eglCreatePbufferFromClientBuffer(EGLDisplay dpy, EGLenum buftype, EGLClientBuffer buffer, EGLConfig config, const EGLint *attrib_list);
|
||||
|
||||
#endif /* EGL_VERSION_1_2 */
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -21,6 +21,8 @@ subdirs:
|
||||
fi \
|
||||
done
|
||||
|
||||
# Dummy install target
|
||||
install:
|
||||
|
||||
clean:
|
||||
@for dir in $(SUBDIRS) tests ; do \
|
||||
|
||||
@@ -31,6 +31,8 @@ readtex.h
|
||||
reflect
|
||||
renormal
|
||||
shadowtex
|
||||
showbuffer.c
|
||||
showbuffer.h
|
||||
spectex
|
||||
stex3d
|
||||
teapot
|
||||
|
||||
@@ -15,19 +15,23 @@ LIB_DEP = $(LIB_DIR)/$(GL_LIB_NAME) $(LIB_DIR)/$(GLU_LIB_NAME) $(LIB_DIR)/$(GLUT
|
||||
|
||||
PROGS = \
|
||||
arbfplight \
|
||||
arbfslight \
|
||||
arbocclude \
|
||||
bounce \
|
||||
clearspd \
|
||||
cubemap \
|
||||
drawpix \
|
||||
engine \
|
||||
fire \
|
||||
fogcoord \
|
||||
fplight \
|
||||
gamma \
|
||||
gearbox \
|
||||
gears \
|
||||
geartrain \
|
||||
glinfo \
|
||||
gloss \
|
||||
glslnoise \
|
||||
gltestperf \
|
||||
glutfx \
|
||||
isosurf \
|
||||
@@ -35,7 +39,6 @@ PROGS = \
|
||||
lodbias \
|
||||
morph3d \
|
||||
multiarb \
|
||||
occlude \
|
||||
paltex \
|
||||
pointblast \
|
||||
ray \
|
||||
@@ -57,6 +60,7 @@ PROGS = \
|
||||
trispd \
|
||||
tunnel \
|
||||
tunnel2 \
|
||||
vao_demo \
|
||||
winpos
|
||||
|
||||
|
||||
@@ -97,6 +101,16 @@ showbuffer.o: showbuffer.c showbuffer.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) showbuffer.c
|
||||
|
||||
|
||||
trackball.c: $(TOP)/progs/util/trackball.c
|
||||
cp $< .
|
||||
|
||||
trackball.h: $(TOP)/progs/util/trackball.h
|
||||
cp $< .
|
||||
|
||||
trackball.o: trackball.c trackball.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) trackball.c
|
||||
|
||||
|
||||
reflect: reflect.o showbuffer.o readtex.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) reflect.o showbuffer.o readtex.o $(APP_LIB_DEPS) -o $@
|
||||
|
||||
@@ -110,6 +124,21 @@ shadowtex: shadowtex.o showbuffer.o
|
||||
shadowtex.o: shadowtex.c showbuffer.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) shadowtex.c
|
||||
|
||||
|
||||
gloss: gloss.o trackball.o readtex.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) gloss.o trackball.o readtex.o $(APP_LIB_DEPS) -o $@
|
||||
|
||||
gloss.o: gloss.c trackball.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) gloss.c
|
||||
|
||||
|
||||
engine: engine.o trackball.o readtex.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) engine.o trackball.o readtex.o $(APP_LIB_DEPS) -o $@
|
||||
|
||||
engine.o: engine.c trackball.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) engine.c
|
||||
|
||||
|
||||
clean:
|
||||
-rm -f $(PROGS)
|
||||
-rm -f *.o *~
|
||||
|
||||
118
progs/demos/Makefile.win
Normal file
118
progs/demos/Makefile.win
Normal file
@@ -0,0 +1,118 @@
|
||||
|
||||
# Mesa 3-D graphics library
|
||||
# Version: 6.5
|
||||
# Copyright (C) 1995-2006 Brian Paul
|
||||
|
||||
# Makefile for GLUT-based demo programs for Windows
|
||||
|
||||
# Build the Mesa and GLUT libraries by using the Visual Studio
|
||||
# Workspaces in this distribution before running this Makefile.
|
||||
|
||||
# Invocation: nmake -f Makefile.win
|
||||
|
||||
NODEBUG=1
|
||||
!include <win32.mak>
|
||||
|
||||
##### MACROS #####
|
||||
|
||||
TOP = ..\..
|
||||
INCDIR = ..\..\include
|
||||
LIBDIR = ..\..\lib
|
||||
LIBS = GLUT32.LIB OPENGL32.LIB
|
||||
|
||||
all: OPENGL32.DLL GLU32.DLL GLUT32.DLL \
|
||||
readtex.h readtex.c showbuffer.h showbuffer.c \
|
||||
arbfplight.exe arbfslight.exe arbocclude.exe bounce.exe \
|
||||
clearspd.exe cubemap.exe drawpix.exe fire.exe fogcoord.exe \
|
||||
fplight.exe gamma.exe gearbox.exe \
|
||||
gears.exe geartrain.exe gloss.exe \
|
||||
glinfo.exe glslnoise.exe \
|
||||
gltestperf.exe glutfx.exe ipers.exe isosurf.exe lodbias.exe \
|
||||
morph3d.exe multiarb.exe occlude.exe paltex.exe pointblast.exe \
|
||||
ray.exe readpix.exe reflect.exe renormal.exe \
|
||||
shadowtex.exe singlebuffer.exe spectex.exe spriteblast.exe \
|
||||
stex3d.exe teapot.exe terrain.exe tessdemo.exe texcyl.exe \
|
||||
texdown.exe texenv.exe texobj.exe trispd.exe tunnel.exe tunnel2.exe \
|
||||
winpos.exe
|
||||
|
||||
arbfplight.exe: arbfplight.obj
|
||||
arbfslight.exe: arbfslight.obj
|
||||
arbocclude.exe: arbocclude.obj
|
||||
bounce.exe: bounce.obj
|
||||
clearspd.exe: clearspd.obj
|
||||
cubemap.exe: cubemap.obj readtex.obj
|
||||
drawpix.exe: drawpix.obj readtex.obj
|
||||
fire.exe: fire.obj readtex.obj
|
||||
fogcoord.exe: fogcoord.obj readtex.obj
|
||||
fplight.exe: fplight.obj
|
||||
gamma.exe: gamma.obj
|
||||
gearbox.exe: gearbox.obj
|
||||
gears.exe: gears.obj
|
||||
geartrain.exe: geartrain.obj
|
||||
gloss.exe: gloss.obj readtex.obj
|
||||
glinfo.exe: glinfo.obj
|
||||
glslnoise.exe: glslnoise.obj
|
||||
gltestperf.exe: gltestperf.obj
|
||||
glutfx.exe: glutfx.obj
|
||||
ipers.exe: ipers.obj readtex.obj
|
||||
isosurf.exe: isosurf.obj readtex.obj
|
||||
lodbias.exe: lodbias.obj readtex.obj
|
||||
morph3d.exe: morph3d.obj
|
||||
multiarb.exe: multiarb.obj readtex.obj
|
||||
occlude.exe: occlude.obj
|
||||
paltex.exe: paltex.obj
|
||||
pointblast.exe: pointblast.obj
|
||||
ray.exe: ray.obj
|
||||
readpix.exe: readpix.obj readtex.obj
|
||||
reflect.exe: reflect.obj readtex.obj showbuffer.obj
|
||||
renormal.exe: renormal.obj
|
||||
shadowtex.exe: shadowtex.obj showbuffer.obj
|
||||
singlebuffer.exe: singlebuffer.obj
|
||||
spectex.exe: spectex.obj
|
||||
spriteblast.exe: spriteblast.obj
|
||||
stex3d.exe: stex3d.obj
|
||||
teapot.exe: teapot.obj readtex.obj
|
||||
terrain.exe: terrain.obj
|
||||
tessdemo.exe: tessdemo.obj
|
||||
texcyl.exe: texcyl.obj readtex.obj
|
||||
texdown.exe: texdown.obj
|
||||
texenv.exe: texenv.obj
|
||||
texobj.exe: texobj.obj
|
||||
trispd.exe: trispd.obj
|
||||
tunnel.exe: tunnel.obj readtex.obj
|
||||
tunnel2.exe: tunnel2.obj readtex.obj
|
||||
winpos.exe: winpos.obj readtex.obj
|
||||
|
||||
|
||||
OPENGL32.DLL: $(LIBDIR)\OPENGL32.DLL
|
||||
copy $? .
|
||||
|
||||
GLU32.DLL: $(LIBDIR)\GLU32.DLL
|
||||
copy $? .
|
||||
|
||||
GLUT32.DLL: $(LIBDIR)\GLUT32.DLL
|
||||
copy $? .
|
||||
|
||||
readtex.c: $(TOP)\progs\util\readtex.c
|
||||
copy $** .
|
||||
|
||||
readtex.h: $(TOP)\progs\util\readtex.h
|
||||
copy $** .
|
||||
|
||||
showbuffer.c: $(TOP)\progs\util\showbuffer.c
|
||||
copy $** .
|
||||
|
||||
showbuffer.h: $(TOP)\progs\util\showbuffer.h
|
||||
copy $** .
|
||||
|
||||
.obj.exe:
|
||||
$(link) $(ldebug) -out:$@ $** /LIBPATH:$(LIBDIR) $(LIBS)
|
||||
|
||||
.c.obj:
|
||||
$(cc) $(cdebug) $(cflags) $(cvars) /I$(INCDIR) $*.c
|
||||
|
||||
clean::
|
||||
del *.obj *.exe readtex.* showbuffer.*
|
||||
|
||||
clobber::
|
||||
|
||||
@@ -343,7 +343,7 @@ static void Init( void )
|
||||
(const GLubyte *) vertProgramText);
|
||||
glGetIntegerv(GL_PROGRAM_ERROR_POSITION_ARB, &errorPos);
|
||||
if (glGetError() != GL_NO_ERROR || errorPos != -1) {
|
||||
int l = FindLine(fragProgramText, errorPos);
|
||||
int l = FindLine(vertProgramText, errorPos);
|
||||
printf("Vertex Program Error (pos=%d line=%d): %s\n", errorPos, l,
|
||||
(char *) glGetString(GL_PROGRAM_ERROR_STRING_ARB));
|
||||
exit(0);
|
||||
|
||||
289
progs/demos/arbfslight.c
Normal file
289
progs/demos/arbfslight.c
Normal file
@@ -0,0 +1,289 @@
|
||||
/*
|
||||
* Use GL_ARB_fragment_shader and GL_ARB_vertex_shader to implement
|
||||
* simple per-pixel lighting.
|
||||
*
|
||||
* Michal Krol
|
||||
* 20 February 2006
|
||||
*
|
||||
* Based on the original demo by:
|
||||
* Brian Paul
|
||||
* 17 April 2003
|
||||
*/
|
||||
|
||||
#ifdef WIN32
|
||||
#include <windows.h>
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glut.h>
|
||||
#include <GL/glext.h>
|
||||
|
||||
#ifdef WIN32
|
||||
#define GETPROCADDRESS wglGetProcAddress
|
||||
#else
|
||||
#define GETPROCADDRESS glutGetProcAddress
|
||||
#endif
|
||||
|
||||
static GLfloat diffuse[4] = { 0.5f, 0.5f, 1.0f, 1.0f };
|
||||
static GLfloat specular[4] = { 0.8f, 0.8f, 0.8f, 1.0f };
|
||||
static GLfloat lightPos[4] = { 0.0f, 10.0f, 20.0f, 1.0f };
|
||||
static GLfloat delta = 1.0f;
|
||||
|
||||
static GLhandleARB fragShader;
|
||||
static GLhandleARB vertShader;
|
||||
static GLhandleARB program;
|
||||
|
||||
static GLint uLightPos;
|
||||
static GLint uDiffuse;
|
||||
static GLint uSpecular;
|
||||
|
||||
static GLboolean anim = GL_TRUE;
|
||||
static GLboolean wire = GL_FALSE;
|
||||
static GLboolean pixelLight = GL_TRUE;
|
||||
|
||||
static GLint t0 = 0;
|
||||
static GLint frames = 0;
|
||||
|
||||
static GLfloat xRot = 0.0f, yRot = 0.0f;
|
||||
|
||||
static PFNGLCREATESHADEROBJECTARBPROC glCreateShaderObjectARB = NULL;
|
||||
static PFNGLSHADERSOURCEARBPROC glShaderSourceARB = NULL;
|
||||
static PFNGLCOMPILESHADERARBPROC glCompileShaderARB = NULL;
|
||||
static PFNGLCREATEPROGRAMOBJECTARBPROC glCreateProgramObjectARB = NULL;
|
||||
static PFNGLATTACHOBJECTARBPROC glAttachObjectARB = NULL;
|
||||
static PFNGLLINKPROGRAMARBPROC glLinkProgramARB = NULL;
|
||||
static PFNGLUSEPROGRAMOBJECTARBPROC glUseProgramObjectARB = NULL;
|
||||
static PFNGLGETUNIFORMLOCATIONARBPROC glGetUniformLocationARB = NULL;
|
||||
static PFNGLUNIFORM4FVARBPROC glUniform4fvARB = NULL;
|
||||
|
||||
static void Redisplay (void)
|
||||
{
|
||||
glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
if (pixelLight)
|
||||
{
|
||||
glUseProgramObjectARB (program);
|
||||
glUniform4fvARB (uLightPos, 1, lightPos);
|
||||
glDisable(GL_LIGHTING);
|
||||
}
|
||||
else
|
||||
{
|
||||
glUseProgramObjectARB (0);
|
||||
glLightfv (GL_LIGHT0, GL_POSITION, lightPos);
|
||||
glEnable(GL_LIGHTING);
|
||||
}
|
||||
|
||||
glPushMatrix ();
|
||||
glRotatef (xRot, 1.0f, 0.0f, 0.0f);
|
||||
glRotatef (yRot, 0.0f, 1.0f, 0.0f);
|
||||
glutSolidSphere (2.0, 10, 5);
|
||||
glPopMatrix ();
|
||||
|
||||
glutSwapBuffers();
|
||||
frames++;
|
||||
|
||||
if (anim)
|
||||
{
|
||||
GLint t = glutGet (GLUT_ELAPSED_TIME);
|
||||
if (t - t0 >= 5000)
|
||||
{
|
||||
GLfloat seconds = (GLfloat) (t - t0) / 1000.0f;
|
||||
GLfloat fps = frames / seconds;
|
||||
printf ("%d frames in %6.3f seconds = %6.3f FPS\n", frames, seconds, fps);
|
||||
t0 = t;
|
||||
frames = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void Idle (void)
|
||||
{
|
||||
lightPos[0] += delta;
|
||||
if (lightPos[0] > 25.0f || lightPos[0] < -25.0f)
|
||||
delta = -delta;
|
||||
glutPostRedisplay ();
|
||||
}
|
||||
|
||||
static void Reshape (int width, int height)
|
||||
{
|
||||
glViewport (0, 0, width, height);
|
||||
glMatrixMode (GL_PROJECTION);
|
||||
glLoadIdentity ();
|
||||
glFrustum (-1.0, 1.0, -1.0, 1.0, 5.0, 25.0);
|
||||
glMatrixMode (GL_MODELVIEW);
|
||||
glLoadIdentity ();
|
||||
glTranslatef (0.0f, 0.0f, -15.0f);
|
||||
}
|
||||
|
||||
static void Key (unsigned char key, int x, int y)
|
||||
{
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch (key)
|
||||
{
|
||||
case ' ':
|
||||
case 'a':
|
||||
anim = !anim;
|
||||
if (anim)
|
||||
glutIdleFunc (Idle);
|
||||
else
|
||||
glutIdleFunc (NULL);
|
||||
break;
|
||||
case 'x':
|
||||
lightPos[0] -= 1.0f;
|
||||
break;
|
||||
case 'X':
|
||||
lightPos[0] += 1.0f;
|
||||
break;
|
||||
case 'w':
|
||||
wire = !wire;
|
||||
if (wire)
|
||||
glPolygonMode (GL_FRONT_AND_BACK, GL_LINE);
|
||||
else
|
||||
glPolygonMode (GL_FRONT_AND_BACK, GL_FILL);
|
||||
break;
|
||||
case 'p':
|
||||
pixelLight = !pixelLight;
|
||||
if (pixelLight)
|
||||
printf ("Per-pixel lighting\n");
|
||||
else
|
||||
printf ("Conventional lighting\n");
|
||||
break;
|
||||
case 27:
|
||||
exit(0);
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay ();
|
||||
}
|
||||
|
||||
static void SpecialKey (int key, int x, int y)
|
||||
{
|
||||
const GLfloat step = 3.0f;
|
||||
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch (key)
|
||||
{
|
||||
case GLUT_KEY_UP:
|
||||
xRot -= step;
|
||||
break;
|
||||
case GLUT_KEY_DOWN:
|
||||
xRot += step;
|
||||
break;
|
||||
case GLUT_KEY_LEFT:
|
||||
yRot -= step;
|
||||
break;
|
||||
case GLUT_KEY_RIGHT:
|
||||
yRot += step;
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay ();
|
||||
}
|
||||
|
||||
static void Init (void)
|
||||
{
|
||||
static const char *fragShaderText =
|
||||
"uniform vec4 lightPos;\n"
|
||||
"uniform vec4 diffuse;\n"
|
||||
"uniform vec4 specular;\n"
|
||||
"void main () {\n"
|
||||
" // Compute dot product of light direction and normal vector\n"
|
||||
" float dotProd;\n"
|
||||
" dotProd = clamp (dot (normalize (lightPos).xyz, normalize (gl_TexCoord[0]).xyz), 0.0, 1.0);\n"
|
||||
" // Compute diffuse and specular contributions\n"
|
||||
" gl_FragColor = diffuse * dotProd + specular * pow (dotProd, 20.0);\n"
|
||||
"}\n"
|
||||
;
|
||||
static const char *vertShaderText =
|
||||
"void main () {\n"
|
||||
" gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;\n"
|
||||
" gl_TexCoord[0] = vec4 (gl_NormalMatrix * gl_Normal, 1.0);\n"
|
||||
"}\n"
|
||||
;
|
||||
|
||||
if (!glutExtensionSupported ("GL_ARB_fragment_shader"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_fragment_shader\n");
|
||||
exit(1);
|
||||
}
|
||||
if (!glutExtensionSupported ("GL_ARB_shader_objects"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_shader_objects\n");
|
||||
exit(1);
|
||||
}
|
||||
if (!glutExtensionSupported ("GL_ARB_shading_language_100"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_shading_language_100\n");
|
||||
exit(1);
|
||||
}
|
||||
if (!glutExtensionSupported ("GL_ARB_vertex_shader"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_vertex_shader\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
glCreateShaderObjectARB = (PFNGLCREATESHADEROBJECTARBPROC) GETPROCADDRESS ("glCreateShaderObjectARB");
|
||||
glShaderSourceARB = (PFNGLSHADERSOURCEARBPROC) GETPROCADDRESS ("glShaderSourceARB");
|
||||
glCompileShaderARB = (PFNGLCOMPILESHADERARBPROC) GETPROCADDRESS ("glCompileShaderARB");
|
||||
glCreateProgramObjectARB = (PFNGLCREATEPROGRAMOBJECTARBPROC) GETPROCADDRESS ("glCreateProgramObjectARB");
|
||||
glAttachObjectARB = (PFNGLATTACHOBJECTARBPROC) GETPROCADDRESS ("glAttachObjectARB");
|
||||
glLinkProgramARB = (PFNGLLINKPROGRAMARBPROC) GETPROCADDRESS ("glLinkProgramARB");
|
||||
glUseProgramObjectARB = (PFNGLUSEPROGRAMOBJECTARBPROC) GETPROCADDRESS ("glUseProgramObjectARB");
|
||||
glGetUniformLocationARB = (PFNGLGETUNIFORMLOCATIONARBPROC) GETPROCADDRESS ("glGetUniformLocationARB");
|
||||
glUniform4fvARB = (PFNGLUNIFORM4FVARBPROC) GETPROCADDRESS ("glUniform4fvARB");
|
||||
|
||||
fragShader = glCreateShaderObjectARB (GL_FRAGMENT_SHADER_ARB);
|
||||
glShaderSourceARB (fragShader, 1, &fragShaderText, NULL);
|
||||
glCompileShaderARB (fragShader);
|
||||
|
||||
vertShader = glCreateShaderObjectARB (GL_VERTEX_SHADER_ARB);
|
||||
glShaderSourceARB (vertShader, 1, &vertShaderText, NULL);
|
||||
glCompileShaderARB (vertShader);
|
||||
|
||||
program = glCreateProgramObjectARB ();
|
||||
glAttachObjectARB (program, fragShader);
|
||||
glAttachObjectARB (program, vertShader);
|
||||
glLinkProgramARB (program);
|
||||
glUseProgramObjectARB (program);
|
||||
|
||||
uLightPos = glGetUniformLocationARB (program, "lightPos");
|
||||
uDiffuse = glGetUniformLocationARB (program, "diffuse");
|
||||
uSpecular = glGetUniformLocationARB (program, "specular");
|
||||
|
||||
glUniform4fvARB (uDiffuse, 1, diffuse);
|
||||
glUniform4fvARB (uSpecular, 1, specular);
|
||||
|
||||
glClearColor (0.3f, 0.3f, 0.3f, 0.0f);
|
||||
glEnable (GL_DEPTH_TEST);
|
||||
glEnable (GL_LIGHT0);
|
||||
glEnable (GL_LIGHTING);
|
||||
glMaterialfv (GL_FRONT_AND_BACK, GL_DIFFUSE, diffuse);
|
||||
glMaterialfv (GL_FRONT_AND_BACK, GL_SPECULAR, specular);
|
||||
glMaterialf (GL_FRONT_AND_BACK, GL_SHININESS, 20.0f);
|
||||
|
||||
printf ("GL_RENDERER = %s\n", (const char *) glGetString (GL_RENDERER));
|
||||
printf ("Press p to toggle between per-pixel and per-vertex lighting\n");
|
||||
}
|
||||
|
||||
int main (int argc, char *argv[])
|
||||
{
|
||||
glutInit (&argc, argv);
|
||||
glutInitWindowPosition ( 0, 0);
|
||||
glutInitWindowSize (200, 200);
|
||||
glutInitDisplayMode (GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH);
|
||||
glutCreateWindow (argv[0]);
|
||||
glutReshapeFunc (Reshape);
|
||||
glutKeyboardFunc (Key);
|
||||
glutSpecialFunc (SpecialKey);
|
||||
glutDisplayFunc (Redisplay);
|
||||
if (anim)
|
||||
glutIdleFunc (Idle);
|
||||
Init ();
|
||||
glutMainLoop ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -14,8 +14,6 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <GL/glut.h>
|
||||
#include <sys/time.h>
|
||||
#include <time.h>
|
||||
|
||||
#define COS(X) cos( (X) * 3.14159/180.0 )
|
||||
#define SIN(X) sin( (X) * 3.14159/180.0 )
|
||||
|
||||
1099
progs/demos/engine.c
Normal file
1099
progs/demos/engine.c
Normal file
File diff suppressed because it is too large
Load Diff
485
progs/demos/gearbox.c
Normal file
485
progs/demos/gearbox.c
Normal file
@@ -0,0 +1,485 @@
|
||||
/*
|
||||
* Use glCopyTexSubImage2D to draw animated gears on the sides of a box.
|
||||
*
|
||||
* Brian Paul
|
||||
* 27 January 2006
|
||||
*/
|
||||
|
||||
#include <math.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <GL/glut.h>
|
||||
|
||||
#ifndef M_PI
|
||||
#define M_PI 3.14159265
|
||||
#endif
|
||||
|
||||
static GLint WinWidth = 800, WinHeight = 500;
|
||||
static GLint TexWidth, TexHeight;
|
||||
static GLuint TexObj = 1;
|
||||
static GLenum IntFormat = GL_RGB;
|
||||
|
||||
static GLboolean WireFrame = GL_FALSE;
|
||||
|
||||
static GLint T0 = 0;
|
||||
static GLint Frames = 0;
|
||||
static GLint Win = 0;
|
||||
|
||||
static GLfloat ViewRotX = 20.0, ViewRotY = 30.0, ViewRotZ = 0.0;
|
||||
static GLint Gear1, Gear2, Gear3;
|
||||
static GLfloat GearRot = 0.0;
|
||||
static GLfloat CubeRot = 0.0;
|
||||
|
||||
|
||||
/**
|
||||
Draw a gear wheel. You'll probably want to call this function when
|
||||
building a display list since we do a lot of trig here.
|
||||
|
||||
Input: inner_radius - radius of hole at center
|
||||
outer_radius - radius at center of teeth
|
||||
width - width of gear
|
||||
teeth - number of teeth
|
||||
tooth_depth - depth of tooth
|
||||
**/
|
||||
static void
|
||||
gear(GLfloat inner_radius, GLfloat outer_radius, GLfloat width,
|
||||
GLint teeth, GLfloat tooth_depth)
|
||||
{
|
||||
GLint i;
|
||||
GLfloat r0, r1, r2;
|
||||
GLfloat angle, da;
|
||||
GLfloat u, v, len;
|
||||
|
||||
r0 = inner_radius;
|
||||
r1 = outer_radius - tooth_depth / 2.0;
|
||||
r2 = outer_radius + tooth_depth / 2.0;
|
||||
|
||||
da = 2.0 * M_PI / teeth / 4.0;
|
||||
|
||||
glShadeModel(GL_FLAT);
|
||||
|
||||
glNormal3f(0.0, 0.0, 1.0);
|
||||
|
||||
/* draw front face */
|
||||
glBegin(GL_QUAD_STRIP);
|
||||
for (i = 0; i <= teeth; i++) {
|
||||
angle = i * 2.0 * M_PI / teeth;
|
||||
glVertex3f(r0 * cos(angle), r0 * sin(angle), width * 0.5);
|
||||
glVertex3f(r1 * cos(angle), r1 * sin(angle), width * 0.5);
|
||||
if (i < teeth) {
|
||||
glVertex3f(r0 * cos(angle), r0 * sin(angle), width * 0.5);
|
||||
glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), width * 0.5);
|
||||
}
|
||||
}
|
||||
glEnd();
|
||||
|
||||
/* draw front sides of teeth */
|
||||
glBegin(GL_QUADS);
|
||||
da = 2.0 * M_PI / teeth / 4.0;
|
||||
for (i = 0; i < teeth; i++) {
|
||||
angle = i * 2.0 * M_PI / teeth;
|
||||
|
||||
glVertex3f(r1 * cos(angle), r1 * sin(angle), width * 0.5);
|
||||
glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), width * 0.5);
|
||||
glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), width * 0.5);
|
||||
glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), width * 0.5);
|
||||
}
|
||||
glEnd();
|
||||
|
||||
glNormal3f(0.0, 0.0, -1.0);
|
||||
|
||||
/* draw back face */
|
||||
glBegin(GL_QUAD_STRIP);
|
||||
for (i = 0; i <= teeth; i++) {
|
||||
angle = i * 2.0 * M_PI / teeth;
|
||||
glVertex3f(r1 * cos(angle), r1 * sin(angle), -width * 0.5);
|
||||
glVertex3f(r0 * cos(angle), r0 * sin(angle), -width * 0.5);
|
||||
if (i < teeth) {
|
||||
glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), -width * 0.5);
|
||||
glVertex3f(r0 * cos(angle), r0 * sin(angle), -width * 0.5);
|
||||
}
|
||||
}
|
||||
glEnd();
|
||||
|
||||
/* draw back sides of teeth */
|
||||
glBegin(GL_QUADS);
|
||||
da = 2.0 * M_PI / teeth / 4.0;
|
||||
for (i = 0; i < teeth; i++) {
|
||||
angle = i * 2.0 * M_PI / teeth;
|
||||
|
||||
glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), -width * 0.5);
|
||||
glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), -width * 0.5);
|
||||
glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), -width * 0.5);
|
||||
glVertex3f(r1 * cos(angle), r1 * sin(angle), -width * 0.5);
|
||||
}
|
||||
glEnd();
|
||||
|
||||
/* draw outward faces of teeth */
|
||||
glBegin(GL_QUAD_STRIP);
|
||||
for (i = 0; i < teeth; i++) {
|
||||
angle = i * 2.0 * M_PI / teeth;
|
||||
|
||||
glVertex3f(r1 * cos(angle), r1 * sin(angle), width * 0.5);
|
||||
glVertex3f(r1 * cos(angle), r1 * sin(angle), -width * 0.5);
|
||||
u = r2 * cos(angle + da) - r1 * cos(angle);
|
||||
v = r2 * sin(angle + da) - r1 * sin(angle);
|
||||
len = sqrt(u * u + v * v);
|
||||
u /= len;
|
||||
v /= len;
|
||||
glNormal3f(v, -u, 0.0);
|
||||
glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), width * 0.5);
|
||||
glVertex3f(r2 * cos(angle + da), r2 * sin(angle + da), -width * 0.5);
|
||||
glNormal3f(cos(angle), sin(angle), 0.0);
|
||||
glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), width * 0.5);
|
||||
glVertex3f(r2 * cos(angle + 2 * da), r2 * sin(angle + 2 * da), -width * 0.5);
|
||||
u = r1 * cos(angle + 3 * da) - r2 * cos(angle + 2 * da);
|
||||
v = r1 * sin(angle + 3 * da) - r2 * sin(angle + 2 * da);
|
||||
glNormal3f(v, -u, 0.0);
|
||||
glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), width * 0.5);
|
||||
glVertex3f(r1 * cos(angle + 3 * da), r1 * sin(angle + 3 * da), -width * 0.5);
|
||||
glNormal3f(cos(angle), sin(angle), 0.0);
|
||||
}
|
||||
|
||||
glVertex3f(r1 * cos(0), r1 * sin(0), width * 0.5);
|
||||
glVertex3f(r1 * cos(0), r1 * sin(0), -width * 0.5);
|
||||
|
||||
glEnd();
|
||||
|
||||
glShadeModel(GL_SMOOTH);
|
||||
|
||||
/* draw inside radius cylinder */
|
||||
glBegin(GL_QUAD_STRIP);
|
||||
for (i = 0; i <= teeth; i++) {
|
||||
angle = i * 2.0 * M_PI / teeth;
|
||||
glNormal3f(-cos(angle), -sin(angle), 0.0);
|
||||
glVertex3f(r0 * cos(angle), r0 * sin(angle), -width * 0.5);
|
||||
glVertex3f(r0 * cos(angle), r0 * sin(angle), width * 0.5);
|
||||
}
|
||||
glEnd();
|
||||
|
||||
}
|
||||
|
||||
static void
|
||||
cleanup(void)
|
||||
{
|
||||
glDeleteTextures(1, &TexObj);
|
||||
glDeleteLists(Gear1, 1);
|
||||
glDeleteLists(Gear2, 1);
|
||||
glDeleteLists(Gear3, 1);
|
||||
glutDestroyWindow(Win);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
DrawGears(void)
|
||||
{
|
||||
if (WireFrame) {
|
||||
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
|
||||
}
|
||||
|
||||
glPushMatrix();
|
||||
glRotatef(20/*ViewRotX*/, 1.0, 0.0, 0.0);
|
||||
glRotatef(ViewRotY, 0.0, 1.0, 0.0);
|
||||
glRotatef(ViewRotZ, 0.0, 0.0, 1.0);
|
||||
|
||||
glPushMatrix();
|
||||
glTranslatef(-3.0, -2.0, 0.0);
|
||||
glRotatef(GearRot, 0.0, 0.0, 1.0);
|
||||
glCallList(Gear1);
|
||||
glPopMatrix();
|
||||
|
||||
glPushMatrix();
|
||||
glTranslatef(3.1, -2.0, 0.0);
|
||||
glRotatef(-2.0 * GearRot - 9.0, 0.0, 0.0, 1.0);
|
||||
glCallList(Gear2);
|
||||
glPopMatrix();
|
||||
|
||||
glPushMatrix();
|
||||
glTranslatef(-3.1, 4.2, 0.0);
|
||||
glRotatef(-2.0 * GearRot - 25.0, 0.0, 0.0, 1.0);
|
||||
glCallList(Gear3);
|
||||
glPopMatrix();
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
DrawCube(void)
|
||||
{
|
||||
static const GLfloat texcoords[4][2] = {
|
||||
{ 0, 0 }, { 1, 0 }, { 1, 1 }, { 0, 1 }
|
||||
};
|
||||
static const GLfloat vertices[4][2] = {
|
||||
{ -1, -1 }, { 1, -1 }, { 1, 1 }, { -1, 1 }
|
||||
};
|
||||
static const GLfloat xforms[6][4] = {
|
||||
{ 0, 0, 1, 0 },
|
||||
{ 90, 0, 1, 0 },
|
||||
{ 180, 0, 1, 0 },
|
||||
{ 270, 0, 1, 0 },
|
||||
{ 90, 1, 0, 0 },
|
||||
{ -90, 1, 0, 0 }
|
||||
};
|
||||
static const GLfloat mat[4] = { 1.0, 1.0, 0.5, 1.0 };
|
||||
GLint i, j;
|
||||
|
||||
glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, mat);
|
||||
glEnable(GL_TEXTURE_2D);
|
||||
|
||||
glPushMatrix();
|
||||
glRotatef(ViewRotX, 1.0, 0.0, 0.0);
|
||||
glRotatef(15, 1, 0, 0);
|
||||
glRotatef(CubeRot, 0, 1, 0);
|
||||
glScalef(4, 4, 4);
|
||||
|
||||
for (i = 0; i < 6; i++) {
|
||||
glPushMatrix();
|
||||
glRotatef(xforms[i][0], xforms[i][1], xforms[i][2], xforms[i][3]);
|
||||
glTranslatef(0, 0, 1.1);
|
||||
glBegin(GL_POLYGON);
|
||||
glNormal3f(0, 0, 1);
|
||||
for (j = 0; j < 4; j++) {
|
||||
glTexCoord2fv(texcoords[j]);
|
||||
glVertex2fv(vertices[j]);
|
||||
}
|
||||
glEnd();
|
||||
glPopMatrix();
|
||||
}
|
||||
glPopMatrix();
|
||||
|
||||
glDisable(GL_TEXTURE_2D);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
draw(void)
|
||||
{
|
||||
float ar;
|
||||
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
glLoadIdentity();
|
||||
glTranslatef(0.0, 0.0, -40.0);
|
||||
|
||||
glDisable(GL_SCISSOR_TEST);
|
||||
glClear(GL_DEPTH_BUFFER_BIT);
|
||||
glEnable(GL_SCISSOR_TEST);
|
||||
|
||||
/* draw gears */
|
||||
glViewport(0, 0, TexWidth, TexHeight);
|
||||
glScissor(0, 0, TexWidth, TexHeight);
|
||||
glClearColor(0.5, 0.5, 0.8, 0.0);
|
||||
glClearColor(1, 1, 1, 0);
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glLoadIdentity();
|
||||
glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 60.0);
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
|
||||
DrawGears();
|
||||
|
||||
glCopyTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, 0, 0, TexWidth, TexHeight);
|
||||
|
||||
/* draw textured cube */
|
||||
glViewport(TexWidth, 0, WinWidth - TexWidth, WinHeight);
|
||||
glScissor(TexWidth, 0, WinWidth - TexWidth, WinHeight);
|
||||
glClearColor(0.5, 0.5, 0.8, 0.0);
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
|
||||
ar = (float) (WinWidth - TexWidth) / WinHeight;
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glLoadIdentity();
|
||||
glFrustum(-ar, ar, -1.0, 1.0, 5.0, 60.0);
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
|
||||
DrawCube();
|
||||
|
||||
/* finish up */
|
||||
glutSwapBuffers();
|
||||
|
||||
Frames++;
|
||||
{
|
||||
GLint t = glutGet(GLUT_ELAPSED_TIME);
|
||||
if (t - T0 >= 5000) {
|
||||
GLfloat seconds = (t - T0) / 1000.0;
|
||||
GLfloat fps = Frames / seconds;
|
||||
printf("%d frames in %6.3f seconds = %6.3f FPS\n", Frames, seconds, fps);
|
||||
T0 = t;
|
||||
Frames = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
idle(void)
|
||||
{
|
||||
static double t0 = -1.;
|
||||
double dt, t = glutGet(GLUT_ELAPSED_TIME) / 1000.0;
|
||||
if (t0 < 0.0)
|
||||
t0 = t;
|
||||
dt = t - t0;
|
||||
t0 = t;
|
||||
|
||||
/* fmod to prevent overflow */
|
||||
GearRot = fmod(GearRot + 70.0 * dt, 360.0); /* 70 deg/sec */
|
||||
CubeRot = fmod(CubeRot + 15.0 * dt, 360.0); /* 15 deg/sec */
|
||||
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
/* change view angle, exit upon ESC */
|
||||
static void
|
||||
key(unsigned char k, int x, int y)
|
||||
{
|
||||
(void) x;
|
||||
(void) y;
|
||||
switch (k) {
|
||||
case 'w':
|
||||
WireFrame = !WireFrame;
|
||||
break;
|
||||
case 'z':
|
||||
ViewRotZ += 5.0;
|
||||
break;
|
||||
case 'Z':
|
||||
ViewRotZ -= 5.0;
|
||||
break;
|
||||
case 27: /* Escape */
|
||||
cleanup();
|
||||
exit(0);
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
/* change view angle */
|
||||
static void
|
||||
special(int k, int x, int y)
|
||||
{
|
||||
(void) x;
|
||||
(void) y;
|
||||
switch (k) {
|
||||
case GLUT_KEY_UP:
|
||||
ViewRotX += 5.0;
|
||||
break;
|
||||
case GLUT_KEY_DOWN:
|
||||
ViewRotX -= 5.0;
|
||||
break;
|
||||
case GLUT_KEY_LEFT:
|
||||
ViewRotY += 5.0;
|
||||
break;
|
||||
case GLUT_KEY_RIGHT:
|
||||
ViewRotY -= 5.0;
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
/* new window size or exposure */
|
||||
static void
|
||||
reshape(int width, int height)
|
||||
{
|
||||
WinWidth = width;
|
||||
WinHeight = height;
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
init(int argc, char *argv[])
|
||||
{
|
||||
static GLfloat pos[4] = {5.0, 5.0, 10.0, 0.0};
|
||||
static GLfloat red[4] = {0.8, 0.1, 0.0, 1.0};
|
||||
static GLfloat green[4] = {0.0, 0.8, 0.2, 1.0};
|
||||
static GLfloat blue[4] = {0.2, 0.2, 1.0, 1.0};
|
||||
GLint i;
|
||||
|
||||
glLightfv(GL_LIGHT0, GL_POSITION, pos);
|
||||
#if 0
|
||||
glEnable(GL_CULL_FACE);
|
||||
#endif
|
||||
glEnable(GL_LIGHTING);
|
||||
glEnable(GL_LIGHT0);
|
||||
glEnable(GL_DEPTH_TEST);
|
||||
|
||||
/* make the gears */
|
||||
Gear1 = glGenLists(1);
|
||||
glNewList(Gear1, GL_COMPILE);
|
||||
glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, red);
|
||||
gear(1.0, 4.0, 1.0, 20, 0.7);
|
||||
glEndList();
|
||||
|
||||
Gear2 = glGenLists(1);
|
||||
glNewList(Gear2, GL_COMPILE);
|
||||
glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, green);
|
||||
gear(0.5, 2.0, 2.0, 10, 0.7);
|
||||
glEndList();
|
||||
|
||||
Gear3 = glGenLists(1);
|
||||
glNewList(Gear3, GL_COMPILE);
|
||||
glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, blue);
|
||||
gear(1.3, 2.0, 0.5, 10, 0.7);
|
||||
glEndList();
|
||||
|
||||
glEnable(GL_NORMALIZE);
|
||||
|
||||
/* xxx make size dynamic */
|
||||
TexWidth = 256;
|
||||
TexHeight = 256;
|
||||
|
||||
glBindTexture(GL_TEXTURE_2D, TexObj);
|
||||
glTexImage2D(GL_TEXTURE_2D, 0, IntFormat, TexWidth, TexHeight, 0,
|
||||
GL_RGBA, GL_UNSIGNED_BYTE, NULL);
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
|
||||
glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
|
||||
|
||||
for ( i=1; i<argc; i++ ) {
|
||||
if (strcmp(argv[i], "-info")==0) {
|
||||
printf("GL_RENDERER = %s\n", (char *) glGetString(GL_RENDERER));
|
||||
printf("GL_VERSION = %s\n", (char *) glGetString(GL_VERSION));
|
||||
printf("GL_VENDOR = %s\n", (char *) glGetString(GL_VENDOR));
|
||||
printf("GL_EXTENSIONS = %s\n", (char *) glGetString(GL_EXTENSIONS));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
visible(int vis)
|
||||
{
|
||||
if (vis == GLUT_VISIBLE)
|
||||
glutIdleFunc(idle);
|
||||
else
|
||||
glutIdleFunc(NULL);
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
glutInit(&argc, argv);
|
||||
glutInitDisplayMode(GLUT_RGB | GLUT_DEPTH | GLUT_DOUBLE);
|
||||
|
||||
glutInitWindowSize(WinWidth, WinHeight);
|
||||
Win = glutCreateWindow("gearbox");
|
||||
init(argc, argv);
|
||||
|
||||
glutDisplayFunc(draw);
|
||||
glutReshapeFunc(reshape);
|
||||
glutKeyboardFunc(key);
|
||||
glutSpecialFunc(special);
|
||||
glutVisibilityFunc(visible);
|
||||
|
||||
glutMainLoop();
|
||||
return 0; /* ANSI C requires main to return int. */
|
||||
}
|
||||
@@ -25,6 +25,8 @@
|
||||
#include <GL/glut.h>
|
||||
|
||||
#include "readtex.h"
|
||||
#include "trackball.h"
|
||||
|
||||
|
||||
#define SPECULAR_TEXTURE_FILE "../images/reflect.rgb"
|
||||
#define BASE_TEXTURE_FILE "../images/tile.rgb"
|
||||
@@ -38,13 +40,13 @@
|
||||
/* for convolution */
|
||||
#define FILTER_SIZE 7
|
||||
|
||||
static GLint WinWidth = 500, WinHeight = 500;
|
||||
static GLuint CylinderObj = 0;
|
||||
static GLuint TeapotObj = 0;
|
||||
static GLuint Object = 0;
|
||||
static GLboolean Animate = GL_TRUE;
|
||||
|
||||
static GLfloat Xrot = 0.0, Yrot = 0.0, Zrot = 0.0;
|
||||
static GLfloat DXrot = 20.0, DYrot = 50.;
|
||||
static float CurQuat[4] = { 0, 0, 0, 1 };
|
||||
|
||||
static GLfloat Black[4] = { 0, 0, 0, 0 };
|
||||
static GLfloat White[4] = { 1, 1, 1, 1 };
|
||||
@@ -54,6 +56,10 @@ static GLfloat Shininess = 6;
|
||||
static GLuint BaseTexture, SpecularTexture;
|
||||
static GLboolean DoSpecTexture = GL_TRUE;
|
||||
|
||||
static GLboolean ButtonDown = GL_FALSE;
|
||||
static GLint ButtonX, ButtonY;
|
||||
|
||||
|
||||
/* performance info */
|
||||
static GLint T0 = 0;
|
||||
static GLint Frames = 0;
|
||||
@@ -61,29 +67,31 @@ static GLint Frames = 0;
|
||||
|
||||
static void Idle( void )
|
||||
{
|
||||
static const float yAxis[3] = {0, 1, 0};
|
||||
static double t0 = -1.;
|
||||
float quat[4];
|
||||
double dt, t = glutGet(GLUT_ELAPSED_TIME) / 1000.0;
|
||||
if (t0 < 0.0)
|
||||
t0 = t;
|
||||
dt = t - t0;
|
||||
t0 = t;
|
||||
|
||||
if (Animate) {
|
||||
Xrot += DXrot*dt;
|
||||
Yrot += DYrot*dt;
|
||||
glutPostRedisplay();
|
||||
}
|
||||
axis_to_quat(yAxis, 2.0 * dt, quat);
|
||||
add_quats(quat, CurQuat, CurQuat);
|
||||
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void Display( void )
|
||||
{
|
||||
GLfloat rot[4][4];
|
||||
|
||||
glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
|
||||
|
||||
glPushMatrix();
|
||||
glRotatef(Xrot, 1.0, 0.0, 0.0);
|
||||
glRotatef(Yrot, 0.0, 1.0, 0.0);
|
||||
glRotatef(Zrot, 0.0, 0.0, 1.0);
|
||||
build_rotmatrix(rot, CurQuat);
|
||||
glMultMatrixf(&rot[0][0]);
|
||||
|
||||
/* First pass: diffuse lighting with base texture */
|
||||
glMaterialfv(GL_FRONT, GL_DIFFUSE, Diffuse);
|
||||
@@ -134,6 +142,8 @@ static void Reshape( int width, int height )
|
||||
{
|
||||
GLfloat h = 30.0;
|
||||
GLfloat w = h * width / height;
|
||||
WinWidth = width;
|
||||
WinHeight = height;
|
||||
glViewport( 0, 0, width, height );
|
||||
glMatrixMode( GL_PROJECTION );
|
||||
glLoadIdentity();
|
||||
@@ -198,6 +208,7 @@ static void Key( unsigned char key, int x, int y )
|
||||
glMaterialf(GL_FRONT, GL_SHININESS, Shininess);
|
||||
printf("Shininess = %g\n", Shininess);
|
||||
break;
|
||||
case 'a':
|
||||
case ' ':
|
||||
ToggleAnimate();
|
||||
break;
|
||||
@@ -209,33 +220,44 @@ static void Key( unsigned char key, int x, int y )
|
||||
}
|
||||
|
||||
|
||||
static void SpecialKey( int key, int x, int y )
|
||||
static void
|
||||
MouseMotion(int x, int y)
|
||||
{
|
||||
float step = 3.0;
|
||||
(void) x;
|
||||
(void) y;
|
||||
if (ButtonDown) {
|
||||
float x0 = (2.0 * ButtonX - WinWidth) / WinWidth;
|
||||
float y0 = (WinHeight - 2.0 * ButtonY) / WinHeight;
|
||||
float x1 = (2.0 * x - WinWidth) / WinWidth;
|
||||
float y1 = (WinHeight - 2.0 * y) / WinHeight;
|
||||
float q[4];
|
||||
|
||||
switch (key) {
|
||||
case GLUT_KEY_UP:
|
||||
Xrot += step;
|
||||
break;
|
||||
case GLUT_KEY_DOWN:
|
||||
Xrot -= step;
|
||||
break;
|
||||
case GLUT_KEY_LEFT:
|
||||
Yrot += step;
|
||||
break;
|
||||
case GLUT_KEY_RIGHT:
|
||||
Yrot -= step;
|
||||
break;
|
||||
trackball(q, x0, y0, x1, y1);
|
||||
ButtonX = x;
|
||||
ButtonY = y;
|
||||
add_quats(q, CurQuat, CurQuat);
|
||||
|
||||
glutPostRedisplay();
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
MouseButton(int button, int state, int x, int y)
|
||||
{
|
||||
if (button == GLUT_LEFT_BUTTON && state == GLUT_DOWN) {
|
||||
ButtonDown = GL_TRUE;
|
||||
ButtonX = x;
|
||||
ButtonY = y;
|
||||
}
|
||||
else if (button == GLUT_LEFT_BUTTON && state == GLUT_UP) {
|
||||
ButtonDown = GL_FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void Init( int argc, char *argv[] )
|
||||
{
|
||||
GLboolean convolve = GL_FALSE;
|
||||
GLboolean fullscreen = GL_FALSE;
|
||||
int i;
|
||||
|
||||
for (i = 1; i < argc; i++) {
|
||||
@@ -248,8 +270,13 @@ static void Init( int argc, char *argv[] )
|
||||
else if (strcmp(argv[i], "-c")==0) {
|
||||
convolve = GL_TRUE;
|
||||
}
|
||||
else if (strcmp(argv[i], "-f")==0) {
|
||||
fullscreen = GL_TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
if (fullscreen)
|
||||
glutFullScreen();
|
||||
|
||||
/* Cylinder object */
|
||||
{
|
||||
@@ -408,20 +435,16 @@ static void Init( int argc, char *argv[] )
|
||||
int main( int argc, char *argv[] )
|
||||
{
|
||||
glutInit( &argc, argv );
|
||||
glutInitWindowPosition(0, 0);
|
||||
glutInitWindowSize( 500, 500 );
|
||||
|
||||
glutInitWindowSize(WinWidth, WinHeight);
|
||||
glutInitDisplayMode( GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH );
|
||||
|
||||
glutCreateWindow(argv[0] );
|
||||
|
||||
Init(argc, argv);
|
||||
|
||||
glutReshapeFunc( Reshape );
|
||||
glutKeyboardFunc( Key );
|
||||
glutSpecialFunc( SpecialKey );
|
||||
glutDisplayFunc( Display );
|
||||
glutIdleFunc( Idle );
|
||||
glutMotionFunc(MouseMotion);
|
||||
glutMouseFunc(MouseButton);
|
||||
if (Animate)
|
||||
glutIdleFunc( Idle );
|
||||
|
||||
glutCreateMenu(ModeMenu);
|
||||
glutAddMenuEntry("Toggle Highlight", DO_SPEC_TEXTURE);
|
||||
@@ -430,6 +453,8 @@ int main( int argc, char *argv[] )
|
||||
glutAddMenuEntry("Quit", QUIT);
|
||||
glutAttachMenu(GLUT_RIGHT_BUTTON);
|
||||
|
||||
Init(argc, argv);
|
||||
|
||||
glutMainLoop();
|
||||
return 0;
|
||||
}
|
||||
|
||||
185
progs/demos/glslnoise.c
Executable file
185
progs/demos/glslnoise.c
Executable file
@@ -0,0 +1,185 @@
|
||||
/*
|
||||
* GLSL noise demo.
|
||||
*
|
||||
* Michal Krol
|
||||
* 20 February 2006
|
||||
*
|
||||
* Based on the original demo by:
|
||||
* Stefan Gustavson (stegu@itn.liu.se) 2004, 2005
|
||||
*/
|
||||
|
||||
#ifdef WIN32
|
||||
#include <windows.h>
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glut.h>
|
||||
#include <GL/glext.h>
|
||||
|
||||
#ifdef WIN32
|
||||
#define GETPROCADDRESS(F) wglGetProcAddress(F)
|
||||
#else
|
||||
#define GETPROCADDRESS(F) glutGetProcAddress(F)
|
||||
#endif
|
||||
|
||||
static GLhandleARB fragShader;
|
||||
static GLhandleARB vertShader;
|
||||
static GLhandleARB program;
|
||||
|
||||
static GLint uTime;
|
||||
|
||||
static GLfloat u_time = 0.0f;
|
||||
|
||||
static PFNGLCREATESHADEROBJECTARBPROC glCreateShaderObjectARB = NULL;
|
||||
static PFNGLSHADERSOURCEARBPROC glShaderSourceARB = NULL;
|
||||
static PFNGLCOMPILESHADERARBPROC glCompileShaderARB = NULL;
|
||||
static PFNGLCREATEPROGRAMOBJECTARBPROC glCreateProgramObjectARB = NULL;
|
||||
static PFNGLATTACHOBJECTARBPROC glAttachObjectARB = NULL;
|
||||
static PFNGLLINKPROGRAMARBPROC glLinkProgramARB = NULL;
|
||||
static PFNGLUSEPROGRAMOBJECTARBPROC glUseProgramObjectARB = NULL;
|
||||
static PFNGLGETUNIFORMLOCATIONARBPROC glGetUniformLocationARB = NULL;
|
||||
static PFNGLUNIFORM1FARBPROC glUniform1fARB = NULL;
|
||||
|
||||
static void Redisplay (void)
|
||||
{
|
||||
glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
glUniform1fARB (uTime, u_time);
|
||||
|
||||
glPushMatrix ();
|
||||
glutSolidSphere (2.0, 20, 10);
|
||||
glPopMatrix ();
|
||||
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
static void Idle (void)
|
||||
{
|
||||
u_time += 0.1f;
|
||||
glutPostRedisplay ();
|
||||
}
|
||||
|
||||
static void Reshape (int width, int height)
|
||||
{
|
||||
glViewport (0, 0, width, height);
|
||||
glMatrixMode (GL_PROJECTION);
|
||||
glLoadIdentity ();
|
||||
glFrustum (-1.0, 1.0, -1.0, 1.0, 5.0, 25.0);
|
||||
glMatrixMode (GL_MODELVIEW);
|
||||
glLoadIdentity ();
|
||||
glTranslatef (0.0f, 0.0f, -15.0f);
|
||||
}
|
||||
|
||||
static void Key (unsigned char key, int x, int y)
|
||||
{
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch (key)
|
||||
{
|
||||
case 27:
|
||||
exit(0);
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay ();
|
||||
}
|
||||
|
||||
static void Init (void)
|
||||
{
|
||||
static const char *fragShaderText =
|
||||
"uniform float time;\n"
|
||||
"void main () {\n"
|
||||
" gl_FragColor = gl_Color * vec4 ((0.5 + 0.5 * vec3 (noise1 (\n"
|
||||
" vec4 (4.0 * gl_TexCoord[0].xyz, 0.5 * time)))), 1.0);\n"
|
||||
"}\n"
|
||||
;
|
||||
static const char *vertShaderText =
|
||||
"void main () {\n"
|
||||
" gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;\n"
|
||||
" gl_TexCoord[0] = gl_Vertex;\n"
|
||||
" gl_FrontColor = gl_Color;\n"
|
||||
"}\n"
|
||||
;
|
||||
|
||||
if (!glutExtensionSupported ("GL_ARB_fragment_shader"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_fragment_shader\n");
|
||||
exit(1);
|
||||
}
|
||||
if (!glutExtensionSupported ("GL_ARB_shader_objects"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_shader_objects\n");
|
||||
exit(1);
|
||||
}
|
||||
if (!glutExtensionSupported ("GL_ARB_shading_language_100"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_shading_language_100\n");
|
||||
exit(1);
|
||||
}
|
||||
if (!glutExtensionSupported ("GL_ARB_vertex_shader"))
|
||||
{
|
||||
printf ("Sorry, this demo requires GL_ARB_vertex_shader\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
glCreateShaderObjectARB = (PFNGLCREATESHADEROBJECTARBPROC)
|
||||
GETPROCADDRESS("glCreateShaderObjectARB");
|
||||
glShaderSourceARB = (PFNGLSHADERSOURCEARBPROC)
|
||||
GETPROCADDRESS("glShaderSourceARB");
|
||||
glCompileShaderARB = (PFNGLCOMPILESHADERARBPROC)
|
||||
GETPROCADDRESS("glCompileShaderARB");
|
||||
glCreateProgramObjectARB = (PFNGLCREATEPROGRAMOBJECTARBPROC)
|
||||
GETPROCADDRESS("glCreateProgramObjectARB");
|
||||
glAttachObjectARB = (PFNGLATTACHOBJECTARBPROC)
|
||||
GETPROCADDRESS("glAttachObjectARB");
|
||||
glLinkProgramARB = (PFNGLLINKPROGRAMARBPROC)
|
||||
GETPROCADDRESS ("glLinkProgramARB");
|
||||
glUseProgramObjectARB = (PFNGLUSEPROGRAMOBJECTARBPROC)
|
||||
GETPROCADDRESS("glUseProgramObjectARB");
|
||||
|
||||
glGetUniformLocationARB = (PFNGLGETUNIFORMLOCATIONARBPROC)
|
||||
GETPROCADDRESS("glGetUniformLocationARB");
|
||||
glUniform1fARB = (PFNGLUNIFORM1FARBPROC)
|
||||
GETPROCADDRESS("glUniform1fARB");
|
||||
|
||||
fragShader = glCreateShaderObjectARB (GL_FRAGMENT_SHADER_ARB);
|
||||
glShaderSourceARB (fragShader, 1, &fragShaderText, NULL);
|
||||
glCompileShaderARB (fragShader);
|
||||
|
||||
vertShader = glCreateShaderObjectARB (GL_VERTEX_SHADER_ARB);
|
||||
glShaderSourceARB (vertShader, 1, &vertShaderText, NULL);
|
||||
glCompileShaderARB (vertShader);
|
||||
|
||||
program = glCreateProgramObjectARB ();
|
||||
glAttachObjectARB (program, fragShader);
|
||||
glAttachObjectARB (program, vertShader);
|
||||
glLinkProgramARB (program);
|
||||
glUseProgramObjectARB (program);
|
||||
|
||||
uTime = glGetUniformLocationARB (program, "time");
|
||||
|
||||
glClearColor (0.0f, 0.1f, 0.3f, 1.0f);
|
||||
glEnable (GL_CULL_FACE);
|
||||
glEnable (GL_DEPTH_TEST);
|
||||
|
||||
printf ("GL_RENDERER = %s\n", (const char *) glGetString (GL_RENDERER));
|
||||
}
|
||||
|
||||
int main (int argc, char *argv[])
|
||||
{
|
||||
glutInit (&argc, argv);
|
||||
glutInitWindowPosition ( 0, 0);
|
||||
glutInitWindowSize (200, 200);
|
||||
glutInitDisplayMode (GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH);
|
||||
glutCreateWindow (argv[0]);
|
||||
glutReshapeFunc (Reshape);
|
||||
glutKeyboardFunc (Key);
|
||||
glutDisplayFunc (Redisplay);
|
||||
glutIdleFunc (Idle);
|
||||
Init ();
|
||||
glutMainLoop ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -49,7 +49,9 @@ static GLint Frames = 0;
|
||||
|
||||
#define clamp255(a) ( (a)<(0.0f) ? (0.0f) : ((a)>(255.0f) ? (255.0f) : (a)) )
|
||||
|
||||
#ifndef fabs
|
||||
#define fabs(x) ((x)<0.0f?-(x):(x))
|
||||
#endif
|
||||
|
||||
#define vequ(a,b) { (a)[0]=(b)[0]; (a)[1]=(b)[1]; (a)[2]=(b)[2]; }
|
||||
#define vsub(a,b,c) { (a)[0]=(b)[0]-(c)[0]; (a)[1]=(b)[1]-(c)[1]; (a)[2]=(b)[2]-(c)[2]; }
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user