~ubuntu-branches/ubuntu/natty/mesa/natty-proposed

« back to all changes in this revision

Viewing changes to src/gallium/auxiliary/draw/draw_pipe_validate.c

  • Committer: Bazaar Package Importer
  • Author(s): Robert Hooker, Robert Hooker, Christopher James Halse Rogers
  • Date: 2010-09-14 08:55:40 UTC
  • mfrom: (1.2.28 upstream)
  • Revision ID: james.westby@ubuntu.com-20100914085540-m4fpl0hdjlfd4jgz
Tags: 7.9~git20100909-0ubuntu1
[ Robert Hooker ]
* New upstream git snapshot up to commit 94118fe2d4b1e5 (LP: #631413)
* New features include ATI HD5xxx series support in r600, and a vastly
  improved glsl compiler.
* Remove pre-generated .pc's, use the ones generated at build time
  instead.
* Remove all references to mesa-utils now that its no longer shipped
  with the mesa source.
* Disable the experimental ARB_fragment_shader option by default on
  i915, it exposes incomplete functionality that breaks KDE compositing
  among other things. It can be enabled via driconf still. (LP: #628930).

[ Christopher James Halse Rogers ]
* debian/patches/04_osmesa_version.diff:
  - Refresh for new upstream
* Bugs fixed in this release:
  - Fixes severe rendering corruption in Unity on radeon (LP: #628727,
    LP: #596292, LP: #599741, LP: #630315, LP: #613694, LP: #599741).
  - Also fixes rendering in gnome-shell (LP: #578619).
  - Flickering in OpenGL apps on radeon (LP: #626943, LP: #610541).
  - Provides preliminary support for new intel chips (LP: #601052).
* debian/rules:
  - Update configure flags to match upstream reshuffling.
  - Explicitly remove gallium DRI drivers that we don't want to ship.
* Update debian/gbp.conf for this Maverick-specific packaging
* libegl1-mesa-dri-x11,kms: There are no longer separate kms or x11 drivers
  for EGL, libegl1-mesa-drivers now contains a single driver that provides
  both backends.

Show diffs side-by-side

added added

removed removed

Lines of Context:
100
100
      if (rasterizer->point_size > draw->pipeline.wide_point_threshold)
101
101
         return TRUE;
102
102
 
 
103
      /* sprite points */
 
104
      if (rasterizer->point_quad_rasterization
 
105
          && draw->pipeline.wide_point_sprites)
 
106
         return TRUE;
 
107
 
103
108
      /* AA points */
104
109
      if (rasterizer->point_smooth && draw->pipeline.aapoint)
105
110
         return TRUE;
117
122
         return TRUE;
118
123
 
119
124
      /* unfilled polygons */
120
 
      if (rasterizer->fill_cw != PIPE_POLYGON_MODE_FILL ||
121
 
          rasterizer->fill_ccw != PIPE_POLYGON_MODE_FILL)
 
125
      if (rasterizer->fill_front != PIPE_POLYGON_MODE_FILL ||
 
126
          rasterizer->fill_back != PIPE_POLYGON_MODE_FILL)
122
127
         return TRUE;
123
128
      
124
129
      /* polygon offset */
125
 
      if (rasterizer->offset_cw || rasterizer->offset_ccw)
 
130
      if (rasterizer->offset_point ||
 
131
          rasterizer->offset_line ||
 
132
          rasterizer->offset_tri)
126
133
         return TRUE;
127
134
 
128
135
      /* two-side lighting */
154
161
   boolean need_det = FALSE;
155
162
   boolean precalc_flat = FALSE;
156
163
   boolean wide_lines, wide_points;
 
164
   const struct pipe_rasterizer_state *rast = draw->rasterizer;
157
165
 
158
166
   /* Set the validate's next stage to the rasterize stage, so that it
159
167
    * can be found later if needed for flushing.
161
169
   stage->next = next;
162
170
 
163
171
   /* drawing wide lines? */
164
 
   wide_lines = (draw->rasterizer->line_width > draw->pipeline.wide_line_threshold
165
 
                 && !draw->rasterizer->line_smooth);
 
172
   wide_lines = (rast->line_width > draw->pipeline.wide_line_threshold
 
173
                 && !rast->line_smooth);
166
174
 
167
175
   /* drawing large points? */
168
 
   if (draw->rasterizer->sprite_coord_enable && draw->pipeline.point_sprite)
 
176
   if (rast->sprite_coord_enable && draw->pipeline.point_sprite)
169
177
      wide_points = TRUE;
170
 
   else if (draw->rasterizer->point_smooth && draw->pipeline.aapoint)
 
178
   else if (rast->point_smooth && draw->pipeline.aapoint)
171
179
      wide_points = FALSE;
172
 
   else if (draw->rasterizer->point_size > draw->pipeline.wide_point_threshold)
 
180
   else if (rast->point_size > draw->pipeline.wide_point_threshold)
 
181
      wide_points = TRUE;
 
182
   else if (rast->point_quad_rasterization && draw->pipeline.wide_point_sprites)
173
183
      wide_points = TRUE;
174
184
   else
175
185
      wide_points = FALSE;
181
191
    * shorter pipelines for lines & points.
182
192
    */
183
193
 
184
 
   if (draw->rasterizer->line_smooth && draw->pipeline.aaline) {
 
194
   if (rast->line_smooth && draw->pipeline.aaline) {
185
195
      draw->pipeline.aaline->next = next;
186
196
      next = draw->pipeline.aaline;
187
197
   }
188
198
 
189
 
   if (draw->rasterizer->point_smooth && draw->pipeline.aapoint) {
 
199
   if (rast->point_smooth && draw->pipeline.aapoint) {
190
200
      draw->pipeline.aapoint->next = next;
191
201
      next = draw->pipeline.aapoint;
192
202
   }
197
207
      precalc_flat = TRUE;
198
208
   }
199
209
 
200
 
   if (wide_points || draw->rasterizer->sprite_coord_enable) {
 
210
   if (wide_points || rast->sprite_coord_enable) {
201
211
      draw->pipeline.wide_point->next = next;
202
212
      next = draw->pipeline.wide_point;
203
213
   }
204
214
 
205
 
   if (draw->rasterizer->line_stipple_enable && draw->pipeline.line_stipple) {
 
215
   if (rast->line_stipple_enable && draw->pipeline.line_stipple) {
206
216
      draw->pipeline.stipple->next = next;
207
217
      next = draw->pipeline.stipple;
208
218
      precalc_flat = TRUE;              /* only needed for lines really */
209
219
   }
210
220
 
211
 
   if (draw->rasterizer->poly_stipple_enable
 
221
   if (rast->poly_stipple_enable
212
222
       && draw->pipeline.pstipple) {
213
223
      draw->pipeline.pstipple->next = next;
214
224
      next = draw->pipeline.pstipple;
215
225
   }
216
226
 
217
 
   if (draw->rasterizer->fill_cw != PIPE_POLYGON_MODE_FILL ||
218
 
       draw->rasterizer->fill_ccw != PIPE_POLYGON_MODE_FILL) {
 
227
   if (rast->fill_front != PIPE_POLYGON_MODE_FILL ||
 
228
       rast->fill_back != PIPE_POLYGON_MODE_FILL) {
219
229
      draw->pipeline.unfilled->next = next;
220
230
      next = draw->pipeline.unfilled;
221
231
      precalc_flat = TRUE;              /* only needed for triangles really */
222
232
      need_det = TRUE;
223
233
   }
224
234
 
225
 
   if (draw->rasterizer->flatshade && precalc_flat) {
 
235
   if (rast->flatshade && precalc_flat) {
226
236
      draw->pipeline.flatshade->next = next;
227
237
      next = draw->pipeline.flatshade;
228
238
   }
229
239
         
230
 
   if (draw->rasterizer->offset_cw ||
231
 
       draw->rasterizer->offset_ccw) {
 
240
   if (rast->offset_point ||
 
241
       rast->offset_line ||
 
242
       rast->offset_tri) {
232
243
      draw->pipeline.offset->next = next;
233
244
      next = draw->pipeline.offset;
234
245
      need_det = TRUE;
235
246
   }
236
247
 
237
 
   if (draw->rasterizer->light_twoside) {
 
248
   if (rast->light_twoside) {
238
249
      draw->pipeline.twoside->next = next;
239
250
      next = draw->pipeline.twoside;
240
251
      need_det = TRUE;
247
258
    * to less work emitting vertices, smaller vertex buffers, etc.
248
259
    * It's difficult to say whether this will be true in general.
249
260
    */
250
 
   if (need_det || draw->rasterizer->cull_mode) {
 
261
   if (need_det || rast->cull_face != PIPE_FACE_NONE) {
251
262
      draw->pipeline.cull->next = next;
252
263
      next = draw->pipeline.cull;
253
264
   }
254
265
 
255
266
   /* Clip stage
256
267
    */
257
 
   if (!draw->bypass_clipping)
 
268
   if (draw->clip_xy || draw->clip_z || draw->clip_user)
258
269
   {
259
270
      draw->pipeline.clip->next = next;
260
271
      next = draw->pipeline.clip;