|
36 | 36 | extern "C" { |
37 | 37 | #endif |
38 | 38 |
|
39 | | -/** |
40 | | - * \defgroup api_compat Compatibility API |
41 | | - * |
42 | | - * The Compatibility API allows older programs that are not ported to |
43 | | - * the current API to still build and run correctly. In particular, |
44 | | - * this exposes older API to allow for backwards source compatibility. |
45 | | - * |
46 | | - * @{ |
47 | | - */ |
48 | | - |
49 | | -/** |
50 | | - * Makes a string literal out of the macro argument |
51 | | - */ |
52 | | -#define VA_CPP_HELPER_STRINGIFY(x) \ |
53 | | - VA_CPP_HELPER_STRINGIFY_(x) |
54 | | -#define VA_CPP_HELPER_STRINGIFY_(x) \ |
55 | | - #x |
56 | | - |
57 | | -/** |
58 | | - * Concatenates two macro arguments at preprocessing time. |
59 | | - */ |
60 | | -#define VA_CPP_HELPER_CONCAT(a, b) \ |
61 | | - VA_CPP_HELPER_CONCAT_(a, b) |
62 | | -#define VA_CPP_HELPER_CONCAT_(a, b) \ |
63 | | - a ## b |
64 | | - |
65 | | -/** |
66 | | - * Generates the number of macro arguments at preprocessing time. |
67 | | - * <http://groups.google.com/group/comp.std.c/browse_thread/thread/77ee8c8f92e4a3fb/346fc464319b1ee5> |
68 | | - * |
69 | | - * Note: this doesn't work for macros with no arguments |
70 | | - */ |
71 | | -#define VA_CPP_HELPER_N_ARGS(...) \ |
72 | | - VA_CPP_HELPER_N_ARGS_(__VA_ARGS__, VA_CPP_HELPER_N_ARGS_LIST_REV()) |
73 | | -#define VA_CPP_HELPER_N_ARGS_(...) \ |
74 | | - VA_CPP_HELPER_N_ARGS_LIST(__VA_ARGS__) |
75 | | -#define VA_CPP_HELPER_N_ARGS_LIST(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a12, a13, a14, a15, a16, N, ...) N |
76 | | -#define VA_CPP_HELPER_N_ARGS_LIST_REV() \ |
77 | | - 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0 |
78 | | - |
79 | | -/** |
80 | | - * Generates a versioned function alias. |
81 | | - * |
82 | | - * VA_CPP_HELPER_ALIAS(vaSomeFunction, 0,32,0) will generate |
83 | | - * .symber vaSomeFunction_0_32_0, vaSomeFunction@VA_API_0.32.0 |
84 | | - */ |
85 | | -#define VA_CPP_HELPER_ALIAS(func, major, minor, micro) \ |
86 | | - VA_CPP_HELPER_ALIAS_(func, major, minor, micro, "@") |
87 | | -#define VA_CPP_HELPER_ALIAS_DEFAULT(func, major, minor, micro) \ |
88 | | - VA_CPP_HELPER_ALIAS_(func, major, minor, micro, "@@") |
89 | | -#define VA_CPP_HELPER_ALIAS_(func, major, minor, micro, binding) \ |
90 | | - asm(".symver " #func "_" #major "_" #minor "_" #micro ", " \ |
91 | | - #func binding "VA_API_" #major "." #minor "." #micro) |
92 | | - |
93 | | -/* vaCreateSurfaces() */ |
94 | | - |
95 | | -#ifndef VA_COMPAT_DISABLED |
96 | | -#define vaCreateSurfaces(dpy, ...) \ |
97 | | - VA_CPP_HELPER_CONCAT(vaCreateSurfaces, \ |
98 | | - VA_CPP_HELPER_N_ARGS(dpy, __VA_ARGS__)) \ |
99 | | - (dpy, __VA_ARGS__) |
100 | | -#endif |
101 | | - |
102 | | -#define vaCreateSurfaces6(dpy, width, height, format, num_surfaces, surfaces) \ |
103 | | - (vaCreateSurfaces)(dpy, format, width, height, surfaces, num_surfaces, \ |
104 | | - NULL, 0) |
105 | | - |
106 | | -#define vaCreateSurfaces8(dpy, format, width, height, surfaces, num_surfaces, attribs, num_attribs) \ |
107 | | - (vaCreateSurfaces)(dpy, format, width, height, surfaces, num_surfaces, \ |
108 | | - attribs, num_attribs) |
109 | | - |
110 | | -/*@}*/ |
| 39 | +#warning deprecated, keep a empty file because some application may include it |
111 | 40 |
|
112 | 41 | #ifdef __cplusplus |
113 | 42 | } |
|
0 commit comments