summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/nvfx/nvfx_state.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/nvfx/nvfx_state.h')
-rw-r--r--src/gallium/drivers/nvfx/nvfx_state.h30
1 files changed, 12 insertions, 18 deletions
diff --git a/src/gallium/drivers/nvfx/nvfx_state.h b/src/gallium/drivers/nvfx/nvfx_state.h
index e585246879..9ceb2577ec 100644
--- a/src/gallium/drivers/nvfx/nvfx_state.h
+++ b/src/gallium/drivers/nvfx/nvfx_state.h
@@ -3,6 +3,7 @@
#include "pipe/p_state.h"
#include "tgsi/tgsi_scan.h"
+#include "nouveau/nouveau_statebuf.h"
struct nvfx_vertex_program_exec {
uint32_t data[4];
@@ -38,7 +39,6 @@ struct nvfx_vertex_program {
uint32_t ir;
uint32_t or;
uint32_t clip_ctrl;
- struct nouveau_stateobj *so;
};
struct nvfx_fragment_program_data {
@@ -46,6 +46,12 @@ struct nvfx_fragment_program_data {
unsigned index;
};
+struct nvfx_fragment_program_bo {
+ struct nvfx_fragment_program_bo* next;
+ struct nouveau_bo* bo;
+ char insn[] __attribute__((aligned(16)));
+};
+
struct nvfx_fragment_program {
struct pipe_shader_state pipe;
struct tgsi_shader_info info;
@@ -59,25 +65,13 @@ struct nvfx_fragment_program {
struct nvfx_fragment_program_data *consts;
unsigned nr_consts;
- struct pipe_buffer *buffer;
-
uint32_t fp_control;
- struct nouveau_stateobj *so;
-};
-#define NVFX_MAX_TEXTURE_LEVELS 16
-
-struct nvfx_miptree {
- struct pipe_texture base;
- struct nouveau_bo *bo;
-
- struct pipe_buffer *buffer;
- uint total_size;
-
- struct {
- uint pitch;
- uint *image_offset;
- } level[NVFX_MAX_TEXTURE_LEVELS];
+ unsigned bo_prog_idx;
+ unsigned prog_size;
+ unsigned progs_per_bo;
+ struct nvfx_fragment_program_bo* fpbo;
};
+
#endif