mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 13:10:10 +01:00
i965: Move intel_context::driContext to brw_context.
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Acked-by: Chris Forbes <chrisf@ijw.co.nz> Acked-by: Paul Berry <stereotype441@gmail.com> Acked-by: Anuj Phogat <anuj.phogat@gmail.com>
This commit is contained in:
parent
a9d33dbbdd
commit
a1d94cdb00
4 changed files with 7 additions and 9 deletions
|
|
@ -1223,6 +1223,8 @@ struct brw_context
|
|||
int max_entries;
|
||||
double report_time;
|
||||
} shader_time;
|
||||
|
||||
__DRIcontext *driContext;
|
||||
};
|
||||
|
||||
/*======================================================================
|
||||
|
|
|
|||
|
|
@ -58,7 +58,6 @@ intelDrawBuffer(struct gl_context * ctx, GLenum mode)
|
|||
{
|
||||
if (ctx->DrawBuffer && _mesa_is_winsys_fbo(ctx->DrawBuffer)) {
|
||||
struct brw_context *const brw = brw_context(ctx);
|
||||
struct intel_context *const intel = intel_context(ctx);
|
||||
const bool was_front_buffer_rendering = brw->is_front_buffer_rendering;
|
||||
|
||||
brw->is_front_buffer_rendering = (mode == GL_FRONT_LEFT)
|
||||
|
|
@ -69,7 +68,7 @@ intelDrawBuffer(struct gl_context * ctx, GLenum mode)
|
|||
* (including the fake front) before we start rendering again.
|
||||
*/
|
||||
if (!was_front_buffer_rendering && brw->is_front_buffer_rendering)
|
||||
dri2InvalidateDrawable(intel->driContext->driDrawablePriv);
|
||||
dri2InvalidateDrawable(brw->driContext->driDrawablePriv);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -79,7 +78,6 @@ intelReadBuffer(struct gl_context * ctx, GLenum mode)
|
|||
{
|
||||
if (ctx->DrawBuffer && _mesa_is_winsys_fbo(ctx->DrawBuffer)) {
|
||||
struct brw_context *const brw = brw_context(ctx);
|
||||
struct intel_context *const intel = intel_context(ctx);
|
||||
const bool was_front_buffer_reading = brw->is_front_buffer_reading;
|
||||
|
||||
brw->is_front_buffer_reading = mode == GL_FRONT_LEFT || mode == GL_FRONT;
|
||||
|
|
@ -89,7 +87,7 @@ intelReadBuffer(struct gl_context * ctx, GLenum mode)
|
|||
* (including the fake front) before we start reading again.
|
||||
*/
|
||||
if (!was_front_buffer_reading && brw->is_front_buffer_reading)
|
||||
dri2InvalidateDrawable(intel->driContext->driReadablePriv);
|
||||
dri2InvalidateDrawable(brw->driContext->driReadablePriv);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -129,7 +129,7 @@ intel_flush_front(struct gl_context *ctx)
|
|||
{
|
||||
struct brw_context *brw = brw_context(ctx);
|
||||
struct intel_context *intel = intel_context(ctx);
|
||||
__DRIcontext *driContext = intel->driContext;
|
||||
__DRIcontext *driContext = brw->driContext;
|
||||
__DRIdrawable *driDrawable = driContext->driDrawablePriv;
|
||||
__DRIscreen *const screen = intel->intelScreen->driScrnPriv;
|
||||
|
||||
|
|
@ -243,8 +243,7 @@ intel_update_renderbuffers(__DRIcontext *context, __DRIdrawable *drawable)
|
|||
void
|
||||
intel_prepare_render(struct brw_context *brw)
|
||||
{
|
||||
struct intel_context *intel = &brw->intel;
|
||||
__DRIcontext *driContext = intel->driContext;
|
||||
__DRIcontext *driContext = brw->driContext;
|
||||
__DRIdrawable *drawable;
|
||||
|
||||
drawable = driContext->driDrawablePriv;
|
||||
|
|
@ -474,7 +473,7 @@ intelInitContext(struct brw_context *brw,
|
|||
}
|
||||
|
||||
driContextPriv->driverPrivate = intel;
|
||||
intel->driContext = driContextPriv;
|
||||
brw->driContext = driContextPriv;
|
||||
intel->driFd = sPriv->fd;
|
||||
|
||||
intel->gen = intelScreen->gen;
|
||||
|
|
|
|||
|
|
@ -129,7 +129,6 @@ struct intel_context
|
|||
|
||||
int driFd;
|
||||
|
||||
__DRIcontext *driContext;
|
||||
struct intel_screen *intelScreen;
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue