#include "tr_stream.h"
#include "tr_dump.h"
#include "tr_state.h"
+#include "tr_winsys.h"
#include "tr_screen.h"
#include "tr_context.h"
struct pipe_context *
trace_context_create(struct pipe_context *pipe)
{
- struct trace_screen *tr_scr;
struct trace_context *tr_ctx;
if(!debug_get_bool_option("GALLIUM_TRACE", FALSE))
return pipe;
- tr_scr = trace_screen(pipe->screen);
-
tr_ctx = CALLOC_STRUCT(trace_context);
if(!tr_ctx)
return NULL;
tr_ctx->pipe = pipe;
- /* We don't want to trace the pipe calls */
- pipe->screen = tr_scr->screen;
+ /* We don't want to trace the internal pipe calls */
+ pipe->winsys = trace_winsys(pipe->winsys)->winsys;
+ pipe->screen = trace_screen(pipe->screen)->screen;
return &tr_ctx->base;
}