* for this output attribute. attr is currently a VERT_RESULT_* but should
* be FRAG_ATTRIB_*.
*/
- for (i = 0; i < vs_attr; i++) {
+ for (i = 1; i < vs_attr; i++) {
if (brw->vs.prog_data->outputs_written & BITFIELD64_BIT(i))
attr_index++;
}
upload_sf_state(struct brw_context *brw)
{
struct intel_context *intel = &brw->intel;
- GLcontext *ctx = &intel->ctx;
+ struct gl_context *ctx = &intel->ctx;
/* CACHE_NEW_VS_PROG */
uint32_t num_inputs = brw_count_bits(brw->vs.prog_data->outputs_written);
uint32_t num_outputs = brw_count_bits(brw->fragment_program->Base.InputsRead);
int attr = 0;
dw1 =
+ GEN6_SF_SWIZZLE_ENABLE |
num_outputs << GEN6_SF_NUM_OUTPUTS_SHIFT |
(num_inputs + 1) / 2 << GEN6_SF_URB_ENTRY_READ_LENGTH_SHIFT |
1 << GEN6_SF_URB_ENTRY_READ_OFFSET_SHIFT;
}
/* _NEW_POINT */
- if (ctx->Point._Attenuated)
+ if (!(ctx->VertexProgram.PointSizeEnabled ||
+ ctx->Point._Attenuated))
dw4 |= GEN6_SF_USE_STATE_POINT_WIDTH;
dw4 |= U_FIXED(CLAMP(ctx->Point.Size, 0.125, 225.875), 3) <<