.flush_with_flags = intel_dri2_flush_with_flags,
};
-static struct intel_image_format intel_image_formats[] = {
+static const struct intel_image_format intel_image_formats[] = {
{ __DRI_IMAGE_FOURCC_ARGB8888, __DRI_IMAGE_COMPONENTS_RGBA, 1,
{ { 0, 0, 0, __DRI_IMAGE_FORMAT_ARGB8888, 4 } } },
}
}
-static struct intel_image_format *
+static const struct intel_image_format *
intel_image_format_lookup(int fourcc)
{
- struct intel_image_format *f = NULL;
+ const struct intel_image_format *f = NULL;
for (unsigned i = 0; i < ARRAY_SIZE(intel_image_formats); i++) {
if (intel_image_formats[i].fourcc == fourcc) {
int *strides, int *offsets,
void *loaderPrivate)
{
- struct intel_image_format *f = NULL;
+ const struct intel_image_format *f = NULL;
__DRIimage *image;
int i, index;
void *loaderPrivate)
{
struct intel_screen *screen = dri_screen->driverPrivate;
- struct intel_image_format *f;
+ const struct intel_image_format *f;
__DRIimage *image;
int i, index;
bool ok;
void *loaderPrivate)
{
__DRIimage *image;
- struct intel_image_format *f = intel_image_format_lookup(fourcc);
+ const struct intel_image_format *f = intel_image_format_lookup(fourcc);
if (!f) {
*error = __DRI_IMAGE_ERROR_BAD_MATCH;
int *count)
{
struct intel_screen *screen = _screen->driverPrivate;
- struct intel_image_format *f;
+ const struct intel_image_format *f;
int num_mods = 0, i;
f = intel_image_format_lookup(fourcc);
intel_from_planar(__DRIimage *parent, int plane, void *loaderPrivate)
{
int width, height, offset, stride, dri_format, index;
- struct intel_image_format *f;
+ const struct intel_image_format *f;
__DRIimage *image;
if (parent == NULL || parent->planar_format == NULL)