brw_wm_iz.c File Reference

Include dependency graph for brw_wm_iz.c:

Go to the source code of this file.

Defines

#define P   0
#define C   1
#define N   2

Functions

void brw_wm_lookup_iz (unsigned line_aa, unsigned lookup, struct brw_wm_prog_key *key)

Variables

struct {
   unsigned   mode:2
   unsigned   sd_present:1
   unsigned   sd_to_rt:1
   unsigned   dd_present:1
   unsigned   ds_present:1
wm_iz_table [0x80]


Define Documentation

#define C   1

Definition at line 40 of file brw_wm_iz.c.

#define N   2

Definition at line 41 of file brw_wm_iz.c.

#define P   0

Definition at line 39 of file brw_wm_iz.c.


Function Documentation

void brw_wm_lookup_iz ( unsigned  line_aa,
unsigned  lookup,
struct brw_wm_prog_key key 
)

Definition at line 181 of file brw_wm_iz.c.

References brw_wm_prog_key::aa_dest_stencil_reg, AA_NEVER, AA_SOMETIMES, assert, brw_wm_prog_key::computes_depth, dd_present, brw_wm_prog_key::dest_depth_reg, ds_present, IZ_BIT_MAX, IZ_PS_COMPUTES_DEPTH_BIT, brw_wm_prog_key::nr_depth_regs, brw_wm_prog_key::runtime_check_aads_emit, sd_present, sd_to_rt, brw_wm_prog_key::source_depth_reg, brw_wm_prog_key::source_depth_to_render_target, and wm_iz_table.

00184 {
00185    unsigned reg = 2;
00186 
00187    assert (lookup < IZ_BIT_MAX);
00188       
00189    if (lookup & IZ_PS_COMPUTES_DEPTH_BIT)
00190       key->computes_depth = 1;
00191 
00192    if (wm_iz_table[lookup].sd_present) {
00193       key->source_depth_reg = reg;
00194       reg += 2;
00195    }
00196 
00197    if (wm_iz_table[lookup].sd_to_rt)
00198       key->source_depth_to_render_target = 1;
00199 
00200    if (wm_iz_table[lookup].ds_present || line_aa != AA_NEVER) {
00201       key->aa_dest_stencil_reg = reg;
00202       key->runtime_check_aads_emit = (!wm_iz_table[lookup].ds_present &&
00203                                       line_aa == AA_SOMETIMES);
00204       reg++;
00205    }
00206 
00207    if (wm_iz_table[lookup].dd_present) {
00208       key->dest_depth_reg = reg;
00209       reg+=2;
00210    }
00211 
00212    key->nr_depth_regs = (reg+1)/2;
00213 }


Variable Documentation

unsigned dd_present

Definition at line 47 of file brw_wm_iz.c.

unsigned ds_present

Definition at line 48 of file brw_wm_iz.c.

unsigned mode

Definition at line 44 of file brw_wm_iz.c.

unsigned sd_present

Definition at line 45 of file brw_wm_iz.c.

unsigned sd_to_rt

Definition at line 46 of file brw_wm_iz.c.

struct { ... } wm_iz_table[ 0x80 ]


Generated on Tue Sep 29 06:25:39 2009 for Gallium3D by  doxygen 1.5.4