uint32_t vap_control_status; /* R300_VAP_CNTL_STATUS: 0x2140 */
uint32_t antialiasing_config; /* R300_GB_AA_CONFIG: 0x4020 */
uint32_t point_size; /* R300_GA_POINT_SIZE: 0x421c */
- uint32_t point_minmax; /* R300_GA_POINT_MINMAX: 0x4230 */
uint32_t line_control; /* R300_GA_LINE_CNTL: 0x4234 */
float depth_scale; /* R300_SU_POLY_OFFSET_FRONT_SCALE: 0x42a4 */
/* R300_SU_POLY_OFFSET_BACK_SCALE: 0x42ac */
CS_LOCALS(r300);
BEGIN_CS((10 * fb->nr_cbufs) + (2 * (4 - fb->nr_cbufs)) +
- (fb->zsbuf ? 10 : 0) + 6);
+ (fb->zsbuf ? 10 : 0) + 8);
/* Flush and free renderbuffer caches. */
OUT_CS_REG(R300_RB3D_DSTCACHE_CTLSTAT,
0, RADEON_GEM_DOMAIN_VRAM, 0);
}
+ OUT_CS_REG(R300_GA_POINT_MINMAX,
+ (MAX2(fb->width, fb->height) * 6) << R300_GA_POINT_MINMAX_MAX_SHIFT);
END_CS;
}
float scale, offset;
CS_LOCALS(r300);
- BEGIN_CS(18 + (rs->polygon_offset_enable ? 5 : 0));
+ BEGIN_CS(17 + (rs->polygon_offset_enable ? 5 : 0));
OUT_CS_REG(R300_VAP_CNTL_STATUS, rs->vap_control_status);
OUT_CS_REG(R300_GB_AA_CONFIG, rs->antialiasing_config);
OUT_CS_REG(R300_GA_POINT_SIZE, rs->point_size);
- OUT_CS_REG_SEQ(R300_GA_POINT_MINMAX, 2);
- OUT_CS(rs->point_minmax);
- OUT_CS(rs->line_control);
+ OUT_CS_REG(R300_GA_LINE_CNTL, rs->line_control);
if (rs->polygon_offset_enable) {
scale = rs->depth_scale * 12;
memcpy(r300->fb_state.state, state, sizeof(struct pipe_framebuffer_state));
r300->fb_state.size = (10 * state->nr_cbufs) + (2 * (4 - state->nr_cbufs)) +
- (state->zsbuf ? 10 : 0) + 6;
+ (state->zsbuf ? 10 : 0) + 8;
r300_fb_update_tiling_flags(r300, r300->fb_state.state, state);
rs->point_size = pack_float_16_6x(state->point_size) |
(pack_float_16_6x(state->point_size) << R300_POINTSIZE_X_SHIFT);
- /* Point minimum and maximum sizes. This register has to be emitted,
- * and it'd be a step backwards to put it in invariant state. */
- if (r300screen->caps->is_r500) {
- rs->point_minmax =
- ((int)(0.0 * 6.0) << R300_GA_POINT_MINMAX_MIN_SHIFT) |
- ((int)(4096.0 * 6.0) << R300_GA_POINT_MINMAX_MAX_SHIFT);
- } else if (r300screen->caps->is_r400) {
- rs->point_minmax =
- ((int)(0.0 * 6.0) << R300_GA_POINT_MINMAX_MIN_SHIFT) |
- ((int)(4021.0 * 6.0) << R300_GA_POINT_MINMAX_MAX_SHIFT);
- } else {
- rs->point_minmax =
- ((int)(0.0 * 6.0) << R300_GA_POINT_MINMAX_MIN_SHIFT) |
- ((int)(2560.0 * 6.0) << R300_GA_POINT_MINMAX_MAX_SHIFT);
- }
-
rs->line_control = pack_float_16_6x(state->line_width) |
R300_GA_LINE_CNTL_END_TYPE_COMP;
}
r300->rs_state.state = rs;
+ r300->rs_state.size = 17 + (r300->polygon_offset_enabled ? 5 : 0);
/* XXX Why is this still needed, dammit!? */
r300->scissor_state.dirty = TRUE;
r300->viewport_state.dirty = TRUE;