1 #ifndef __NV40_STATE_H__
2 #define __NV40_STATE_H__
4 #include "pipe/p_state.h"
5 #include "tgsi/tgsi_scan.h"
7 struct nv40_sampler_state
{
15 struct nv40_vertex_program_exec
{
17 boolean has_branch_offset
;
21 struct nv40_vertex_program_data
{
22 int index
; /* immediates == -1 */
26 struct nv40_vertex_program
{
27 struct pipe_shader_state pipe
;
29 struct draw_vertex_shader
*draw
;
33 struct pipe_clip_state ucp
;
35 struct nv40_vertex_program_exec
*insns
;
37 struct nv40_vertex_program_data
*consts
;
40 struct nouveau_resource
*exec
;
42 struct nouveau_resource
*data
;
44 unsigned data_start_min
;
49 struct nouveau_stateobj
*so
;
52 struct nv40_fragment_program_data
{
57 struct nv40_fragment_program
{
58 struct pipe_shader_state pipe
;
59 struct tgsi_shader_info info
;
67 struct nv40_fragment_program_data
*consts
;
70 struct pipe_buffer
*buffer
;
73 struct nouveau_stateobj
*so
;
76 #define NV40_MAX_TEXTURE_LEVELS 16
79 struct pipe_texture base
;
80 struct nouveau_bo
*bo
;
82 struct pipe_buffer
*buffer
;
88 } level
[NV40_MAX_TEXTURE_LEVELS
];