[Mesa-dev] [PATCH 1/4] st/dri: expose sRGB visuals (v2)
Emil Velikov
emil.l.velikov at gmail.com
Thu Jul 16 06:06:25 PDT 2015
On 12 July 2015 at 20:10, Marek Olšák <maraeo at gmail.com> wrote:
> From: Marek Olšák <marek.olsak at amd.com>
>
> v2: The fix for the darkness in Ubuntu Unity is in the hunk
> with the 4-line comment.
> ---
> src/gallium/state_trackers/dri/dri2.c | 2 ++
> src/gallium/state_trackers/dri/dri_drawable.c | 7 ++++++-
> src/gallium/state_trackers/dri/dri_screen.c | 23 +++++++++++++++++++----
> src/mesa/state_tracker/st_manager.c | 1 +
> 4 files changed, 28 insertions(+), 5 deletions(-)
>
> diff --git a/src/gallium/state_trackers/dri/dri2.c b/src/gallium/state_trackers/dri/dri2.c
> index 1eda036..5aa785c 100644
> --- a/src/gallium/state_trackers/dri/dri2.c
> +++ b/src/gallium/state_trackers/dri/dri2.c
> @@ -189,9 +189,11 @@ dri2_drawable_get_buffers(struct dri_drawable *drawable,
> */
> switch(format) {
> case PIPE_FORMAT_B8G8R8A8_UNORM:
> + case PIPE_FORMAT_B8G8R8A8_SRGB:
> depth = 32;
> break;
> case PIPE_FORMAT_B8G8R8X8_UNORM:
> + case PIPE_FORMAT_B8G8R8X8_SRGB:
> depth = 24;
> break;
> case PIPE_FORMAT_B5G6R5_UNORM:
Have you looked what it'll take for get __DRI_IMAGE (dri3?) going ?
>From a quick look we need a couple extra defines, and some minimal
changes in the st/dri2.
__DRI_SWRAST on the other hand, might not be as straightforward.
Note that I'm not suggesting that you do either of these, merely curious.
Thanks
Emil
More information about the mesa-dev
mailing list