diff options
author | Maarten Lankhorst <maarten.lankhorst@linux.intel.com> | 2019-01-29 18:47:30 +0100 |
---|---|---|
committer | Maarten Lankhorst <maarten.lankhorst@linux.intel.com> | 2019-03-29 10:36:30 +0100 |
commit | 66deae8b6fa69540f069d6551cd22013f5343948 (patch) | |
tree | 5a2e6bcbe6b910915906002e6253773a123994df /lib/igt_color_encoding.c | |
parent | 78f78fb7463d43f346272e4e309d005354f13f86 (diff) |
lib/igt_fb: Add support for Y410/Y416 formats, v5.
Y410 is packed with compressed a channel and only 32 bpp, like
10 bits RGB formats. Y416 is a packed 16 bits per component format.
Changes since v1:
- Rebase on top of upstream YUV changes.
Changes since v2:
- Discard alpha channel, not used upstream.
Changes since v3:
- Handle the XVYU formats and Y41x formats correctly.
Changes since v4:
- Fix YUV conversion routines. (Ville)
- Use memset64 to clear initial fb. (Ville)
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
[mlankhorst: Add missing ULL (Ville)
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Diffstat (limited to 'lib/igt_color_encoding.c')
-rw-r--r-- | lib/igt_color_encoding.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/igt_color_encoding.c b/lib/igt_color_encoding.c index 9f9dc143..7de6d5ab 100644 --- a/lib/igt_color_encoding.c +++ b/lib/igt_color_encoding.c @@ -154,6 +154,12 @@ static const struct color_encoding_format { { DRM_FORMAT_Y210, 65472.f, 4096.f, 60160.f, 4096.f, 32768.f, 61440.f }, { DRM_FORMAT_Y212, 65520.f, 4096.f, 60160.f, 4096.f, 32768.f, 61440.f }, { DRM_FORMAT_Y216, 65535.f, 4096.f, 60160.f, 4096.f, 32768.f, 61440.f }, + { DRM_FORMAT_Y410, 1023.f, 64.f, 940.f, 64.f, 512.f, 960.f }, + { DRM_FORMAT_Y412, 65520.f, 4096.f, 60160.f, 4096.f, 32768.f, 61440.f }, + { DRM_FORMAT_Y416, 65535.f, 4096.f, 60160.f, 4096.f, 32768.f, 61440.f }, + { DRM_FORMAT_XVYU2101010, 1023.f, 64.f, 940.f, 64.f, 512.f, 960.f }, + { DRM_FORMAT_XVYU12_16161616, 65520.f, 4096.f, 60160.f, 4096.f, 32768.f, 61440.f }, + { DRM_FORMAT_XVYU16161616, 65535.f, 4096.f, 60160.f, 4096.f, 32768.f, 61440.f }, }; static const struct color_encoding_format *lookup_fourcc(uint32_t fourcc) |