Age | Commit message (Collapse) | Author |
|
When adding a new bitmap to the cache we have to check if the Z value is
changing and flush first if it is.
This is a modified version of a patch from Justin Dou <justin.dou@intel.com>
|
|
|
|
This branch introduces new FRAG_ATTRIB_FACE and FRAG_ATTRIB_PNTC fragment
program inputs for GLSL gl_FrontFacing and gl_PointCoord. Before, these
attributes were packed with the FOG attribute. That made things
complicated elsewhere.
|
|
This saves mapping the index buffer to get a bounds on the indices that
drivers just drop on the floor in the VBO case (cache win), saves a bonus
walk of the indices in the CheckArrayBounds case, and other miscellaneous
validation. On intel it's a particularly a large win (50-100% in my app)
because even though we let the indices stay in both CPU and GPU caches, we
still end up waiting for the GPU to be done with the buffer before reading
from it.
Drivers that want the min/max_index fields must now check index_bounds_valid
and use vbo_get_minmax_index before using them.
|
|
Called from core Mesa now.
|
|
This commit adds functions to bind a pipe surface to a texture. This
allows texturing directly from the surface.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
|
|
Conflicts:
src/mesa/main/state.c
|
|
We now handle the case of blitting Z+stencil to/from combined Z/stencil
surfaces. But Z-only or stencil-only and separate depth/stencil surfaces
are not yet implemented.
|
|
Need to check for Y inversion separately for src/dest buffers.
If both the src and dest regions are upside down, make them right-side
up for a better chance at a fast path.
progs/tests/copypixrate -blit is much faster now.
|
|
|
|
supported
|
|
|
|
The LOOP/ENDLOOP pair is renamed to BGNFOR/ENDFOR as its behaviour
is similar to a C language for-loop.
The BGNLOOP2/ENDLOOP2 pair is renamed to BGNLOOP/ENDLOOP as now
there is no name collision.
|
|
|
|
For GL_RGB5, GL_RGB4 and GL_R3_G3_B2, prefer
PIPE_FORMAT_R5G6B5_UNORM over PIPE_FORMAT_A1R5G5B5_UNORM, since hardware
is more likely to support the previous format for rendering.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
|
|
If a texture image is bound to a framebuffer for render-to-texture, but
the hardware doesn't support rendering to its internal format,
report the framebuffer as incomplete with FRAMEBUFFER_UNSUPPORTED.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
|
|
Previously, the FOGC attribute contained the fragment fog coord, front/back-
face flag and the gl_PointCoord.xy values. Now each of those things are
separate fragment program attributes. This simplifies quite a few things in
Mesa and gallium.
Need to test i965 driver and fix up point coord handling in the gallium/draw
module...
|
|
When sampling a 2D shadow map we need 3 texcoord components, not 2.
The third component (distance from light source) is compared against
the texture sample to return the result (visible vs. occluded).
Also, enable proper handling of TGSI_TEXTURE_SHADOW targets in Mesa->TGSI
translation. There's a possibility for breakage in gallium drivers if
they fail to handle the TGSI_TEXTURE_SHADOW1D / TGSI_TEXTURE_SHADOW2D /
TGSI_TEXTURE_SHADOWRECT texture targets for TGSI_OPCODE_TEX/TXP instructions,
but that should be easy to fix.
With these changes, progs/demos/shadowtex.c renders properly again with
softpipe.
|
|
Windows opengl32.dll calls glFinish prior to every swapbuffers, which
makes it pretty hard to get decent performance...
Work around by mapping finish to flush on PIPE_OS_WINDOWS. This is
conformant, though it might confuse poorly-written benchmarks which
attempt to measure a single event rather than figuring out the rate of
continuous processing.
|
|
Some apps enable scissor but set the rectangle to the dimensions of
the window. Don't let this force us onto a slower clear path.
|
|
Conflicts:
Makefile
configs/default
docs/relnotes.html
src/mesa/main/version.h
|
|
|
|
Remove the need to have a pointer in this struct by just including
the immediate data inline. Having a pointer in the struct introduces
complications like needing to alloc/free the data pointed to, uncertainty
about who owns the data, etc. There doesn't seem to be a need for it,
and it is unlikely to make much difference plus or minus to performance.
Added some asserts as we now will trip up on immediates with more
than four elements. There were actually already quite a few such asserts,
but the >4 case could be used in the future to specify indexable immediate
ranges, such as lookup tables.
|
|
Conflicts:
Makefile
progs/glsl/multitex.c
src/mesa/main/enums.c
src/mesa/main/state.c
src/mesa/main/texenvprogram.c
src/mesa/main/version.h
|
|
It was providing 1 too many for non power two values.
|
|
|
|
|
|
default extension list
|
|
|
|
otherwise we decrement indexes for all registers
|
|
|
|
|
|
Also fix one case where a 32 bit depth value was incorrectly converted to a
combined depth/stencil value.
|
|
Fixes potential crash when SwapBuffers is called but there's no back buffer.
|
|
fix the cases when fog coord/front face/point coord are used in the same
shader.
|
|
|
|
|
|
Conflicts:
src/mesa/main/dlist.c
src/mesa/vbo/vbo_save_api.c
|
|
|
|
Conflicts:
src/mesa/vbo/vbo_exec_draw.c
|
|
As prescribed by ARB_map_buffer_range.
|
|
|
|
|
|
|
|
mesa allocates both frontface and pointcoord registers within the fog
coordinate register, by using swizzling. to make it cleaner and easier
for drivers we want each of them in its own register. so when doing
compilation from the mesa IR to tgsi allocate new registers for both
and add new semantics to the respective declarations.
|
|
All gallium drivers should be able to support mixed-size color/depth/stencil
buffers. If not, we'll need a new PIPE_CAP_ query.
|
|
|
|
|
|
Fixes leak running compiz with direct rendering.
|
|
The first time a context is bound to a drawable, the viewport and scissor
bounds are initialized to the buffer's size. This is actually a bit tricky.
A new _mesa_check_init_viewport() function is called in several places
to check if the viewport has been initialized. We also use a new
ctx->ViewportInitialized flag instead of the overloaded
ctx->FirstTimeCurrent flag.
|