diff options
author | Emil Velikov <[email protected]> | 2015-10-28 11:21:49 +0000 |
---|---|---|
committer | Emil Velikov <[email protected]> | 2015-10-30 17:37:09 +0000 |
commit | dafcb21405622eae3f8aa49000142f870549cc9b (patch) | |
tree | 5353e54eca3d8b1e0478439de9c5922544c2f23a /src/gallium/drivers/virgl/virgl_encode.c | |
parent | 7af46b9c747cbd503a2b97f00f1c603f1b75aaff (diff) |
virgl: use virgl_screen/surface upcast wrappers
Signed-off-by: Emil Velikov <[email protected]>
Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/gallium/drivers/virgl/virgl_encode.c')
-rw-r--r-- | src/gallium/drivers/virgl/virgl_encode.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/drivers/virgl/virgl_encode.c b/src/gallium/drivers/virgl/virgl_encode.c index d825397e11b..4493c3f8ad2 100644 --- a/src/gallium/drivers/virgl/virgl_encode.c +++ b/src/gallium/drivers/virgl/virgl_encode.c @@ -323,14 +323,14 @@ int virgl_encode_clear(struct virgl_context *ctx, int virgl_encoder_set_framebuffer_state(struct virgl_context *ctx, const struct pipe_framebuffer_state *state) { - struct virgl_surface *zsurf = (struct virgl_surface *)state->zsbuf; + struct virgl_surface *zsurf = virgl_surface(state->zsbuf); int i; virgl_encoder_write_cmd_dword(ctx, VIRGL_CMD0(VIRGL_CCMD_SET_FRAMEBUFFER_STATE, 0, VIRGL_SET_FRAMEBUFFER_STATE_SIZE(state->nr_cbufs))); virgl_encoder_write_dword(ctx->cbuf, state->nr_cbufs); virgl_encoder_write_dword(ctx->cbuf, zsurf ? zsurf->handle : 0); for (i = 0; i < state->nr_cbufs; i++) { - struct virgl_surface *surf = (struct virgl_surface *)state->cbufs[i]; + struct virgl_surface *surf = virgl_surface(state->cbufs[i]); virgl_encoder_write_dword(ctx->cbuf, surf ? surf->handle : 0); } |