* Rob Clark <robclark@freedesktop.org>
*/
-#ifndef FREEDRENO_LOWERING_H_
-#define FREEDRENO_LOWERING_H_
+#ifndef TGSI_LOWERING_H_
+#define TGSI_LOWERING_H_
#include "pipe/p_shader_tokens.h"
#include "tgsi/tgsi_scan.h"
-struct fd_lowering_config
+struct tgsi_lowering_config
{
/* For fragment shaders, generate a shader that emulates two
* sided color by inserting a BGCOLOR input for each COLOR
* enable lowering of TGSI_OPCODE_<opc>
*/
unsigned lower_DST:1;
- unsigned lower_XPD:1;
- unsigned lower_SCS:1;
unsigned lower_LRP:1;
unsigned lower_FRC:1;
unsigned lower_POW:1;
unsigned lower_LOG:1;
unsigned lower_DP4:1;
unsigned lower_DP3:1;
- unsigned lower_DPH:1;
unsigned lower_DP2:1;
- unsigned lower_DP2A:1;
+ unsigned lower_FLR:1;
+ unsigned lower_CEIL:1;
+ unsigned lower_TRUNC:1;
+
+ /* bitmask of (1 << TGSI_TEXTURE_type): */
+ unsigned lower_TXP;
/* To emulate certain texture wrap modes, this can be used
* to saturate the specified tex coord to [0.0, 1.0]. The
};
const struct tgsi_token *
-fd_transform_lowering(const struct fd_lowering_config *config,
- const struct tgsi_token *tokens,
- struct tgsi_shader_info *info);
+tgsi_transform_lowering(const struct tgsi_lowering_config *config,
+ const struct tgsi_token *tokens,
+ struct tgsi_shader_info *info);
#endif /* FREEDRENO_LOWERING_H_ */