summaryrefslogtreecommitdiff
path: root/lib/rendercopy_gen6.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2014-03-22 15:44:48 +0100
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-03-22 15:44:48 +0100
commit83a4c7d3eb6347f9b743144611b08a2869f11f94 (patch)
tree45136688d8bc1ff98a5aacf50e68dfb4846a6e3a /lib/rendercopy_gen6.c
parent82c6dffe9fdc75a7ef3b9a7e53e1c20d8a9b3703 (diff)
lib/intel_batchbuffer: igt_ namespace for the buffer structure
Step one to properly namespace the rendercpy/mediafill functions. Als give the buf_height/width helpers a proper igt_ prefix. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'lib/rendercopy_gen6.c')
-rw-r--r--lib/rendercopy_gen6.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/lib/rendercopy_gen6.c b/lib/rendercopy_gen6.c
index 092a312b..4f5b5790 100644
--- a/lib/rendercopy_gen6.c
+++ b/lib/rendercopy_gen6.c
@@ -107,7 +107,7 @@ gen6_render_flush(struct intel_batchbuffer *batch,
}
static uint32_t
-gen6_bind_buf(struct intel_batchbuffer *batch, struct scratch_buf *buf,
+gen6_bind_buf(struct intel_batchbuffer *batch, struct igt_buf *buf,
uint32_t format, int is_dst)
{
struct gen6_surface_state *ss;
@@ -135,8 +135,8 @@ gen6_bind_buf(struct intel_batchbuffer *batch, struct scratch_buf *buf,
read_domain, write_domain);
assert(ret == 0);
- ss->ss2.height = buf_height(buf) - 1;
- ss->ss2.width = buf_width(buf) - 1;
+ ss->ss2.height = igt_buf_height(buf) - 1;
+ ss->ss2.width = igt_buf_width(buf) - 1;
ss->ss3.pitch = buf->stride - 1;
ss->ss3.tiled_surface = buf->tiling != I915_TILING_NONE;
ss->ss3.tile_walk = buf->tiling == I915_TILING_Y;
@@ -146,8 +146,8 @@ gen6_bind_buf(struct intel_batchbuffer *batch, struct scratch_buf *buf,
static uint32_t
gen6_bind_surfaces(struct intel_batchbuffer *batch,
- struct scratch_buf *src,
- struct scratch_buf *dst)
+ struct igt_buf *src,
+ struct igt_buf *dst)
{
uint32_t *binding_table;
@@ -376,11 +376,11 @@ gen6_emit_binding_table(struct intel_batchbuffer *batch, uint32_t wm_table)
}
static void
-gen6_emit_drawing_rectangle(struct intel_batchbuffer *batch, struct scratch_buf *dst)
+gen6_emit_drawing_rectangle(struct intel_batchbuffer *batch, struct igt_buf *dst)
{
OUT_BATCH(GEN6_3DSTATE_DRAWING_RECTANGLE | (4 - 2));
OUT_BATCH(0);
- OUT_BATCH((buf_height(dst) - 1) << 16 | (buf_width(dst) - 1));
+ OUT_BATCH((igt_buf_height(dst) - 1) << 16 | (igt_buf_width(dst) - 1));
OUT_BATCH(0);
}
@@ -547,9 +547,9 @@ static uint32_t gen6_emit_primitive(struct intel_batchbuffer *batch)
void gen6_render_copyfunc(struct intel_batchbuffer *batch,
drm_intel_context *context,
- struct scratch_buf *src, unsigned src_x, unsigned src_y,
+ struct igt_buf *src, unsigned src_x, unsigned src_y,
unsigned width, unsigned height,
- struct scratch_buf *dst, unsigned dst_x, unsigned dst_y)
+ struct igt_buf *dst, unsigned dst_x, unsigned dst_y)
{
uint32_t wm_state, wm_kernel, wm_table;
uint32_t cc_vp, cc_blend, offset;
@@ -601,16 +601,16 @@ void gen6_render_copyfunc(struct intel_batchbuffer *batch,
batch_round_upto(batch, VERTEX_SIZE)/VERTEX_SIZE;
emit_vertex_2s(batch, dst_x + width, dst_y + height);
- emit_vertex_normalized(batch, src_x + width, buf_width(src));
- emit_vertex_normalized(batch, src_y + height, buf_height(src));
+ emit_vertex_normalized(batch, src_x + width, igt_buf_width(src));
+ emit_vertex_normalized(batch, src_y + height, igt_buf_height(src));
emit_vertex_2s(batch, dst_x, dst_y + height);
- emit_vertex_normalized(batch, src_x, buf_width(src));
- emit_vertex_normalized(batch, src_y + height, buf_height(src));
+ emit_vertex_normalized(batch, src_x, igt_buf_width(src));
+ emit_vertex_normalized(batch, src_y + height, igt_buf_height(src));
emit_vertex_2s(batch, dst_x, dst_y);
- emit_vertex_normalized(batch, src_x, buf_width(src));
- emit_vertex_normalized(batch, src_y, buf_height(src));
+ emit_vertex_normalized(batch, src_x, igt_buf_width(src));
+ emit_vertex_normalized(batch, src_y, igt_buf_height(src));
gen6_render_flush(batch, context, batch_end);
intel_batchbuffer_reset(batch);