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
cee21cf3
Commit
cee21cf3
authored
Nov 04, 2022
by
Zebediah Figura
Committed by
Alexandre Julliard
Nov 17, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dcompiler: Print message output with ERR() in D3DCompile2().
parent
f801ac97
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
34 additions
and
0 deletions
+34
-0
compiler.c
dlls/d3dcompiler_43/compiler.c
+34
-0
No files found.
dlls/d3dcompiler_43/compiler.c
View file @
cee21cf3
...
...
@@ -173,6 +173,23 @@ static void close_include(const struct vkd3d_shader_code *code, void *context)
ID3DInclude_Close
(
iface
,
code
->
code
);
}
static
const
char
*
get_line
(
const
char
**
ptr
)
{
const
char
*
p
,
*
q
;
p
=
*
ptr
;
if
(
!
(
q
=
strstr
(
p
,
"
\n
"
)))
{
if
(
!*
p
)
return
NULL
;
*
ptr
+=
strlen
(
p
);
return
p
;
}
*
ptr
=
q
+
1
;
return
p
;
}
static
HRESULT
preprocess_shader
(
const
void
*
data
,
SIZE_T
data_size
,
const
char
*
filename
,
const
D3D_SHADER_MACRO
*
defines
,
ID3DInclude
*
include
,
ID3DBlob
**
shader_blob
,
ID3DBlob
**
messages_blob
)
...
...
@@ -486,8 +503,25 @@ HRESULT WINAPI D3DCompile2(const void *data, SIZE_T data_size, const char *filen
}
ret
=
vkd3d_shader_compile
(
&
compile_info
,
&
byte_code
,
&
messages
);
if
(
ret
)
ERR
(
"Failed to compile shader, vkd3d result %d.
\n
"
,
ret
);
if
(
messages
)
{
if
(
*
messages
&&
ERR_ON
(
d3dcompiler
))
{
const
char
*
ptr
=
messages
;
const
char
*
line
;
ERR
(
"Shader log:
\n
"
);
while
((
line
=
get_line
(
&
ptr
)))
{
ERR
(
" %.*s"
,
(
int
)(
ptr
-
line
),
line
);
}
ERR
(
"
\n
"
);
}
if
(
messages_blob
)
{
size_t
size
=
strlen
(
messages
);
...
...
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