Age | Commit message (Collapse) | Author |
|
We probably don't want to propagate this condition to the pipe driver,
this reverts commit f455ca6490fcb65781b21f81c7117bd923e250d1 and the
dri_update_buffer flush altogether until an agreement is reached.
|
|
Undoes part of commit f455ca6 which would permit pipe->flush() to be
called while the VBO module still had its buffers mapped. Some
drivers care deeply about this. Sorry for not spotting this earlier.
|
|
So far the frontbuffer was only being flushed on st_glFlush and
st_glFinish, however, a co-state tracker may need to make sure that
any frontbuffer changes are already on its way to the actual front.
The dri2 state tracker will need this for event-driven GL applications
to resize properly (It could also be done calling "dri_flush_frontbuffer",
but that way we would flush unnecessarily in the double-buffered case).
Additionally this patch avoids flushing the mesa rendering cache if
PIPE_FLUSH_RENDER_CACHE wasn't specified.
|
|
Core Mesa will not call ctx->Driver.CheckQuery() if the Ready flag
is already set.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This fixes invalid calls to rastpos_point/line/tri() that can occur
when glRasterPos() is called while in feedback or selection mode.
(cherry picked from commit b3c7dc6ff232eb4c5ff6b0ddcfa90bcb56f78df1)
|
|
Don't use pipe->draw_range_elements() if min_index=max_index=~0 since
that doesn't provide any useful info.
Also, implement the loop around pipe->draw_range_elements() when
nr_prims > 1.
|
|
|
|
|
|
|
|
saves us a dword in sampler state, hw can't do non-integer aniso degree anyway.
To allow aniso 1x (which seems of dubious value but some hardware (radeons)
have such a mode, and even d3d allows specifiying it) redefine anisotropic
filtering as disabled only if max_anistropy is 0.
|
|
seems cleaner, and other dynamic state like viewport is handled that way too
|
|
Fixes invalid texture level when rendering to a texture where
GL_BASE_LEVEL > 0.
This will be cherry-picked to the 7.7 branch after additional
testing.
|
|
makes life of state trackers easier
|
|
|
|
compiles. Might need to do something to make it possible to save/restore
stencil ref.
|
|
This will make driver's life a bit harder, however it makes sense that stencil
reference value is not part of the pipe_depth_stencil_alpha_state, because
it often (there are some algorithms which require this) changes more frequently
than the rest of the dsa state. This is also encouraged by some graphic APIs.
Treat it similar to pipe_blend_color.
|
|
Conflicts:
src/gallium/drivers/nv10/nv10_state.c
src/gallium/drivers/nv20/nv20_state.c
src/gallium/drivers/nv50/nv50_program.c
|
|
|
|
Cylinder wrap mode works with perspective interpolation now.
|
|
|
|
Lets see if this is not too pedantic. Obj pointers are never exposed to
GL apps so it should be possible to get this right.
Furthermore apps with GL widgets and test suits create and destroy many
contexts and objects, so bad reference counting is not really an option.
|
|
The piglit vp-address-01 test uses negative address-relative
offsets. In this test we're indexing into PROGRAM_STATE_VAR
which, in turn, contains references to ENV vars.
We previously fixed this issue for PROGRAM_CONSTANT.
piglit/vp-address-01 (the version from Feb 5) passes now.
(cherry picked from commit 64be837b0b171c44f47a3c0b83f566d292ffff50)
|
|
This fixes the progs/glsl/pointcoord.c demo. But this isn't a proper fix.
We really need a TGSI_SEMANTIC_POINT_COORD label so that the draw module
can determine which fragment input / vertex output slot needs to be set
up with the point coordinate info. We've been using generic slot 0 so far.
This would also require telling the draw module about fragment shaders
(something it doesn't have at this time).
|
|
GL_TRUE indicates that the driver accepts the program.
GL_FALSE indicates the program can't be compiled/translated by the
driver for some reason (too many resources used, etc).
Propogate this result up to the GL API: set GL_INVALID_OPERATION
error if glProgramString() was called. Set shader program link
status to GL_FALSE if glLinkProgram() was called.
At this point, drivers still don't do any program checking and
always return GL_TRUE.
|
|
This determines if points should be rasterized according to GL point rules
or as normal quads (GL point sprites / d3d points / d3d point sprites).
|
|
The point size min/max registers (unused by mesa state tracker) were removed
since most hardware couldn't do much with them. However, we don't want to have
to rely on hw to do point size clamping correctly to implementation
dependent limits, hence have to do that in the vertex shader. This should also
solve a potential problem with (non-AA) points smaller than 1.0 which according
to OGL still have size 1.0.
Note that OGL point rendering is odd, in particular point sprites are rasterized
differently to points. Some hardware might support those different modes, but in
any case the different clamping values used for smooth/multisampled/sprite
enabled points might help a bit for hw which rasterizes points the same as point
sprites.
Also tweak mesa's ff to vertex shader translation so don't have to clamp twice in
case of point attenuation.
|
|
|
|
|
|
Don't need sprite coord origin per coord.
Also, don't need separate sprite enable bit - if all coords have it diabled,
then there are no point sprites (technically, there's a distinction in pre-GL3,
but it only differs in having more leniency in clamping to max size, something
the state tracker would need to handle and the hardware won't bother anyway).
Also, use packed field for the per-coord enables.
All in all, should save 3 dwords in rasterizer state (from 10 down to 7).
|
|
This should make things easier for drivers wanting to work with a
"subclass" of gl_framebuffer.
The complementary "_mesa_initialize_framebuffer" function is now
called "_mesa_initialize_window_framebuffer" for the sake of
symmetry.
Signed-off-by: Brian Paul <brianp@vmware.com>
|
|
This is a very informal version number, but there have been enough
changes that a bump is appropriate at this time.
|
|
Compiler can't usually turn x/2.0f into x * 0.5f, though we're happy
with either.
|
|
|
|
This fixes a bug reported by Christoph Bumiller on mesa3d-dev.
When a texture is first created as RGBA, then re-defined with
glTexImage(internalFormat=GL_DEPTH_COMPONENT) we failed to deallocate
the original texture. When this texture was bound as a FBO surface,
the depth/Z surface format was RGBA instead of Z. Depending on the
driver this led to a failed assertion or FBO validation failure.
This patch does three things:
1. Remove ancient code that mysteriously tested if we were replacing
the smallest mipmap level and tested if the texture was not a cube map
texture. I can't see any reason for those tests.
2. Move the width=height=depth=0 test to after the code which frees
texture data. Calling glTexImage with width=height=depth=0 and data=NULL
is a way to free a single mipmap level.
3. Update the code comments.
There are no apparent conform, glean or piglit regressions from this change.
(cherry picked from commit 43e4b584227534e30e487e7fb7e99d6501cbcd85)
|
|
This was being calculated the same way in two different places.
Now just do it in st_translate_fragment_program().
|
|
Was being calculated and not used. Also was probably incorrect...
|
|
|
|
|
|
|
|
(cherry picked from commit 4d1234e22242529c8d85f5ef0cf826af41a91570)
Conflicts:
src/mesa/state_tracker/st_draw.c
|
|
Changes in v4;
- Implemented Brian Paul's style suggestions
Changes in v3:
- Use positive caps instead of negative ones
Changes in v2:
- Updated formatting
The state tracker will use the TGSI convention properties if the hardware
exposes the appropriate capability, and otherwise adjust WPOS itself.
This will also fix some drivers that were previously broken due to their
incorrect, inadvertent, use of conventions other than upper_left+half_integer.
|
|
Conflicts:
src/gallium/drivers/softpipe/sp_screen.c
src/gallium/include/pipe/p_defines.h
|
|
|