diff options
author | Eric Anholt <eric@anholt.net> | 2015-07-02 12:21:41 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2015-07-10 09:42:58 -0700 |
commit | 1bd966d16d87ed908547144c68850f2cdee05469 (patch) | |
tree | 0551c6750b7726034e246783e6debdc5710dabce | |
parent | 5a81de8284f851751a8943aa6a905377be315c7b (diff) |
glamor: Ignore picture formats when choosing color for core rendering.
Attaching a picture to a pixmap doesn't change its GL format, so it
doesn't change how core rendering should be assigning colors to it.
(Imagine XCreatePixmap(), optional XCreatePicture(pixmap) with various
formats, XFillRectangle, XGetImage(). If the XGetImage results
changed, this would be wrong).
Fixes all failures in "rendercheck -t fill" and, as a result, the
remaining failures in "rendercheck -t blend -o src -f
a8r8g8b8,x2r10g10b10"
Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
-rw-r--r-- | glamor/glamor_utils.h | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/glamor/glamor_utils.h b/glamor/glamor_utils.h index a923b7a9d..81820069e 100644 --- a/glamor/glamor_utils.h +++ b/glamor/glamor_utils.h @@ -805,16 +805,7 @@ gl_iformat_for_pixmap(PixmapPtr pixmap) static inline CARD32 format_for_pixmap(PixmapPtr pixmap) { - glamor_pixmap_private *pixmap_priv; - PictFormatShort pict_format; - - pixmap_priv = glamor_get_pixmap_private(pixmap); - if (GLAMOR_PIXMAP_PRIV_IS_PICTURE(pixmap_priv)) - pict_format = pixmap_priv->picture->format; - else - pict_format = format_for_depth((pixmap)->drawable.depth); - - return pict_format; + return format_for_depth((pixmap)->drawable.depth); } #define REVERT_NONE 0 |