2 * Mesa 3-D graphics library
4 * Copyright (C) 1999-2007 Brian Paul All Rights Reserved.
6 * Permission is hereby granted, free of charge, to any person obtaining a
7 * copy of this software and associated documentation files (the "Software"),
8 * to deal in the Software without restriction, including without limitation
9 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
10 * and/or sell copies of the Software, and to permit persons to whom the
11 * Software is furnished to do so, subject to the following conditions:
13 * The above copyright notice and this permission notice shall be included
14 * in all copies or substantial portions of the Software.
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
17 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
19 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
20 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
21 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
22 * OTHER DEALINGS IN THE SOFTWARE.
31 #include "main/glheader.h"
32 #include "main/mtypes.h"
41 struct gl_program_parameter_list
;
43 struct prog_instruction
;
47 * The output style to use when printing programs.
56 _mesa_register_file_name(gl_register_file f
);
59 _mesa_print_vp_inputs(GLbitfield inputs
);
62 _mesa_print_fp_inputs(GLbitfield inputs
);
65 _mesa_condcode_string(GLuint condcode
);
68 _mesa_swizzle_string(GLuint swizzle
, GLuint negateBase
, GLboolean extended
);
71 _mesa_writemask_string(GLuint writeMask
);
74 _mesa_print_swizzle(GLuint swizzle
);
77 _mesa_fprint_alu_instruction(FILE *f
,
78 const struct prog_instruction
*inst
,
79 const char *opcode_string
, GLuint numRegs
,
80 gl_prog_print_mode mode
,
81 const struct gl_program
*prog
);
84 _mesa_print_alu_instruction(const struct prog_instruction
*inst
,
85 const char *opcode_string
, GLuint numRegs
);
88 _mesa_print_instruction(const struct prog_instruction
*inst
);
91 _mesa_fprint_instruction_opt(FILE *f
,
92 const struct prog_instruction
*inst
,
94 gl_prog_print_mode mode
,
95 const struct gl_program
*prog
);
98 _mesa_print_instruction_opt(const struct prog_instruction
*inst
, GLint indent
,
99 gl_prog_print_mode mode
,
100 const struct gl_program
*prog
);
103 _mesa_print_program(const struct gl_program
*prog
);
106 _mesa_fprint_program_opt(FILE *f
,
107 const struct gl_program
*prog
, gl_prog_print_mode mode
,
108 GLboolean lineNumbers
);
111 _mesa_print_program_parameters(struct gl_context
*ctx
, const struct gl_program
*prog
);
114 _mesa_print_parameter_list(const struct gl_program_parameter_list
*list
);
118 _mesa_write_shader_to_file(const struct gl_shader
*shader
);
121 _mesa_append_uniforms_to_file(const struct gl_shader
*shader
);
129 #endif /* PROG_PRINT_H */