if (usage & GBM_BO_USE_RENDERING)
resource_usage |= PIPE_BIND_RENDER_TARGET | PIPE_BIND_SAMPLER_VIEW;
- if (usage & GBM_BO_USE_CURSOR_64X64)
+ if (usage & GBM_BO_USE_CURSOR)
resource_usage |= PIPE_BIND_CURSOR;
return resource_usage;
return 0;
}
- if (usage & GBM_BO_USE_CURSOR_64X64 &&
+ if (usage & GBM_BO_USE_CURSOR &&
usage & GBM_BO_USE_RENDERING)
return 0;
if (usage & GBM_BO_USE_SCANOUT)
dri_use |= __DRI_IMAGE_USE_SCANOUT;
- if (usage & GBM_BO_USE_CURSOR_64X64)
+ if (usage & GBM_BO_USE_CURSOR)
dri_use |= __DRI_IMAGE_USE_CURSOR;
if (dri->image->base.version >= 2 &&
!dri->image->validateUsage(bo->image, dri_use)) {
struct drm_mode_destroy_dumb destroy_arg;
int ret;
- if (!(usage & GBM_BO_USE_CURSOR_64X64)) {
+ if (!(usage & GBM_BO_USE_CURSOR)) {
errno = EINVAL;
return NULL;
}
if (usage & GBM_BO_USE_SCANOUT)
dri_use |= __DRI_IMAGE_USE_SCANOUT;
- if (usage & GBM_BO_USE_CURSOR_64X64)
+ if (usage & GBM_BO_USE_CURSOR)
dri_use |= __DRI_IMAGE_USE_CURSOR;
/* Gallium drivers requires shared in order to get the handle/stride */
return NULL;
}
- if (usage & GBM_BO_USE_CURSOR_64X64 &&
- (width != 64 || height != 64)) {
- errno = EINVAL;
- return NULL;
- }
-
return gbm->bo_create(gbm, width, height, format, usage);
}
*/
GBM_BO_USE_SCANOUT = (1 << 0),
/**
- * Buffer is going to be used as cursor - the dimensions for the buffer
- * must be 64x64 if this flag is passed.
+ * Buffer is going to be used as cursor
*/
- GBM_BO_USE_CURSOR_64X64 = (1 << 1),
+ GBM_BO_USE_CURSOR = (1 << 1),
+ /**
+ * Deprecated
+ */
+ GBM_BO_USE_CURSOR_64X64 = GBM_BO_USE_CURSOR,
/**
* Buffer is to be used for rendering - for example it is going to be used
* as the storage for a color buffer
GBM_BO_USE_RENDERING = (1 << 2),
/**
* Buffer can be used for gbm_bo_write. This is guaranteed to work
- * with GBM_BO_USE_CURSOR_64X64. but may not work for other
- * combinations.
+ * with GBM_BO_USE_CURSOR. but may not work for other combinations.
*/
GBM_BO_USE_WRITE = (1 << 3),
};