You've already forked wine-staging
mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-04-13 14:42:51 -07:00
Compare commits
80 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
76900de5bb | ||
|
776306026a | ||
|
c4c72e90ab | ||
|
f8c3c9a6f8 | ||
|
39678da196 | ||
|
be8a670b5b | ||
|
4d11895651 | ||
|
bf3fbb7bdf | ||
|
160a5024b4 | ||
|
f36c844f11 | ||
|
732ab97a7e | ||
|
46fbb7d31e | ||
|
44d1a45e98 | ||
|
f23b6cb7dc | ||
|
4d01e48843 | ||
|
90109a5fc5 | ||
|
e8abb98858 | ||
|
56b4eed468 | ||
|
755d1ca559 | ||
|
001ea51fb5 | ||
|
db80e169c7 | ||
|
7757a2d4f6 | ||
|
1a980ed93d | ||
|
528306ccb6 | ||
|
7fe7d87f09 | ||
|
805f2e9252 | ||
|
18f7125892 | ||
|
f993930ee6 | ||
|
2a9e87abea | ||
|
af97ec8ce0 | ||
|
b14430433d | ||
|
f9d1798edb | ||
|
e5da84dc36 | ||
|
75c7644c3d | ||
|
7c7868f4bb | ||
|
d1a8b6bc14 | ||
|
53b02cd0ee | ||
|
36b8b8cc65 | ||
|
13536af59c | ||
|
a6f3bd989e | ||
|
0830db32cd | ||
|
cd7d77fe36 | ||
|
2e9977f4ac | ||
|
a1246b5e92 | ||
|
676dd02663 | ||
|
648db00708 | ||
|
6bfaa3b0a5 | ||
|
cbf7f73313 | ||
|
c896e5cb69 | ||
|
4d65ec9456 | ||
|
d14250ab03 | ||
|
789f5c7c64 | ||
|
69cb47fd36 | ||
|
8450903b5c | ||
|
ffe93505d2 | ||
|
5213d551f8 | ||
|
e61a75f75f | ||
|
7428dd8656 | ||
|
40e84b052b | ||
|
92b2688a74 | ||
|
f7eec766a5 | ||
|
b4e0277488 | ||
|
f54b943bca | ||
|
6138369b4f | ||
|
59fe96c14c | ||
|
afdf5020ff | ||
|
2fc5c88068 | ||
|
ad3de029e7 | ||
|
4ff3984c49 | ||
|
deeaa04aa4 | ||
|
592b853fe4 | ||
|
26f14c2ddd | ||
|
57204d77d9 | ||
|
37e000145f | ||
|
d68ab574f5 | ||
|
469cbe7ed8 | ||
|
1fe141dd3e | ||
|
a3b99d730d | ||
|
de7c2faf80 | ||
|
8b2fd051c9 |
@@ -1,4 +1,4 @@
|
||||
From d216f85a593a09e7983d9178fb3e1f20bfcf08cc Mon Sep 17 00:00:00 2001
|
||||
From 63d2046a8f4388fbc7c12a07ae5f412fccc1b202 Mon Sep 17 00:00:00 2001
|
||||
From: Sebastian Lackner <sebastian@fds-team.de>
|
||||
Date: Thu, 29 May 2014 23:43:45 +0200
|
||||
Subject: [PATCH] loader: Add commandline option --patches to show the patch
|
||||
@@ -14,7 +14,7 @@ Subject: [PATCH] loader: Add commandline option --patches to show the patch
|
||||
6 files changed, 58 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dlls/ntdll/misc.c b/dlls/ntdll/misc.c
|
||||
index c29a1c26c..8906e1942 100644
|
||||
index c29a1c26c26..8906e194272 100644
|
||||
--- a/dlls/ntdll/misc.c
|
||||
+++ b/dlls/ntdll/misc.c
|
||||
@@ -60,6 +60,14 @@ const char * CDECL NTDLL_wine_get_version(void)
|
||||
@@ -33,10 +33,10 @@ index c29a1c26c..8906e1942 100644
|
||||
* wine_get_build_id (NTDLL.@)
|
||||
*/
|
||||
diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec
|
||||
index 7aa953ca6..cf7d5b6f9 100644
|
||||
index e61a2578da5..52db67fd978 100644
|
||||
--- a/dlls/ntdll/ntdll.spec
|
||||
+++ b/dlls/ntdll/ntdll.spec
|
||||
@@ -1566,6 +1566,7 @@
|
||||
@@ -1571,6 +1571,7 @@
|
||||
|
||||
# Version
|
||||
@ cdecl wine_get_version() NTDLL_wine_get_version
|
||||
@@ -45,7 +45,7 @@ index 7aa953ca6..cf7d5b6f9 100644
|
||||
@ cdecl wine_get_host_version(ptr ptr) NTDLL_wine_get_host_version
|
||||
|
||||
diff --git a/include/wine/library.h b/include/wine/library.h
|
||||
index a6fe28059..511bf4722 100644
|
||||
index f338c4da190..1f992da6062 100644
|
||||
--- a/include/wine/library.h
|
||||
+++ b/include/wine/library.h
|
||||
@@ -47,6 +47,7 @@ extern const char *wine_get_data_dir(void);
|
||||
@@ -57,7 +57,7 @@ index a6fe28059..511bf4722 100644
|
||||
extern void wine_init_argv0_path( const char *argv0 );
|
||||
extern void wine_exec_wine_binary( const char *name, char **argv, const char *env_var );
|
||||
diff --git a/libs/wine/config.c b/libs/wine/config.c
|
||||
index 2a3314cbf..5b66c063d 100644
|
||||
index 2a3314cbfda..5b66c063db6 100644
|
||||
--- a/libs/wine/config.c
|
||||
+++ b/libs/wine/config.c
|
||||
@@ -504,6 +504,12 @@ const char *wine_get_version(void)
|
||||
@@ -74,22 +74,22 @@ index 2a3314cbf..5b66c063d 100644
|
||||
const char *wine_get_build_id(void)
|
||||
{
|
||||
diff --git a/libs/wine/wine.map b/libs/wine/wine.map
|
||||
index 3f2c430fa..ca46979f5 100644
|
||||
index 7ea849b908e..a7359ee7872 100644
|
||||
--- a/libs/wine/wine.map
|
||||
+++ b/libs/wine/wine.map
|
||||
@@ -28,6 +28,7 @@ WINE_1.0
|
||||
wine_get_ss;
|
||||
@@ -22,6 +22,7 @@ WINE_1.0
|
||||
wine_get_server_dir;
|
||||
wine_get_user_name;
|
||||
wine_get_version;
|
||||
+ wine_get_patches;
|
||||
wine_init;
|
||||
wine_init_argv0_path;
|
||||
wine_ldt_alloc_entries;
|
||||
wine_mmap_add_reserved_area;
|
||||
diff --git a/loader/main.c b/loader/main.c
|
||||
index f197cf802..f6629128d 100644
|
||||
index 407c897892d..d97d6b28bf8 100644
|
||||
--- a/loader/main.c
|
||||
+++ b/loader/main.c
|
||||
@@ -54,7 +54,8 @@ static void check_command_line( int argc, char *argv[] )
|
||||
@@ -53,7 +53,8 @@ static void check_command_line( int argc, char *argv[] )
|
||||
static const char usage[] =
|
||||
"Usage: wine PROGRAM [ARGUMENTS...] Run the specified program\n"
|
||||
" wine --help Display this help and exit\n"
|
||||
@@ -99,7 +99,7 @@ index f197cf802..f6629128d 100644
|
||||
|
||||
if (argc <= 1)
|
||||
{
|
||||
@@ -71,6 +72,45 @@ static void check_command_line( int argc, char *argv[] )
|
||||
@@ -70,6 +71,45 @@ static void check_command_line( int argc, char *argv[] )
|
||||
printf( "%s\n", wine_get_build_id() );
|
||||
exit(0);
|
||||
}
|
||||
@@ -146,5 +146,5 @@ index f197cf802..f6629128d 100644
|
||||
|
||||
|
||||
--
|
||||
2.25.0
|
||||
2.25.1
|
||||
|
||||
|
@@ -1,313 +0,0 @@
|
||||
From c07a490a6950f4efe563e38ca78b1aa459dfad86 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Wed, 28 May 2014 19:50:51 +0200
|
||||
Subject: [PATCH] loader: Add commandline option --check-libs.
|
||||
|
||||
---
|
||||
include/wine/library.h | 2 +
|
||||
libs/wine/config.c | 124 +++++++++++++++++++++++++++++++++++++++++
|
||||
libs/wine/loader.c | 36 ++++++++++++
|
||||
libs/wine/wine.map | 2 +
|
||||
loader/main.c | 50 ++++++++++++++++-
|
||||
5 files changed, 213 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/include/wine/library.h b/include/wine/library.h
|
||||
index 511bf4722..557cec20c 100644
|
||||
--- a/include/wine/library.h
|
||||
+++ b/include/wine/library.h
|
||||
@@ -44,6 +44,7 @@ extern "C" {
|
||||
extern const char *wine_get_build_dir(void);
|
||||
extern const char *wine_get_config_dir(void);
|
||||
extern const char *wine_get_data_dir(void);
|
||||
+extern const char **wine_get_libs(void);
|
||||
extern const char *wine_get_server_dir(void);
|
||||
extern const char *wine_get_user_name(void);
|
||||
extern const char *wine_get_version(void);
|
||||
@@ -56,6 +57,7 @@ extern void wine_exec_wine_binary( const char *name, char **argv, const char *en
|
||||
|
||||
typedef void (*load_dll_callback_t)( void *, const char * );
|
||||
|
||||
+extern int wine_dladdr( void *addr, void *info, char *error, size_t errorsize );
|
||||
extern void *wine_dlopen( const char *filename, int flag, char *error, size_t errorsize );
|
||||
extern void *wine_dlsym( void *handle, const char *symbol, char *error, size_t errorsize );
|
||||
extern int wine_dlclose( void *handle, char *error, size_t errorsize );
|
||||
diff --git a/libs/wine/config.c b/libs/wine/config.c
|
||||
index 5b66c063d..e0988513e 100644
|
||||
--- a/libs/wine/config.c
|
||||
+++ b/libs/wine/config.c
|
||||
@@ -470,6 +470,130 @@ const char *wine_get_build_dir(void)
|
||||
return build_dir;
|
||||
}
|
||||
|
||||
+const char *wine_libs[] = {
|
||||
+#ifdef SONAME_LIBCAIRO
|
||||
+ SONAME_LIBCAIRO,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBCAPI20
|
||||
+ SONAME_LIBCAPI20,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBCUPS
|
||||
+ SONAME_LIBCUPS,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBCURSES
|
||||
+ SONAME_LIBCURSES,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBDBUS_1
|
||||
+ SONAME_LIBDBUS_1,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBFONTCONFIG
|
||||
+ SONAME_LIBFONTCONFIG,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBFREETYPE
|
||||
+ SONAME_LIBFREETYPE,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBGL
|
||||
+ SONAME_LIBGL,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBGNUTLS
|
||||
+ SONAME_LIBGNUTLS,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBGOBJECT_2_0
|
||||
+ SONAME_LIBGOBJECT_2_0,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBGSM
|
||||
+ SONAME_LIBGSM,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBGTK_3
|
||||
+ SONAME_LIBGTK_3,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBHAL
|
||||
+ SONAME_LIBHAL,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBJPEG
|
||||
+ SONAME_LIBJPEG,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBNCURSES
|
||||
+ SONAME_LIBNCURSES,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBNETAPI
|
||||
+ SONAME_LIBNETAPI,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBODBC
|
||||
+ SONAME_LIBODBC,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBOSMESA
|
||||
+ SONAME_LIBOSMESA,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBPCAP
|
||||
+ SONAME_LIBPCAP,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBPNG
|
||||
+ SONAME_LIBPNG,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBSANE
|
||||
+ SONAME_LIBSANE,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBTIFF
|
||||
+ SONAME_LIBTIFF,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBTXC_DXTN
|
||||
+ SONAME_LIBTXC_DXTN,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBV4L1
|
||||
+ SONAME_LIBV4L1,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBVA
|
||||
+ SONAME_LIBVA,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBVA_DRM
|
||||
+ SONAME_LIBVA_DRM,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBVA_X11
|
||||
+ SONAME_LIBVA_X11,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBX11
|
||||
+ SONAME_LIBX11,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBX11_XCB
|
||||
+ SONAME_LIBX11_XCB,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXCOMPOSITE
|
||||
+ SONAME_LIBXCOMPOSITE,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXCURSOR
|
||||
+ SONAME_LIBXCURSOR,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXEXT
|
||||
+ SONAME_LIBXEXT,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXI
|
||||
+ SONAME_LIBXI,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXINERAMA
|
||||
+ SONAME_LIBXINERAMA,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXRANDR
|
||||
+ SONAME_LIBXRANDR,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXRENDER
|
||||
+ SONAME_LIBXRENDER,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXSLT
|
||||
+ SONAME_LIBXSLT,
|
||||
+#endif
|
||||
+#ifdef SONAME_LIBXXF86VM
|
||||
+ SONAME_LIBXXF86VM,
|
||||
+#endif
|
||||
+ NULL
|
||||
+};
|
||||
+
|
||||
+/* return the list of shared libs used by wine */
|
||||
+const char **wine_get_libs(void)
|
||||
+{
|
||||
+ return &wine_libs[0];
|
||||
+}
|
||||
+
|
||||
/* return the full name of the server directory (the one containing the socket) */
|
||||
const char *wine_get_server_dir(void)
|
||||
{
|
||||
diff --git a/libs/wine/loader.c b/libs/wine/loader.c
|
||||
index 2a569f5b7..5f10c3f9d 100644
|
||||
--- a/libs/wine/loader.c
|
||||
+++ b/libs/wine/loader.c
|
||||
@@ -1072,6 +1072,42 @@ void *wine_dlopen( const char *filename, int flag, char *error, size_t errorsize
|
||||
return ret;
|
||||
}
|
||||
|
||||
+/***********************************************************************
|
||||
+ * wine_dladdr
|
||||
+ */
|
||||
+int wine_dladdr( void *addr, void *info, char *error, size_t errorsize )
|
||||
+{
|
||||
+#ifdef HAVE_DLADDR
|
||||
+ int ret;
|
||||
+ const char *s;
|
||||
+ dlerror(); dlerror();
|
||||
+ ret = dladdr( addr, (Dl_info *)info );
|
||||
+ s = dlerror();
|
||||
+ if (error && errorsize)
|
||||
+ {
|
||||
+ if (s)
|
||||
+ {
|
||||
+ size_t len = strlen(s);
|
||||
+ if (len >= errorsize) len = errorsize - 1;
|
||||
+ memcpy( error, s, len );
|
||||
+ error[len] = 0;
|
||||
+ }
|
||||
+ else error[0] = 0;
|
||||
+ }
|
||||
+ dlerror();
|
||||
+ return ret;
|
||||
+#else
|
||||
+ if (error)
|
||||
+ {
|
||||
+ static const char msg[] = "dladdr interface not detected by configure";
|
||||
+ size_t len = min( errorsize, sizeof(msg) );
|
||||
+ memcpy( error, msg, len );
|
||||
+ error[len - 1] = 0;
|
||||
+ }
|
||||
+ return 0;
|
||||
+#endif
|
||||
+}
|
||||
+
|
||||
/***********************************************************************
|
||||
* wine_dlsym
|
||||
*/
|
||||
diff --git a/libs/wine/wine.map b/libs/wine/wine.map
|
||||
index ca46979f5..22a4e73b0 100644
|
||||
--- a/libs/wine/wine.map
|
||||
+++ b/libs/wine/wine.map
|
||||
@@ -9,6 +9,7 @@ WINE_1.0
|
||||
wine_anon_mmap;
|
||||
wine_casemap_lower;
|
||||
wine_casemap_upper;
|
||||
+ wine_dladdr;
|
||||
wine_dlclose;
|
||||
wine_dll_enum_load_path;
|
||||
wine_dll_set_callback;
|
||||
@@ -24,6 +25,7 @@ WINE_1.0
|
||||
wine_get_es;
|
||||
wine_get_fs;
|
||||
wine_get_gs;
|
||||
+ wine_get_libs;
|
||||
wine_get_server_dir;
|
||||
wine_get_ss;
|
||||
wine_get_user_name;
|
||||
diff --git a/loader/main.c b/loader/main.c
|
||||
index f6629128d..a2dc40c51 100644
|
||||
--- a/loader/main.c
|
||||
+++ b/loader/main.c
|
||||
@@ -36,6 +36,12 @@
|
||||
#ifdef HAVE_UNISTD_H
|
||||
# include <unistd.h>
|
||||
#endif
|
||||
+#ifdef HAVE_DLADDR
|
||||
+# include <dlfcn.h>
|
||||
+#endif
|
||||
+#ifdef HAVE_LINK_H
|
||||
+# include <link.h>
|
||||
+#endif
|
||||
#include <pthread.h>
|
||||
|
||||
#include "wine/library.h"
|
||||
@@ -55,7 +61,8 @@ static void check_command_line( int argc, char *argv[] )
|
||||
"Usage: wine PROGRAM [ARGUMENTS...] Run the specified program\n"
|
||||
" wine --help Display this help and exit\n"
|
||||
" wine --version Output version information and exit\n"
|
||||
- " wine --patches Output patch information and exit";
|
||||
+ " wine --patches Output patch information and exit\n"
|
||||
+ " wine --check-libs Checks if shared libs are installed";
|
||||
|
||||
if (argc <= 1)
|
||||
{
|
||||
@@ -111,6 +118,47 @@ static void check_command_line( int argc, char *argv[] )
|
||||
|
||||
exit(0);
|
||||
}
|
||||
+ if (!strcmp( argv[1], "--check-libs" ))
|
||||
+ {
|
||||
+ void* lib_handle;
|
||||
+ int ret = 0;
|
||||
+ const char **wine_libs = wine_get_libs();
|
||||
+
|
||||
+ for(; *wine_libs; wine_libs++)
|
||||
+ {
|
||||
+ lib_handle = wine_dlopen( *wine_libs, RTLD_NOW, NULL, 0 );
|
||||
+ if (lib_handle)
|
||||
+ {
|
||||
+ #ifdef HAVE_DLADDR
|
||||
+ Dl_info libinfo;
|
||||
+ void* symbol;
|
||||
+
|
||||
+ #ifdef HAVE_LINK_H
|
||||
+ struct link_map *lm = (struct link_map *)lib_handle;
|
||||
+ symbol = (void *)lm->l_addr;
|
||||
+ #else
|
||||
+ symbol = wine_dlsym( lib_handle, "_init", NULL, 0 );
|
||||
+ #endif
|
||||
+ if (symbol && wine_dladdr( symbol, &libinfo, NULL, 0 ))
|
||||
+ {
|
||||
+ printf( "%s: %s\n", *wine_libs, libinfo.dli_fname );
|
||||
+ }
|
||||
+ else
|
||||
+ #endif
|
||||
+ {
|
||||
+ printf( "%s: found\n", *wine_libs );
|
||||
+ }
|
||||
+ wine_dlclose( lib_handle, NULL, 0 );
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ printf( "%s: missing\n", *wine_libs );
|
||||
+ ret = 1;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ exit(ret);
|
||||
+ }
|
||||
}
|
||||
|
||||
|
||||
--
|
||||
2.25.0
|
||||
|
@@ -1,60 +0,0 @@
|
||||
From 07ca5e888c3265c57c88ef1758e6c47fbea4fb07 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sat, 27 Jun 2015 19:28:51 +0200
|
||||
Subject: loader: Print library paths for --check-libs on Mac OS X.
|
||||
|
||||
---
|
||||
loader/main.c | 30 +++++++++++++++++++++++++++++-
|
||||
1 file changed, 29 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/loader/main.c b/loader/main.c
|
||||
index a2dc40c51c..1642fb0965 100644
|
||||
--- a/loader/main.c
|
||||
+++ b/loader/main.c
|
||||
@@ -50,6 +50,30 @@
|
||||
/* the preloader will set this variable */
|
||||
const struct wine_preload_info *wine_main_preload_info = NULL;
|
||||
|
||||
+#ifdef __APPLE__
|
||||
+#include <mach-o/dyld.h>
|
||||
+
|
||||
+static const char *get_macho_library_path( const char *libname )
|
||||
+{
|
||||
+ unsigned int path_len, libname_len = strlen( libname );
|
||||
+ uint32_t i, count = _dyld_image_count();
|
||||
+
|
||||
+ for (i = 0; i < count; i++)
|
||||
+ {
|
||||
+ const char *path = _dyld_get_image_name( i );
|
||||
+ if (!path) continue;
|
||||
+
|
||||
+ path_len = strlen( path );
|
||||
+ if (path_len < libname_len + 1) continue;
|
||||
+ if (path[path_len - libname_len - 1] != '/') continue;
|
||||
+ if (strcmp( path + path_len - libname_len, libname )) continue;
|
||||
+
|
||||
+ return path;
|
||||
+ }
|
||||
+ return NULL;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
/***********************************************************************
|
||||
* check_command_line
|
||||
*
|
||||
@@ -146,7 +170,11 @@ static void check_command_line( int argc, char *argv[] )
|
||||
else
|
||||
#endif
|
||||
{
|
||||
- printf( "%s: found\n", *wine_libs );
|
||||
+ const char *path = NULL;
|
||||
+ #ifdef __APPLE__
|
||||
+ path = get_macho_library_path( *wine_libs );
|
||||
+ #endif
|
||||
+ printf( "%s: %s\n", *wine_libs, path ? path : "found");
|
||||
}
|
||||
wine_dlclose( lib_handle, NULL, 0 );
|
||||
}
|
||||
--
|
||||
2.14.1
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 8959c13f2be7e2a31f27c8483ee2202692f00710 Mon Sep 17 00:00:00 2001
|
||||
From 8fe522dadc480b57415a7b63e0752de113851231 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sat, 5 Aug 2017 01:45:29 +0200
|
||||
Subject: [PATCH] ntdll: Add function to create new tokens for elevation
|
||||
@@ -14,10 +14,10 @@ Subject: [PATCH] ntdll: Add function to create new tokens for elevation
|
||||
6 files changed, 117 insertions(+)
|
||||
|
||||
diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec
|
||||
index d626e0bf2..5057e2b07 100644
|
||||
index 853da5c3fcf..33c1355c8b5 100644
|
||||
--- a/dlls/ntdll/ntdll.spec
|
||||
+++ b/dlls/ntdll/ntdll.spec
|
||||
@@ -1556,6 +1556,9 @@
|
||||
@@ -1569,6 +1569,9 @@
|
||||
# Virtual memory
|
||||
@ cdecl __wine_locked_recvmsg(long ptr long)
|
||||
|
||||
@@ -28,12 +28,12 @@ index d626e0bf2..5057e2b07 100644
|
||||
@ cdecl wine_get_version() NTDLL_wine_get_version
|
||||
@ cdecl wine_get_patches() NTDLL_wine_get_patches
|
||||
diff --git a/dlls/ntdll/ntdll_misc.h b/dlls/ntdll/ntdll_misc.h
|
||||
index ac1469412..6c2345c6c 100644
|
||||
index b62239de5b4..d494dc71263 100644
|
||||
--- a/dlls/ntdll/ntdll_misc.h
|
||||
+++ b/dlls/ntdll/ntdll_misc.h
|
||||
@@ -89,6 +89,9 @@ extern void init_user_process_params( SIZE_T data_size ) DECLSPEC_HIDDEN;
|
||||
extern char **build_envp( const WCHAR *envW ) DECLSPEC_HIDDEN;
|
||||
extern NTSTATUS restart_process( RTL_USER_PROCESS_PARAMETERS *params, NTSTATUS status ) DECLSPEC_HIDDEN;
|
||||
@@ -96,6 +96,9 @@ extern int __wine_main_argc;
|
||||
extern char **__wine_main_argv;
|
||||
extern WCHAR **__wine_main_wargv;
|
||||
|
||||
+/* token */
|
||||
+extern HANDLE CDECL __wine_create_default_token(BOOL admin);
|
||||
@@ -42,10 +42,10 @@ index ac1469412..6c2345c6c 100644
|
||||
extern timeout_t server_start_time DECLSPEC_HIDDEN;
|
||||
extern unsigned int server_cpus DECLSPEC_HIDDEN;
|
||||
diff --git a/dlls/ntdll/process.c b/dlls/ntdll/process.c
|
||||
index 52d7ea429..e24691b8a 100644
|
||||
index 6d506c85306..9940e6cf7c9 100644
|
||||
--- a/dlls/ntdll/process.c
|
||||
+++ b/dlls/ntdll/process.c
|
||||
@@ -125,6 +125,24 @@ HANDLE CDECL __wine_make_process_system(void)
|
||||
@@ -124,6 +124,24 @@ HANDLE CDECL __wine_make_process_system(void)
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -71,10 +71,10 @@ index 52d7ea429..e24691b8a 100644
|
||||
|
||||
#define UNIMPLEMENTED_INFO_CLASS(c) \
|
||||
diff --git a/server/protocol.def b/server/protocol.def
|
||||
index e908f2131..0177cb579 100644
|
||||
index efacadac42b..434cd11baf0 100644
|
||||
--- a/server/protocol.def
|
||||
+++ b/server/protocol.def
|
||||
@@ -3734,6 +3734,14 @@ struct handle_info
|
||||
@@ -3749,6 +3749,14 @@ struct handle_info
|
||||
@END
|
||||
|
||||
|
||||
@@ -90,7 +90,7 @@ index e908f2131..0177cb579 100644
|
||||
@REQ(create_completion)
|
||||
unsigned int access; /* desired access to a port */
|
||||
diff --git a/server/security.h b/server/security.h
|
||||
index 6c337143c..21e90ccf2 100644
|
||||
index 6c337143c3d..21e90ccf23f 100644
|
||||
--- a/server/security.h
|
||||
+++ b/server/security.h
|
||||
@@ -49,6 +49,7 @@ extern const PSID security_builtin_users_sid;
|
||||
@@ -102,10 +102,10 @@ index 6c337143c..21e90ccf2 100644
|
||||
|
||||
/* token functions */
|
||||
diff --git a/server/token.c b/server/token.c
|
||||
index 381ae6871..fcab79955 100644
|
||||
index c4f1cd943c2..970ed1838da 100644
|
||||
--- a/server/token.c
|
||||
+++ b/server/token.c
|
||||
@@ -79,6 +79,7 @@ static const SID anonymous_logon_sid = { SID_REVISION, 1, { SECURITY_NT_AUTHORIT
|
||||
@@ -77,6 +77,7 @@ static const SID anonymous_logon_sid = { SID_REVISION, 1, { SECURITY_NT_AUTHORIT
|
||||
static const SID authenticated_user_sid = { SID_REVISION, 1, { SECURITY_NT_AUTHORITY }, { SECURITY_AUTHENTICATED_USER_RID } };
|
||||
static const SID local_system_sid = { SID_REVISION, 1, { SECURITY_NT_AUTHORITY }, { SECURITY_LOCAL_SYSTEM_RID } };
|
||||
static const SID high_label_sid = { SID_REVISION, 1, { SECURITY_MANDATORY_LABEL_AUTHORITY }, { SECURITY_MANDATORY_HIGH_RID } };
|
||||
@@ -113,7 +113,7 @@ index 381ae6871..fcab79955 100644
|
||||
static const SID_N(5) local_user_sid = { SID_REVISION, 5, { SECURITY_NT_AUTHORITY }, { SECURITY_NT_NON_UNIQUE, 0, 0, 0, 1000 } };
|
||||
static const SID_N(2) builtin_admins_sid = { SID_REVISION, 2, { SECURITY_NT_AUTHORITY }, { SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_ADMINS } };
|
||||
static const SID_N(2) builtin_users_sid = { SID_REVISION, 2, { SECURITY_NT_AUTHORITY }, { SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_USERS } };
|
||||
@@ -95,6 +96,7 @@ const PSID security_builtin_admins_sid = (PSID)&builtin_admins_sid;
|
||||
@@ -93,6 +94,7 @@ const PSID security_builtin_admins_sid = (PSID)&builtin_admins_sid;
|
||||
const PSID security_builtin_users_sid = (PSID)&builtin_users_sid;
|
||||
const PSID security_domain_users_sid = (PSID)&domain_users_sid;
|
||||
const PSID security_high_label_sid = (PSID)&high_label_sid;
|
||||
@@ -121,7 +121,7 @@ index 381ae6871..fcab79955 100644
|
||||
|
||||
static luid_t prev_luid_value = { 1000, 0 };
|
||||
|
||||
@@ -917,6 +919,64 @@ struct token *token_create_admin( void )
|
||||
@@ -915,6 +917,64 @@ struct token *token_create_admin( void )
|
||||
return token;
|
||||
}
|
||||
|
||||
@@ -186,7 +186,7 @@ index 381ae6871..fcab79955 100644
|
||||
static struct privilege *token_find_privilege( struct token *token, const LUID *luid, int enabled_only )
|
||||
{
|
||||
struct privilege *privilege;
|
||||
@@ -1722,3 +1782,27 @@ DECL_HANDLER(set_token_default_dacl)
|
||||
@@ -1720,3 +1780,27 @@ DECL_HANDLER(set_token_default_dacl)
|
||||
release_object( token );
|
||||
}
|
||||
}
|
||||
@@ -215,5 +215,5 @@ index 381ae6871..fcab79955 100644
|
||||
+ }
|
||||
+}
|
||||
--
|
||||
2.23.0
|
||||
2.26.0
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,149 @@
|
||||
From d0c4ac467f5e85e29ae407b29b6a93c85f375fd3 Mon Sep 17 00:00:00 2001
|
||||
From: Derek Lesho <dlesho@codeweavers.com>
|
||||
Date: Tue, 7 Jan 2020 14:22:49 -0600
|
||||
Subject: [PATCH] bcrypt: Implement BCRYPT_KDF_HASH.
|
||||
|
||||
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47699
|
||||
Signed-off-by: Derek Lesho <dlesho at codeweavers.com>
|
||||
---
|
||||
dlls/bcrypt/bcrypt_main.c | 110 +++++++++++++++++++++++++++++++++++++
|
||||
dlls/bcrypt/tests/bcrypt.c | 2 +-
|
||||
2 files changed, 111 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dlls/bcrypt/bcrypt_main.c b/dlls/bcrypt/bcrypt_main.c
|
||||
index 15b934247d..57d552a4c0 100644
|
||||
--- a/dlls/bcrypt/bcrypt_main.c
|
||||
+++ b/dlls/bcrypt/bcrypt_main.c
|
||||
@@ -1773,6 +1773,116 @@ NTSTATUS WINAPI BCryptDeriveKey(BCRYPT_SECRET_HANDLE hSecret, LPCWSTR deriv_func
|
||||
return STATUS_INVALID_HANDLE;
|
||||
}
|
||||
|
||||
+ if (flags)
|
||||
+ {
|
||||
+ FIXME("flags ignored: %08x\n", flags);
|
||||
+ }
|
||||
+
|
||||
+ if (!(strcmpW(deriv_func, BCRYPT_KDF_HASH)))
|
||||
+ {
|
||||
+ unsigned int i;
|
||||
+ BCryptBuffer *hash_algorithm = NULL;
|
||||
+ BCryptBuffer *secret_prepend = NULL;
|
||||
+ BCryptBuffer *secret_append = NULL;
|
||||
+ enum alg_id hash_alg_id;
|
||||
+ ULONG hash_length;
|
||||
+ struct hash_impl hash;
|
||||
+ NTSTATUS status;
|
||||
+
|
||||
+ if (parameter)
|
||||
+ {
|
||||
+ for (i = 0; i < parameter->cBuffers; i++)
|
||||
+ {
|
||||
+ BCryptBuffer *cur_buffer = ¶meter->pBuffers[i];
|
||||
+ switch(cur_buffer->BufferType)
|
||||
+ {
|
||||
+ case KDF_HASH_ALGORITHM:
|
||||
+ if (hash_algorithm)
|
||||
+ FIXME("Duplicate KDF_HASH_ALGORITHM, untested\n");
|
||||
+ hash_algorithm = cur_buffer;
|
||||
+ break;
|
||||
+ case KDF_SECRET_PREPEND:
|
||||
+ if (secret_prepend)
|
||||
+ FIXME("Multiple prefixes unsupported\n");
|
||||
+ secret_prepend = cur_buffer;
|
||||
+ break;
|
||||
+ case KDF_SECRET_APPEND:
|
||||
+ if (secret_append)
|
||||
+ FIXME("Multiple suffixes unsupported\n");
|
||||
+ secret_append = cur_buffer;
|
||||
+ break;
|
||||
+ default:
|
||||
+ FIXME("Unsupported BCRYPT_KDF_HASH parameter type %x\n", cur_buffer->BufferType);
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ if (!(hash_algorithm))
|
||||
+ hash_alg_id = ALG_ID_SHA1;
|
||||
+ else
|
||||
+ {
|
||||
+ for (i = 0; i < ARRAY_SIZE( builtin_algorithms ); i++)
|
||||
+ {
|
||||
+ if (!strcmpW( hash_algorithm->pvBuffer, builtin_algorithms[i].name))
|
||||
+ {
|
||||
+ hash_alg_id = i;
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+ if (i == ARRAY_SIZE(builtin_algorithms))
|
||||
+ {
|
||||
+ WARN("Algorithm %s not found\n", debugstr_w(hash_algorithm->pvBuffer));
|
||||
+ return STATUS_NOT_SUPPORTED;
|
||||
+ }
|
||||
+ if (builtin_algorithms[hash_alg_id].class != BCRYPT_HASH_INTERFACE)
|
||||
+ {
|
||||
+ return STATUS_NOT_SUPPORTED;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ hash_length = builtin_algorithms[hash_alg_id].hash_length;
|
||||
+
|
||||
+ if (!derived)
|
||||
+ {
|
||||
+ *result = hash_length;
|
||||
+ return STATUS_SUCCESS;
|
||||
+ }
|
||||
+
|
||||
+ if ((status = hash_init(&hash, hash_alg_id)))
|
||||
+ {
|
||||
+ return status;
|
||||
+ }
|
||||
+
|
||||
+ if (secret_prepend)
|
||||
+ {
|
||||
+ hash_update(&hash, hash_alg_id, secret_prepend->pvBuffer, secret_prepend->cbBuffer);
|
||||
+ }
|
||||
+
|
||||
+ hash_update(&hash, hash_alg_id, secret->data, secret->len);
|
||||
+
|
||||
+ if (secret_append)
|
||||
+ {
|
||||
+ hash_update(&hash, hash_alg_id, secret_append->pvBuffer, secret_append->cbBuffer);
|
||||
+ }
|
||||
+
|
||||
+ if (derived_size >= hash_length)
|
||||
+ {
|
||||
+ hash_finish(&hash, hash_alg_id, derived, derived_size);
|
||||
+ *result = hash_length;
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ UCHAR *output = heap_alloc(hash_length);
|
||||
+ hash_finish(&hash, hash_alg_id, output, hash_length);
|
||||
+ memcpy(derived, output, derived_size);
|
||||
+ heap_free(output);
|
||||
+ *result = derived_size;
|
||||
+ }
|
||||
+
|
||||
+ return STATUS_SUCCESS;
|
||||
+ }
|
||||
+ else
|
||||
if (!(strcmpW(deriv_func, BCRYPT_KDF_RAW_SECRET)))
|
||||
{
|
||||
ULONG n;
|
||||
diff --git a/dlls/bcrypt/tests/bcrypt.c b/dlls/bcrypt/tests/bcrypt.c
|
||||
index d9509f2c49..edc59a8a97 100644
|
||||
--- a/dlls/bcrypt/tests/bcrypt.c
|
||||
+++ b/dlls/bcrypt/tests/bcrypt.c
|
||||
@@ -2084,7 +2084,7 @@ static void test_ECDH(void)
|
||||
raw_secret_end:
|
||||
|
||||
status = pBCryptDeriveKey(secret, BCRYPT_KDF_HASH, &hash_params, NULL, 0, &size, 0);
|
||||
- todo_wine ok (status == STATUS_SUCCESS, "got %08x\n", status);
|
||||
+ ok (status == STATUS_SUCCESS, "got %08x\n", status);
|
||||
|
||||
if (status != STATUS_SUCCESS)
|
||||
{
|
||||
--
|
||||
2.24.1
|
||||
|
2
patches/bcrypt-ECDHSecretAgreement/definition
Normal file
2
patches/bcrypt-ECDHSecretAgreement/definition
Normal file
@@ -0,0 +1,2 @@
|
||||
Fixes: [47699] Multiple games fail to connect to online services (missing BCryptSecretAgreement / BCryptDeriveKey implementation)
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From ad23e816eb724d81032306f8ac6d4faa96ccaf4a Mon Sep 17 00:00:00 2001
|
||||
From c88a1acf9ac625cb2a7cbfc90ac3bb2d426889a0 Mon Sep 17 00:00:00 2001
|
||||
From: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
Date: Tue, 12 Nov 2019 18:13:20 +0800
|
||||
Subject: [PATCH] comctl32: Bump version to 6.0.
|
||||
@@ -14,12 +14,12 @@ Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
|
||||
3 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/dlls/comctl32/comctl32.h b/dlls/comctl32/comctl32.h
|
||||
index 78e97983381..42b434a96d9 100644
|
||||
index 66b341ae5ad..1af9baea7ee 100644
|
||||
--- a/dlls/comctl32/comctl32.h
|
||||
+++ b/dlls/comctl32/comctl32.h
|
||||
@@ -192,7 +192,7 @@ INT Str_GetPtrAtoW (LPCSTR lpSrc, LPWSTR lpDest, INT nMaxLen) DECLSPEC_HIDDEN;
|
||||
BOOL Str_SetPtrAtoW (LPWSTR *lppDest, LPCSTR lpSrc) DECLSPEC_HIDDEN;
|
||||
@@ -193,7 +193,7 @@ BOOL Str_SetPtrAtoW (LPWSTR *lppDest, LPCSTR lpSrc) DECLSPEC_HIDDEN;
|
||||
BOOL Str_SetPtrWtoA (LPSTR *lppDest, LPCWSTR lpSrc) DECLSPEC_HIDDEN;
|
||||
BOOL imagelist_has_alpha(HIMAGELIST, UINT) DECLSPEC_HIDDEN;
|
||||
|
||||
-#define COMCTL32_VERSION_MINOR 81
|
||||
+#define COMCTL32_VERSION_MINOR 0
|
||||
@@ -40,7 +40,7 @@ index c9aa1ba6253..be6e2425193 100644
|
||||
#define WINE_PRODUCTVERSION_STR WINE_FILEVERSION_STR
|
||||
|
||||
diff --git a/include/commctrl.h b/include/commctrl.h
|
||||
index 700b335fbb7..029a4b45457 100644
|
||||
index dfd2f4a37d2..0784478ce14 100644
|
||||
--- a/include/commctrl.h
|
||||
+++ b/include/commctrl.h
|
||||
@@ -51,7 +51,7 @@ enum _LI_METRIC
|
||||
@@ -50,8 +50,8 @@ index 700b335fbb7..029a4b45457 100644
|
||||
-#define COMCTL32_VERSION 5 /* dll version */
|
||||
+#define COMCTL32_VERSION 6 /* dll version */
|
||||
|
||||
#ifndef _WIN32_IE
|
||||
#define _WIN32_IE 0x0400
|
||||
#define ICC_LISTVIEW_CLASSES 0x00000001 /* listview, header */
|
||||
#define ICC_TREEVIEW_CLASSES 0x00000002 /* treeview, tooltips */
|
||||
--
|
||||
2.24.1
|
||||
2.25.1
|
||||
|
||||
|
@@ -1,333 +0,0 @@
|
||||
From b1655e88c9c7b4b87ae87d06261ce3db4fac1432 Mon Sep 17 00:00:00 2001
|
||||
From: Christian Costa <titan.costa@gmail.com>
|
||||
Date: Sun, 26 May 2013 19:42:08 +0200
|
||||
Subject: [PATCH] d3dx9_36: Implement ID3DXFontImpl_DrawText.
|
||||
|
||||
Changes by Sebastian Lackner <sebastian@fds-team.de>:
|
||||
* Use pitch value for locked buffer instead of assuming that pitch = width * bytesperpixel
|
||||
* Avoid one for loop to simplify code
|
||||
* Ensure that DrawText doesn't dereference a NULL pointer when count != 0.
|
||||
|
||||
Changes by Christian Costa <titan.costa@gmail.com>
|
||||
* Use dedicated variables for text width & height instead of reusing rect.right and rect.bottom
|
||||
* Remove useless test in pixel conversion
|
||||
* Remove left over 'partial stub' in fixme
|
||||
|
||||
Changes by Sebastian Lackner <sebastian@fds-team.de>:
|
||||
* Replace code to convert text from ascii to widechar
|
||||
* Strip terminating NULL chars before drawing text
|
||||
---
|
||||
dlls/d3dx9_36/font.c | 229 ++++++++++++++++++++++++++++++++++++++++++++++-----
|
||||
1 file changed, 210 insertions(+), 19 deletions(-)
|
||||
|
||||
diff --git a/dlls/d3dx9_36/font.c b/dlls/d3dx9_36/font.c
|
||||
index 5522dea..916ce4c 100644
|
||||
--- a/dlls/d3dx9_36/font.c
|
||||
+++ b/dlls/d3dx9_36/font.c
|
||||
@@ -35,8 +35,29 @@ struct d3dx_font
|
||||
|
||||
HDC hdc;
|
||||
HFONT hfont;
|
||||
+
|
||||
+ UINT tex_width;
|
||||
+ UINT tex_height;
|
||||
+ IDirect3DTexture9 *texture;
|
||||
+ HBITMAP bitmap;
|
||||
+ BYTE *bits;
|
||||
};
|
||||
|
||||
+/* Returns the smallest power of 2 which is greater than or equal to num */
|
||||
+static UINT make_pow2(UINT num)
|
||||
+{
|
||||
+ UINT result = 1;
|
||||
+
|
||||
+ /* In the unlikely event somebody passes a large value, make sure we don't enter an infinite loop */
|
||||
+ if (num >= 0x80000000)
|
||||
+ return 0x80000000;
|
||||
+
|
||||
+ while (result < num)
|
||||
+ result <<= 1;
|
||||
+
|
||||
+ return result;
|
||||
+}
|
||||
+
|
||||
static inline struct d3dx_font *impl_from_ID3DXFont(ID3DXFont *iface)
|
||||
{
|
||||
return CONTAINING_RECORD(iface, struct d3dx_font, ID3DXFont_iface);
|
||||
@@ -63,19 +84,27 @@ static HRESULT WINAPI ID3DXFontImpl_QueryInterface(ID3DXFont *iface, REFIID riid
|
||||
static ULONG WINAPI ID3DXFontImpl_AddRef(ID3DXFont *iface)
|
||||
{
|
||||
struct d3dx_font *This = impl_from_ID3DXFont(iface);
|
||||
- ULONG ref=InterlockedIncrement(&This->ref);
|
||||
+ ULONG ref = InterlockedIncrement(&This->ref);
|
||||
+
|
||||
TRACE("%p increasing refcount to %u\n", iface, ref);
|
||||
+
|
||||
return ref;
|
||||
}
|
||||
|
||||
static ULONG WINAPI ID3DXFontImpl_Release(ID3DXFont *iface)
|
||||
{
|
||||
struct d3dx_font *This = impl_from_ID3DXFont(iface);
|
||||
- ULONG ref=InterlockedDecrement(&This->ref);
|
||||
+ ULONG ref = InterlockedDecrement(&This->ref);
|
||||
|
||||
TRACE("%p decreasing refcount to %u\n", iface, ref);
|
||||
|
||||
- if(ref==0) {
|
||||
+ if (!ref)
|
||||
+ {
|
||||
+ if (This->texture)
|
||||
+ {
|
||||
+ IDirect3DTexture9_Release(This->texture);
|
||||
+ DeleteObject(This->bitmap);
|
||||
+ }
|
||||
DeleteObject(This->hfont);
|
||||
DeleteDC(This->hdc);
|
||||
IDirect3DDevice9_Release(This->device);
|
||||
@@ -178,17 +207,170 @@ static HRESULT WINAPI ID3DXFontImpl_PreloadTextW(ID3DXFont *iface, const WCHAR *
|
||||
static INT WINAPI ID3DXFontImpl_DrawTextA(ID3DXFont *iface, ID3DXSprite *sprite,
|
||||
const char *string, INT count, RECT *rect, DWORD format, D3DCOLOR color)
|
||||
{
|
||||
- FIXME("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x stub!\n",
|
||||
+ LPWSTR stringW;
|
||||
+ INT countW, ret = 0;
|
||||
+
|
||||
+ TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
|
||||
iface, sprite, debugstr_a(string), count, wine_dbgstr_rect(rect), format, color);
|
||||
- return 1;
|
||||
+
|
||||
+ if (!string || count <= 0)
|
||||
+ return 0;
|
||||
+
|
||||
+ countW = MultiByteToWideChar(CP_ACP, 0, string, count, NULL, 0);
|
||||
+ stringW = HeapAlloc(GetProcessHeap(), 0, countW * sizeof(WCHAR));
|
||||
+ if (stringW)
|
||||
+ {
|
||||
+ MultiByteToWideChar(CP_ACP, 0, string, count, stringW, countW);
|
||||
+ ret = ID3DXFont_DrawTextW(iface, sprite, stringW, countW, rect, format, color);
|
||||
+ HeapFree(GetProcessHeap(), 0, stringW);
|
||||
+ }
|
||||
+
|
||||
+ return ret;
|
||||
}
|
||||
|
||||
static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
|
||||
const WCHAR *string, INT count, RECT *rect, DWORD format, D3DCOLOR color)
|
||||
{
|
||||
- FIXME("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x stub!\n",
|
||||
+ struct d3dx_font *This = impl_from_ID3DXFont(iface);
|
||||
+ RECT calc_rect = *rect;
|
||||
+ INT height;
|
||||
+
|
||||
+ TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
|
||||
iface, sprite, debugstr_w(string), count, wine_dbgstr_rect(rect), format, color);
|
||||
- return 1;
|
||||
+
|
||||
+ if (!string || count <= 0)
|
||||
+ return 0;
|
||||
+
|
||||
+ /* Strip terminating NULL characters */
|
||||
+ while (count > 0 && !string[count-1])
|
||||
+ count--;
|
||||
+
|
||||
+ height = DrawTextW(This->hdc, string, count, &calc_rect, format | DT_CALCRECT);
|
||||
+
|
||||
+ if (format & DT_CALCRECT)
|
||||
+ {
|
||||
+ *rect = calc_rect;
|
||||
+ return height;
|
||||
+ }
|
||||
+
|
||||
+ if (height && (calc_rect.left < calc_rect.right))
|
||||
+ {
|
||||
+ D3DLOCKED_RECT locked_rect;
|
||||
+ D3DXVECTOR3 position;
|
||||
+ UINT text_width, text_height;
|
||||
+ RECT text_rect;
|
||||
+ ID3DXSprite *target = sprite;
|
||||
+ HRESULT hr;
|
||||
+ int i, j;
|
||||
+
|
||||
+ /* Get rect position and dimensions */
|
||||
+ position.x = calc_rect.left;
|
||||
+ position.y = calc_rect.top;
|
||||
+ position.z = 0;
|
||||
+ text_width = calc_rect.right - calc_rect.left;
|
||||
+ text_height = calc_rect.bottom - calc_rect.top;
|
||||
+ text_rect.left = 0;
|
||||
+ text_rect.top = 0;
|
||||
+ text_rect.right = text_width;
|
||||
+ text_rect.bottom = text_height;
|
||||
+
|
||||
+ /* We need to flush as it seems all draws in the begin/end sequence use only the latest updated texture */
|
||||
+ if (sprite)
|
||||
+ ID3DXSprite_Flush(sprite);
|
||||
+
|
||||
+ /* Extend texture and DIB section to contain text */
|
||||
+ if ((text_width > This->tex_width) || (text_height > This->tex_height))
|
||||
+ {
|
||||
+ BITMAPINFOHEADER header;
|
||||
+
|
||||
+ if (text_width > This->tex_width)
|
||||
+ This->tex_width = make_pow2(text_width);
|
||||
+ if (text_height > This->tex_height)
|
||||
+ This->tex_height = make_pow2(text_height);
|
||||
+
|
||||
+ if (This->texture)
|
||||
+ {
|
||||
+ IDirect3DTexture9_Release(This->texture);
|
||||
+ DeleteObject(This->bitmap);
|
||||
+ }
|
||||
+
|
||||
+ hr = D3DXCreateTexture(This->device, This->tex_width, This->tex_height, 1, D3DUSAGE_DYNAMIC,
|
||||
+ D3DFMT_A8R8G8B8, D3DPOOL_DEFAULT, &This->texture);
|
||||
+ if (FAILED(hr))
|
||||
+ {
|
||||
+ This->texture = NULL;
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+ header.biSize = sizeof(header);
|
||||
+ header.biWidth = This->tex_width;
|
||||
+ header.biHeight = -This->tex_height;
|
||||
+ header.biPlanes = 1;
|
||||
+ header.biBitCount = 32;
|
||||
+ header.biCompression = BI_RGB;
|
||||
+ header.biSizeImage = sizeof(DWORD) * This->tex_width * This->tex_height;
|
||||
+ header.biXPelsPerMeter = 0;
|
||||
+ header.biYPelsPerMeter = 0;
|
||||
+ header.biClrUsed = 0;
|
||||
+ header.biClrImportant = 0;
|
||||
+
|
||||
+ This->bitmap = CreateDIBSection(This->hdc, (const BITMAPINFO*)&header,
|
||||
+ DIB_RGB_COLORS, (void**)&This->bits, NULL, 0);
|
||||
+ if (!This->bitmap)
|
||||
+ {
|
||||
+ IDirect3DTexture9_Release(This->texture);
|
||||
+ This->texture = NULL;
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+ SelectObject(This->hdc, This->bitmap);
|
||||
+ }
|
||||
+
|
||||
+ if (FAILED(IDirect3DTexture9_LockRect(This->texture, 0, &locked_rect, &text_rect, D3DLOCK_DISCARD)))
|
||||
+ return 0;
|
||||
+
|
||||
+ /* Clear rect */
|
||||
+ for (i = 0; i < text_height; i++)
|
||||
+ memset(This->bits + i * This->tex_width * sizeof(DWORD), 0,
|
||||
+ text_width * sizeof(DWORD));
|
||||
+
|
||||
+ DrawTextW(This->hdc, string, count, &text_rect, format);
|
||||
+
|
||||
+ /* All RGB components are equal so take one as alpha and set RGB
|
||||
+ * color to white, so it can be modulated with color parameter */
|
||||
+ for (i = 0; i < text_height; i++)
|
||||
+ {
|
||||
+ DWORD *src = (DWORD *)This->bits + i * This->tex_width;
|
||||
+ DWORD *dst = (DWORD *)((BYTE *)locked_rect.pBits + i * locked_rect.Pitch);
|
||||
+ for (j = 0; j < text_width; j++)
|
||||
+ {
|
||||
+ *dst++ = (*src++ << 24) | 0xFFFFFF;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ IDirect3DTexture9_UnlockRect(This->texture, 0);
|
||||
+
|
||||
+ if (!sprite)
|
||||
+ {
|
||||
+ hr = D3DXCreateSprite(This->device, &target);
|
||||
+ if (FAILED(hr))
|
||||
+ return 0;
|
||||
+ ID3DXSprite_Begin(target, 0);
|
||||
+ }
|
||||
+
|
||||
+ hr = target->lpVtbl->Draw(target, This->texture, &text_rect, NULL, &position, color);
|
||||
+
|
||||
+ if (!sprite)
|
||||
+ {
|
||||
+ ID3DXSprite_End(target);
|
||||
+ ID3DXSprite_Release(target);
|
||||
+ }
|
||||
+
|
||||
+ if (FAILED(hr))
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+ return height;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI ID3DXFontImpl_OnLostDevice(ID3DXFont *iface)
|
||||
@@ -302,46 +484,55 @@ HRESULT WINAPI D3DXCreateFontIndirectW(IDirect3DDevice9 *device, const D3DXFONT_
|
||||
|
||||
TRACE("(%p, %p, %p)\n", device, desc, font);
|
||||
|
||||
- if( !device || !desc || !font ) return D3DERR_INVALIDCALL;
|
||||
+ if (!device || !desc || !font) return D3DERR_INVALIDCALL;
|
||||
+
|
||||
+ TRACE("desc: %d %d %d %d %d %d %d %d %d %s\n", desc->Height, desc->Width, desc->Weight, desc->MipLevels, desc->Italic,
|
||||
+ desc->CharSet, desc->OutputPrecision, desc->Quality, desc->PitchAndFamily, debugstr_w(desc->FaceName));
|
||||
|
||||
- /* the device MUST support D3DFMT_A8R8G8B8 */
|
||||
+ /* The device MUST support D3DFMT_A8R8G8B8 */
|
||||
IDirect3DDevice9_GetDirect3D(device, &d3d);
|
||||
IDirect3DDevice9_GetCreationParameters(device, &cpars);
|
||||
IDirect3DDevice9_GetDisplayMode(device, 0, &mode);
|
||||
hr = IDirect3D9_CheckDeviceFormat(d3d, cpars.AdapterOrdinal, cpars.DeviceType, mode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_A8R8G8B8);
|
||||
- if(FAILED(hr)) {
|
||||
+ if (FAILED(hr))
|
||||
+ {
|
||||
IDirect3D9_Release(d3d);
|
||||
return D3DXERR_INVALIDDATA;
|
||||
}
|
||||
IDirect3D9_Release(d3d);
|
||||
|
||||
- object = HeapAlloc(GetProcessHeap(), 0, sizeof(struct d3dx_font));
|
||||
- if(object==NULL) {
|
||||
- *font=NULL;
|
||||
+ object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct d3dx_font));
|
||||
+ if (!object)
|
||||
+ {
|
||||
+ *font = NULL;
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
object->ID3DXFont_iface.lpVtbl = &D3DXFont_Vtbl;
|
||||
- object->ref=1;
|
||||
- object->device=device;
|
||||
- object->desc=*desc;
|
||||
+ object->ref = 1;
|
||||
+ object->device = device;
|
||||
+ object->desc = *desc;
|
||||
|
||||
object->hdc = CreateCompatibleDC(NULL);
|
||||
- if( !object->hdc ) {
|
||||
+ if (!object->hdc)
|
||||
+ {
|
||||
HeapFree(GetProcessHeap(), 0, object);
|
||||
return D3DXERR_INVALIDDATA;
|
||||
}
|
||||
|
||||
object->hfont = CreateFontW(desc->Height, desc->Width, 0, 0, desc->Weight, desc->Italic, FALSE, FALSE, desc->CharSet,
|
||||
desc->OutputPrecision, CLIP_DEFAULT_PRECIS, desc->Quality, desc->PitchAndFamily, desc->FaceName);
|
||||
- if( !object->hfont ) {
|
||||
+ if (!object->hfont)
|
||||
+ {
|
||||
DeleteDC(object->hdc);
|
||||
HeapFree(GetProcessHeap(), 0, object);
|
||||
return D3DXERR_INVALIDDATA;
|
||||
}
|
||||
SelectObject(object->hdc, object->hfont);
|
||||
+ SetTextColor(object->hdc, 0x00ffffff);
|
||||
+ SetBkColor(object->hdc, 0x00000000);
|
||||
|
||||
IDirect3DDevice9_AddRef(device);
|
||||
- *font=&object->ID3DXFont_iface;
|
||||
+ *font = &object->ID3DXFont_iface;
|
||||
|
||||
return D3D_OK;
|
||||
}
|
||||
--
|
||||
1.9.1
|
||||
|
@@ -1,32 +0,0 @@
|
||||
From 93b91dc6b0ccaf6c9babab7adb218454df93b750 Mon Sep 17 00:00:00 2001
|
||||
From: Christian Costa <titan.costa@gmail.com>
|
||||
Date: Sun, 4 Jan 2015 18:43:42 +0100
|
||||
Subject: d3dx9_36: Fix horizontal centering in ID3DXFont_DrawText.
|
||||
|
||||
Fix remaining text issues in Air Strike.
|
||||
Should fix text placement in Stronghold Kingdoms.
|
||||
---
|
||||
dlls/d3dx9_36/font.c | 7 +++++++
|
||||
1 file changed, 7 insertions(+)
|
||||
|
||||
diff --git a/dlls/d3dx9_36/font.c b/dlls/d3dx9_36/font.c
|
||||
index 368c784..fa52859 100644
|
||||
--- a/dlls/d3dx9_36/font.c
|
||||
+++ b/dlls/d3dx9_36/font.c
|
||||
@@ -254,6 +254,13 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
|
||||
return height;
|
||||
}
|
||||
|
||||
+ if (format & DT_CENTER)
|
||||
+ {
|
||||
+ UINT new_width = calc_rect.right - calc_rect.left;
|
||||
+ calc_rect.left = (rect->right + rect->left - new_width) / 2;
|
||||
+ calc_rect.right = calc_rect.left + new_width;
|
||||
+ }
|
||||
+
|
||||
if (height && (calc_rect.left < calc_rect.right))
|
||||
{
|
||||
D3DLOCKED_RECT locked_rect;
|
||||
--
|
||||
2.2.1
|
||||
|
@@ -1,47 +0,0 @@
|
||||
From 0b6fc918564f580a9d62f14d76da83349075574f Mon Sep 17 00:00:00 2001
|
||||
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
Date: Fri, 4 Dec 2015 09:22:35 +1100
|
||||
Subject: [PATCH] d3dx9_36: Support NULL terminated strings in
|
||||
ID3DXFont_DrawText
|
||||
|
||||
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
---
|
||||
dlls/d3dx9_36/font.c | 10 ++++++++--
|
||||
dlls/d3dx9_36/tests/core.c | 1 -
|
||||
2 files changed, 8 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/dlls/d3dx9_36/font.c b/dlls/d3dx9_36/font.c
|
||||
index ad1eb2383e4..83fec560fc5 100644
|
||||
--- a/dlls/d3dx9_36/font.c
|
||||
+++ b/dlls/d3dx9_36/font.c
|
||||
@@ -210,9 +210,12 @@ static INT WINAPI ID3DXFontImpl_DrawTextA(ID3DXFont *iface, ID3DXSprite *sprite,
|
||||
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
|
||||
iface, sprite, debugstr_a(string), count, wine_dbgstr_rect(rect), format, color);
|
||||
|
||||
- if (!string || count <= 0)
|
||||
+ if (!string || count == 0)
|
||||
return 0;
|
||||
|
||||
+ if (count < 0)
|
||||
+ count = -1;
|
||||
+
|
||||
countW = MultiByteToWideChar(CP_ACP, 0, string, count, NULL, 0);
|
||||
stringW = HeapAlloc(GetProcessHeap(), 0, countW * sizeof(WCHAR));
|
||||
if (stringW)
|
||||
@@ -235,9 +238,12 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
|
||||
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
|
||||
iface, sprite, debugstr_w(string), count, wine_dbgstr_rect(rect), format, color);
|
||||
|
||||
- if (!string || count <= 0)
|
||||
+ if (!string || count == 0)
|
||||
return 0;
|
||||
|
||||
+ if (count < 0)
|
||||
+ count = lstrlenW(string);
|
||||
+
|
||||
/* Strip terminating NULL characters */
|
||||
while (count > 0 && !string[count-1])
|
||||
count--;
|
||||
--
|
||||
2.17.1
|
||||
|
@@ -1,43 +0,0 @@
|
||||
From ccf7cfe0cd7cbaa15ee34b4390dd6c30cf7e84ec Mon Sep 17 00:00:00 2001
|
||||
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
Date: Sat, 5 Dec 2015 15:31:06 +1100
|
||||
Subject: [PATCH] d3dx9_36: ID3DXFont_DrawText calc_rect can be null
|
||||
|
||||
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
---
|
||||
dlls/d3dx9_36/font.c | 8 ++++++--
|
||||
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dlls/d3dx9_36/font.c b/dlls/d3dx9_36/font.c
|
||||
index 83fec560fc5..f5c704ebabb 100644
|
||||
--- a/dlls/d3dx9_36/font.c
|
||||
+++ b/dlls/d3dx9_36/font.c
|
||||
@@ -232,7 +232,7 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
|
||||
const WCHAR *string, INT count, RECT *rect, DWORD format, D3DCOLOR color)
|
||||
{
|
||||
struct d3dx_font *This = impl_from_ID3DXFont(iface);
|
||||
- RECT calc_rect = *rect;
|
||||
+ RECT calc_rect;
|
||||
INT height;
|
||||
|
||||
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
|
||||
@@ -248,11 +248,15 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
|
||||
while (count > 0 && !string[count-1])
|
||||
count--;
|
||||
|
||||
+ if (rect)
|
||||
+ calc_rect = *rect;
|
||||
+
|
||||
height = DrawTextW(This->hdc, string, count, &calc_rect, format | DT_CALCRECT);
|
||||
|
||||
if (format & DT_CALCRECT)
|
||||
{
|
||||
- *rect = calc_rect;
|
||||
+ if (rect)
|
||||
+ *rect = calc_rect;
|
||||
return height;
|
||||
}
|
||||
|
||||
--
|
||||
2.17.1
|
||||
|
@@ -1 +0,0 @@
|
||||
Fixes: [24754] Support for ID3DXFont::DrawTextA/W
|
@@ -1,15 +1,15 @@
|
||||
From e920f461eaf4c5d19c0cfc8e9c9a40671269dd93 Mon Sep 17 00:00:00 2001
|
||||
From b17741a716e2633c02c2237eb424f126860a0c39 Mon Sep 17 00:00:00 2001
|
||||
From: Sebastian Lackner <sebastian@fds-team.de>
|
||||
Date: Mon, 6 Oct 2014 05:06:06 +0200
|
||||
Subject: [PATCH] dbghelp: Always check for debug symbols in BINDIR.
|
||||
|
||||
---
|
||||
dlls/dbghelp/Makefile.in | 2 +-
|
||||
dlls/dbghelp/elf_module.c | 8 +++++---
|
||||
2 files changed, 6 insertions(+), 4 deletions(-)
|
||||
dlls/dbghelp/elf_module.c | 1 +
|
||||
2 files changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dlls/dbghelp/Makefile.in b/dlls/dbghelp/Makefile.in
|
||||
index f08464cd422..aa7a767110b 100644
|
||||
index 076c50323dd..ddb69c96dd4 100644
|
||||
--- a/dlls/dbghelp/Makefile.in
|
||||
+++ b/dlls/dbghelp/Makefile.in
|
||||
@@ -1,6 +1,6 @@
|
||||
@@ -18,27 +18,20 @@ index f08464cd422..aa7a767110b 100644
|
||||
-EXTRADEFS = -D_IMAGEHLP_SOURCE_
|
||||
+EXTRADEFS = -D_IMAGEHLP_SOURCE_ -DBINDIR="\"${bindir}\""
|
||||
DELAYIMPORTS = version
|
||||
EXTRAINCL = $(Z_CFLAGS)
|
||||
EXTRALIBS = $(Z_LIBS) $(CORESERVICES_LIBS) $(COREFOUNDATION_LIBS)
|
||||
|
||||
EXTRADLLFLAGS = -mno-cygwin
|
||||
diff --git a/dlls/dbghelp/elf_module.c b/dlls/dbghelp/elf_module.c
|
||||
index 96b16fd5c0c..611533ee098 100644
|
||||
index ab2a693ecaf..2add1025e39 100644
|
||||
--- a/dlls/dbghelp/elf_module.c
|
||||
+++ b/dlls/dbghelp/elf_module.c
|
||||
@@ -1644,9 +1644,11 @@ static BOOL elf_search_and_load_file(struct process* pcs, const WCHAR* filename,
|
||||
if (!ret && !strchrW(filename, '/'))
|
||||
{
|
||||
ret = elf_load_file_from_path(pcs, filename, load_offset, dyn_addr,
|
||||
- getenv("PATH"), elf_info) ||
|
||||
- elf_load_file_from_path(pcs, filename, load_offset, dyn_addr,
|
||||
- getenv("LD_LIBRARY_PATH"), elf_info);
|
||||
+ getenv("PATH"), elf_info);
|
||||
+ if (!ret) ret = elf_load_file_from_path(pcs, filename, load_offset, dyn_addr,
|
||||
+ getenv("LD_LIBRARY_PATH"), elf_info);
|
||||
+ if (!ret) ret = elf_load_file_from_path(pcs, filename, load_offset, dyn_addr,
|
||||
+ BINDIR, elf_info);
|
||||
if (!ret) ret = elf_load_file_from_dll_path(pcs, filename,
|
||||
load_offset, dyn_addr, elf_info);
|
||||
@@ -1436,6 +1436,7 @@ static BOOL elf_search_and_load_file(struct process* pcs, const WCHAR* filename,
|
||||
load_elf.elf_info = elf_info;
|
||||
|
||||
ret = search_unix_path(filename, getenv("LD_LIBRARY_PATH"), elf_load_file_cb, &load_elf)
|
||||
+ || search_unix_path(filename, BINDIR, elf_load_file_cb, &load_elf)
|
||||
|| search_dll_path(pcs, filename, elf_load_file_cb, &load_elf);
|
||||
}
|
||||
|
||||
--
|
||||
2.20.1
|
||||
2.26.0
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From cdf51c18aa92ddfc4df67216ebeaea0c393d8cbd Mon Sep 17 00:00:00 2001
|
||||
From 2097fbe83a66a3a423bdd148ecfc4f16c1237110 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Wed, 29 Jul 2015 17:09:50 +0200
|
||||
Subject: [PATCH] ddraw: Create rendering targets in video memory if possible.
|
||||
@@ -12,10 +12,10 @@ Based on a patch by Henri Verbeet.
|
||||
4 files changed, 56 insertions(+), 15 deletions(-)
|
||||
|
||||
diff --git a/dlls/ddraw/ddraw.c b/dlls/ddraw/ddraw.c
|
||||
index e77aab1cc5c..7df9cf5b28f 100644
|
||||
index 050f625f7..9655f9e47 100644
|
||||
--- a/dlls/ddraw/ddraw.c
|
||||
+++ b/dlls/ddraw/ddraw.c
|
||||
@@ -4297,7 +4297,7 @@ static HRESULT WINAPI d3d7_CreateDevice(IDirect3D7 *iface, REFCLSID riid,
|
||||
@@ -4214,7 +4214,7 @@ static HRESULT WINAPI d3d7_CreateDevice(IDirect3D7 *iface, REFCLSID riid,
|
||||
TRACE("iface %p, riid %s, surface %p, device %p.\n", iface, debugstr_guid(riid), surface, device);
|
||||
|
||||
wined3d_mutex_lock();
|
||||
@@ -24,7 +24,7 @@ index e77aab1cc5c..7df9cf5b28f 100644
|
||||
{
|
||||
*device = &object->IDirect3DDevice7_iface;
|
||||
}
|
||||
@@ -4326,7 +4326,7 @@ static HRESULT WINAPI d3d3_CreateDevice(IDirect3D3 *iface, REFCLSID riid,
|
||||
@@ -4243,7 +4243,7 @@ static HRESULT WINAPI d3d3_CreateDevice(IDirect3D3 *iface, REFCLSID riid,
|
||||
return CLASS_E_NOAGGREGATION;
|
||||
|
||||
wined3d_mutex_lock();
|
||||
@@ -33,7 +33,7 @@ index e77aab1cc5c..7df9cf5b28f 100644
|
||||
{
|
||||
*device = &device_impl->IDirect3DDevice3_iface;
|
||||
}
|
||||
@@ -4352,7 +4352,7 @@ static HRESULT WINAPI d3d2_CreateDevice(IDirect3D2 *iface, REFCLSID riid,
|
||||
@@ -4269,7 +4269,7 @@ static HRESULT WINAPI d3d2_CreateDevice(IDirect3D2 *iface, REFCLSID riid,
|
||||
iface, debugstr_guid(riid), surface, device);
|
||||
|
||||
wined3d_mutex_lock();
|
||||
@@ -43,10 +43,10 @@ index e77aab1cc5c..7df9cf5b28f 100644
|
||||
*device = &device_impl->IDirect3DDevice2_iface;
|
||||
}
|
||||
diff --git a/dlls/ddraw/ddraw_private.h b/dlls/ddraw/ddraw_private.h
|
||||
index 4ecd83d006b..c11f4f0aa80 100644
|
||||
index f4fe970a6..ba0ec73d8 100644
|
||||
--- a/dlls/ddraw/ddraw_private.h
|
||||
+++ b/dlls/ddraw/ddraw_private.h
|
||||
@@ -309,6 +309,7 @@ struct d3d_device
|
||||
@@ -313,6 +313,7 @@ struct d3d_device
|
||||
IUnknown IUnknown_inner;
|
||||
LONG ref;
|
||||
UINT version;
|
||||
@@ -54,8 +54,8 @@ index 4ecd83d006b..c11f4f0aa80 100644
|
||||
|
||||
IUnknown *outer_unknown;
|
||||
struct wined3d_device *wined3d_device;
|
||||
@@ -356,7 +357,7 @@ struct d3d_device
|
||||
struct wined3d_stateblock *recording, *state, *update_state;
|
||||
@@ -360,7 +361,7 @@ struct d3d_device
|
||||
const struct wined3d_stateblock_state *stateblock_state;
|
||||
};
|
||||
|
||||
-HRESULT d3d_device_create(struct ddraw *ddraw, struct ddraw_surface *target, IUnknown *rt_iface,
|
||||
@@ -64,10 +64,10 @@ index 4ecd83d006b..c11f4f0aa80 100644
|
||||
enum wined3d_depth_buffer_type d3d_device_update_depth_stencil(struct d3d_device *device) DECLSPEC_HIDDEN;
|
||||
|
||||
diff --git a/dlls/ddraw/device.c b/dlls/ddraw/device.c
|
||||
index ffa029321c1..31f76bdcbd3 100644
|
||||
index 048ba7fba..ce74a0fb8 100644
|
||||
--- a/dlls/ddraw/device.c
|
||||
+++ b/dlls/ddraw/device.c
|
||||
@@ -1854,7 +1854,7 @@ static HRESULT d3d_device7_SetRenderTarget(IDirect3DDevice7 *iface,
|
||||
@@ -1858,7 +1858,7 @@ static HRESULT d3d_device7_SetRenderTarget(IDirect3DDevice7 *iface,
|
||||
return DDERR_INVALIDCAPS;
|
||||
}
|
||||
|
||||
@@ -76,7 +76,7 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
{
|
||||
WARN("Surface %p is not in video memory.\n", target_impl);
|
||||
wined3d_mutex_unlock();
|
||||
@@ -1930,7 +1930,7 @@ static HRESULT WINAPI d3d_device3_SetRenderTarget(IDirect3DDevice3 *iface,
|
||||
@@ -1934,7 +1934,7 @@ static HRESULT WINAPI d3d_device3_SetRenderTarget(IDirect3DDevice3 *iface,
|
||||
return DDERR_INVALIDPIXELFORMAT;
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
{
|
||||
WARN("Surface %p is not in video memory.\n", target_impl);
|
||||
IDirectDrawSurface4_AddRef(target);
|
||||
@@ -1979,7 +1979,7 @@ static HRESULT WINAPI d3d_device2_SetRenderTarget(IDirect3DDevice2 *iface,
|
||||
@@ -1983,7 +1983,7 @@ static HRESULT WINAPI d3d_device2_SetRenderTarget(IDirect3DDevice2 *iface,
|
||||
return DDERR_INVALIDPIXELFORMAT;
|
||||
}
|
||||
|
||||
@@ -94,7 +94,7 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
{
|
||||
WARN("Surface %p is not in video memory.\n", target_impl);
|
||||
IDirectDrawSurface_AddRef(target);
|
||||
@@ -6972,7 +6972,7 @@ static void ddraw_reset_viewport_state(struct ddraw *ddraw)
|
||||
@@ -6951,7 +6951,7 @@ static void ddraw_reset_viewport_state(struct ddraw *ddraw)
|
||||
wined3d_stateblock_set_scissor_rect(ddraw->state, &rect);
|
||||
}
|
||||
|
||||
@@ -102,8 +102,8 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
+static HRESULT d3d_device_init(struct d3d_device *device, struct ddraw *ddraw, BOOL hw,
|
||||
struct ddraw_surface *target, IUnknown *rt_iface, UINT version, IUnknown *outer_unknown)
|
||||
{
|
||||
static const D3DMATRIX ident =
|
||||
@@ -6995,6 +6995,7 @@ static HRESULT d3d_device_init(struct d3d_device *device, struct ddraw *ddraw,
|
||||
static const struct wined3d_matrix ident =
|
||||
@@ -6974,6 +6974,7 @@ static HRESULT d3d_device_init(struct d3d_device *device, struct ddraw *ddraw,
|
||||
device->IUnknown_inner.lpVtbl = &d3d_device_inner_vtbl;
|
||||
device->ref = 1;
|
||||
device->version = version;
|
||||
@@ -111,7 +111,7 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
|
||||
if (outer_unknown)
|
||||
device->outer_unknown = outer_unknown;
|
||||
@@ -7054,14 +7055,18 @@ static HRESULT d3d_device_init(struct d3d_device *device, struct ddraw *ddraw,
|
||||
@@ -7032,14 +7033,18 @@ static HRESULT d3d_device_init(struct d3d_device *device, struct ddraw *ddraw,
|
||||
return D3D_OK;
|
||||
}
|
||||
|
||||
@@ -133,7 +133,7 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
|
||||
if (!(target->surface_desc.ddsCaps.dwCaps & DDSCAPS_3DDEVICE)
|
||||
|| (target->surface_desc.ddsCaps.dwCaps & DDSCAPS_ZBUFFER))
|
||||
@@ -7084,7 +7089,7 @@ HRESULT d3d_device_create(struct ddraw *ddraw, struct ddraw_surface *target, IUn
|
||||
@@ -7062,7 +7067,7 @@ HRESULT d3d_device_create(struct ddraw *ddraw, struct ddraw_surface *target, IUn
|
||||
return DDERR_OUTOFMEMORY;
|
||||
}
|
||||
|
||||
@@ -142,7 +142,7 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
{
|
||||
WARN("Surface %p is not in video memory.\n", target);
|
||||
return D3DERR_SURFACENOTINVIDMEM;
|
||||
@@ -7102,7 +7107,7 @@ HRESULT d3d_device_create(struct ddraw *ddraw, struct ddraw_surface *target, IUn
|
||||
@@ -7080,7 +7085,7 @@ HRESULT d3d_device_create(struct ddraw *ddraw, struct ddraw_surface *target, IUn
|
||||
return DDERR_OUTOFMEMORY;
|
||||
}
|
||||
|
||||
@@ -152,7 +152,7 @@ index ffa029321c1..31f76bdcbd3 100644
|
||||
WARN("Failed to initialize device, hr %#x.\n", hr);
|
||||
heap_free(object);
|
||||
diff --git a/dlls/ddraw/surface.c b/dlls/ddraw/surface.c
|
||||
index 1f24c49634b..dc017d87467 100644
|
||||
index 85c1ef496..01522f515 100644
|
||||
--- a/dlls/ddraw/surface.c
|
||||
+++ b/dlls/ddraw/surface.c
|
||||
@@ -223,7 +223,7 @@ static HRESULT WINAPI ddraw_surface7_QueryInterface(IDirectDrawSurface7 *iface,
|
||||
@@ -164,7 +164,7 @@ index 1f24c49634b..dc017d87467 100644
|
||||
1, &This->device1, (IUnknown *)&This->IDirectDrawSurface_iface)))
|
||||
{
|
||||
This->device1 = NULL;
|
||||
@@ -6201,7 +6201,42 @@ HRESULT ddraw_surface_create(struct ddraw *ddraw, const DDSURFACEDESC2 *surface_
|
||||
@@ -6192,7 +6192,42 @@ HRESULT ddraw_surface_create(struct ddraw *ddraw, const DDSURFACEDESC2 *surface_
|
||||
|
||||
if (desc->ddsCaps.dwCaps & DDSCAPS_SYSTEMMEMORY)
|
||||
{
|
||||
@@ -196,7 +196,7 @@ index 1f24c49634b..dc017d87467 100644
|
||||
+ * possible.
|
||||
+ */
|
||||
+ if (bind_flags
|
||||
+ && SUCCEEDED(hr = wined3d_check_device_format(ddraw->wined3d, WINED3DADAPTER_DEFAULT,
|
||||
+ && SUCCEEDED(hr = wined3d_check_device_format(ddraw->wined3d, ddraw->wined3d_adapter,
|
||||
+ WINED3D_DEVICE_TYPE_HAL, mode.format_id, 0,
|
||||
+ bind_flags, WINED3D_RTYPE_TEXTURE_2D, wined3d_desc.format)))
|
||||
+ {
|
||||
@@ -209,5 +209,5 @@ index 1f24c49634b..dc017d87467 100644
|
||||
}
|
||||
else
|
||||
--
|
||||
2.17.1
|
||||
2.25.1
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 882c25ffe94d7e8869ed5a364120cf0c5f2ef241 Mon Sep 17 00:00:00 2001
|
||||
From a6f14f05fefc9510f673b47092cbc62a2366ccf9 Mon Sep 17 00:00:00 2001
|
||||
From: Paul Gofman <gofmanp@gmail.com>
|
||||
Date: Thu, 4 Apr 2019 02:25:00 +0300
|
||||
Subject: [PATCH] ddraw: Allow setting texture without DDSCAPS_TEXTURE for
|
||||
@@ -6,26 +6,15 @@ Subject: [PATCH] ddraw: Allow setting texture without DDSCAPS_TEXTURE for
|
||||
|
||||
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
|
||||
---
|
||||
dlls/ddraw/device.c | 22 +++++--
|
||||
dlls/ddraw/device.c | 20 ++++--
|
||||
dlls/ddraw/tests/ddraw4.c | 128 +++++++++++++++++++++++++++++++++++++-
|
||||
2 files changed, 141 insertions(+), 9 deletions(-)
|
||||
2 files changed, 141 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/dlls/ddraw/device.c b/dlls/ddraw/device.c
|
||||
index e2643e6589..a43bca7a14 100644
|
||||
index 11e60f80c..324475303 100644
|
||||
--- a/dlls/ddraw/device.c
|
||||
+++ b/dlls/ddraw/device.c
|
||||
@@ -2921,10 +2921,8 @@ static HRESULT WINAPI d3d_device3_SetLightState(IDirect3DDevice3 *iface,
|
||||
wined3d_mutex_unlock();
|
||||
return DDERR_INVALIDPARAMS;
|
||||
}
|
||||
-
|
||||
material_activate(m);
|
||||
}
|
||||
-
|
||||
device->material = value;
|
||||
}
|
||||
else if (state == D3DLIGHTSTATE_COLORMODEL)
|
||||
@@ -4807,7 +4805,8 @@ static HRESULT d3d_device7_SetTexture(IDirect3DDevice7 *iface,
|
||||
@@ -4798,7 +4798,8 @@ static HRESULT d3d_device7_SetTexture(IDirect3DDevice7 *iface,
|
||||
struct ddraw_surface *surf = unsafe_impl_from_IDirectDrawSurface7(texture);
|
||||
struct wined3d_texture *wined3d_texture = NULL;
|
||||
|
||||
@@ -35,7 +24,7 @@ index e2643e6589..a43bca7a14 100644
|
||||
|
||||
if (surf && (surf->surface_desc.ddsCaps.dwCaps & DDSCAPS_TEXTURE))
|
||||
wined3d_texture = surf->wined3d_texture;
|
||||
@@ -4845,19 +4844,30 @@ static HRESULT WINAPI d3d_device3_SetTexture(IDirect3DDevice3 *iface,
|
||||
@@ -4834,19 +4835,30 @@ static HRESULT WINAPI d3d_device3_SetTexture(IDirect3DDevice3 *iface,
|
||||
{
|
||||
struct d3d_device *device = impl_from_IDirect3DDevice3(iface);
|
||||
struct ddraw_surface *tex = unsafe_impl_from_IDirect3DTexture2(texture);
|
||||
@@ -58,7 +47,7 @@ index e2643e6589..a43bca7a14 100644
|
||||
+ wined3d_texture = NULL;
|
||||
+ }
|
||||
+
|
||||
+ wined3d_device_set_texture(device->wined3d_device, stage, wined3d_texture);
|
||||
+ wined3d_stateblock_set_texture(device->state, stage, wined3d_texture);
|
||||
|
||||
fixup_texture_alpha_op(device);
|
||||
|
||||
@@ -70,7 +59,7 @@ index e2643e6589..a43bca7a14 100644
|
||||
|
||||
static const struct tss_lookup
|
||||
diff --git a/dlls/ddraw/tests/ddraw4.c b/dlls/ddraw/tests/ddraw4.c
|
||||
index e3146ca45d..8861244e05 100644
|
||||
index e1d5bac18..e18f3c638 100644
|
||||
--- a/dlls/ddraw/tests/ddraw4.c
|
||||
+++ b/dlls/ddraw/tests/ddraw4.c
|
||||
@@ -330,7 +330,7 @@ static IDirectDraw4 *create_ddraw(void)
|
||||
@@ -132,7 +121,7 @@ index e3146ca45d..8861244e05 100644
|
||||
static IDirect3DViewport3 *create_viewport(IDirect3DDevice3 *device, UINT x, UINT y, UINT w, UINT h)
|
||||
{
|
||||
IDirect3DViewport3 *viewport;
|
||||
@@ -16819,6 +16830,116 @@ static void test_surface_format_conversion_alpha(void)
|
||||
@@ -16980,6 +16991,116 @@ static void test_surface_format_conversion_alpha(void)
|
||||
DestroyWindow(window);
|
||||
}
|
||||
|
||||
@@ -249,7 +238,7 @@ index e3146ca45d..8861244e05 100644
|
||||
START_TEST(ddraw4)
|
||||
{
|
||||
DDDEVICEIDENTIFIER identifier;
|
||||
@@ -16951,6 +17072,7 @@ START_TEST(ddraw4)
|
||||
@@ -17112,6 +17233,7 @@ START_TEST(ddraw4)
|
||||
test_gdi_surface();
|
||||
test_alphatest();
|
||||
test_clipper_refcount();
|
||||
@@ -258,5 +247,5 @@ index e3146ca45d..8861244e05 100644
|
||||
test_d32_support();
|
||||
test_surface_format_conversion_alpha();
|
||||
--
|
||||
2.17.1
|
||||
2.25.1
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From e70e35f995515223d802e47e139089e964576b1f Mon Sep 17 00:00:00 2001
|
||||
From 5ce4edd65773a793bc4b4f8ad1fa3b64b5894c7d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Tue, 10 Feb 2015 16:54:21 +0100
|
||||
Subject: dxva2: Implement stubbed interfaces for
|
||||
@@ -9,15 +9,15 @@ Subject: dxva2: Implement stubbed interfaces for
|
||||
dlls/dxva2/devicemanager.c | 4 +-
|
||||
dlls/dxva2/dxva2_private.h | 1 +
|
||||
dlls/dxva2/main.c | 4 +-
|
||||
dlls/dxva2/videoservices.c | 467 +++++++++++++++++++++++++++++++++++++++++++++
|
||||
dlls/dxva2/videoservices.c | 467 +++++++++++++++++++++++++++++++++++++
|
||||
5 files changed, 474 insertions(+), 5 deletions(-)
|
||||
create mode 100644 dlls/dxva2/videoservices.c
|
||||
|
||||
diff --git a/dlls/dxva2/Makefile.in b/dlls/dxva2/Makefile.in
|
||||
index 27c653d3f20..b517921190b 100644
|
||||
index 5c3e3842d..c86b165e8 100644
|
||||
--- a/dlls/dxva2/Makefile.in
|
||||
+++ b/dlls/dxva2/Makefile.in
|
||||
@@ -3,4 +3,5 @@ IMPORTS = ole32
|
||||
@@ -5,4 +5,5 @@ EXTRADLLFLAGS = -mno-cygwin
|
||||
|
||||
C_SRCS = \
|
||||
devicemanager.c \
|
||||
@@ -25,10 +25,10 @@ index 27c653d3f20..b517921190b 100644
|
||||
+ main.c \
|
||||
+ videoservices.c
|
||||
diff --git a/dlls/dxva2/devicemanager.c b/dlls/dxva2/devicemanager.c
|
||||
index 15d78aa7ff0..b9ed76c865d 100644
|
||||
index bba0fbc61..8182adedc 100644
|
||||
--- a/dlls/dxva2/devicemanager.c
|
||||
+++ b/dlls/dxva2/devicemanager.c
|
||||
@@ -169,9 +169,9 @@ static HRESULT WINAPI Direct3DDeviceManager9_GetVideoService( IDirect3DDeviceMan
|
||||
@@ -170,9 +170,9 @@ static HRESULT WINAPI Direct3DDeviceManager9_GetVideoService( IDirect3DDeviceMan
|
||||
{
|
||||
Direct3DDeviceManager9Impl *This = impl_from_Direct3DDeviceManager9(iface);
|
||||
|
||||
@@ -41,7 +41,7 @@ index 15d78aa7ff0..b9ed76c865d 100644
|
||||
|
||||
static const IDirect3DDeviceManager9Vtbl Direct3DDeviceManager9_VTable =
|
||||
diff --git a/dlls/dxva2/dxva2_private.h b/dlls/dxva2/dxva2_private.h
|
||||
index d6e59fc6da8..a88809cf7ec 100644
|
||||
index d6e59fc6d..a88809cf7 100644
|
||||
--- a/dlls/dxva2/dxva2_private.h
|
||||
+++ b/dlls/dxva2/dxva2_private.h
|
||||
@@ -18,4 +18,5 @@
|
||||
@@ -51,7 +51,7 @@ index d6e59fc6da8..a88809cf7ec 100644
|
||||
+extern HRESULT videoservice_create( IDirect3DDevice9 *device, REFIID riid, void **ppv ) DECLSPEC_HIDDEN;
|
||||
extern HRESULT devicemanager_create( UINT *resetToken, void **ppv ) DECLSPEC_HIDDEN;
|
||||
diff --git a/dlls/dxva2/main.c b/dlls/dxva2/main.c
|
||||
index df8f2030104..0382b5fb00a 100644
|
||||
index df8f20301..0382b5fb0 100644
|
||||
--- a/dlls/dxva2/main.c
|
||||
+++ b/dlls/dxva2/main.c
|
||||
@@ -49,9 +49,9 @@ HRESULT WINAPI DXVA2CreateDirect3DDeviceManager9( UINT *resetToken, IDirect3DDev
|
||||
@@ -68,7 +68,7 @@ index df8f2030104..0382b5fb00a 100644
|
||||
BOOL WINAPI DegaussMonitor( HMONITOR monitor )
|
||||
diff --git a/dlls/dxva2/videoservices.c b/dlls/dxva2/videoservices.c
|
||||
new file mode 100644
|
||||
index 00000000000..936aa37b43c
|
||||
index 000000000..607729502
|
||||
--- /dev/null
|
||||
+++ b/dlls/dxva2/videoservices.c
|
||||
@@ -0,0 +1,467 @@
|
||||
@@ -302,9 +302,9 @@ index 00000000000..936aa37b43c
|
||||
+
|
||||
+ /* TODO: Query decoder instead of using hardcoded values */
|
||||
+
|
||||
+ memcpy(&config->guidConfigBitstreamEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigMBcontrolEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigResidDiffEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigBitstreamEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigMBcontrolEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigResidDiffEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
+
|
||||
+ config->ConfigBitstreamRaw = 1;
|
||||
+ config->ConfigMBcontrolRasterOrder = is_h264_codec(guid) ? 0 : 1;
|
||||
@@ -540,5 +540,5 @@ index 00000000000..936aa37b43c
|
||||
+ return S_OK;
|
||||
+}
|
||||
--
|
||||
2.11.0
|
||||
2.25.0
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 935b985d2e4fab7402030c71ff1a6ba0abdd9874 Mon Sep 17 00:00:00 2001
|
||||
From a667953fb14e6061418e42e77a2bf494121cc2b1 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sun, 22 Feb 2015 01:25:20 +0100
|
||||
Subject: [PATCH] dxva2: Initial implementation of MPEG2 decoder using vaapi
|
||||
@@ -22,19 +22,19 @@ Subject: [PATCH] dxva2: Initial implementation of MPEG2 decoder using vaapi
|
||||
create mode 100644 dlls/dxva2/vaapi.c
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 58e5211e9bc..53aea6188ca 100644
|
||||
index 3766908bd62..13584352f3e 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -110,6 +110,8 @@ AC_ARG_WITH(xslt, AS_HELP_STRING([--without-xslt],[do not use XSLT]))
|
||||
@@ -112,6 +112,8 @@ AC_ARG_WITH(xshm, AS_HELP_STRING([--without-xshm],[do not use XShm (shared
|
||||
AC_ARG_WITH(xslt, AS_HELP_STRING([--without-xslt],[do not use XSLT]))
|
||||
AC_ARG_WITH(xxf86vm, AS_HELP_STRING([--without-xxf86vm],[do not use XFree video mode extension]),
|
||||
[if test "x$withval" = "xno"; then ac_cv_header_X11_extensions_xf86vmode_h=no; ac_cv_header_X11_extensions_xf86vmproto_h=no; fi])
|
||||
AC_ARG_WITH(zlib, AS_HELP_STRING([--without-zlib],[do not use Zlib (data compression)]))
|
||||
+AC_ARG_WITH(va, AS_HELP_STRING([--without-va],[do not use VA (GPU video acceleration)]),
|
||||
+ [if test "x$withval" = "xno"; then ac_cv_header_va_va_x11_h=no; fi])
|
||||
|
||||
AC_ARG_WITH(wine-tools,AS_HELP_STRING([--with-wine-tools=DIR],[use Wine tools from directory DIR]))
|
||||
AC_ARG_WITH(wine64, AS_HELP_STRING([--with-wine64=DIR],[use the 64-bit Wine in DIR for a Wow64 build]))
|
||||
@@ -1292,6 +1294,20 @@ This probably prevents linking to OpenGL. Try deleting the file and restarting c
|
||||
@@ -1319,6 +1321,20 @@ This probably prevents linking to OpenGL. Try deleting the file and restarting c
|
||||
WINE_WARNING_WITH(opengl,[test -n "$opengl_msg"],[$opengl_msg
|
||||
OpenGL and Direct3D won't be supported.])
|
||||
|
||||
@@ -1688,7 +1688,7 @@ index 00000000000..7b7f61db755
|
||||
+#endif /* HAVE_VAAPI */
|
||||
diff --git a/dlls/dxva2/vaapi.c b/dlls/dxva2/vaapi.c
|
||||
new file mode 100644
|
||||
index 00000000000..80e63bf38d9
|
||||
index 00000000000..e2a64065e16
|
||||
--- /dev/null
|
||||
+++ b/dlls/dxva2/vaapi.c
|
||||
@@ -0,0 +1,767 @@
|
||||
@@ -1764,7 +1764,7 @@ index 00000000000..80e63bf38d9
|
||||
+#undef MAKE_FUNCPTR
|
||||
+
|
||||
+#define LOAD_FUNCPTR(f) \
|
||||
+ if(!(p##f = wine_dlsym(handle, #f, NULL, 0))) \
|
||||
+ if(!(p##f = dlsym(handle, #f))) \
|
||||
+ { \
|
||||
+ WARN("Can't find symbol %s.\n", #f); \
|
||||
+ goto error; \
|
||||
@@ -1772,7 +1772,7 @@ index 00000000000..80e63bf38d9
|
||||
+
|
||||
+static void *load_libva( void )
|
||||
+{
|
||||
+ void *handle = wine_dlopen(SONAME_LIBVA, RTLD_NOW, NULL, 0);
|
||||
+ void *handle = dlopen(SONAME_LIBVA, RTLD_NOW);
|
||||
+ if (!handle)
|
||||
+ {
|
||||
+ FIXME("Wine cannot find the %s library.\n", SONAME_LIBVA);
|
||||
@@ -1808,13 +1808,13 @@ index 00000000000..80e63bf38d9
|
||||
+ return handle;
|
||||
+
|
||||
+error:
|
||||
+ wine_dlclose(handle, NULL, 0);
|
||||
+ dlclose(handle);
|
||||
+ return NULL;
|
||||
+}
|
||||
+
|
||||
+static void *load_libva_x11( void )
|
||||
+{
|
||||
+ void *handle = wine_dlopen(SONAME_LIBVA_X11, RTLD_NOW, NULL, 0);
|
||||
+ void *handle = dlopen(SONAME_LIBVA_X11, RTLD_NOW);
|
||||
+ if (!handle)
|
||||
+ {
|
||||
+ FIXME("Wine cannot find the %s library.\n", SONAME_LIBVA_X11);
|
||||
@@ -1825,13 +1825,13 @@ index 00000000000..80e63bf38d9
|
||||
+ return handle;
|
||||
+
|
||||
+error:
|
||||
+ wine_dlclose(handle, NULL, 0);
|
||||
+ dlclose(handle);
|
||||
+ return NULL;
|
||||
+}
|
||||
+
|
||||
+static void *load_libx11( void )
|
||||
+{
|
||||
+ void *handle = wine_dlopen(SONAME_LIBX11, RTLD_NOW, NULL, 0);
|
||||
+ void *handle = dlopen(SONAME_LIBX11, RTLD_NOW);
|
||||
+ if (!handle)
|
||||
+ {
|
||||
+ FIXME("Wine cannot find the %s library.\n", SONAME_LIBX11);
|
||||
@@ -1843,7 +1843,7 @@ index 00000000000..80e63bf38d9
|
||||
+ return handle;
|
||||
+
|
||||
+error:
|
||||
+ wine_dlclose(handle, NULL, 0);
|
||||
+ dlclose(handle);
|
||||
+ return NULL;
|
||||
+}
|
||||
+
|
||||
@@ -2176,9 +2176,9 @@ index 00000000000..80e63bf38d9
|
||||
+
|
||||
+ pXCloseDisplay(This->x11_display);
|
||||
+
|
||||
+ wine_dlclose(This->x11_handle, NULL, 0);
|
||||
+ wine_dlclose(This->va_x11_handle, NULL, 0);
|
||||
+ wine_dlclose(This->va_handle, NULL, 0);
|
||||
+ dlclose(This->x11_handle);
|
||||
+ dlclose(This->va_x11_handle);
|
||||
+ dlclose(This->va_handle);
|
||||
+
|
||||
+ CoTaskMemFree(This);
|
||||
+ }
|
||||
@@ -2306,9 +2306,9 @@ index 00000000000..80e63bf38d9
|
||||
+ return E_OUTOFMEMORY;
|
||||
+
|
||||
+ /* TODO: Query decoder instead of using hardcoded values */
|
||||
+ memcpy(&config->guidConfigBitstreamEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigMBcontrolEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigResidDiffEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigBitstreamEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigMBcontrolEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
+ memcpy(&config->guidConfigResidDiffEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
+
|
||||
+ config->ConfigBitstreamRaw = 1;
|
||||
+ config->ConfigMBcontrolRasterOrder = is_h264_codec(guid) ? 0 : 1;
|
||||
@@ -2440,11 +2440,11 @@ index 00000000000..80e63bf38d9
|
||||
+ if (videoservice->x11_display)
|
||||
+ pXCloseDisplay(videoservice->x11_display);
|
||||
+ if (videoservice->x11_handle)
|
||||
+ wine_dlclose(videoservice->x11_handle, NULL, 0);
|
||||
+ dlclose(videoservice->x11_handle);
|
||||
+ if (videoservice->va_x11_handle)
|
||||
+ wine_dlclose(videoservice->va_x11_handle, NULL, 0);
|
||||
+ dlclose(videoservice->va_x11_handle);
|
||||
+ if (videoservice->va_handle)
|
||||
+ wine_dlclose(videoservice->va_handle, NULL, 0);
|
||||
+ dlclose(videoservice->va_handle);
|
||||
+
|
||||
+ CoTaskMemFree(videoservice);
|
||||
+ return NULL;
|
||||
@@ -2460,7 +2460,7 @@ index 00000000000..80e63bf38d9
|
||||
+
|
||||
+#endif /* HAVE_VAAPI */
|
||||
diff --git a/dlls/dxva2/videoservices.c b/dlls/dxva2/videoservices.c
|
||||
index 46e431a7f29..84222dce558 100644
|
||||
index 11cba14417a..84222dce558 100644
|
||||
--- a/dlls/dxva2/videoservices.c
|
||||
+++ b/dlls/dxva2/videoservices.c
|
||||
@@ -1,5 +1,5 @@
|
||||
@@ -2540,9 +2540,9 @@ index 46e431a7f29..84222dce558 100644
|
||||
-
|
||||
- /* TODO: Query decoder instead of using hardcoded values */
|
||||
-
|
||||
- memcpy(&config->guidConfigBitstreamEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
- memcpy(&config->guidConfigMBcontrolEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
- memcpy(&config->guidConfigResidDiffEncryption, &DXVA_NoEncrypt, sizeof(GUID));
|
||||
- memcpy(&config->guidConfigBitstreamEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
- memcpy(&config->guidConfigMBcontrolEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
- memcpy(&config->guidConfigResidDiffEncryption, &DXVA2_NoEncrypt, sizeof(GUID));
|
||||
-
|
||||
- config->ConfigBitstreamRaw = 1;
|
||||
- config->ConfigMBcontrolRasterOrder = is_h264_codec(guid) ? 0 : 1;
|
||||
@@ -2637,5 +2637,5 @@ index 46e431a7f29..84222dce558 100644
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
--
|
||||
2.20.1
|
||||
2.25.1
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 84b8c115d10082aff224d56bebc3fbd63c0b6377 Mon Sep 17 00:00:00 2001
|
||||
From 8f9f3999c7b8cbd610fa0e91d1ffeb9a59f687c5 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Wed, 4 Mar 2015 03:57:29 +0100
|
||||
Subject: [PATCH] dxva2: Add DRM mode for vaapi.
|
||||
@@ -11,10 +11,10 @@ Subject: [PATCH] dxva2: Add DRM mode for vaapi.
|
||||
4 files changed, 91 insertions(+), 22 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 2d60234b02..7a93b20ca6 100644
|
||||
index 13584352f3e..06df84aa378 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -1297,17 +1297,18 @@ This probably prevents linking to OpenGL. Try deleting the file and restarting c
|
||||
@@ -1322,17 +1322,18 @@ This probably prevents linking to OpenGL. Try deleting the file and restarting c
|
||||
OpenGL and Direct3D won't be supported.])
|
||||
|
||||
dnl **** Check for libva ****
|
||||
@@ -38,7 +38,7 @@ index 2d60234b02..7a93b20ca6 100644
|
||||
|
||||
CPPFLAGS="$ac_save_CPPFLAGS"
|
||||
diff --git a/dlls/dxva2/dxva2_private.h b/dlls/dxva2/dxva2_private.h
|
||||
index 5df59bd3f0..14ac586240 100644
|
||||
index 5df59bd3f03..b1d2dd9b92d 100644
|
||||
--- a/dlls/dxva2/dxva2_private.h
|
||||
+++ b/dlls/dxva2/dxva2_private.h
|
||||
@@ -22,6 +22,7 @@
|
||||
@@ -74,7 +74,7 @@ index 5df59bd3f0..14ac586240 100644
|
||||
|
||||
static inline WineVideoServiceImpl *impl_from_IWineVideoService( IWineVideoService *iface )
|
||||
diff --git a/dlls/dxva2/main.c b/dlls/dxva2/main.c
|
||||
index 3006f175b7..9da3995f78 100644
|
||||
index 3006f175b7f..9da3995f788 100644
|
||||
--- a/dlls/dxva2/main.c
|
||||
+++ b/dlls/dxva2/main.c
|
||||
@@ -33,6 +33,8 @@
|
||||
@@ -100,7 +100,7 @@ index 3006f175b7..9da3995f78 100644
|
||||
if (appkey) RegCloseKey(appkey);
|
||||
}
|
||||
diff --git a/dlls/dxva2/vaapi.c b/dlls/dxva2/vaapi.c
|
||||
index 4c570f5b94..1b19684053 100644
|
||||
index ef5fb5d26a6..8be65df82f7 100644
|
||||
--- a/dlls/dxva2/vaapi.c
|
||||
+++ b/dlls/dxva2/vaapi.c
|
||||
@@ -55,6 +55,7 @@ MAKE_FUNCPTR(vaEndPicture);
|
||||
@@ -117,7 +117,7 @@ index 4c570f5b94..1b19684053 100644
|
||||
|
||||
+static void *load_libva_drm( void )
|
||||
+{
|
||||
+ void *handle = wine_dlopen(SONAME_LIBVA_DRM, RTLD_NOW, NULL, 0);
|
||||
+ void *handle = dlopen(SONAME_LIBVA_DRM, RTLD_NOW);
|
||||
+ if (!handle)
|
||||
+ {
|
||||
+ FIXME("Wine cannot find the %s library.\n", SONAME_LIBVA_DRM);
|
||||
@@ -128,34 +128,34 @@ index 4c570f5b94..1b19684053 100644
|
||||
+ return handle;
|
||||
+
|
||||
+error:
|
||||
+ wine_dlclose(handle, NULL, 0);
|
||||
+ dlclose(handle);
|
||||
+ return NULL;
|
||||
+}
|
||||
+
|
||||
static void *load_libx11( void )
|
||||
{
|
||||
void *handle = wine_dlopen(SONAME_LIBX11, RTLD_NOW, NULL, 0);
|
||||
void *handle = dlopen(SONAME_LIBX11, RTLD_NOW);
|
||||
@@ -480,11 +498,18 @@ static ULONG WINAPI WineVideoService_Release( IWineVideoService *iface )
|
||||
pvaTerminate(This->va_display);
|
||||
vaapi_unlock();
|
||||
|
||||
- pXCloseDisplay(This->x11_display);
|
||||
-
|
||||
- wine_dlclose(This->x11_handle, NULL, 0);
|
||||
- wine_dlclose(This->va_x11_handle, NULL, 0);
|
||||
- wine_dlclose(This->va_handle, NULL, 0);
|
||||
- dlclose(This->x11_handle);
|
||||
- dlclose(This->va_x11_handle);
|
||||
- dlclose(This->va_handle);
|
||||
+ if (This->x11_display)
|
||||
+ pXCloseDisplay(This->x11_display);
|
||||
+ if (This->x11_handle)
|
||||
+ wine_dlclose(This->x11_handle, NULL, 0);
|
||||
+ dlclose(This->x11_handle);
|
||||
+ if (This->drm_fd > 0)
|
||||
+ close(This->drm_fd);
|
||||
+ if (This->va_drm_handle)
|
||||
+ wine_dlclose(This->va_drm_handle, NULL, 0);
|
||||
+ dlclose(This->va_drm_handle);
|
||||
+ if (This->va_x11_handle)
|
||||
+ wine_dlclose(This->va_x11_handle, NULL, 0);
|
||||
+ dlclose(This->va_x11_handle);
|
||||
+ if (This->va_handle)
|
||||
+ wine_dlclose(This->va_handle, NULL, 0);
|
||||
+ dlclose(This->va_handle);
|
||||
|
||||
CoTaskMemFree(This);
|
||||
}
|
||||
@@ -231,14 +231,14 @@ index 4c570f5b94..1b19684053 100644
|
||||
@@ -749,6 +800,10 @@ err:
|
||||
pXCloseDisplay(videoservice->x11_display);
|
||||
if (videoservice->x11_handle)
|
||||
wine_dlclose(videoservice->x11_handle, NULL, 0);
|
||||
dlclose(videoservice->x11_handle);
|
||||
+ if (videoservice->drm_fd > 0)
|
||||
+ close(videoservice->drm_fd);
|
||||
+ if (videoservice->va_drm_handle)
|
||||
+ wine_dlclose(videoservice->va_drm_handle, NULL, 0);
|
||||
+ dlclose(videoservice->va_drm_handle);
|
||||
if (videoservice->va_x11_handle)
|
||||
wine_dlclose(videoservice->va_x11_handle, NULL, 0);
|
||||
dlclose(videoservice->va_x11_handle);
|
||||
if (videoservice->va_handle)
|
||||
--
|
||||
2.17.1
|
||||
2.25.1
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 3c98dd79ccad72249122925b6b748c6ec84db003 Mon Sep 17 00:00:00 2001
|
||||
From e0719eabba7a7c187767441b361acedd50766234 Mon Sep 17 00:00:00 2001
|
||||
From: Zebediah Figura <z.figura12@gmail.com>
|
||||
Date: Wed, 13 Jun 2018 10:44:49 -0500
|
||||
Subject: [PATCH] configure: Check for sys/eventfd.h, ppoll(), and shm_open().
|
||||
@@ -11,18 +11,18 @@ Although perhaps we shouldn't since the server doesn't do this.
|
||||
1 file changed, 12 insertions(+)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 4f1c925bf95..662d510317a 100644
|
||||
index da5f24aba5f..6c2653c4c82 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -511,6 +511,7 @@ AC_CHECK_HEADERS(\
|
||||
sys/elf32.h \
|
||||
@@ -509,6 +509,7 @@ AC_CHECK_HEADERS(\
|
||||
sys/cdio.h \
|
||||
sys/epoll.h \
|
||||
sys/event.h \
|
||||
+ sys/eventfd.h \
|
||||
sys/exec_elf.h \
|
||||
sys/filio.h \
|
||||
sys/ioctl.h \
|
||||
@@ -2130,6 +2131,7 @@ AC_CHECK_FUNCS(\
|
||||
sys/ipc.h \
|
||||
@@ -2191,6 +2192,7 @@ AC_CHECK_FUNCS(\
|
||||
pipe2 \
|
||||
poll \
|
||||
port_create \
|
||||
@@ -30,7 +30,7 @@ index 4f1c925bf95..662d510317a 100644
|
||||
prctl \
|
||||
pread \
|
||||
proc_pidinfo \
|
||||
@@ -2204,6 +2206,16 @@ case $host_os in
|
||||
@@ -2265,6 +2267,16 @@ case $host_os in
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -48,5 +48,5 @@ index 4f1c925bf95..662d510317a 100644
|
||||
if test "x$with_ldap" != "xno"
|
||||
then
|
||||
--
|
||||
2.20.1
|
||||
2.25.1
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user