diff options
Diffstat (limited to 'src/gallium/drivers/nvc0/nvc0_context.h')
-rw-r--r-- | src/gallium/drivers/nvc0/nvc0_context.h | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/src/gallium/drivers/nvc0/nvc0_context.h b/src/gallium/drivers/nvc0/nvc0_context.h index 7072b5918fa..140ce1ac7ef 100644 --- a/src/gallium/drivers/nvc0/nvc0_context.h +++ b/src/gallium/drivers/nvc0/nvc0_context.h | |||
@@ -27,7 +27,9 @@ | |||
27 | #include "nvc0_3d.xml.h" | 27 | #include "nvc0_3d.xml.h" |
28 | #include "nvc0_2d.xml.h" | 28 | #include "nvc0_2d.xml.h" |
29 | #include "nvc0_m2mf.xml.h" | 29 | #include "nvc0_m2mf.xml.h" |
30 | #include "nve4_p2mf.xml.h" | ||
30 | 31 | ||
32 | /* NOTE: must keep NVC0_NEW_...PROG in consecutive bits in this order */ | ||
31 | #define NVC0_NEW_BLEND (1 << 0) | 33 | #define NVC0_NEW_BLEND (1 << 0) |
32 | #define NVC0_NEW_RASTERIZER (1 << 1) | 34 | #define NVC0_NEW_RASTERIZER (1 << 1) |
33 | #define NVC0_NEW_ZSA (1 << 2) | 35 | #define NVC0_NEW_ZSA (1 << 2) |
@@ -75,6 +77,11 @@ struct nvc0_context { | |||
75 | 77 | ||
76 | struct nvc0_screen *screen; | 78 | struct nvc0_screen *screen; |
77 | 79 | ||
80 | void (*m2mf_copy_rect)(struct nvc0_context *, | ||
81 | const struct nv50_m2mf_rect *dst, | ||
82 | const struct nv50_m2mf_rect *src, | ||
83 | uint32_t nblocksx, uint32_t nblocksy); | ||
84 | |||
78 | uint32_t dirty; | 85 | uint32_t dirty; |
79 | 86 | ||
80 | struct { | 87 | struct { |
@@ -130,6 +137,8 @@ struct nvc0_context { | |||
130 | unsigned num_samplers[5]; | 137 | unsigned num_samplers[5]; |
131 | uint16_t samplers_dirty[5]; | 138 | uint16_t samplers_dirty[5]; |
132 | 139 | ||
140 | uint32_t tex_handles[5][PIPE_MAX_SAMPLERS]; /* for nve4 */ | ||
141 | |||
133 | struct pipe_framebuffer_state framebuffer; | 142 | struct pipe_framebuffer_state framebuffer; |
134 | struct pipe_blend_color blend_colour; | 143 | struct pipe_blend_color blend_colour; |
135 | struct pipe_stencil_ref stencil_ref; | 144 | struct pipe_stencil_ref stencil_ref; |
@@ -165,7 +174,7 @@ void nvc0_default_kick_notify(struct nouveau_pushbuf *); | |||
165 | extern struct draw_stage *nvc0_draw_render_stage(struct nvc0_context *); | 174 | extern struct draw_stage *nvc0_draw_render_stage(struct nvc0_context *); |
166 | 175 | ||
167 | /* nvc0_program.c */ | 176 | /* nvc0_program.c */ |
168 | boolean nvc0_program_translate(struct nvc0_program *); | 177 | boolean nvc0_program_translate(struct nvc0_program *, uint16_t chipset); |
169 | boolean nvc0_program_upload_code(struct nvc0_context *, struct nvc0_program *); | 178 | boolean nvc0_program_upload_code(struct nvc0_context *, struct nvc0_program *); |
170 | void nvc0_program_destroy(struct nvc0_context *, struct nvc0_program *); | 179 | void nvc0_program_destroy(struct nvc0_context *, struct nvc0_program *); |
171 | void nvc0_program_library_upload(struct nvc0_context *); | 180 | void nvc0_program_library_upload(struct nvc0_context *); |
@@ -206,6 +215,7 @@ extern void nvc0_init_surface_functions(struct nvc0_context *); | |||
206 | /* nvc0_tex.c */ | 215 | /* nvc0_tex.c */ |
207 | void nvc0_validate_textures(struct nvc0_context *); | 216 | void nvc0_validate_textures(struct nvc0_context *); |
208 | void nvc0_validate_samplers(struct nvc0_context *); | 217 | void nvc0_validate_samplers(struct nvc0_context *); |
218 | void nve4_set_tex_handles(struct nvc0_context *); | ||
209 | 219 | ||
210 | struct pipe_sampler_view * | 220 | struct pipe_sampler_view * |
211 | nvc0_create_sampler_view(struct pipe_context *, | 221 | nvc0_create_sampler_view(struct pipe_context *, |
@@ -214,19 +224,16 @@ nvc0_create_sampler_view(struct pipe_context *, | |||
214 | 224 | ||
215 | /* nvc0_transfer.c */ | 225 | /* nvc0_transfer.c */ |
216 | void | 226 | void |
217 | nvc0_m2mf_transfer_rect(struct nvc0_context *, | 227 | nvc0_init_transfer_functions(struct nvc0_context *); |
218 | const struct nv50_m2mf_rect *dst, | 228 | |
219 | const struct nv50_m2mf_rect *src, | ||
220 | uint32_t nblocksx, uint32_t nblocksy); | ||
221 | void | 229 | void |
222 | nvc0_m2mf_push_linear(struct nouveau_context *nv, | 230 | nvc0_m2mf_push_linear(struct nouveau_context *nv, |
223 | struct nouveau_bo *dst, unsigned offset, unsigned domain, | 231 | struct nouveau_bo *dst, unsigned offset, unsigned domain, |
224 | unsigned size, const void *data); | 232 | unsigned size, const void *data); |
225 | void | 233 | void |
226 | nvc0_m2mf_copy_linear(struct nouveau_context *nv, | 234 | nve4_p2mf_push_linear(struct nouveau_context *nv, |
227 | struct nouveau_bo *dst, unsigned dstoff, unsigned dstdom, | 235 | struct nouveau_bo *dst, unsigned offset, unsigned domain, |
228 | struct nouveau_bo *src, unsigned srcoff, unsigned srcdom, | 236 | unsigned size, const void *data); |
229 | unsigned size); | ||
230 | void | 237 | void |
231 | nvc0_cb_push(struct nouveau_context *, | 238 | nvc0_cb_push(struct nouveau_context *, |
232 | struct nouveau_bo *bo, unsigned domain, | 239 | struct nouveau_bo *bo, unsigned domain, |