mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 22:38:05 +02:00
intel: Hook up the WARN_ONCE macro to GL_ARB_debug_output.
This doesn't provide detailed error type information, but it's important to get these relatively severe but rare error messages out to the developer through whatever mechanism they are using. v2: Rebase on new WARN_ONCE additions. Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> (v1)
This commit is contained in:
parent
3025680578
commit
807eedf70f
4 changed files with 8 additions and 0 deletions
|
|
@ -630,6 +630,7 @@ translate_tex_format(struct intel_context *intel,
|
|||
GLenum depth_mode,
|
||||
GLenum srgb_decode)
|
||||
{
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
if (srgb_decode == GL_SKIP_DECODE_EXT)
|
||||
mesa_format = _mesa_get_srgb_format_linear(mesa_format);
|
||||
|
||||
|
|
|
|||
|
|
@ -824,6 +824,7 @@ gen6_blorp_emit_depth_stencil_config(struct brw_context *brw,
|
|||
const brw_blorp_params *params)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
uint32_t draw_x = params->depth.x_offset;
|
||||
uint32_t draw_y = params->depth.y_offset;
|
||||
uint32_t tile_mask_x, tile_mask_y;
|
||||
|
|
|
|||
|
|
@ -579,6 +579,7 @@ gen7_blorp_emit_depth_stencil_config(struct brw_context *brw,
|
|||
const brw_blorp_params *params)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
struct gl_context *ctx = &intel->ctx;
|
||||
uint32_t draw_x = params->depth.x_offset;
|
||||
uint32_t draw_y = params->depth.y_offset;
|
||||
uint32_t tile_mask_x, tile_mask_y;
|
||||
|
|
|
|||
|
|
@ -474,10 +474,15 @@ extern int INTEL_DEBUG;
|
|||
#define WARN_ONCE(cond, fmt...) do { \
|
||||
if (unlikely(cond)) { \
|
||||
static bool _warned = false; \
|
||||
static GLuint msg_id = 0; \
|
||||
if (!_warned) { \
|
||||
fprintf(stderr, "WARNING: "); \
|
||||
fprintf(stderr, fmt); \
|
||||
_warned = true; \
|
||||
\
|
||||
_mesa_gl_debug(ctx, &msg_id, \
|
||||
MESA_DEBUG_TYPE_OTHER, \
|
||||
MESA_DEBUG_SEVERITY_HIGH, fmt); \
|
||||
} \
|
||||
} \
|
||||
} while (0)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue