/**
* Formats with sub-sampled channels.
*
- * This is for formats like YV12 where there is less than one sample per
+ * This is for formats like YVYU where there is less than one sample per
* pixel.
*/
UTIL_FORMAT_LAYOUT_SUBSAMPLED = 3,
}
+/**
+ * Checks if color mask covers every channel for the specified format
+ *
+ * @param desc a format description to check colormask with
+ * @param colormask a bit mask for channels, matches format of PIPE_MASK_RGBA
+ */
+static INLINE boolean
+util_format_colormask_full(const struct util_format_description *desc, unsigned colormask)
+{
+ return (~colormask & util_format_colormask(desc)) == 0;
+}
+
+
boolean
util_format_is_float(enum pipe_format format);
boolean
util_format_is_pure_uint(enum pipe_format format);
+/**
+ * Whether the format is a simple array format where all channels
+ * are of the same type and can be loaded from memory as a vector
+ */
+boolean
+util_format_is_array(const struct util_format_description *desc);
+
/**
* Check if the src format can be blitted to the destination format with
* a simple memcpy. For example, blitting from RGBA to RGBx is OK, but not