summaryrefslogtreecommitdiff
path: root/lib/intel_batchbuffer.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2014-03-22 18:16:30 +0100
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-03-22 19:36:50 +0100
commit7754c4dd769e61ea57bf3e4ab635099b47aa6223 (patch)
tree8eb0dd254dd1b3aba7e076bea2bb1a6fbd2d0e68 /lib/intel_batchbuffer.c
parent43b7aa44fdc8dee372f6d0766e953da0a36de25a (diff)
lib/intel_batchbuffer: api documentation for render copy/media fill
Also fix a fumble in the documentation for intel_blt_copy. One thing we might want to do is unify the parameter ordering here a bit ... Again gtkdoc fails to pick up the documentation for struct igt_buf :( Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'lib/intel_batchbuffer.c')
-rw-r--r--lib/intel_batchbuffer.c41
1 files changed, 39 insertions, 2 deletions
diff --git a/lib/intel_batchbuffer.c b/lib/intel_batchbuffer.c
index 6a585c7d..3a38f133 100644
--- a/lib/intel_batchbuffer.c
+++ b/lib/intel_batchbuffer.c
@@ -286,8 +286,8 @@ intel_batchbuffer_data(struct intel_batchbuffer *batch,
* @src_y1: source pixel y-coordination
* @src_pitch: @src_bo's pitch in bytes
* @dst_bo: destination libdrm buffer object
- * @dst_x1: source pixel x-coordination
- * @dst_y1: source pixel y-coordination
+ * @dst_x1: destination pixel x-coordination
+ * @dst_y1: destination pixel y-coordination
* @dst_pitch: @dst_bo's pitch in bytes
* @width: width of the copied rectangle
* @height: height of the copied rectangle
@@ -387,16 +387,44 @@ intel_copy_bo(struct intel_batchbuffer *batch,
4096/4, size/4096, 32);
}
+/**
+ * igt_buf_width:
+ * @buf: the i-g-t buffer object
+ *
+ * Computes the widht in 32-bit pixels of the given buffer.
+ *
+ * Returns:
+ * The width of the buffer.
+ */
unsigned igt_buf_width(struct igt_buf *buf)
{
return buf->stride/sizeof(uint32_t);
}
+/**
+ * igt_buf_height:
+ * @buf: the i-g-t buffer object
+ *
+ * Computes the height in 32-bit pixels of the given buffer.
+ *
+ * Returns:
+ * The height of the buffer.
+ */
unsigned igt_buf_height(struct igt_buf *buf)
{
return buf->size/buf->stride;
}
+/**
+ * igt_get_render_copyfunc:
+ * @devid: pci device id
+ *
+ * Returns:
+ *
+ * The platform-specific render copy function pointer for the device
+ * specified with @devid. Will return NULL when no render copy function is
+ * implemented.
+ */
igt_render_copyfunc_t igt_get_render_copyfunc(int devid)
{
igt_render_copyfunc_t copy = NULL;
@@ -415,6 +443,15 @@ igt_render_copyfunc_t igt_get_render_copyfunc(int devid)
return copy;
}
+/**
+ * igt_get_media_fillfunc:
+ * @devid: pci device id
+ *
+ * Returns:
+ *
+ * The platform-specific media fill function pointer for the device specified
+ * with @devid. Will return NULL when no media fill function is implemented.
+ */
igt_media_fillfunc_t igt_get_media_fillfunc(int devid)
{
igt_media_fillfunc_t fill = NULL;