mesa.git
16 years agomove cliprect bounds, do trivial rejection triangle clipping
Brian [Wed, 9 Jan 2008 21:44:19 +0000 (14:44 -0700)]
move cliprect bounds, do trivial rejection triangle clipping

16 years agoCell: remove some debug printfs, predicate others with Debug boolean
Brian [Wed, 9 Jan 2008 21:14:24 +0000 (14:14 -0700)]
Cell: remove some debug printfs, predicate others with Debug boolean

16 years agoCell: implemement basic Z testing
Brian [Wed, 9 Jan 2008 21:10:59 +0000 (14:10 -0700)]
Cell: implemement basic Z testing

Also, improve some surface clearing code

16 years agosoftpipe: map only once in softpipe_map_surfaces
Jerome Glisse [Thu, 10 Jan 2008 00:11:53 +0000 (01:11 +0100)]
softpipe: map only once in softpipe_map_surfaces

softpipe_map_surfaces get call several time but softpipe_unmap_surfaces
get call only once. So to make sure stuff are properly unmap when
softpipe_unmap_surfaces get call we map surfaces only one time in
softpipe_map_surfaces.

16 years agogallium: Make texture target an enum for better debuggability.
Michel Dänzer [Fri, 4 Jan 2008 16:06:55 +0000 (17:06 +0100)]
gallium: Make texture target an enum for better debuggability.

Also make enum pipe_format used in a couple more places.

16 years agollvm: if llvm is enabled don't even try to use sse for vs
Zack Rusin [Fri, 4 Jan 2008 15:01:32 +0000 (10:01 -0500)]
llvm: if llvm is enabled don't even try to use sse for vs

16 years agollvm: we need custom rules so had to redo the build a little bit
Zack Rusin [Fri, 4 Jan 2008 14:27:42 +0000 (09:27 -0500)]
llvm: we need custom rules so had to redo the build a little bit

also don't use sse when llvm is enabled

16 years agollvm: update llvm sources the latest svn
Zack Rusin [Fri, 4 Jan 2008 13:32:20 +0000 (08:32 -0500)]
llvm: update llvm sources the latest svn

16 years ago965: fix various refcount issues
Keith Whitwell [Thu, 3 Jan 2008 19:46:59 +0000 (19:46 +0000)]
965: fix various refcount issues

16 years ago965: use correct offset for constants vs immediates
Keith Whitwell [Thu, 3 Jan 2008 19:46:16 +0000 (19:46 +0000)]
965: use correct offset for constants vs immediates

16 years ago965: always perform SF parameter setup for position
Keith Whitwell [Thu, 3 Jan 2008 17:21:22 +0000 (17:21 +0000)]
965: always perform SF parameter setup for position

Match behaviour of DRI driver.  Fix fragment shader to find the other
parameters one slot further on.  Will need more work to cope with FP's
that actually reference position.

16 years ago965: scan fs inputs to work out interpolation in setup program
Keith Whitwell [Thu, 3 Jan 2008 16:44:56 +0000 (16:44 +0000)]
965: scan fs inputs to work out interpolation in setup program

16 years agoclean-ups, silence warnings
Brian [Thu, 3 Jan 2008 22:09:30 +0000 (15:09 -0700)]
clean-ups, silence warnings

16 years agorename vars, clean-up formatting
Brian [Thu, 3 Jan 2008 22:05:51 +0000 (15:05 -0700)]
rename vars, clean-up formatting

16 years agoreplace void * with struct draw_vertex_shader opaque type
Brian [Thu, 3 Jan 2008 22:03:52 +0000 (15:03 -0700)]
replace void * with struct draw_vertex_shader opaque type

16 years agoCell: added -Wmissing-prototypes to SPU_CFLAGS
Brian [Thu, 3 Jan 2008 16:57:12 +0000 (09:57 -0700)]
Cell: added -Wmissing-prototypes to SPU_CFLAGS

16 years agoCell: initial work for getting/putting Z tiles
Brian [Thu, 3 Jan 2008 16:56:48 +0000 (09:56 -0700)]
Cell: initial work for getting/putting Z tiles

16 years agodisable bbox code until glitches are fixed
Brian [Thu, 3 Jan 2008 16:40:32 +0000 (09:40 -0700)]
disable bbox code until glitches are fixed

16 years agoCell: improve surface state code to replace some temporary code.
Brian [Thu, 3 Jan 2008 16:40:02 +0000 (09:40 -0700)]
Cell: improve surface state code to replace some temporary code.

16 years agoasst changes in bbox code, dma tags, etc
Brian [Thu, 3 Jan 2008 15:58:51 +0000 (08:58 -0700)]
asst changes in bbox code, dma tags, etc

16 years agoinsert a temporary flush to fix missing triangles artifact
Brian [Thu, 3 Jan 2008 15:58:01 +0000 (08:58 -0700)]
insert a temporary flush to fix missing triangles artifact

16 years agopass surface format in cell_command_framebuffer struct
Brian [Thu, 3 Jan 2008 14:49:59 +0000 (07:49 -0700)]
pass surface format in cell_command_framebuffer struct

16 years agobetter debug code
Brian [Thu, 3 Jan 2008 14:49:13 +0000 (07:49 -0700)]
better debug code

16 years agomake use of prim bounds box info
Brian [Thu, 3 Jan 2008 02:31:36 +0000 (19:31 -0700)]
make use of prim bounds box info

16 years agoonly fetch as much vertex data as needed
Brian [Thu, 3 Jan 2008 02:05:34 +0000 (19:05 -0700)]
only fetch as much vertex data as needed

16 years agoremove previous triangle test code
Brian [Thu, 3 Jan 2008 01:58:44 +0000 (18:58 -0700)]
remove previous triangle test code

16 years agoCell: basic triangle rendering works.
Brian [Thu, 3 Jan 2008 01:53:33 +0000 (18:53 -0700)]
Cell: basic triangle rendering works.

The cell "render_stage" (last in the "draw" pipeline) emits vertices into
a buffer which is pulled by the SPUs in response to a "RENDER" command.
This is pretty much temporary/scaffold code for now.

16 years agoPlug in more infrastructure for actual rendering.
Brian [Tue, 1 Jan 2008 22:21:14 +0000 (15:21 -0700)]
Plug in more infrastructure for actual rendering.

Track vertex/fragment shader state.
Plug in pipe->draw_arrays(), pipe->draw_elements().
Plug render stage (a stub) into end of 'draw' pipeline.
Specify a hard-coded vertex format for now.

16 years agohack/fix pack_color() for correct ps3 format
Brian [Tue, 1 Jan 2008 21:01:14 +0000 (14:01 -0700)]
hack/fix pack_color() for correct ps3 format

16 years agoClean-up, re-org some vertex/fragment shader state code.
Brian [Tue, 1 Jan 2008 22:17:30 +0000 (15:17 -0700)]
Clean-up, re-org some vertex/fragment shader state code.

16 years agomove SP_NEW_ #defines into sp_state.h
Brian [Tue, 1 Jan 2008 22:09:16 +0000 (15:09 -0700)]
move SP_NEW_ #defines into sp_state.h

16 years agofix vbo display list memleak upon context destruction
Brian [Fri, 28 Dec 2007 21:52:12 +0000 (14:52 -0700)]
fix vbo display list memleak upon context destruction

16 years agounref buffer after drawing, fixes rastpos mem leak
Brian [Fri, 28 Dec 2007 21:25:09 +0000 (14:25 -0700)]
unref buffer after drawing, fixes rastpos mem leak

16 years agofix single-sided stencil test bug
Brian [Fri, 28 Dec 2007 21:18:18 +0000 (14:18 -0700)]
fix single-sided stencil test bug

16 years agofix leak, fix refcount error
Brian [Fri, 28 Dec 2007 02:18:12 +0000 (19:18 -0700)]
fix leak, fix refcount error

16 years agofix a mem leak, document another existing leak
Brian [Fri, 28 Dec 2007 02:17:41 +0000 (19:17 -0700)]
fix a mem leak, document another existing leak

16 years agounref const buffers during context destroy
Brian [Wed, 26 Dec 2007 14:16:41 +0000 (07:16 -0700)]
unref const buffers during context destroy

16 years agounref const buffers during context destroy
Brian [Wed, 26 Dec 2007 14:16:12 +0000 (07:16 -0700)]
unref const buffers during context destroy

16 years agofree program caches
Brian [Wed, 26 Dec 2007 13:57:24 +0000 (06:57 -0700)]
free program caches

16 years agofix mem leaks
Brian [Wed, 26 Dec 2007 13:56:58 +0000 (06:56 -0700)]
fix mem leaks

16 years agofix mem leak (free key)
Brian [Wed, 26 Dec 2007 13:56:42 +0000 (06:56 -0700)]
fix mem leak (free key)

16 years agofree surface caches in softpipe_destroy()
Brian [Tue, 25 Dec 2007 00:40:02 +0000 (17:40 -0700)]
free surface caches in softpipe_destroy()

16 years agofix a memleak
Brian [Tue, 25 Dec 2007 00:39:21 +0000 (17:39 -0700)]
fix a memleak

16 years agofree tgsi machine state
Brian [Tue, 25 Dec 2007 00:39:01 +0000 (17:39 -0700)]
free tgsi machine state

16 years agofree tgsi machine state
Brian [Tue, 25 Dec 2007 00:38:35 +0000 (17:38 -0700)]
free tgsi machine state

16 years agoadded tgsi_exec_machine_free_data()
Brian [Tue, 25 Dec 2007 00:37:59 +0000 (17:37 -0700)]
added tgsi_exec_machine_free_data()

16 years agofree Default1D/2DArray objects
Brian [Tue, 25 Dec 2007 00:37:30 +0000 (17:37 -0700)]
free Default1D/2DArray objects

16 years agoi965: a little better way of handling immediates
Zack Rusin [Mon, 24 Dec 2007 12:57:34 +0000 (07:57 -0500)]
i965: a little better way of handling immediates

16 years agoi965: very crude and hacky way of handling immediates
Zack Rusin [Thu, 20 Dec 2007 17:54:23 +0000 (12:54 -0500)]
i965: very crude and hacky way of handling immediates

16 years agogallium: make state tracker explictly ask for rendercache flushes
Keith Whitwell [Thu, 20 Dec 2007 13:47:46 +0000 (13:47 +0000)]
gallium: make state tracker explictly ask for rendercache flushes

16 years ago965: respect pipe flush flags
Keith Whitwell [Thu, 20 Dec 2007 13:47:11 +0000 (13:47 +0000)]
965: respect pipe flush flags

Now we emit way too many flushes instead of none at all.

16 years agogallium: translate ARB fp/vp immediates consistently to tgsi immediates
Keith Whitwell [Thu, 20 Dec 2007 13:19:56 +0000 (13:19 +0000)]
gallium: translate ARB fp/vp immediates consistently to tgsi immediates

16 years ago965: fix the constant buffers
Zack Rusin [Thu, 20 Dec 2007 12:05:52 +0000 (07:05 -0500)]
965: fix the constant buffers

16 years agoAdd some prototype code for converting RET to END for main(). Disabled for now.
Brian [Wed, 19 Dec 2007 21:06:22 +0000 (14:06 -0700)]
Add some prototype code for converting RET to END for main().  Disabled for now.

16 years agotemporarily defeat an assertion
Brian [Wed, 19 Dec 2007 20:53:28 +0000 (13:53 -0700)]
temporarily defeat an assertion

16 years agoFix problem with initial viewport/scissor size.
Brian [Wed, 19 Dec 2007 20:45:00 +0000 (13:45 -0700)]
Fix problem with initial viewport/scissor size.

If an app never called glViewport, the viewport size was always 0 by 0 pixels.
Now pass initial size to st_create_framebuffer() and initialize the viewport
and scissor bounds in st_make_current().
This could also be fixed by ensuring the gl_framebuffers passed to
_mesa_make_current() were initialized to the right size.  But that involves
allocating the renderbuffers/pipe_surfaces earlier and that runs into some
other issues ATM.
Also remove obsolete createRenderbuffers param to st_create_framebuffer().

16 years agoconvert Mesa OPCODE_END to TGSI_OPCODE_END, not TGSI_OPCOD_RET
Brian [Wed, 19 Dec 2007 18:50:50 +0000 (11:50 -0700)]
convert Mesa OPCODE_END to TGSI_OPCODE_END, not TGSI_OPCOD_RET

16 years agoremove obsolete TXP, add some sanity checks
Brian [Wed, 19 Dec 2007 15:51:17 +0000 (08:51 -0700)]
remove obsolete TXP, add some sanity checks

16 years agospecial-case PSIZE too
Brian [Wed, 19 Dec 2007 15:50:52 +0000 (08:50 -0700)]
special-case PSIZE too

16 years agomove st_make_current() before buffer size check so renderbuffer alloc storage works
Brian [Wed, 19 Dec 2007 15:50:35 +0000 (08:50 -0700)]
move st_make_current() before buffer size check so renderbuffer alloc storage works

16 years agonew assertions
Brian [Wed, 19 Dec 2007 15:49:59 +0000 (08:49 -0700)]
new assertions

16 years ago965: dump curbe contents to stderr
Keith Whitwell [Wed, 19 Dec 2007 19:05:19 +0000 (19:05 +0000)]
965: dump curbe contents to stderr

16 years ago965: handle BRW_CONSTANT_BUFFER data type
Keith Whitwell [Wed, 19 Dec 2007 19:04:35 +0000 (19:04 +0000)]
965: handle BRW_CONSTANT_BUFFER data type

16 years agoconsts
Zack Rusin [Wed, 19 Dec 2007 18:22:27 +0000 (13:22 -0500)]
consts

16 years ago965: count grf allocation correctly for wm prog, first aub triangle
Keith Whitwell [Wed, 19 Dec 2007 15:48:53 +0000 (15:48 +0000)]
965: count grf allocation correctly for wm prog, first aub triangle

16 years ago965: hardwire correct behaviour for vp-tri setup (for now...)
Keith Whitwell [Wed, 19 Dec 2007 15:16:25 +0000 (15:16 +0000)]
965: hardwire correct behaviour for vp-tri setup (for now...)

16 years agovp-tri: match vertex/color data of other tests
Keith Whitwell [Wed, 19 Dec 2007 15:13:20 +0000 (15:13 +0000)]
vp-tri: match vertex/color data of other tests

16 years ago965: align buffer allocations to 4k
Keith Whitwell [Wed, 19 Dec 2007 14:20:23 +0000 (14:20 +0000)]
965: align buffer allocations to 4k

16 years agouse a depth buffer temporarily
Keith Whitwell [Wed, 19 Dec 2007 13:13:42 +0000 (13:13 +0000)]
use a depth buffer temporarily

16 years ago965: make sure stipple state gets uploaded
Keith Whitwell [Wed, 19 Dec 2007 13:12:34 +0000 (13:12 +0000)]
965: make sure stipple state gets uploaded

16 years ago965: allocate buffer space to hold batch commands
Keith Whitwell [Wed, 19 Dec 2007 13:11:56 +0000 (13:11 +0000)]
965: allocate buffer space to hold batch commands

16 years agoactually set the max_index. useful in the driver
Zack Rusin [Wed, 19 Dec 2007 12:49:42 +0000 (07:49 -0500)]
actually set the max_index. useful in the driver

16 years ago965: fill unused surface pointers with zero
Keith Whitwell [Wed, 19 Dec 2007 12:23:27 +0000 (12:23 +0000)]
965: fill unused surface pointers with zero

16 years agoi965: emit fb write on RET for now (until we get END back)
Zack Rusin [Wed, 19 Dec 2007 12:08:13 +0000 (07:08 -0500)]
i965: emit fb write on RET for now (until we get END back)

16 years ago965: pitch is in bytes not pixels
Keith Whitwell [Wed, 19 Dec 2007 11:49:56 +0000 (11:49 +0000)]
965: pitch is in bytes not pixels

16 years ago965: fix off-by-one in scissor rect
Keith Whitwell [Wed, 19 Dec 2007 11:36:03 +0000 (11:36 +0000)]
965: fix off-by-one in scissor rect

16 years ago965: fix off-by-one in surface dimensions
Keith Whitwell [Wed, 19 Dec 2007 11:35:21 +0000 (11:35 +0000)]
965: fix off-by-one in surface dimensions

16 years ago965: respect surface width when dumping bitmap
Keith Whitwell [Wed, 19 Dec 2007 11:32:56 +0000 (11:32 +0000)]
965: respect surface width when dumping bitmap

16 years agoi965: actually detect whether a sampler is enabled/disabled
Zack Rusin [Wed, 19 Dec 2007 11:00:30 +0000 (06:00 -0500)]
i965: actually detect whether a sampler is enabled/disabled

16 years ago965: disable clipping more, and restore drawing rect packet
Keith Whitwell [Wed, 19 Dec 2007 11:10:30 +0000 (11:10 +0000)]
965: disable clipping more, and restore drawing rect packet

16 years ago965: disable clipping for now
Keith Whitwell [Wed, 19 Dec 2007 11:10:06 +0000 (11:10 +0000)]
965: disable clipping for now

16 years ago965: fix vertex pointsize state, match default cull mode
Keith Whitwell [Wed, 19 Dec 2007 10:55:49 +0000 (10:55 +0000)]
965: fix vertex pointsize state, match default cull mode

16 years ago965: fix colormask state
Keith Whitwell [Wed, 19 Dec 2007 10:49:16 +0000 (10:49 +0000)]
965: fix colormask state

16 years ago965: populate fp_input_count in setup key
Keith Whitwell [Wed, 19 Dec 2007 10:20:14 +0000 (10:20 +0000)]
965: populate fp_input_count in setup key

16 years agoi965: stuff the outputs into mrf registers when possible
Zack Rusin [Wed, 19 Dec 2007 10:28:28 +0000 (05:28 -0500)]
i965: stuff the outputs into mrf registers when possible

16 years agoi965: be smarter about register allocation
Zack Rusin [Wed, 19 Dec 2007 09:58:29 +0000 (04:58 -0500)]
i965: be smarter about register allocation

16 years agoturn off TGSI_DEBUG
Brian [Tue, 18 Dec 2007 23:01:25 +0000 (16:01 -0700)]
turn off TGSI_DEBUG

16 years agofix bug on GL_VERTEX_PROGRAM_TWO_SIDE path
Brian [Tue, 18 Dec 2007 23:00:58 +0000 (16:00 -0700)]
fix bug on GL_VERTEX_PROGRAM_TWO_SIDE path

16 years agosetup the frontface register (fog.y, ATM)
Brian [Tue, 18 Dec 2007 23:00:31 +0000 (16:00 -0700)]
setup the frontface register (fog.y, ATM)

16 years agofix some semantic info mix-ups in calculate_vertex_layout()
Brian [Tue, 18 Dec 2007 22:59:54 +0000 (15:59 -0700)]
fix some semantic info mix-ups in calculate_vertex_layout()

16 years agogallium: rationalize vertex_element state packet
Keith Whitwell [Tue, 18 Dec 2007 17:25:33 +0000 (17:25 +0000)]
gallium:  rationalize vertex_element state packet

Remove dst_offset (not used)
Add nr_components, which could be calculated from format, but would be
too much effort.

Update i965 driver to cope.

16 years agogallium: give userbuffers some storage in the aub buffer pool
Keith Whitwell [Tue, 18 Dec 2007 16:57:17 +0000 (16:57 +0000)]
gallium: give userbuffers some storage in the aub buffer pool

16 years agovbo: unmap and remap immediate vbo before/after each draw.
Keith Whitwell [Tue, 18 Dec 2007 16:56:22 +0000 (16:56 +0000)]
vbo: unmap and remap immediate vbo before/after each draw.

Also use BufferData(NULL) to get fresh storage and avoid synchronous
operation where we would have to flush and wait for the fence after each
draw because of the map.

This will chew through a whole load of buffer space on small draws, so
it isn't a proper solution.  Need to support a no-fence or append mapping
mode to do this right, or use user buffers.

16 years agoi965: don't treat swz differently and upload vertex buffers
Zack Rusin [Tue, 18 Dec 2007 14:59:54 +0000 (09:59 -0500)]
i965: don't treat swz differently and upload vertex buffers

16 years agoobsolete
Brian [Tue, 18 Dec 2007 03:41:20 +0000 (20:41 -0700)]
obsolete

16 years agoupdates for depth/stencil/alpha state
Brian [Mon, 17 Dec 2007 21:05:53 +0000 (14:05 -0700)]
updates for depth/stencil/alpha state

16 years agoEmit declarations for constants (references to the const buffer)
Brian [Mon, 17 Dec 2007 20:59:55 +0000 (13:59 -0700)]
Emit declarations for constants (references to the const buffer)

16 years agoi965: index the destination offset with regards to the current index
Zack Rusin [Mon, 17 Dec 2007 19:36:31 +0000 (14:36 -0500)]
i965: index the destination offset with regards to the current index

16 years agoi965: return false when the function fails, not succeeds
Zack Rusin [Mon, 17 Dec 2007 19:05:46 +0000 (14:05 -0500)]
i965: return false when the function fails, not succeeds

16 years agoAdd the new test program for fp's.
Zack Rusin [Mon, 17 Dec 2007 18:21:45 +0000 (13:21 -0500)]
Add the new test program for fp's.