8 Commits

Author SHA1 Message Date
Thomas Wood
f0381d1abe lib: various documentation fixes
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-09-08 16:15:16 +01:00
Paulo Zanoni
9113c9aa9b lib/igt_draw: break if we already wrote every pixel
Due to the nature of accessing a tiled buffer in an untiled way, we
used to loop through the whole buffer all the time. Add a small
mechanism to just break in case we know we already wrote every pixel
we should have written.

On kms_frontbuffer_tracknig/fbc-2p-primscrn-pri-shrfb-draw-pwrite
(with a 3200x1800 primary screen and a 1920x1080 secondary screen), I
could reduce the runtime from ~7.53s to ~6.01s.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2015-08-14 15:28:27 -03:00
Paulo Zanoni
9194f4efdf lib/igt_draw: fix pwrite_tiled()
Don't forget to flush in case we're in the last iteration of the loop.
This fixes failures of kms_frontbuffer_tracking when used with
--use-small-modes on eDP monitors.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2015-08-14 15:28:07 -03:00
Paulo Zanoni
caaf3b869f lib/igt_draw: add support for RGB565 and XRGB2101010
We need to test those pixel formats on the FBC code, so let's make
sure the drawing library works on them first.

v2: Update the gtkdoc (Daniel).

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2015-08-14 15:27:19 -03:00
Damien Lespiau
6ebd8c2dc3 doc: Remove i-g-t/intel prefixes and capitalize section titles
Looks better!

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2015-06-27 16:04:07 +01:00
Paulo Zanoni
e86557ca9f lib/igt_draw: move to the GTT domain before using GTT mmaps
With this, we don't need to worry about what happened to the buffer
before.

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2015-06-26 17:36:47 -03:00
Thomas Wood
6141aa2dad docs: various documentation fixes
Fix various typos, add missing parameter documentation, include the
igt_draw section and update the list of ignored headers.

Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-05-14 17:00:40 +01:00
Paulo Zanoni
cf9f48e704 lib: add igt_draw
For all those IGT tests that need an easy way to draw rectangles on
buffers using different methods. Current planned users: FBC and PSR
CRC tests.

There is also a tests/kms_draw_crc program to check if the library is
sane.

v2: - Move the test from lib/tests to tests/ (Daniel).
    - Add igt_require() to filter out the swizzling/tiling methods we
      don't support (Daniel).
    - Simplify reloc handling on the BLT case (Daniel).
    - Document enum igt_draw_method (Daniel).
    - Document igt_draw_get_method_name() (Paulo).
v3: - Add IGT_DRAW_MMAP_WC (Chris).
    - Implement the other trivial swizzling methods (Chris).
    - Remove the gem_sync() calls (Chris).

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2015-05-07 15:11:49 -03:00