2
* Mesa 3-D graphics library
4
* Copyright (C) 1999-2008 Brian Paul All Rights Reserved.
5
* Copyright (c) 2008-2009 VMware, Inc.
6
* Copyright (c) 2012 Intel Corporation
8
* Permission is hereby granted, free of charge, to any person obtaining a
9
* copy of this software and associated documentation files (the "Software"),
10
* to deal in the Software without restriction, including without limitation
11
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
12
* and/or sell copies of the Software, and to permit persons to whom the
13
* Software is furnished to do so, subject to the following conditions:
15
* The above copyright notice and this permission notice shall be included
16
* in all copies or substantial portions of the Software.
18
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
19
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
22
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
23
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
24
* OTHER DEALINGS IN THE SOFTWARE.
43
_mesa_compute_component_mapping(GLenum inFormat, GLenum outFormat, GLubyte *map);
46
_mesa_type_is_packed(GLenum type);
49
_mesa_sizeof_type( GLenum type );
52
_mesa_sizeof_packed_type( GLenum type );
55
_mesa_components_in_format( GLenum format );
58
_mesa_bytes_per_pixel( GLenum format, GLenum type );
61
_mesa_bytes_per_vertex_attrib(GLint comps, GLenum type);
64
_mesa_is_astc_format(GLenum internalFormat);
67
_mesa_is_etc2_format(GLenum internalFormat);
70
_mesa_is_type_unsigned(GLenum type);
73
_mesa_is_enum_format_unsized(GLenum format);
76
_mesa_is_enum_format_unorm(GLenum format);
79
_mesa_is_enum_format_snorm(GLenum format);
82
_mesa_is_enum_format_integer(GLenum format);
85
_mesa_is_enum_format_unsigned_int(GLenum format);
88
_mesa_is_enum_format_signed_int(GLenum format);
91
_mesa_is_color_format(GLenum format);
94
_mesa_is_depth_format(GLenum format);
97
_mesa_is_stencil_format(GLenum format);
100
_mesa_is_ycbcr_format(GLenum format);
103
_mesa_is_depthstencil_format(GLenum format);
106
_mesa_is_depth_or_stencil_format(GLenum format);
109
_mesa_has_depth_float_channel(GLenum internalFormat);
112
_mesa_is_compressed_format(const struct gl_context *ctx, GLenum format);
115
_mesa_is_srgb_format(GLenum format);
118
_mesa_base_format_to_integer_format(GLenum format);
121
_mesa_unpack_format_to_base_format(GLenum format);
124
_mesa_base_format_has_channel(GLenum base_format, GLenum pname);
127
_mesa_generic_compressed_format_to_uncompressed_format(GLenum format);
130
_mesa_get_nongeneric_internalformat(GLenum format);
133
_mesa_get_linear_internalformat(GLenum format);
136
_mesa_error_check_format_and_type(const struct gl_context *ctx,
137
GLenum format, GLenum type);
140
_mesa_es_error_check_format_and_type(const struct gl_context *ctx,
141
GLenum format, GLenum type,
142
unsigned dimensions);
145
_mesa_gles_error_check_format_and_type(const struct gl_context *ctx,
146
GLenum format, GLenum type,
147
GLenum internalFormat);
149
_mesa_base_tex_format(const struct gl_context *ctx, GLint internalFormat );
152
_mesa_format_from_format_and_type(GLenum format, GLenum type);
155
_mesa_swap_bytes_in_type_enum(GLenum *type);
158
_mesa_tex_format_from_format_and_type(const struct gl_context *ctx,
159
GLenum gl_format, GLenum type);
162
_mesa_is_es3_color_renderable(const struct gl_context *ctx,
163
GLenum internal_format);
166
_mesa_is_es3_texture_filterable(const struct gl_context *ctx,
167
GLenum internal_format);
173
#endif /* GLFORMATS_H */