2 * Copyright 2008 Ben Skeggs
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
11 * The above copyright notice and this permission notice shall be included in
12 * all copies or substantial portions of the Software.
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17 * THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
18 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
19 * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 #include "pipe/p_state.h"
24 #include "pipe/p_defines.h"
25 #include "pipe/p_inlines.h"
27 #include "tgsi/tgsi_parse.h"
29 #include "nv50_context.h"
30 #include "nv50_texture.h"
32 #include "nouveau/nouveau_stateobj.h"
35 nv50_blend_state_create(struct pipe_context
*pipe
,
36 const struct pipe_blend_state
*cso
)
38 struct nouveau_stateobj
*so
= so_new(64, 0);
39 struct nouveau_grobj
*tesla
= nv50_context(pipe
)->screen
->tesla
;
40 struct nv50_blend_stateobj
*bso
= CALLOC_STRUCT(nv50_blend_stateobj
);
41 unsigned cmask
= 0, i
;
47 if (cso
->blend_enable
== 0) {
48 so_method(so
, tesla
, NV50TCL_BLEND_ENABLE(0), 8);
49 for (i
= 0; i
< 8; i
++)
52 so_method(so
, tesla
, NV50TCL_BLEND_ENABLE(0), 8);
53 for (i
= 0; i
< 8; i
++)
55 so_method(so
, tesla
, NV50TCL_BLEND_EQUATION_RGB
, 5);
56 so_data (so
, nvgl_blend_eqn(cso
->rgb_func
));
57 so_data (so
, 0x4000 | nvgl_blend_func(cso
->rgb_src_factor
));
58 so_data (so
, 0x4000 | nvgl_blend_func(cso
->rgb_dst_factor
));
59 so_data (so
, nvgl_blend_eqn(cso
->alpha_func
));
60 so_data (so
, 0x4000 | nvgl_blend_func(cso
->alpha_src_factor
));
61 so_method(so
, tesla
, NV50TCL_BLEND_FUNC_DST_ALPHA
, 1);
62 so_data (so
, 0x4000 | nvgl_blend_func(cso
->alpha_dst_factor
));
65 if (cso
->logicop_enable
== 0 ) {
66 so_method(so
, tesla
, NV50TCL_LOGIC_OP_ENABLE
, 1);
69 so_method(so
, tesla
, NV50TCL_LOGIC_OP_ENABLE
, 2);
71 so_data (so
, nvgl_logicop_func(cso
->logicop_func
));
74 if (cso
->colormask
& PIPE_MASK_R
)
76 if (cso
->colormask
& PIPE_MASK_G
)
78 if (cso
->colormask
& PIPE_MASK_B
)
80 if (cso
->colormask
& PIPE_MASK_A
)
82 so_method(so
, tesla
, NV50TCL_COLOR_MASK(0), 8);
83 for (i
= 0; i
< 8; i
++)
92 nv50_blend_state_bind(struct pipe_context
*pipe
, void *hwcso
)
94 struct nv50_context
*nv50
= nv50_context(pipe
);
97 nv50
->dirty
|= NV50_NEW_BLEND
;
101 nv50_blend_state_delete(struct pipe_context
*pipe
, void *hwcso
)
103 struct nv50_blend_stateobj
*bso
= hwcso
;
105 so_ref(NULL
, &bso
->so
);
109 static INLINE
unsigned
110 wrap_mode(unsigned wrap
)
113 case PIPE_TEX_WRAP_REPEAT
:
114 return NV50TSC_1_0_WRAPS_REPEAT
;
115 case PIPE_TEX_WRAP_MIRROR_REPEAT
:
116 return NV50TSC_1_0_WRAPS_MIRROR_REPEAT
;
117 case PIPE_TEX_WRAP_CLAMP_TO_EDGE
:
118 return NV50TSC_1_0_WRAPS_CLAMP_TO_EDGE
;
119 case PIPE_TEX_WRAP_CLAMP_TO_BORDER
:
120 return NV50TSC_1_0_WRAPS_CLAMP_TO_BORDER
;
121 case PIPE_TEX_WRAP_CLAMP
:
122 return NV50TSC_1_0_WRAPS_CLAMP
;
123 case PIPE_TEX_WRAP_MIRROR_CLAMP_TO_EDGE
:
124 return NV50TSC_1_0_WRAPS_MIRROR_CLAMP_TO_EDGE
;
125 case PIPE_TEX_WRAP_MIRROR_CLAMP_TO_BORDER
:
126 return NV50TSC_1_0_WRAPS_MIRROR_CLAMP_TO_BORDER
;
127 case PIPE_TEX_WRAP_MIRROR_CLAMP
:
128 return NV50TSC_1_0_WRAPS_MIRROR_CLAMP
;
130 NOUVEAU_ERR("unknown wrap mode: %d\n", wrap
);
131 return NV50TSC_1_0_WRAPS_REPEAT
;
135 nv50_sampler_state_create(struct pipe_context
*pipe
,
136 const struct pipe_sampler_state
*cso
)
138 unsigned *tsc
= CALLOC(8, sizeof(unsigned));
140 tsc
[0] = (0x00024000 |
141 (wrap_mode(cso
->wrap_s
) << 0) |
142 (wrap_mode(cso
->wrap_t
) << 3) |
143 (wrap_mode(cso
->wrap_r
) << 6));
145 switch (cso
->mag_img_filter
) {
146 case PIPE_TEX_FILTER_LINEAR
:
147 tsc
[1] |= NV50TSC_1_1_MAGF_LINEAR
;
149 case PIPE_TEX_FILTER_NEAREST
:
151 tsc
[1] |= NV50TSC_1_1_MAGF_NEAREST
;
155 switch (cso
->min_img_filter
) {
156 case PIPE_TEX_FILTER_LINEAR
:
157 tsc
[1] |= NV50TSC_1_1_MINF_LINEAR
;
159 case PIPE_TEX_FILTER_NEAREST
:
161 tsc
[1] |= NV50TSC_1_1_MINF_NEAREST
;
165 switch (cso
->min_mip_filter
) {
166 case PIPE_TEX_MIPFILTER_LINEAR
:
167 tsc
[1] |= NV50TSC_1_1_MIPF_LINEAR
;
169 case PIPE_TEX_MIPFILTER_NEAREST
:
170 tsc
[1] |= NV50TSC_1_1_MIPF_NEAREST
;
172 case PIPE_TEX_MIPFILTER_NONE
:
174 tsc
[1] |= NV50TSC_1_1_MIPF_NONE
;
178 if (cso
->max_anisotropy
>= 16.0)
181 if (cso
->max_anisotropy
>= 12.0)
184 if (cso
->max_anisotropy
>= 10.0)
187 if (cso
->max_anisotropy
>= 8.0)
190 if (cso
->max_anisotropy
>= 6.0)
193 if (cso
->max_anisotropy
>= 4.0)
196 if (cso
->max_anisotropy
>= 2.0)
199 if (cso
->compare_mode
== PIPE_TEX_COMPARE_R_TO_TEXTURE
) {
201 tsc
[0] |= (nvgl_comparison_op(cso
->compare_func
) & 0x7);
208 nv50_sampler_state_bind(struct pipe_context
*pipe
, unsigned nr
, void **sampler
)
210 struct nv50_context
*nv50
= nv50_context(pipe
);
213 nv50
->sampler_nr
= nr
;
214 for (i
= 0; i
< nv50
->sampler_nr
; i
++)
215 nv50
->sampler
[i
] = sampler
[i
];
217 nv50
->dirty
|= NV50_NEW_SAMPLER
;
221 nv50_sampler_state_delete(struct pipe_context
*pipe
, void *hwcso
)
227 nv50_set_sampler_texture(struct pipe_context
*pipe
, unsigned nr
,
228 struct pipe_texture
**pt
)
230 struct nv50_context
*nv50
= nv50_context(pipe
);
233 for (i
= 0; i
< nr
; i
++)
234 pipe_texture_reference((void *)&nv50
->miptree
[i
], pt
[i
]);
235 for (i
= nr
; i
< nv50
->miptree_nr
; i
++)
236 pipe_texture_reference((void *)&nv50
->miptree
[i
], NULL
);
238 nv50
->miptree_nr
= nr
;
239 nv50
->dirty
|= NV50_NEW_TEXTURE
;
243 nv50_rasterizer_state_create(struct pipe_context
*pipe
,
244 const struct pipe_rasterizer_state
*cso
)
246 struct nouveau_stateobj
*so
= so_new(64, 0);
247 struct nouveau_grobj
*tesla
= nv50_context(pipe
)->screen
->tesla
;
248 struct nv50_rasterizer_stateobj
*rso
=
249 CALLOC_STRUCT(nv50_rasterizer_stateobj
);
255 * - point_sprite / sprite_coord_mode
258 so_method(so
, tesla
, NV50TCL_SHADE_MODEL
, 1);
259 so_data (so
, cso
->flatshade
? NV50TCL_SHADE_MODEL_FLAT
:
260 NV50TCL_SHADE_MODEL_SMOOTH
);
262 so_method(so
, tesla
, NV50TCL_LINE_WIDTH
, 1);
263 so_data (so
, fui(cso
->line_width
));
264 so_method(so
, tesla
, NV50TCL_LINE_SMOOTH_ENABLE
, 1);
265 so_data (so
, cso
->line_smooth
? 1 : 0);
266 if (cso
->line_stipple_enable
) {
267 so_method(so
, tesla
, NV50TCL_LINE_STIPPLE_ENABLE
, 1);
269 so_method(so
, tesla
, NV50TCL_LINE_STIPPLE_PATTERN
, 1);
270 so_data (so
, (cso
->line_stipple_pattern
<< 8) |
271 cso
->line_stipple_factor
);
273 so_method(so
, tesla
, NV50TCL_LINE_STIPPLE_ENABLE
, 1);
277 so_method(so
, tesla
, NV50TCL_POINT_SIZE
, 1);
278 so_data (so
, fui(cso
->point_size
));
280 so_method(so
, tesla
, NV50TCL_POLYGON_MODE_FRONT
, 3);
281 if (cso
->front_winding
== PIPE_WINDING_CCW
) {
282 so_data(so
, nvgl_polygon_mode(cso
->fill_ccw
));
283 so_data(so
, nvgl_polygon_mode(cso
->fill_cw
));
285 so_data(so
, nvgl_polygon_mode(cso
->fill_cw
));
286 so_data(so
, nvgl_polygon_mode(cso
->fill_ccw
));
288 so_data(so
, cso
->poly_smooth
? 1 : 0);
290 so_method(so
, tesla
, NV50TCL_CULL_FACE_ENABLE
, 3);
291 so_data (so
, cso
->cull_mode
!= PIPE_WINDING_NONE
);
292 if (cso
->front_winding
== PIPE_WINDING_CCW
) {
293 so_data(so
, NV50TCL_FRONT_FACE_CCW
);
294 switch (cso
->cull_mode
) {
295 case PIPE_WINDING_CCW
:
296 so_data(so
, NV50TCL_CULL_FACE_FRONT
);
298 case PIPE_WINDING_CW
:
299 so_data(so
, NV50TCL_CULL_FACE_BACK
);
301 case PIPE_WINDING_BOTH
:
302 so_data(so
, NV50TCL_CULL_FACE_FRONT_AND_BACK
);
305 so_data(so
, NV50TCL_CULL_FACE_BACK
);
309 so_data(so
, NV50TCL_FRONT_FACE_CW
);
310 switch (cso
->cull_mode
) {
311 case PIPE_WINDING_CCW
:
312 so_data(so
, NV50TCL_CULL_FACE_BACK
);
314 case PIPE_WINDING_CW
:
315 so_data(so
, NV50TCL_CULL_FACE_FRONT
);
317 case PIPE_WINDING_BOTH
:
318 so_data(so
, NV50TCL_CULL_FACE_FRONT_AND_BACK
);
321 so_data(so
, NV50TCL_CULL_FACE_BACK
);
326 so_method(so
, tesla
, NV50TCL_POLYGON_STIPPLE_ENABLE
, 1);
327 so_data (so
, cso
->poly_stipple_enable
? 1 : 0);
329 so_method(so
, tesla
, NV50TCL_POLYGON_OFFSET_POINT_ENABLE
, 3);
330 if ((cso
->offset_cw
&& cso
->fill_cw
== PIPE_POLYGON_MODE_POINT
) ||
331 (cso
->offset_ccw
&& cso
->fill_ccw
== PIPE_POLYGON_MODE_POINT
))
335 if ((cso
->offset_cw
&& cso
->fill_cw
== PIPE_POLYGON_MODE_LINE
) ||
336 (cso
->offset_ccw
&& cso
->fill_ccw
== PIPE_POLYGON_MODE_LINE
))
340 if ((cso
->offset_cw
&& cso
->fill_cw
== PIPE_POLYGON_MODE_FILL
) ||
341 (cso
->offset_ccw
&& cso
->fill_ccw
== PIPE_POLYGON_MODE_FILL
))
346 if (cso
->offset_cw
|| cso
->offset_ccw
) {
347 so_method(so
, tesla
, NV50TCL_POLYGON_OFFSET_FACTOR
, 1);
348 so_data (so
, fui(cso
->offset_scale
));
349 so_method(so
, tesla
, NV50TCL_POLYGON_OFFSET_UNITS
, 1);
350 so_data (so
, fui(cso
->offset_units
));
354 so_ref(so
, &rso
->so
);
359 nv50_rasterizer_state_bind(struct pipe_context
*pipe
, void *hwcso
)
361 struct nv50_context
*nv50
= nv50_context(pipe
);
363 nv50
->rasterizer
= hwcso
;
364 nv50
->dirty
|= NV50_NEW_RASTERIZER
;
368 nv50_rasterizer_state_delete(struct pipe_context
*pipe
, void *hwcso
)
370 struct nv50_rasterizer_stateobj
*rso
= hwcso
;
372 so_ref(NULL
, &rso
->so
);
377 nv50_depth_stencil_alpha_state_create(struct pipe_context
*pipe
,
378 const struct pipe_depth_stencil_alpha_state
*cso
)
380 struct nouveau_grobj
*tesla
= nv50_context(pipe
)->screen
->tesla
;
381 struct nv50_zsa_stateobj
*zsa
= CALLOC_STRUCT(nv50_zsa_stateobj
);
382 struct nouveau_stateobj
*so
= so_new(64, 0);
384 so_method(so
, tesla
, NV50TCL_DEPTH_WRITE_ENABLE
, 1);
385 so_data (so
, cso
->depth
.writemask
? 1 : 0);
386 if (cso
->depth
.enabled
) {
387 so_method(so
, tesla
, NV50TCL_DEPTH_TEST_ENABLE
, 1);
389 so_method(so
, tesla
, NV50TCL_DEPTH_TEST_FUNC
, 1);
390 so_data (so
, nvgl_comparison_op(cso
->depth
.func
));
392 so_method(so
, tesla
, NV50TCL_DEPTH_TEST_ENABLE
, 1);
396 /*XXX: yes, I know they're backwards.. header needs fixing */
397 if (cso
->stencil
[0].enabled
) {
398 so_method(so
, tesla
, NV50TCL_STENCIL_BACK_ENABLE
, 5);
400 so_data (so
, nvgl_stencil_op(cso
->stencil
[0].fail_op
));
401 so_data (so
, nvgl_stencil_op(cso
->stencil
[0].zfail_op
));
402 so_data (so
, nvgl_stencil_op(cso
->stencil
[0].zpass_op
));
403 so_data (so
, nvgl_comparison_op(cso
->stencil
[0].func
));
404 so_method(so
, tesla
, NV50TCL_STENCIL_BACK_FUNC_REF
, 3);
405 so_data (so
, cso
->stencil
[0].ref_value
);
406 so_data (so
, cso
->stencil
[0].writemask
);
407 so_data (so
, cso
->stencil
[0].valuemask
);
409 so_method(so
, tesla
, NV50TCL_STENCIL_BACK_ENABLE
, 1);
413 if (cso
->stencil
[1].enabled
) {
414 so_method(so
, tesla
, NV50TCL_STENCIL_FRONT_ENABLE
, 8);
416 so_data (so
, nvgl_stencil_op(cso
->stencil
[1].fail_op
));
417 so_data (so
, nvgl_stencil_op(cso
->stencil
[1].zfail_op
));
418 so_data (so
, nvgl_stencil_op(cso
->stencil
[1].zpass_op
));
419 so_data (so
, nvgl_comparison_op(cso
->stencil
[1].func
));
420 so_data (so
, cso
->stencil
[1].ref_value
);
421 so_data (so
, cso
->stencil
[1].writemask
);
422 so_data (so
, cso
->stencil
[1].valuemask
);
424 so_method(so
, tesla
, NV50TCL_STENCIL_FRONT_ENABLE
, 1);
428 if (cso
->alpha
.enabled
) {
429 so_method(so
, tesla
, NV50TCL_ALPHA_TEST_ENABLE
, 1);
431 so_method(so
, tesla
, NV50TCL_ALPHA_TEST_REF
, 2);
432 so_data (so
, fui(cso
->alpha
.ref_value
));
433 so_data (so
, nvgl_comparison_op(cso
->alpha
.func
));
435 so_method(so
, tesla
, NV50TCL_ALPHA_TEST_ENABLE
, 1);
440 so_ref(so
, &zsa
->so
);
445 nv50_depth_stencil_alpha_state_bind(struct pipe_context
*pipe
, void *hwcso
)
447 struct nv50_context
*nv50
= nv50_context(pipe
);
450 nv50
->dirty
|= NV50_NEW_ZSA
;
454 nv50_depth_stencil_alpha_state_delete(struct pipe_context
*pipe
, void *hwcso
)
456 struct nv50_zsa_stateobj
*zsa
= hwcso
;
458 so_ref(NULL
, &zsa
->so
);
463 nv50_vp_state_create(struct pipe_context
*pipe
,
464 const struct pipe_shader_state
*cso
)
466 struct nv50_program
*p
= CALLOC_STRUCT(nv50_program
);
468 p
->pipe
.tokens
= tgsi_dup_tokens(cso
->tokens
);
469 p
->type
= PIPE_SHADER_VERTEX
;
470 tgsi_scan_shader(p
->pipe
.tokens
, &p
->info
);
475 nv50_vp_state_bind(struct pipe_context
*pipe
, void *hwcso
)
477 struct nv50_context
*nv50
= nv50_context(pipe
);
479 nv50
->vertprog
= hwcso
;
480 nv50
->dirty
|= NV50_NEW_VERTPROG
;
484 nv50_vp_state_delete(struct pipe_context
*pipe
, void *hwcso
)
486 struct nv50_context
*nv50
= nv50_context(pipe
);
487 struct nv50_program
*p
= hwcso
;
489 nv50_program_destroy(nv50
, p
);
490 FREE((void*)p
->pipe
.tokens
);
495 nv50_fp_state_create(struct pipe_context
*pipe
,
496 const struct pipe_shader_state
*cso
)
498 struct nv50_program
*p
= CALLOC_STRUCT(nv50_program
);
500 p
->pipe
.tokens
= tgsi_dup_tokens(cso
->tokens
);
501 p
->type
= PIPE_SHADER_FRAGMENT
;
502 tgsi_scan_shader(p
->pipe
.tokens
, &p
->info
);
507 nv50_fp_state_bind(struct pipe_context
*pipe
, void *hwcso
)
509 struct nv50_context
*nv50
= nv50_context(pipe
);
511 nv50
->fragprog
= hwcso
;
512 nv50
->dirty
|= NV50_NEW_FRAGPROG
;
516 nv50_fp_state_delete(struct pipe_context
*pipe
, void *hwcso
)
518 struct nv50_context
*nv50
= nv50_context(pipe
);
519 struct nv50_program
*p
= hwcso
;
521 nv50_program_destroy(nv50
, p
);
522 FREE((void*)p
->pipe
.tokens
);
527 nv50_set_blend_color(struct pipe_context
*pipe
,
528 const struct pipe_blend_color
*bcol
)
530 struct nv50_context
*nv50
= nv50_context(pipe
);
532 nv50
->blend_colour
= *bcol
;
533 nv50
->dirty
|= NV50_NEW_BLEND_COLOUR
;
537 nv50_set_clip_state(struct pipe_context
*pipe
,
538 const struct pipe_clip_state
*clip
)
543 nv50_set_constant_buffer(struct pipe_context
*pipe
, uint shader
, uint index
,
544 const struct pipe_constant_buffer
*buf
)
546 struct nv50_context
*nv50
= nv50_context(pipe
);
548 if (shader
== PIPE_SHADER_VERTEX
) {
549 nv50
->constbuf
[PIPE_SHADER_VERTEX
] = buf
->buffer
;
550 nv50
->dirty
|= NV50_NEW_VERTPROG_CB
;
552 if (shader
== PIPE_SHADER_FRAGMENT
) {
553 nv50
->constbuf
[PIPE_SHADER_FRAGMENT
] = buf
->buffer
;
554 nv50
->dirty
|= NV50_NEW_FRAGPROG_CB
;
559 nv50_set_framebuffer_state(struct pipe_context
*pipe
,
560 const struct pipe_framebuffer_state
*fb
)
562 struct nv50_context
*nv50
= nv50_context(pipe
);
564 nv50
->framebuffer
= *fb
;
565 nv50
->dirty
|= NV50_NEW_FRAMEBUFFER
;
569 nv50_set_polygon_stipple(struct pipe_context
*pipe
,
570 const struct pipe_poly_stipple
*stipple
)
572 struct nv50_context
*nv50
= nv50_context(pipe
);
574 nv50
->stipple
= *stipple
;
575 nv50
->dirty
|= NV50_NEW_STIPPLE
;
579 nv50_set_scissor_state(struct pipe_context
*pipe
,
580 const struct pipe_scissor_state
*s
)
582 struct nv50_context
*nv50
= nv50_context(pipe
);
585 nv50
->dirty
|= NV50_NEW_SCISSOR
;
589 nv50_set_viewport_state(struct pipe_context
*pipe
,
590 const struct pipe_viewport_state
*vpt
)
592 struct nv50_context
*nv50
= nv50_context(pipe
);
594 nv50
->viewport
= *vpt
;
595 nv50
->dirty
|= NV50_NEW_VIEWPORT
;
599 nv50_set_vertex_buffers(struct pipe_context
*pipe
, unsigned count
,
600 const struct pipe_vertex_buffer
*vb
)
602 struct nv50_context
*nv50
= nv50_context(pipe
);
604 memcpy(nv50
->vtxbuf
, vb
, sizeof(*vb
) * count
);
605 nv50
->vtxbuf_nr
= count
;
607 nv50
->dirty
|= NV50_NEW_ARRAYS
;
611 nv50_set_vertex_elements(struct pipe_context
*pipe
, unsigned count
,
612 const struct pipe_vertex_element
*ve
)
614 struct nv50_context
*nv50
= nv50_context(pipe
);
616 memcpy(nv50
->vtxelt
, ve
, sizeof(*ve
) * count
);
617 nv50
->vtxelt_nr
= count
;
619 nv50
->dirty
|= NV50_NEW_ARRAYS
;
623 nv50_init_state_functions(struct nv50_context
*nv50
)
625 nv50
->pipe
.create_blend_state
= nv50_blend_state_create
;
626 nv50
->pipe
.bind_blend_state
= nv50_blend_state_bind
;
627 nv50
->pipe
.delete_blend_state
= nv50_blend_state_delete
;
629 nv50
->pipe
.create_sampler_state
= nv50_sampler_state_create
;
630 nv50
->pipe
.bind_sampler_states
= nv50_sampler_state_bind
;
631 nv50
->pipe
.delete_sampler_state
= nv50_sampler_state_delete
;
632 nv50
->pipe
.set_sampler_textures
= nv50_set_sampler_texture
;
634 nv50
->pipe
.create_rasterizer_state
= nv50_rasterizer_state_create
;
635 nv50
->pipe
.bind_rasterizer_state
= nv50_rasterizer_state_bind
;
636 nv50
->pipe
.delete_rasterizer_state
= nv50_rasterizer_state_delete
;
638 nv50
->pipe
.create_depth_stencil_alpha_state
=
639 nv50_depth_stencil_alpha_state_create
;
640 nv50
->pipe
.bind_depth_stencil_alpha_state
=
641 nv50_depth_stencil_alpha_state_bind
;
642 nv50
->pipe
.delete_depth_stencil_alpha_state
=
643 nv50_depth_stencil_alpha_state_delete
;
645 nv50
->pipe
.create_vs_state
= nv50_vp_state_create
;
646 nv50
->pipe
.bind_vs_state
= nv50_vp_state_bind
;
647 nv50
->pipe
.delete_vs_state
= nv50_vp_state_delete
;
649 nv50
->pipe
.create_fs_state
= nv50_fp_state_create
;
650 nv50
->pipe
.bind_fs_state
= nv50_fp_state_bind
;
651 nv50
->pipe
.delete_fs_state
= nv50_fp_state_delete
;
653 nv50
->pipe
.set_blend_color
= nv50_set_blend_color
;
654 nv50
->pipe
.set_clip_state
= nv50_set_clip_state
;
655 nv50
->pipe
.set_constant_buffer
= nv50_set_constant_buffer
;
656 nv50
->pipe
.set_framebuffer_state
= nv50_set_framebuffer_state
;
657 nv50
->pipe
.set_polygon_stipple
= nv50_set_polygon_stipple
;
658 nv50
->pipe
.set_scissor_state
= nv50_set_scissor_state
;
659 nv50
->pipe
.set_viewport_state
= nv50_set_viewport_state
;
661 nv50
->pipe
.set_vertex_buffers
= nv50_set_vertex_buffers
;
662 nv50
->pipe
.set_vertex_elements
= nv50_set_vertex_elements
;