vkd3d-shader: Allow writing log output via a custom callback.

When using PE vkd3d through Wine, debug output may be swallowed by writing to
Win32 stderr. Avoid this by providing a way to hook up vkd3d log output to Wine
output.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura
2022-06-01 19:01:00 -05:00
committed by Alexandre Julliard
parent 6ff6cb4ed2
commit 174172887b
6 changed files with 52 additions and 2 deletions

View File

@@ -19,6 +19,8 @@
#ifndef __VKD3D_TYPES_H
#define __VKD3D_TYPES_H
#include <stdarg.h>
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
@@ -53,6 +55,8 @@ enum vkd3d_result
VKD3D_FORCE_32_BIT_ENUM(VKD3D_RESULT),
};
typedef void (*PFN_vkd3d_log)(const char *format, va_list args);
#ifdef _WIN32
# define VKD3D_IMPORT __declspec(dllimport)
# define VKD3D_EXPORT __declspec(dllexport)