* Given an OpenGL internalFormat value for a texture or surface, return
* the best matching PIPE_FORMAT_x, or PIPE_FORMAT_NONE if there's no match.
*/
-static enum pipe_format
-choose_format(struct pipe_context *pipe, GLint internalFormat, uint surfType)
+enum pipe_format
+st_choose_format(struct pipe_context *pipe, GLint internalFormat,
+ uint surfType)
{
struct pipe_screen *screen = pipe->screen;
enum pipe_format
st_choose_renderbuffer_format(struct pipe_context *pipe, GLint internalFormat)
{
- return choose_format(pipe, internalFormat, PIPE_SURFACE);
+ return st_choose_format(pipe, internalFormat, PIPE_SURFACE);
}
(void) format;
(void) type;
- pFormat = choose_format(ctx->st->pipe, internalFormat, PIPE_TEXTURE);
+ pFormat = st_choose_format(ctx->st->pipe, internalFormat, PIPE_TEXTURE);
if (pFormat == PIPE_FORMAT_NONE)
return NULL;
st_mesa_format_to_pipe_format(GLuint mesaFormat);
+extern enum pipe_format
+st_choose_format(struct pipe_context *pipe, GLint internalFormat,
+ uint surfType);
+
extern enum pipe_format
st_choose_renderbuffer_format(struct pipe_context *pipe, GLint internalFormat);