Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
f6e80017
Commit
f6e80017
authored
Sep 15, 2021
by
Alexandros Frantzis
Committed by
Alexandre Julliard
Nov 17, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winewayland.drv: Add skeleton Vulkan driver.
parent
a85055ee
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
84 additions
and
1 deletion
+84
-1
Makefile.in
dlls/winewayland.drv/Makefile.in
+1
-0
vulkan.c
dlls/winewayland.drv/vulkan.c
+80
-0
waylanddrv.h
dlls/winewayland.drv/waylanddrv.h
+1
-0
waylanddrv_main.c
dlls/winewayland.drv/waylanddrv_main.c
+2
-1
No files found.
dlls/winewayland.drv/Makefile.in
View file @
f6e80017
...
...
@@ -8,6 +8,7 @@ SOURCES = \
dllmain.c
\
version.rc
\
viewporter.xml
\
vulkan.c
\
wayland.c
\
wayland_keyboard.c
\
wayland_output.c
\
...
...
dlls/winewayland.drv/vulkan.c
0 → 100644
View file @
f6e80017
/* WAYLANDDRV Vulkan implementation
*
* Copyright 2017 Roderick Colenbrander
* Copyright 2021 Alexandros Frantzis
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#if 0
#pragma makedep unix
#endif
#include "config.h"
#include <dlfcn.h>
#include "waylanddrv.h"
#include "wine/debug.h"
#define VK_NO_PROTOTYPES
#define WINE_VK_HOST
#include "wine/vulkan.h"
#include "wine/vulkan_driver.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
vulkan
);
#ifdef SONAME_LIBVULKAN
static
void
*
vulkan_handle
;
static
void
wine_vk_init
(
void
)
{
if
(
!
(
vulkan_handle
=
dlopen
(
SONAME_LIBVULKAN
,
RTLD_NOW
)))
ERR
(
"Failed to load %s.
\n
"
,
SONAME_LIBVULKAN
);
}
static
const
struct
vulkan_funcs
vulkan_funcs
;
/**********************************************************************
* WAYLAND_wine_get_vulkan_driver
*/
const
struct
vulkan_funcs
*
WAYLAND_wine_get_vulkan_driver
(
UINT
version
)
{
static
pthread_once_t
init_once
=
PTHREAD_ONCE_INIT
;
if
(
version
!=
WINE_VULKAN_DRIVER_VERSION
)
{
ERR
(
"version mismatch, vulkan wants %u but driver has %u
\n
"
,
version
,
WINE_VULKAN_DRIVER_VERSION
);
return
NULL
;
}
pthread_once
(
&
init_once
,
wine_vk_init
);
if
(
vulkan_handle
)
return
&
vulkan_funcs
;
return
NULL
;
}
#else
/* No vulkan */
const
struct
vulkan_funcs
*
WAYLAND_wine_get_vulkan_driver
(
UINT
version
)
{
ERR
(
"Wine was built without Vulkan support.
\n
"
);
return
NULL
;
}
#endif
/* SONAME_LIBVULKAN */
dlls/winewayland.drv/waylanddrv.h
View file @
f6e80017
...
...
@@ -297,5 +297,6 @@ void WAYLAND_WindowPosChanged(HWND hwnd, HWND insert_after, UINT swp_flags,
BOOL
WAYLAND_WindowPosChanging
(
HWND
hwnd
,
HWND
insert_after
,
UINT
swp_flags
,
const
RECT
*
window_rect
,
const
RECT
*
client_rect
,
RECT
*
visible_rect
,
struct
window_surface
**
surface
)
DECLSPEC_HIDDEN
;
const
struct
vulkan_funcs
*
WAYLAND_wine_get_vulkan_driver
(
UINT
version
)
DECLSPEC_HIDDEN
;
#endif
/* __WINE_WAYLANDDRV_H */
dlls/winewayland.drv/waylanddrv_main.c
View file @
f6e80017
...
...
@@ -38,7 +38,8 @@ static const struct user_driver_funcs waylanddrv_funcs =
.
pUpdateDisplayDevices
=
WAYLAND_UpdateDisplayDevices
,
.
pWindowMessage
=
WAYLAND_WindowMessage
,
.
pWindowPosChanged
=
WAYLAND_WindowPosChanged
,
.
pWindowPosChanging
=
WAYLAND_WindowPosChanging
.
pWindowPosChanging
=
WAYLAND_WindowPosChanging
,
.
pwine_get_vulkan_driver
=
WAYLAND_wine_get_vulkan_driver
,
};
static
NTSTATUS
waylanddrv_unix_init
(
void
*
arg
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment