Home | History | Annotate | Download | only in main

Lines Matching refs:format

106  * format data types.
160 * Get the number of components in a pixel format.
162 * \param format pixel format.
164 * \return the number of components in the given format, or -1 if a bad format.
167 _mesa_components_in_format(GLenum format)
169 switch (format) {
216 * Get the bytes per pixel of pixel format type pair.
218 * \param format pixel format.
221 * \return bytes per pixel, or -1 if a bad format or type was given.
224 _mesa_bytes_per_pixel(GLenum format, GLenum type)
226 GLint comps = _mesa_components_in_format(format);
248 if (format == GL_RGB || format == GL_BGR ||
249 format == GL_RGB_INTEGER_EXT || format == GL_BGR_INTEGER_EXT)
255 if (format == GL_RGB || format == GL_BGR ||
256 format == GL_RGB_INTEGER_EXT || format == GL_BGR_INTEGER_EXT)
264 if (format == GL_RGBA || format == GL_BGRA || format == GL_ABGR_EXT ||
265 format == GL_RGBA_INTEGER_EXT || format == GL_BGRA_INTEGER_EXT)
273 if (format == GL_RGBA || format == GL_BGRA || format == GL_ABGR_EXT ||
274 format == GL_RGBA_INTEGER_EXT || format == GL_BGRA_INTEGER_EXT)
280 if (format == GL_YCBCR_MESA)
285 if (format == GL_DEPTH_STENCIL_EXT)
290 if (format == GL_RGB)
295 if (format == GL_RGB)
300 if (format == GL_DEPTH_STENCIL)
311 * Test if the given format is an integer (non-normalized) format.
314 _mesa_is_enum_format_integer(GLenum format)
316 switch (format) {
387 * Test if the given type is an integer (non-normalized) format.
407 * Test if the given format or type is an integer (non-normalized) format.
410 _mesa_is_enum_format_or_type_integer(GLenum format, GLenum type)
412 return _mesa_is_enum_format_integer(format) || _mesa_is_type_integer(type);
448 * Test if the given image format is a color/RGBA format (i.e., not color
450 * \param format the image format value (may by an internal texture format)
451 * \return GL_TRUE if its a color/RGBA format, GL_FALSE otherwise.
454 _mesa_is_color_format(GLenum format)
456 switch (format) {
674 * Test if the given image format is a depth component format.
677 _mesa_is_depth_format(GLenum format)
679 switch (format) {
693 * Test if the given image format is a stencil format.
696 _mesa_is_stencil_format(GLenum format)
698 switch (format) {
708 * Test if the given image format is a YCbCr format.
711 _mesa_is_ycbcr_format(GLenum format)
713 switch (format) {
723 * Test if the given image format is a depth+stencil format.
726 _mesa_is_depthstencil_format(GLenum format)
728 switch (format) {
740 * Test if the given image format is a depth or stencil format.
743 _mesa_is_depth_or_stencil_format(GLenum format)
745 switch (format) {
767 * Test if the given image format is a dudv format.
770 _mesa_is_dudv_format(GLenum format)
772 switch (format) {
783 * Test if an image format is a supported compressed format.
784 * \param format the internal format token provided by the user.
788 _mesa_is_compressed_format(struct gl_context *ctx, GLenum format)
790 switch (format) {
852 * Convert various base formats to the cooresponding integer format.
855 _mesa_base_format_to_integer_format(GLenum format)
857 switch(format) {
882 return format;
887 * Does the given base texture/renderbuffer format have the channel
974 * If format is a generic compressed format, return the corresponding
975 * non-compressed format. For other formats, return the format as-is.
978 _mesa_generic_compressed_format_to_uncompressed_format(GLenum format)
980 switch (format) {
1007 return format;
1013 * Do error checking of format/type combinations for glReadPixels,
1014 * glDrawPixels and glTex[Sub]Image. Note that depending on the format
1018 * \param format pixel format.
1025 GLenum format, GLenum type)
1030 if (format != GL_COLOR_INDEX && format != GL_STENCIL_INDEX) {
1039 if (format == GL_RGB) {
1042 if (format == GL_RGB_INTEGER_EXT &&
1056 if (format == GL_RGBA ||
1057 format == GL_BGRA ||
1058 format == GL_ABGR_EXT) {
1061 if ((format == GL_RGBA_INTEGER_EXT || format == GL_BGRA_INTEGER_EXT) &&
1071 if (format != GL_DEPTH_STENCIL) {
1080 if (format != GL_DEPTH_STENCIL) {
1089 if (format != GL_RGB) {
1098 /* now, for each format, check the type for compatibility */
1099 switch (format) {
1323 /* NOTE: no packed formats w/ BGR format */