mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-04-13 05:43:18 -07:00
vkd3d: Introduce API versions.
For backwards compatibility. Newer vkd3d versions may report more capabilities, but some of those may also require newer vkd3d APIs in order to use them. That's an issue for a vkd3d user like Wine, where reporting more capabilities may cause the application to try to use APIs that are not implemented in that version of Wine. Note that using ELF symbol versioning would have solved the issue for existing binaries compiled against older versions of vkd3d, but not for older source compiled against newer versions of vkd3d. Users of vkd3d-utils should define VKD3D_UTILS_API_VERSION to the vkd3d API version they wish to target. Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
committed by
Alexandre Julliard
parent
11980c3944
commit
3777eb4e5c
@ -58,9 +58,16 @@ static HRESULT signal_event(HANDLE event)
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static const struct vkd3d_application_info instance_default_application_info =
|
||||
{
|
||||
.type = VKD3D_STRUCTURE_TYPE_APPLICATION_INFO,
|
||||
.api_version = VKD3D_API_VERSION_1_2,
|
||||
};
|
||||
|
||||
static const struct vkd3d_instance_create_info instance_default_create_info =
|
||||
{
|
||||
.type = VKD3D_STRUCTURE_TYPE_INSTANCE_CREATE_INFO,
|
||||
.next = &instance_default_application_info,
|
||||
.wchar_size = sizeof(WCHAR),
|
||||
.pfn_signal_event = signal_event,
|
||||
};
|
||||
@ -1078,6 +1085,7 @@ static void test_application_info(void)
|
||||
app_info.engine_version = 0;
|
||||
app_info.application_name = NULL;
|
||||
app_info.application_version = 0;
|
||||
app_info.api_version = VKD3D_API_VERSION_1_0;
|
||||
|
||||
create_info = instance_default_create_info;
|
||||
create_info.next = &app_info;
|
||||
|
Reference in New Issue
Block a user