mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 15:20:10 +01:00
mesa: stop truncating MESA_GLSL=dump
this adds a new helper function that can be used to directly dump longer strings to the log file, such as shaders fixes #5614 Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14755>
This commit is contained in:
parent
b1b8b712c1
commit
061bf72a4f
3 changed files with 10 additions and 1 deletions
|
|
@ -414,6 +414,11 @@ _mesa_log(const char *fmtString, ...)
|
|||
output_if_debug(NULL, s, GL_FALSE);
|
||||
}
|
||||
|
||||
void
|
||||
_mesa_log_direct(const char *string)
|
||||
{
|
||||
output_if_debug(NULL, string, GL_TRUE);
|
||||
}
|
||||
|
||||
/**
|
||||
* Report debug information from the shader compiler via GL_ARB_debug_output.
|
||||
|
|
|
|||
|
|
@ -66,6 +66,10 @@ _mesa_debug( const struct gl_context *ctx, const char *fmtString, ... ) PRINTFLI
|
|||
extern void
|
||||
_mesa_log(const char *fmtString, ...) PRINTFLIKE(1, 2);
|
||||
|
||||
extern void
|
||||
_mesa_log_direct(const char *string);
|
||||
|
||||
|
||||
extern FILE *
|
||||
_mesa_get_log_file(void);
|
||||
|
||||
|
|
|
|||
|
|
@ -1203,7 +1203,7 @@ _mesa_compile_shader(struct gl_context *ctx, struct gl_shader *sh)
|
|||
if (ctx->_Shader->Flags & GLSL_DUMP) {
|
||||
_mesa_log("GLSL source for %s shader %d:\n",
|
||||
_mesa_shader_stage_to_string(sh->Stage), sh->Name);
|
||||
_mesa_log("%s\n", sh->Source);
|
||||
_mesa_log_direct(sh->Source);
|
||||
}
|
||||
|
||||
ensure_builtin_types(ctx);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue