1 /**************************************************************************
3 * Copyright 2007 Tungsten Graphics, Inc., Cedar Park, Texas.
6 * Permission is hereby granted, free of charge, to any person obtaining a
7 * copy of this software and associated documentation files (the
8 * "Software"), to deal in the Software without restriction, including
9 * without limitation the rights to use, copy, modify, merge, publish,
10 * distribute, sub license, and/or sell copies of the Software, and to
11 * permit persons to whom the Software is furnished to do so, subject to
12 * the following conditions:
14 * The above copyright notice and this permission notice (including the
15 * next paragraph) shall be included in all copies or substantial portions
18 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
19 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
20 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
21 * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
22 * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
23 * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
24 * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
26 **************************************************************************/
35 #if defined __cplusplus
45 tgsi_build_header( void );
48 tgsi_default_processor( void );
53 struct tgsi_header
*header
);
59 struct tgsi_declaration
60 tgsi_default_declaration( void );
62 struct tgsi_declaration
63 tgsi_build_declaration(
70 struct tgsi_header
*header
);
72 struct tgsi_full_declaration
73 tgsi_default_full_declaration( void );
76 tgsi_build_full_declaration(
77 const struct tgsi_full_declaration
*full_decl
,
78 struct tgsi_token
*tokens
,
79 struct tgsi_header
*header
,
82 struct tgsi_declaration_range
83 tgsi_default_declaration_range( void );
85 struct tgsi_declaration_range
86 tgsi_build_declaration_range(
89 struct tgsi_declaration
*declaration
,
90 struct tgsi_header
*header
);
92 struct tgsi_declaration_semantic
93 tgsi_default_declaration_semantic( void );
95 struct tgsi_declaration_semantic
96 tgsi_build_declaration_semantic(
97 unsigned semantic_name
,
98 unsigned semantic_index
,
99 struct tgsi_declaration
*declaration
,
100 struct tgsi_header
*header
);
106 struct tgsi_immediate
107 tgsi_default_immediate( void );
109 struct tgsi_immediate
110 tgsi_build_immediate(
111 struct tgsi_header
*header
);
113 struct tgsi_full_immediate
114 tgsi_default_full_immediate( void );
116 union tgsi_immediate_data
117 tgsi_build_immediate_float32(
119 struct tgsi_immediate
*immediate
,
120 struct tgsi_header
*header
);
123 tgsi_build_full_immediate(
124 const struct tgsi_full_immediate
*full_imm
,
125 struct tgsi_token
*tokens
,
126 struct tgsi_header
*header
,
133 struct tgsi_instruction
134 tgsi_default_instruction( void );
136 struct tgsi_instruction
137 tgsi_build_instruction(
141 unsigned num_dst_regs
,
142 unsigned num_src_regs
,
143 struct tgsi_header
*header
);
145 struct tgsi_full_instruction
146 tgsi_default_full_instruction( void );
149 tgsi_build_full_instruction(
150 const struct tgsi_full_instruction
*full_inst
,
151 struct tgsi_token
*tokens
,
152 struct tgsi_header
*header
,
155 struct tgsi_instruction_predicate
156 tgsi_default_instruction_predicate(void);
158 struct tgsi_instruction_predicate
159 tgsi_build_instruction_predicate(int index
,
165 struct tgsi_instruction
*instruction
,
166 struct tgsi_header
*header
);
168 struct tgsi_instruction_label
169 tgsi_default_instruction_label( void );
171 struct tgsi_instruction_label
172 tgsi_build_instruction_label(
174 struct tgsi_token
*prev_token
,
175 struct tgsi_instruction
*instruction
,
176 struct tgsi_header
*header
);
178 struct tgsi_instruction_texture
179 tgsi_default_instruction_texture( void );
181 struct tgsi_instruction_texture
182 tgsi_build_instruction_texture(
184 struct tgsi_token
*prev_token
,
185 struct tgsi_instruction
*instruction
,
186 struct tgsi_header
*header
);
188 struct tgsi_src_register
189 tgsi_default_src_register( void );
191 struct tgsi_src_register
192 tgsi_build_src_register(
203 struct tgsi_instruction
*instruction
,
204 struct tgsi_header
*header
);
206 struct tgsi_full_src_register
207 tgsi_default_full_src_register( void );
210 struct tgsi_dimension
211 tgsi_default_dimension( void );
213 struct tgsi_dimension
214 tgsi_build_dimension(
217 struct tgsi_instruction
*instruction
,
218 struct tgsi_header
*header
);
220 struct tgsi_dst_register
221 tgsi_default_dst_register( void );
223 struct tgsi_dst_register
224 tgsi_build_dst_register(
229 struct tgsi_instruction
*instruction
,
230 struct tgsi_header
*header
);
232 struct tgsi_full_dst_register
233 tgsi_default_full_dst_register( void );
236 #if defined __cplusplus
240 #endif /* TGSI_BUILD_H */