diff options
author | Tom Stellard <tstellar@gmail.com> | 2010-10-05 22:53:40 -0700 |
---|---|---|
committer | Tom Stellard <tstellar@gmail.com> | 2010-10-18 20:51:05 -0700 |
commit | 75734d0a37c7cb24fb97c9ba0166f9f2d2da60f8 (patch) | |
tree | 8c616f3838f1927f0b14adf532f4cabad06e83cd /src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c | |
parent | ad683577b202750ffac917392d50fb7202d5bf2a (diff) |
r300/compiler: Fix incorrect assumption
It is possible for a single pair instruction arg to select from both an
RGB and an Alpha source.
Diffstat (limited to 'src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c')
-rw-r--r-- | src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c b/src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c index 15e7c0b143..d4a38607d9 100644 --- a/src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c +++ b/src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c @@ -286,7 +286,7 @@ static void emit_all_tex(struct schedule_state * s, struct rc_instruction * befo static int merge_presub_sources( struct rc_pair_instruction * dst_full, struct rc_pair_sub_instruction src, - rc_pair_source_type type) + unsigned int type) { unsigned int srcp_src, srcp_regs, is_rgb, is_alpha; struct rc_pair_sub_instruction * dst_sub; @@ -355,9 +355,9 @@ static int merge_presub_sources( for(arg = 0; arg < info->NumSrcRegs; arg++) { /*If this arg does not read from an rgb source, * do nothing. */ - if (rc_source_type_that_arg_reads( + if (!(rc_source_type_that_arg_reads( dst_full->RGB.Arg[arg].Source, - dst_full->RGB.Arg[arg].Swizzle, 3) != type) { + dst_full->RGB.Arg[arg].Swizzle) & type)) { continue; } if (dst_full->RGB.Arg[arg].Source == srcp_src) |