diff options
author | Eric Anholt <eric@anholt.net> | 2014-02-28 13:02:15 -0500 |
---|---|---|
committer | Zhigang Gong <zhigang.gong@gmail.com> | 2014-03-13 21:52:28 +0800 |
commit | b68a6f00dbe9ea7b7bf622fc50a6e67e50ce3f9a (patch) | |
tree | f6f791925f3686115808c13adf76abe904299ff1 | |
parent | 50b31c4d0bd51c91f14a821383e466967d2cdc12 (diff) |
glamor: Drop unused GLAMOR_ACCESS_WO.
Nothing was using it, and it was going to complicate the
glamor_prepare_access bugfixing I'm going to do next.
Ported from Eric's xserver glamor tree.
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r-- | src/glamor_pixmap.c | 10 | ||||
-rw-r--r-- | src/glamor_priv.h | 1 |
2 files changed, 1 insertions, 10 deletions
diff --git a/src/glamor_pixmap.c b/src/glamor_pixmap.c index 7980489..72cf7b2 100644 --- a/src/glamor_pixmap.c +++ b/src/glamor_pixmap.c @@ -1251,8 +1251,6 @@ _glamor_download_sub_pixmap_to_cpu(PixmapPtr pixmap, GLenum format, gl_access = GL_READ_ONLY; gl_usage = GL_STREAM_READ; break; - case GLAMOR_ACCESS_WO: - return bits; case GLAMOR_ACCESS_RW: gl_access = GL_READ_WRITE; gl_usage = GL_DYNAMIC_DRAW; @@ -1515,8 +1513,7 @@ glamor_download_pixmap_to_cpu(PixmapPtr pixmap, glamor_access_t access) stride = pixmap->devKind; - if (access == GLAMOR_ACCESS_WO - || glamor_priv->gl_flavor == GLAMOR_GL_ES2 + if (glamor_priv->gl_flavor == GLAMOR_GL_ES2 || (!glamor_priv->has_pack_invert && !glamor_priv->yInverted) || pixmap_priv->type == GLAMOR_TEXTURE_LARGE) { data = malloc(stride * pixmap->drawable.height); @@ -1647,11 +1644,6 @@ glamor_get_sub_pixmap(PixmapPtr pixmap, int x, int y, int w, int h, glamor_acces return NULL; w = (x + w) > pixmap->drawable.width ? (pixmap->drawable.width - x) : w; h = (y + h) > pixmap->drawable.height ? (pixmap->drawable.height - y) : h; - if (access == GLAMOR_ACCESS_WO) { - sub_pixmap = glamor_create_pixmap(pixmap->drawable.pScreen, w, h, - pixmap->drawable.depth, GLAMOR_CREATE_PIXMAP_CPU); - return sub_pixmap; - } glamor_priv = glamor_get_screen_private(pixmap->drawable.pScreen); pixmap_priv = glamor_get_pixmap_private(pixmap); diff --git a/src/glamor_priv.h b/src/glamor_priv.h index 621709a..844bd7a 100644 --- a/src/glamor_priv.h +++ b/src/glamor_priv.h @@ -303,7 +303,6 @@ typedef struct glamor_screen_private { typedef enum glamor_access { GLAMOR_ACCESS_RO, GLAMOR_ACCESS_RW, - GLAMOR_ACCESS_WO, } glamor_access_t; enum glamor_fbo_state { |