diff options
author | Paul Kocialkowski <paul.kocialkowski@bootlin.com> | 2018-12-05 11:33:39 +0100 |
---|---|---|
committer | Paul Kocialkowski <paul.kocialkowski@bootlin.com> | 2019-02-26 09:45:54 +0100 |
commit | c4ca364c776c7943388d1ed0b645ed8894b9a7e1 (patch) | |
tree | 9c7bc1276df71dfabdd518ab20e88bea729ecd83 /lib/igt_vc4.h | |
parent | 7a8456beff7e4b57715f181a5a6c2d2cc7fce18b (diff) |
lib/igt_vc4: Add helpers for converting linear to T-tiled RGB buffers
In order to integrate testing of T-tiled buffers, the easiest path is to
generate patterns (with the already-existing functions) in linear
buffers and convert them to T-tiled subsequently.
Add helpers to do that conversion, with a first helper that returns the
memory offset for a given position in a T-tiled buffer and a second
helper that uses it for converting between framebuffers.
Signed-off-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Acked-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Maxime Ripard <maxime.ripard@bootlin.com>
Diffstat (limited to 'lib/igt_vc4.h')
-rw-r--r-- | lib/igt_vc4.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/igt_vc4.h b/lib/igt_vc4.h index ebc8a388..d5c529bb 100644 --- a/lib/igt_vc4.h +++ b/lib/igt_vc4.h @@ -33,4 +33,8 @@ bool igt_vc4_purgeable_bo(int fd, int handle, bool purgeable); void igt_vc4_set_tiling(int fd, uint32_t handle, uint64_t modifier); uint64_t igt_vc4_get_tiling(int fd, uint32_t handle); +unsigned int igt_vc4_fb_t_tiled_convert(struct igt_fb *dst, struct igt_fb *src); +size_t igt_vc4_t_tiled_offset(size_t stride, size_t height, size_t bpp, + size_t x, size_t y); + #endif /* IGT_VC4_H */ |