Age | Commit message (Collapse) | Author |
|
|
|
This change silenced valgrind warnings but broke progs/tests/drawbuffers.
The problem is we don't know the surface's state when we start caching it
(it may or may not be initialized/cleared/etc). So "clearing" it here was
presumptuous. Leaving the code in place (but disabled) for reference and
when using valgrind.
Fixes bug 24401
|
|
Conflicts:
Makefile
configs/default
docs/relnotes.html
src/gallium/drivers/softpipe/sp_context.c
src/gallium/drivers/softpipe/sp_tile_cache.c
src/mesa/main/version.h
|
|
This silences tons of valgrind warnings in programs that don't call
glClear(), such as progs/demos/gamma.
|
|
Conflicts:
src/gallium/drivers/softpipe/sp_tile_cache.c
|
|
|
|
|
|
Conflicts:
src/gallium/drivers/softpipe/sp_state_derived.c
src/gallium/drivers/softpipe/sp_state_sampler.c
src/gallium/drivers/softpipe/sp_tex_sample.c
src/gallium/drivers/softpipe/sp_tex_sample.h
src/gallium/drivers/softpipe/sp_tile_cache.c
|
|
The tile cache code now has no hard dependencies on softpipe.
|
|
|
|
These do similar jobs but with largely disjoint code. Will want
to evolve them separately going forward.
|
|
|
|
The sp_tile_cache is often called repeatedly to look up the same
tile. Add a cache (to the cache) of the single tile most recently
retreived and make a quick inline check to see if this matches the
subsequent request.
Add a tile_address bitfield struct to make this check easier.
|
|
No performance gain yet, but the code is a bit cleaner.
|
|
The tile cache is a utility, it shouldn't know anything about the
entity which is making use of it (ie softpipe).
Remove softpipe parameter to all the tilecache function calls, and
also remove the need to keep a softpipe pointer in the sampler structs.
|
|
|
|
|
|
Need to null-out pointers after freeing transfer objects.
Fix mix-ups between tc->transfer and tc->tex_trans fields.
|
|
This fixes a number of crashes/regressions in programs such as lodbias.c,
mipmap_limits.c, etc.
|
|
The core reference counting code is centralized in p_refcnt.h.
This has some consequences related to struct pipe_buffer:
* The screen member of struct pipe_buffer must be initialized, or
pipe_buffer_reference() will crash trying to destroy a buffer with reference
count 0. u_simple_screen takes care of this, but I may have missed some of
the drivers not using it.
* Except for rare exceptions deep in winsys code, buffers must always be
allocated via pipe_buffer_create() or via screen->*buffer_create() rather
than via winsys->*buffer_create().
|
|
Conflicts:
src/gallium/drivers/softpipe/sp_tile_cache.c
|
|
Use a somewhat better function in tex_cache_pos() to get better caching.
Increase number of cache entries to 50.
Also fix a texture invalidation bug. If texture is marked as modified,
invalidate all texture tiles.
|
|
A lot more test programs work.
|
|
glxgears works.
|
|
Missed these for the initial gallium-texture-transfer commit.
|
|
Instead, a new pipe_transfer object has to be created and mapped for
transferring data between the CPU and a texture. This gives the driver more
flexibility for textures in address spaces that aren't CPU accessible.
This is a first pass; softpipe/xlib builds and runs glxgears, but it only shows
a black window. Looks like something's off related to the Z buffer, so the
depth test always fails.
|
|
this change disassociates, at least from the driver perspective,
the surface from buffer. surfaces are technically now views on the
textures so make it so by hiding the buffer in the internals of
textures.
|
|
Use tgsi_sampler struct as a base class. Softpipe subclasses it and adds
the fields it needs.
|
|
Also, rename p_tile.[ch] to u_tile.[ch]
|
|
|
|
|
|
You don't need a pipe_context * for this, and all other necessary info is
already inside pipe_surface.
|
|
When a surface is created with GPU_WRITE that really means "GPU render"
and that can involve reads (blending). Set surface usage to
PIPE_BUFFER_USAGE_CPU_READ + WRITE. Fixes progs/demos/lodbias demo.
Also, mark texture as 'modified' when mapped for writing so that the tile
cache can know when to freshen a cached tile. Fixes glTexSubImage2D().
|
|
|
|
Conflicts:
src/mesa/state_tracker/st_atom_sampler.c
src/mesa/state_tracker/st_cb_texture.c
|
|
|
|
But when creating surfaces, adjust incoming flags from GPU->CPU usage.
|
|
|
|
|
|
|
|
|
|
These functions are now per-screen, not per-context.
|
|
Added pipe field to pipe_texture (temporary, see comments).
First step toward context-less texture creation...
|
|
Called whenever texture data is changed (glTexImage, glTexSubImage,
glCopyTexSubImage, etc).
|
|
|
|
Update the Makefiles and includes for the new paths.
Note that there hasn't been no separation of the Makefiles yet, and make is
jumping all over the place. That will be taken care shortly. But for now, make
should work. It was tested with linux and linux-dri. Linux-cell and linux-llvm
might require some minor tweaks.
|
|
This is in a separate commit to ensure renames are properly preserved.
|