Merge remote branch 'upstream/gallium-0.1' into nouveau-gallium-0.1
authorBen Skeggs <skeggsb@gmail.com>
Mon, 26 May 2008 14:59:41 +0000 (00:59 +1000)
committerBen Skeggs <skeggsb@gmail.com>
Mon, 26 May 2008 14:59:41 +0000 (00:59 +1000)
654 files changed:
bin/raw2png.py [new file with mode: 0755]
bin/win32kprof.py [new file with mode: 0755]
common.py
docs/MESA_packed_depth_stencil.spec
docs/MESA_program_debug.spec
docs/MESA_resize_buffers.spec
docs/MESA_shader_debug.spec
docs/MESA_sprite_point.spec
docs/MESA_texture_array.spec
docs/MESA_trace.spec
docs/MESA_window_pos.spec
docs/README.BEOS
docs/README.QUAKE
docs/RELNOTES-3.1
docs/RELNOTES-3.2
docs/RELNOTES-3.2.1
docs/RELNOTES-3.3
docs/RELNOTES-3.4
docs/RELNOTES-3.4.1
docs/RELNOTES-3.4.2
docs/RELNOTES-3.5
docs/RELNOTES-4.0
docs/RELNOTES-4.0.1
docs/RELNOTES-4.0.2
docs/RELNOTES-4.0.3
docs/RELNOTES-4.1
docs/RELNOTES-5.0
docs/RELNOTES-5.0.1
docs/RELNOTES-5.0.2
docs/RELNOTES-6.0
docs/RELNOTES-6.0.1
docs/RELNOTES-6.1
docs/RELNOTES-6.2
docs/RELNOTES-6.2.1
docs/RELNOTES-6.3
docs/RELNOTES-6.3.1
docs/RELNOTES-6.3.2
docs/RELNOTES-6.4
docs/news.html
include/GL/internal/sarea.h
progs/beos/demo.cpp
progs/ggi/gears.c
progs/miniglx/glfbdevtest.c
progs/miniglx/manytex.c
progs/miniglx/sample_server.c
progs/miniglx/sample_server2.c
progs/miniglx/texline.c
progs/tests/Makefile.win
progs/tests/antialias.c
progs/tests/cva.c
progs/tests/fbotest2.c
progs/tests/getprocaddress.py
progs/tests/jkrahntest.c
progs/tests/manytex.c
progs/tests/multipal.c
progs/tests/multiwindow.c
progs/tests/sharedtex.c
progs/tests/texline.c
progs/tests/texrect.c
progs/tests/texwrap.c
progs/util/README
progs/util/glstate.c
progs/util/glstate.h
progs/util/sampleMakefile
progs/windml/ugldrawpix.c
progs/windml/ugltexcyl.c
progs/xdemos/glthreads.c
progs/xdemos/vgears.c
src/gallium/README.portability
src/gallium/auxiliary/cso_cache/cso_context.c
src/gallium/auxiliary/draw/draw_pipe_aaline.c
src/gallium/auxiliary/draw/draw_pipe_pstipple.c
src/gallium/auxiliary/draw/draw_pipe_vbuf.c
src/gallium/auxiliary/draw/draw_pt_fetch.c
src/gallium/auxiliary/draw/draw_pt_fetch_emit.c
src/gallium/auxiliary/pipebuffer/Makefile
src/gallium/auxiliary/pipebuffer/SConscript
src/gallium/auxiliary/pipebuffer/pb_buffer.h
src/gallium/auxiliary/pipebuffer/pb_buffer_fenced.c
src/gallium/auxiliary/pipebuffer/pb_bufmgr.h
src/gallium/auxiliary/pipebuffer/pb_bufmgr_slab.c
src/gallium/auxiliary/pipebuffer/pb_validate.c [new file with mode: 0644]
src/gallium/auxiliary/pipebuffer/pb_validate.h [new file with mode: 0644]
src/gallium/auxiliary/util/SConscript
src/gallium/auxiliary/util/p_debug.c
src/gallium/auxiliary/util/p_debug_mem.c
src/gallium/auxiliary/util/p_debug_prof.c [new file with mode: 0644]
src/gallium/auxiliary/util/p_tile.c
src/gallium/auxiliary/util/u_blit.c
src/gallium/auxiliary/util/u_draw_quad.c
src/gallium/auxiliary/util/u_gen_mipmap.c
src/gallium/auxiliary/util/u_hash_table.c
src/gallium/auxiliary/util/u_hash_table.h
src/gallium/auxiliary/util/u_pack_color.h
src/gallium/auxiliary/util/u_string.h
src/gallium/drivers/failover/fo_context.c
src/gallium/drivers/i915simple/i915_context.h
src/gallium/drivers/i915simple/i915_screen.c
src/gallium/drivers/i915simple/i915_state.c
src/gallium/drivers/i915simple/i915_surface.c
src/gallium/drivers/i915simple/i915_texture.c
src/gallium/drivers/i965simple/brw_context.h
src/gallium/drivers/i965simple/brw_state.c
src/gallium/drivers/i965simple/brw_surface.c
src/gallium/drivers/i965simple/brw_tex_layout.c
src/gallium/drivers/softpipe/sp_context.c
src/gallium/drivers/softpipe/sp_flush.c
src/gallium/drivers/softpipe/sp_screen.c
src/gallium/drivers/softpipe/sp_screen.h [new file with mode: 0644]
src/gallium/drivers/softpipe/sp_surface.c
src/gallium/drivers/softpipe/sp_texture.c
src/gallium/drivers/softpipe/sp_texture.h
src/gallium/drivers/softpipe/sp_tile_cache.c
src/gallium/drivers/softpipe/sp_tile_cache.h
src/gallium/include/pipe/p_context.h
src/gallium/include/pipe/p_debug.h
src/gallium/include/pipe/p_defines.h
src/gallium/include/pipe/p_format.h
src/gallium/include/pipe/p_inlines.h
src/gallium/include/pipe/p_screen.h
src/gallium/include/pipe/p_state.h
src/gallium/include/pipe/p_util.h
src/gallium/include/pipe/p_winsys.h
src/gallium/winsys/dri/intel/intel_winsys_pipe.c
src/gallium/winsys/dri/intel/server/i830_common.h
src/gallium/winsys/dri/intel/server/i830_dri.h
src/gallium/winsys/xlib/xm_winsys.c
src/gallium/winsys/xlib/xm_winsys_aub.c
src/glu/mini/all.h
src/glu/mini/glu.c
src/glu/mini/gluP.h
src/glu/mini/mipmap.c
src/glu/mini/nurbs.c
src/glu/mini/nurbs.h
src/glu/mini/nurbscrv.c
src/glu/mini/polytest.c
src/glu/mini/project.c
src/glu/mini/quadric.c
src/glu/mini/tess.c
src/glu/mini/tess.h
src/glu/mini/tesselat.c
src/glu/sgi/dummy.cc
src/glu/sgi/libnurbs/interface/bezierEval.h
src/glu/sgi/libnurbs/interface/bezierPatch.cc
src/glu/sgi/libnurbs/interface/bezierPatch.h
src/glu/sgi/libnurbs/interface/bezierPatchMesh.cc
src/glu/sgi/libnurbs/interface/bezierPatchMesh.h
src/glu/sgi/libnurbs/interface/glcurveval.cc
src/glu/sgi/libnurbs/interface/glimports.h
src/glu/sgi/libnurbs/interface/glinterface.cc
src/glu/sgi/libnurbs/interface/glrenderer.h
src/glu/sgi/libnurbs/interface/incurveeval.cc
src/glu/sgi/libnurbs/interface/insurfeval.cc
src/glu/sgi/libnurbs/interface/mystdio.h
src/glu/sgi/libnurbs/interface/mystdlib.h
src/glu/sgi/libnurbs/internals/arc.h
src/glu/sgi/libnurbs/internals/arcsorter.cc
src/glu/sgi/libnurbs/internals/arcsorter.h
src/glu/sgi/libnurbs/internals/arctess.h
src/glu/sgi/libnurbs/internals/backend.cc
src/glu/sgi/libnurbs/internals/backend.h
src/glu/sgi/libnurbs/internals/basiccrveval.h
src/glu/sgi/libnurbs/internals/basicsurfeval.h
src/glu/sgi/libnurbs/internals/bezierarc.h
src/glu/sgi/libnurbs/internals/bin.cc
src/glu/sgi/libnurbs/internals/bin.h
src/glu/sgi/libnurbs/internals/bufpool.cc
src/glu/sgi/libnurbs/internals/bufpool.h
src/glu/sgi/libnurbs/internals/cachingeval.cc
src/glu/sgi/libnurbs/internals/cachingeval.h
src/glu/sgi/libnurbs/internals/ccw.cc
src/glu/sgi/libnurbs/internals/coveandtiler.h
src/glu/sgi/libnurbs/internals/curve.cc
src/glu/sgi/libnurbs/internals/curve.h
src/glu/sgi/libnurbs/internals/curvelist.cc
src/glu/sgi/libnurbs/internals/curvelist.h
src/glu/sgi/libnurbs/internals/curvesub.cc
src/glu/sgi/libnurbs/internals/dataTransform.cc
src/glu/sgi/libnurbs/internals/dataTransform.h
src/glu/sgi/libnurbs/internals/defines.h
src/glu/sgi/libnurbs/internals/displaylist.cc
src/glu/sgi/libnurbs/internals/displaylist.h
src/glu/sgi/libnurbs/internals/displaymode.h
src/glu/sgi/libnurbs/internals/flist.cc
src/glu/sgi/libnurbs/internals/flist.h
src/glu/sgi/libnurbs/internals/flistsorter.cc
src/glu/sgi/libnurbs/internals/flistsorter.h
src/glu/sgi/libnurbs/internals/gridline.h
src/glu/sgi/libnurbs/internals/gridtrimvertex.h
src/glu/sgi/libnurbs/internals/gridvertex.h
src/glu/sgi/libnurbs/internals/hull.cc
src/glu/sgi/libnurbs/internals/hull.h
src/glu/sgi/libnurbs/internals/intersect.cc
src/glu/sgi/libnurbs/internals/jarcloc.h
src/glu/sgi/libnurbs/internals/knotvector.h
src/glu/sgi/libnurbs/internals/mapdesc.cc
src/glu/sgi/libnurbs/internals/mapdesc.h
src/glu/sgi/libnurbs/internals/mapdescv.cc
src/glu/sgi/libnurbs/internals/maplist.cc
src/glu/sgi/libnurbs/internals/maplist.h
src/glu/sgi/libnurbs/internals/mesher.cc
src/glu/sgi/libnurbs/internals/mesher.h
src/glu/sgi/libnurbs/internals/monoTriangulationBackend.cc
src/glu/sgi/libnurbs/internals/monotonizer.cc
src/glu/sgi/libnurbs/internals/monotonizer.h
src/glu/sgi/libnurbs/internals/myassert.h
src/glu/sgi/libnurbs/internals/mycode.cc
src/glu/sgi/libnurbs/internals/mystring.h
src/glu/sgi/libnurbs/internals/nurbsconsts.h
src/glu/sgi/libnurbs/internals/nurbstess.cc
src/glu/sgi/libnurbs/internals/patch.cc
src/glu/sgi/libnurbs/internals/patch.h
src/glu/sgi/libnurbs/internals/patchlist.cc
src/glu/sgi/libnurbs/internals/patchlist.h
src/glu/sgi/libnurbs/internals/pwlarc.h
src/glu/sgi/libnurbs/internals/quilt.cc
src/glu/sgi/libnurbs/internals/quilt.h
src/glu/sgi/libnurbs/internals/reader.cc
src/glu/sgi/libnurbs/internals/reader.h
src/glu/sgi/libnurbs/internals/renderhints.cc
src/glu/sgi/libnurbs/internals/renderhints.h
src/glu/sgi/libnurbs/internals/simplemath.h
src/glu/sgi/libnurbs/internals/slicer.cc
src/glu/sgi/libnurbs/internals/slicer.h
src/glu/sgi/libnurbs/internals/sorter.cc
src/glu/sgi/libnurbs/internals/sorter.h
src/glu/sgi/libnurbs/internals/splitarcs.cc
src/glu/sgi/libnurbs/internals/subdivider.h
src/glu/sgi/libnurbs/internals/tobezier.cc
src/glu/sgi/libnurbs/internals/trimline.cc
src/glu/sgi/libnurbs/internals/trimline.h
src/glu/sgi/libnurbs/internals/trimregion.cc
src/glu/sgi/libnurbs/internals/trimregion.h
src/glu/sgi/libnurbs/internals/trimvertex.h
src/glu/sgi/libnurbs/internals/trimvertpool.cc
src/glu/sgi/libnurbs/internals/trimvertpool.h
src/glu/sgi/libnurbs/internals/types.h
src/glu/sgi/libnurbs/internals/uarray.cc
src/glu/sgi/libnurbs/internals/uarray.h
src/glu/sgi/libnurbs/internals/varray.cc
src/glu/sgi/libnurbs/internals/varray.h
src/glu/sgi/libnurbs/nurbtess/definitions.h
src/glu/sgi/libnurbs/nurbtess/directedLine.h
src/glu/sgi/libnurbs/nurbtess/glimports.h
src/glu/sgi/libnurbs/nurbtess/gridWrap.cc
src/glu/sgi/libnurbs/nurbtess/gridWrap.h
src/glu/sgi/libnurbs/nurbtess/monoChain.cc
src/glu/sgi/libnurbs/nurbtess/monoChain.h
src/glu/sgi/libnurbs/nurbtess/monoPolyPart.cc
src/glu/sgi/libnurbs/nurbtess/monoPolyPart.h
src/glu/sgi/libnurbs/nurbtess/monoTriangulation.cc
src/glu/sgi/libnurbs/nurbtess/monoTriangulation.h
src/glu/sgi/libnurbs/nurbtess/mystdio.h
src/glu/sgi/libnurbs/nurbtess/mystdlib.h
src/glu/sgi/libnurbs/nurbtess/partitionX.cc
src/glu/sgi/libnurbs/nurbtess/partitionX.h
src/glu/sgi/libnurbs/nurbtess/partitionY.cc
src/glu/sgi/libnurbs/nurbtess/partitionY.h
src/glu/sgi/libnurbs/nurbtess/polyDBG.h
src/glu/sgi/libnurbs/nurbtess/polyUtil.cc
src/glu/sgi/libnurbs/nurbtess/polyUtil.h
src/glu/sgi/libnurbs/nurbtess/primitiveStream.cc
src/glu/sgi/libnurbs/nurbtess/primitiveStream.h
src/glu/sgi/libnurbs/nurbtess/quicksort.cc
src/glu/sgi/libnurbs/nurbtess/quicksort.h
src/glu/sgi/libnurbs/nurbtess/rectBlock.cc
src/glu/sgi/libnurbs/nurbtess/rectBlock.h
src/glu/sgi/libnurbs/nurbtess/sampleComp.cc
src/glu/sgi/libnurbs/nurbtess/sampleComp.h
src/glu/sgi/libnurbs/nurbtess/sampleCompBot.cc
src/glu/sgi/libnurbs/nurbtess/sampleCompBot.h
src/glu/sgi/libnurbs/nurbtess/sampleCompRight.cc
src/glu/sgi/libnurbs/nurbtess/sampleCompRight.h
src/glu/sgi/libnurbs/nurbtess/sampleCompTop.cc
src/glu/sgi/libnurbs/nurbtess/sampleCompTop.h
src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.cc
src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.h
src/glu/sgi/libnurbs/nurbtess/sampledLine.cc
src/glu/sgi/libnurbs/nurbtess/sampledLine.h
src/glu/sgi/libnurbs/nurbtess/searchTree.cc
src/glu/sgi/libnurbs/nurbtess/searchTree.h
src/glu/sgi/libnurbs/nurbtess/zlassert.h
src/glu/sgi/libtess/README
src/glu/sgi/libtess/alg-outline
src/glu/sgi/libtess/dict-list.h
src/glu/sgi/libtess/dict.c
src/glu/sgi/libtess/dict.h
src/glu/sgi/libtess/geom.c
src/glu/sgi/libtess/memalloc.c
src/glu/sgi/libtess/memalloc.h
src/glu/sgi/libtess/mesh.c
src/glu/sgi/libtess/mesh.h
src/glu/sgi/libtess/normal.h
src/glu/sgi/libtess/priorityq-heap.c
src/glu/sgi/libtess/priorityq-heap.h
src/glu/sgi/libtess/priorityq-sort.h
src/glu/sgi/libtess/priorityq.c
src/glu/sgi/libtess/priorityq.h
src/glu/sgi/libtess/render.c
src/glu/sgi/libtess/render.h
src/glu/sgi/libtess/sweep.h
src/glu/sgi/libtess/tess.h
src/glu/sgi/libtess/tessmono.c
src/glu/sgi/libtess/tessmono.h
src/glu/sgi/libutil/error.c
src/glu/sgi/libutil/glue.c
src/glu/sgi/libutil/gluint.h
src/glu/sgi/libutil/project.c
src/glu/sgi/libutil/registry.c
src/glut/beos/beos_x11.cpp
src/glut/ggi/debug.h
src/glut/glx/stroke.h
src/glut/glx/win32_x11.c
src/glx/mini/miniglx_events.c
src/glx/x11/XF86dri.c
src/glx/x11/clientattrib.c
src/glx/x11/compsize.c
src/glx/x11/dri_glx.c
src/glx/x11/eval.c
src/glx/x11/glxclient.h
src/glx/x11/glxcmds.c
src/glx/x11/glxext.c
src/glx/x11/indirect_init.h
src/glx/x11/packrender.h
src/glx/x11/packsingle.h
src/glx/x11/pixel.c
src/glx/x11/pixelstore.c
src/glx/x11/render2.c
src/glx/x11/renderpix.c
src/glx/x11/single2.c
src/glx/x11/singlepix.c
src/glx/x11/vertarr.c
src/glx/x11/xf86dri.h
src/glx/x11/xf86dristr.h
src/glx/x11/xfont.c
src/mesa/drivers/dri/common/stenciltmp.h
src/mesa/drivers/dri/common/texmem.c
src/mesa/drivers/dri/common/texmem.h
src/mesa/drivers/dri/common/utils.h
src/mesa/drivers/dri/common/vblank.c
src/mesa/drivers/dri/common/vblank.h
src/mesa/drivers/dri/ffb/ffb_bitmap.c
src/mesa/drivers/dri/ffb/ffb_bitmap.h
src/mesa/drivers/dri/ffb/ffb_clear.c
src/mesa/drivers/dri/ffb/ffb_context.h
src/mesa/drivers/dri/ffb/ffb_dd.c
src/mesa/drivers/dri/ffb/ffb_dd.h
src/mesa/drivers/dri/ffb/ffb_depth.c
src/mesa/drivers/dri/ffb/ffb_depth.h
src/mesa/drivers/dri/ffb/ffb_fifo.h
src/mesa/drivers/dri/ffb/ffb_lines.c
src/mesa/drivers/dri/ffb/ffb_lines.h
src/mesa/drivers/dri/ffb/ffb_linetmp.h
src/mesa/drivers/dri/ffb/ffb_lock.h
src/mesa/drivers/dri/ffb/ffb_points.c
src/mesa/drivers/dri/ffb/ffb_points.h
src/mesa/drivers/dri/ffb/ffb_pointtmp.h
src/mesa/drivers/dri/ffb/ffb_rendertmp.h
src/mesa/drivers/dri/ffb/ffb_span.c
src/mesa/drivers/dri/ffb/ffb_span.h
src/mesa/drivers/dri/ffb/ffb_state.c
src/mesa/drivers/dri/ffb/ffb_state.h
src/mesa/drivers/dri/ffb/ffb_stencil.c
src/mesa/drivers/dri/ffb/ffb_stencil.h
src/mesa/drivers/dri/ffb/ffb_tex.c
src/mesa/drivers/dri/ffb/ffb_tex.h
src/mesa/drivers/dri/ffb/ffb_tris.c
src/mesa/drivers/dri/ffb/ffb_tris.h
src/mesa/drivers/dri/ffb/ffb_tritmp.h
src/mesa/drivers/dri/ffb/ffb_vb.c
src/mesa/drivers/dri/ffb/ffb_vb.h
src/mesa/drivers/dri/ffb/ffb_vbtmp.h
src/mesa/drivers/dri/ffb/ffb_vtxfmt.c
src/mesa/drivers/dri/ffb/ffb_vtxfmt.h
src/mesa/drivers/dri/ffb/ffb_xmesa.c
src/mesa/drivers/dri/ffb/ffb_xmesa.h
src/mesa/drivers/dri/ffb/server/ffb_dac.h
src/mesa/drivers/dri/ffb/server/ffb_drishare.h
src/mesa/drivers/dri/ffb/server/ffb_regs.h
src/mesa/drivers/dri/gamma/gamma_client.h
src/mesa/drivers/dri/gamma/gamma_context.h
src/mesa/drivers/dri/gamma/gamma_inithw.c
src/mesa/drivers/dri/gamma/gamma_lock.c
src/mesa/drivers/dri/gamma/gamma_macros.h
src/mesa/drivers/dri/gamma/gamma_regs.h
src/mesa/drivers/dri/gamma/gamma_span.c
src/mesa/drivers/dri/gamma/gamma_state.c
src/mesa/drivers/dri/gamma/gamma_tex.c
src/mesa/drivers/dri/gamma/gamma_texmem.c
src/mesa/drivers/dri/gamma/gamma_texstate.c
src/mesa/drivers/dri/gamma/gamma_tritmp.h
src/mesa/drivers/dri/gamma/gamma_vb.c
src/mesa/drivers/dri/gamma/gamma_xmesa.c
src/mesa/drivers/dri/gamma/server/glint_common.h
src/mesa/drivers/dri/gamma/server/glint_dri.h
src/mesa/drivers/dri/i810/i810_3d_reg.h
src/mesa/drivers/dri/i810/i810context.c
src/mesa/drivers/dri/i810/i810context.h
src/mesa/drivers/dri/i810/i810ioctl.c
src/mesa/drivers/dri/i810/i810ioctl.h
src/mesa/drivers/dri/i810/i810screen.c
src/mesa/drivers/dri/i810/i810state.c
src/mesa/drivers/dri/i810/i810tex.c
src/mesa/drivers/dri/i810/i810tris.c
src/mesa/drivers/dri/i810/i810tris.h
src/mesa/drivers/dri/i810/i810vb.c
src/mesa/drivers/dri/i810/i810vb.h
src/mesa/drivers/dri/i810/server/i810_common.h
src/mesa/drivers/dri/i810/server/i810_dri.h
src/mesa/drivers/dri/i810/server/i810_reg.h
src/mesa/drivers/dri/i915/server/i830_common.h
src/mesa/drivers/dri/i915/server/i830_dri.h
src/mesa/drivers/dri/i965/server/i830_common.h
src/mesa/drivers/dri/i965/server/i830_dri.h
src/mesa/drivers/dri/mach64/mach64_context.c
src/mesa/drivers/dri/mach64/mach64_context.h
src/mesa/drivers/dri/mach64/mach64_dd.c
src/mesa/drivers/dri/mach64/mach64_dd.h
src/mesa/drivers/dri/mach64/mach64_ioctl.c
src/mesa/drivers/dri/mach64/mach64_ioctl.h
src/mesa/drivers/dri/mach64/mach64_lock.c
src/mesa/drivers/dri/mach64/mach64_lock.h
src/mesa/drivers/dri/mach64/mach64_native_vb.c
src/mesa/drivers/dri/mach64/mach64_native_vbtmp.h
src/mesa/drivers/dri/mach64/mach64_reg.h
src/mesa/drivers/dri/mach64/mach64_screen.c
src/mesa/drivers/dri/mach64/mach64_screen.h
src/mesa/drivers/dri/mach64/mach64_span.c
src/mesa/drivers/dri/mach64/mach64_span.h
src/mesa/drivers/dri/mach64/mach64_state.c
src/mesa/drivers/dri/mach64/mach64_state.h
src/mesa/drivers/dri/mach64/mach64_tex.c
src/mesa/drivers/dri/mach64/mach64_tex.h
src/mesa/drivers/dri/mach64/mach64_texmem.c
src/mesa/drivers/dri/mach64/mach64_texstate.c
src/mesa/drivers/dri/mach64/mach64_tris.c
src/mesa/drivers/dri/mach64/mach64_tris.h
src/mesa/drivers/dri/mach64/mach64_vb.c
src/mesa/drivers/dri/mach64/mach64_vb.h
src/mesa/drivers/dri/mach64/mach64_vbtmp.h
src/mesa/drivers/dri/mach64/server/mach64_dri.h
src/mesa/drivers/dri/mga/mga_texstate.c
src/mesa/drivers/dri/mga/mga_xmesa.c
src/mesa/drivers/dri/mga/mga_xmesa.h
src/mesa/drivers/dri/mga/mgacontext.h
src/mesa/drivers/dri/mga/mgadd.c
src/mesa/drivers/dri/mga/mgadd.h
src/mesa/drivers/dri/mga/mgaioctl.h
src/mesa/drivers/dri/mga/mgapixel.c
src/mesa/drivers/dri/mga/mgapixel.h
src/mesa/drivers/dri/mga/mgaregs.h
src/mesa/drivers/dri/mga/mgarender.c
src/mesa/drivers/dri/mga/mgaspan.h
src/mesa/drivers/dri/mga/mgastate.h
src/mesa/drivers/dri/mga/mgatex.c
src/mesa/drivers/dri/mga/mgatex.h
src/mesa/drivers/dri/mga/mgatexmem.c
src/mesa/drivers/dri/mga/mgatris.c
src/mesa/drivers/dri/mga/mgatris.h
src/mesa/drivers/dri/mga/mgavb.c
src/mesa/drivers/dri/mga/mgavb.h
src/mesa/drivers/dri/mga/server/mga.h
src/mesa/drivers/dri/mga/server/mga_bios.h
src/mesa/drivers/dri/mga/server/mga_dri.c
src/mesa/drivers/dri/mga/server/mga_dri.h
src/mesa/drivers/dri/mga/server/mga_macros.h
src/mesa/drivers/dri/mga/server/mga_reg.h
src/mesa/drivers/dri/r128/r128_context.c
src/mesa/drivers/dri/r128/r128_context.h
src/mesa/drivers/dri/r128/r128_dd.c
src/mesa/drivers/dri/r128/r128_dd.h
src/mesa/drivers/dri/r128/r128_ioctl.c
src/mesa/drivers/dri/r128/r128_ioctl.h
src/mesa/drivers/dri/r128/r128_lock.c
src/mesa/drivers/dri/r128/r128_lock.h
src/mesa/drivers/dri/r128/r128_screen.c
src/mesa/drivers/dri/r128/r128_screen.h
src/mesa/drivers/dri/r128/r128_span.c
src/mesa/drivers/dri/r128/r128_span.h
src/mesa/drivers/dri/r128/r128_state.c
src/mesa/drivers/dri/r128/r128_state.h
src/mesa/drivers/dri/r128/r128_tex.c
src/mesa/drivers/dri/r128/r128_tex.h
src/mesa/drivers/dri/r128/r128_texmem.c
src/mesa/drivers/dri/r128/r128_texobj.h
src/mesa/drivers/dri/r128/r128_texstate.c
src/mesa/drivers/dri/r128/r128_tris.c
src/mesa/drivers/dri/r128/r128_tris.h
src/mesa/drivers/dri/r128/server/r128.h
src/mesa/drivers/dri/r128/server/r128_dri.c
src/mesa/drivers/dri/r128/server/r128_dri.h
src/mesa/drivers/dri/r128/server/r128_macros.h
src/mesa/drivers/dri/r128/server/r128_reg.h
src/mesa/drivers/dri/r128/server/r128_version.h
src/mesa/drivers/dri/radeon/radeon_compat.c
src/mesa/drivers/dri/radeon/radeon_context.c
src/mesa/drivers/dri/radeon/radeon_ioctl.c
src/mesa/drivers/dri/radeon/radeon_ioctl.h
src/mesa/drivers/dri/radeon/radeon_lighting.c
src/mesa/drivers/dri/radeon/radeon_maos.h
src/mesa/drivers/dri/radeon/radeon_maos_arrays.c
src/mesa/drivers/dri/radeon/radeon_maos_verts.c
src/mesa/drivers/dri/radeon/radeon_sanity.c
src/mesa/drivers/dri/radeon/radeon_screen.c
src/mesa/drivers/dri/radeon/radeon_screen.h
src/mesa/drivers/dri/radeon/radeon_state.c
src/mesa/drivers/dri/radeon/radeon_state.h
src/mesa/drivers/dri/radeon/radeon_state_init.c
src/mesa/drivers/dri/radeon/radeon_swtcl.c
src/mesa/drivers/dri/radeon/radeon_swtcl.h
src/mesa/drivers/dri/radeon/radeon_tcl.c
src/mesa/drivers/dri/radeon/radeon_tcl.h
src/mesa/drivers/dri/radeon/radeon_tex.c
src/mesa/drivers/dri/radeon/radeon_tex.h
src/mesa/drivers/dri/radeon/radeon_texmem.c
src/mesa/drivers/dri/radeon/radeon_texstate.c
src/mesa/drivers/dri/radeon/server/radeon.h
src/mesa/drivers/dri/radeon/server/radeon_dri.h
src/mesa/drivers/dri/radeon/server/radeon_macros.h
src/mesa/drivers/dri/radeon/server/radeon_reg.h
src/mesa/drivers/dri/savage/savagetris.c
src/mesa/drivers/dri/savage/savagetris.h
src/mesa/drivers/dri/sis/server/sis_common.h
src/mesa/drivers/dri/sis/server/sis_dri.h
src/mesa/drivers/dri/sis/sis_alloc.c
src/mesa/drivers/dri/sis/sis_alloc.h
src/mesa/drivers/dri/sis/sis_clear.c
src/mesa/drivers/dri/sis/sis_context.c
src/mesa/drivers/dri/sis/sis_context.h
src/mesa/drivers/dri/sis/sis_dd.c
src/mesa/drivers/dri/sis/sis_dd.h
src/mesa/drivers/dri/sis/sis_fog.c
src/mesa/drivers/dri/sis/sis_lock.c
src/mesa/drivers/dri/sis/sis_lock.h
src/mesa/drivers/dri/sis/sis_reg.h
src/mesa/drivers/dri/sis/sis_screen.c
src/mesa/drivers/dri/sis/sis_screen.h
src/mesa/drivers/dri/sis/sis_span.c
src/mesa/drivers/dri/sis/sis_span.h
src/mesa/drivers/dri/sis/sis_state.c
src/mesa/drivers/dri/sis/sis_state.h
src/mesa/drivers/dri/sis/sis_stencil.c
src/mesa/drivers/dri/sis/sis_stencil.h
src/mesa/drivers/dri/sis/sis_tex.c
src/mesa/drivers/dri/sis/sis_tex.h
src/mesa/drivers/dri/sis/sis_texstate.c
src/mesa/drivers/dri/sis/sis_tris.h
src/mesa/drivers/dri/tdfx/X86/fx_3dnow_fastpath.S
src/mesa/drivers/dri/tdfx/X86/fx_3dnow_fasttmp.h
src/mesa/drivers/dri/tdfx/dri_glide.h
src/mesa/drivers/dri/tdfx/server/tdfx_dri.h
src/mesa/drivers/dri/tdfx/tdfx_context.h
src/mesa/drivers/dri/tdfx/tdfx_dd.h
src/mesa/drivers/dri/tdfx/tdfx_glide.h
src/mesa/drivers/dri/tdfx/tdfx_lock.c
src/mesa/drivers/dri/tdfx/tdfx_lock.h
src/mesa/drivers/dri/tdfx/tdfx_pixels.c
src/mesa/drivers/dri/tdfx/tdfx_pixels.h
src/mesa/drivers/dri/tdfx/tdfx_render.c
src/mesa/drivers/dri/tdfx/tdfx_render.h
src/mesa/drivers/dri/tdfx/tdfx_screen.c
src/mesa/drivers/dri/tdfx/tdfx_screen.h
src/mesa/drivers/dri/tdfx/tdfx_span.c
src/mesa/drivers/dri/tdfx/tdfx_span.h
src/mesa/drivers/dri/tdfx/tdfx_state.c
src/mesa/drivers/dri/tdfx/tdfx_state.h
src/mesa/drivers/dri/tdfx/tdfx_tex.c
src/mesa/drivers/dri/tdfx/tdfx_tex.h
src/mesa/drivers/dri/tdfx/tdfx_texman.c
src/mesa/drivers/dri/tdfx/tdfx_texman.h
src/mesa/drivers/dri/tdfx/tdfx_texstate.c
src/mesa/drivers/dri/tdfx/tdfx_texstate.h
src/mesa/drivers/dri/tdfx/tdfx_tris.c
src/mesa/drivers/dri/tdfx/tdfx_tris.h
src/mesa/drivers/dri/tdfx/tdfx_vb.c
src/mesa/drivers/dri/tdfx/tdfx_vb.h
src/mesa/drivers/dri/unichrome/server/via_dri.c
src/mesa/drivers/dri/unichrome/server/via_driver.h
src/mesa/drivers/dri/unichrome/server/via_priv.h
src/mesa/drivers/ggi/default/genkgi.h
src/mesa/drivers/ggi/default/genkgi_mode.c
src/mesa/drivers/ggi/default/genkgi_visual.c
src/mesa/drivers/ggi/include/ggi/mesa/debug.h
src/mesa/drivers/svga/svgamesa.c
src/mesa/drivers/svga/svgamesa15.c
src/mesa/drivers/svga/svgamesa15.h
src/mesa/drivers/svga/svgamesa16.c
src/mesa/drivers/svga/svgamesa16.h
src/mesa/drivers/svga/svgamesa24.c
src/mesa/drivers/svga/svgamesa24.h
src/mesa/drivers/svga/svgamesa32.c
src/mesa/drivers/svga/svgamesa32.h
src/mesa/drivers/svga/svgamesa8.c
src/mesa/drivers/svga/svgamesa8.h
src/mesa/drivers/svga/svgapix.h
src/mesa/drivers/windows/gdi/wgl.c
src/mesa/drivers/windows/gldirect/dx7/gld_vb_mesa_render_dx7.c
src/mesa/drivers/windows/gldirect/dx8/gld_vb_mesa_render_dx8.c
src/mesa/drivers/windows/gldirect/dx9/gld_vb_mesa_render_dx9.c
src/mesa/drivers/windows/gldirect/gld_debug_clip.c
src/mesa/drivers/windows/gldirect/gld_debug_norm.c
src/mesa/drivers/windows/gldirect/gld_debug_xform.c
src/mesa/drivers/windows/gldirect/mesasw/colors.h
src/mesa/glapi/mesadef.py
src/mesa/sparc/norm.S
src/mesa/sparc/sparc.h
src/mesa/sparc/xform.S
src/mesa/state_tracker/st_atom.c
src/mesa/state_tracker/st_atom.h
src/mesa/state_tracker/st_atom_framebuffer.c
src/mesa/state_tracker/st_atom_pixeltransfer.c
src/mesa/state_tracker/st_atom_shader.c
src/mesa/state_tracker/st_atom_texture.c
src/mesa/state_tracker/st_cb_accum.c
src/mesa/state_tracker/st_cb_bitmap.c
src/mesa/state_tracker/st_cb_drawpixels.c
src/mesa/state_tracker/st_cb_fbo.c
src/mesa/state_tracker/st_cb_fbo.h
src/mesa/state_tracker/st_cb_feedback.c
src/mesa/state_tracker/st_cb_program.c
src/mesa/state_tracker/st_cb_readpixels.c
src/mesa/state_tracker/st_cb_texture.c
src/mesa/state_tracker/st_context.h
src/mesa/state_tracker/st_gen_mipmap.c
src/mesa/state_tracker/st_texture.c
src/mesa/state_tracker/st_texture.h
src/mesa/x86-64/x86-64.c
src/mesa/x86-64/x86-64.h
src/mesa/x86-64/xform4.S
src/mesa/x86/3dnow.c
src/mesa/x86/3dnow.h
src/mesa/x86/3dnow_normal.S
src/mesa/x86/3dnow_xform1.S
src/mesa/x86/3dnow_xform2.S
src/mesa/x86/3dnow_xform3.S
src/mesa/x86/3dnow_xform4.S
src/mesa/x86/clip_args.h
src/mesa/x86/common_x86_asm.h
src/mesa/x86/common_x86_features.h
src/mesa/x86/common_x86_macros.h
src/mesa/x86/norm_args.h
src/mesa/x86/sse.h
src/mesa/x86/sse_normal.S
src/mesa/x86/sse_xform1.S
src/mesa/x86/sse_xform2.S
src/mesa/x86/sse_xform3.S
src/mesa/x86/sse_xform4.S
src/mesa/x86/x86.c
src/mesa/x86/x86.h
src/mesa/x86/x86_cliptest.S
src/mesa/x86/x86_xform2.S
src/mesa/x86/x86_xform3.S
src/mesa/x86/x86_xform4.S
src/mesa/x86/xform_args.h

diff --git a/bin/raw2png.py b/bin/raw2png.py
new file mode 100755 (executable)
index 0000000..ce18079
--- /dev/null
@@ -0,0 +1,339 @@
+#!/usr/bin/env python
+##########################################################################
+# 
+# Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
+# All Rights Reserved.
+# 
+# Permission is hereby granted, free of charge, to any person obtaining a
+# copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sub license, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject to
+# the following conditions:
+# 
+# The above copyright notice and this permission notice (including the
+# next paragraph) shall be included in all copies or substantial portions
+# of the Software.
+# 
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+# IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
+# ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+# 
+##########################################################################
+
+
+import os.path
+import sys
+import struct
+import Image # http://www.pythonware.com/products/pil/
+
+PIPE_FORMAT_LAYOUT_RGBAZS   = 0
+PIPE_FORMAT_LAYOUT_YCBCR    = 1
+PIPE_FORMAT_LAYOUT_DXT      = 2
+
+PIPE_FORMAT_COMP_R    = 0
+PIPE_FORMAT_COMP_G    = 1
+PIPE_FORMAT_COMP_B    = 2
+PIPE_FORMAT_COMP_A    = 3
+PIPE_FORMAT_COMP_0    = 4
+PIPE_FORMAT_COMP_1    = 5
+PIPE_FORMAT_COMP_Z    = 6
+PIPE_FORMAT_COMP_S    = 7
+
+PIPE_FORMAT_TYPE_UNKNOWN = 0
+PIPE_FORMAT_TYPE_FLOAT   = 1
+PIPE_FORMAT_TYPE_UNORM   = 2
+PIPE_FORMAT_TYPE_SNORM   = 3
+PIPE_FORMAT_TYPE_USCALED = 4
+PIPE_FORMAT_TYPE_SSCALED = 5
+PIPE_FORMAT_TYPE_SRGB    = 6
+
+def _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, EXP8, TYPE ):
+   return ((PIPE_FORMAT_LAYOUT_RGBAZS << 0) |\
+   ((SWZ) << 2) |\
+   ((SIZEX) << 14) |\
+   ((SIZEY) << 17) |\
+   ((SIZEZ) << 20) |\
+   ((SIZEW) << 23) |\
+   ((EXP8) << 26) |\
+   ((TYPE) << 28) )
+
+def _PIPE_FORMAT_SWZ( SWZX, SWZY, SWZZ, SWZW ):
+       return (((SWZX) << 0) | ((SWZY) << 3) | ((SWZZ) << 6) | ((SWZW) << 9))
+
+def _PIPE_FORMAT_RGBAZS_1( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
+       return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 0, TYPE )
+
+def _PIPE_FORMAT_RGBAZS_8( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
+       return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 1, TYPE )
+
+def _PIPE_FORMAT_RGBAZS_64( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
+       return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 2, TYPE )
+
+_PIPE_FORMAT_R001 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_1 )
+_PIPE_FORMAT_RG01 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_1 )
+_PIPE_FORMAT_RGB1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_1 )
+_PIPE_FORMAT_RGBA = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_A )
+_PIPE_FORMAT_ARGB = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_A, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B )
+_PIPE_FORMAT_BGRA = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_A )
+_PIPE_FORMAT_1RGB = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_1, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B )
+_PIPE_FORMAT_BGR1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_1 )
+_PIPE_FORMAT_0000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
+_PIPE_FORMAT_000R = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_R )
+_PIPE_FORMAT_RRR1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_1 )
+_PIPE_FORMAT_RRRR = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R )
+_PIPE_FORMAT_RRRG = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G )
+_PIPE_FORMAT_Z000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
+_PIPE_FORMAT_0Z00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
+_PIPE_FORMAT_SZ00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
+_PIPE_FORMAT_ZS00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
+_PIPE_FORMAT_S000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
+
+def _PIPE_FORMAT_YCBCR( REV ):
+   return ((PIPE_FORMAT_LAYOUT_YCBCR << 0) |\
+   ((REV) << 2) )
+
+def _PIPE_FORMAT_DXT( LEVEL, RSIZE, GSIZE, BSIZE, ASIZE ):
+   return ((PIPE_FORMAT_LAYOUT_DXT << 0) | \
+    ((LEVEL) << 2) | \
+    ((RSIZE) << 5) | \
+    ((GSIZE) << 8) | \
+    ((BSIZE) << 11) | \
+    ((ASIZE) << 14) )
+
+PIPE_FORMAT_NONE                  = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_0000, 0, 0, 0, 0, PIPE_FORMAT_TYPE_UNKNOWN )
+PIPE_FORMAT_A8R8G8B8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_ARGB, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_X8R8G8B8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_1RGB, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_B8G8R8A8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGRA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_B8G8R8X8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGR1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_A1R5G5B5_UNORM        = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_ARGB, 1, 5, 5, 5, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_A4R4G4B4_UNORM        = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_ARGB, 4, 4, 4, 4, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R5G6B5_UNORM          = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_RGB1, 5, 6, 5, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_L8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_A8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_000R, 0, 0, 0, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_I8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRR, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_A8L8_UNORM            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRG, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_YCBCR                 = _PIPE_FORMAT_YCBCR( 0 )
+PIPE_FORMAT_YCBCR_REV             = _PIPE_FORMAT_YCBCR( 1 )
+PIPE_FORMAT_Z16_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 2, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_Z32_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 4, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_Z32_FLOAT             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_S8Z24_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_SZ00, 1, 3, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_Z24S8_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_ZS00, 3, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_X8Z24_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_0Z00, 1, 3, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_Z24X8_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 3, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_S8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_S000, 1, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R64_FLOAT             = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R64G64_FLOAT          = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R64G64B64_FLOAT       = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R64G64B64A64_FLOAT    = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R32_FLOAT             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R32G32_FLOAT          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R32G32B32_FLOAT       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R32G32B32A32_FLOAT    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_FLOAT )
+PIPE_FORMAT_R32_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R32G32_UNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R32G32B32_UNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R32G32B32A32_UNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R32_USCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R32G32_USCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R32G32B32_USCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R32G32B32A32_USCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R32_SNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R32G32_SNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R32G32B32_SNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R32G32B32A32_SNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R32_SSCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R32G32_SSCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R32G32B32_SSCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R32G32B32A32_SSCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R16_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R16G16_UNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R16G16B16_UNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R16G16B16A16_UNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R16_USCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R16G16_USCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R16G16B16_USCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R16G16B16A16_USCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R16_SNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R16G16_SNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R16G16B16_SNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R16G16B16A16_SNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R16_SSCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R16G16_SSCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R16G16B16_SSCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R16G16B16A16_SSCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R8G8_UNORM            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R8G8B8_UNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R8G8B8A8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R8G8B8X8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
+PIPE_FORMAT_R8_USCALED            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R8G8_USCALED          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R8G8B8_USCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R8G8B8A8_USCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R8G8B8X8_USCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_USCALED )
+PIPE_FORMAT_R8_SNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R8G8_SNORM            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R8G8B8_SNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R8G8B8A8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R8G8B8X8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
+PIPE_FORMAT_R8_SSCALED            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R8G8_SSCALED          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R8G8B8_SSCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R8G8B8A8_SSCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_R8G8B8X8_SSCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SSCALED )
+PIPE_FORMAT_L8_SRGB               = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SRGB )
+PIPE_FORMAT_A8_L8_SRGB            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRG, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
+PIPE_FORMAT_R8G8B8_SRGB           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SRGB )
+PIPE_FORMAT_R8G8B8A8_SRGB         = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
+PIPE_FORMAT_R8G8B8X8_SRGB         = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
+PIPE_FORMAT_DXT1_RGB              = _PIPE_FORMAT_DXT( 1, 8, 8, 8, 0 )
+PIPE_FORMAT_DXT1_RGBA             = _PIPE_FORMAT_DXT( 1, 8, 8, 8, 8 )
+PIPE_FORMAT_DXT3_RGBA             = _PIPE_FORMAT_DXT( 3, 8, 8, 8, 8 )
+PIPE_FORMAT_DXT5_RGBA             = _PIPE_FORMAT_DXT( 5, 8, 8, 8, 8 )
+
+formats = {
+       PIPE_FORMAT_NONE: "PIPE_FORMAT_NONE",
+       PIPE_FORMAT_A8R8G8B8_UNORM: "PIPE_FORMAT_A8R8G8B8_UNORM",
+       PIPE_FORMAT_X8R8G8B8_UNORM: "PIPE_FORMAT_X8R8G8B8_UNORM",
+       PIPE_FORMAT_B8G8R8A8_UNORM: "PIPE_FORMAT_B8G8R8A8_UNORM",
+       PIPE_FORMAT_B8G8R8X8_UNORM: "PIPE_FORMAT_B8G8R8X8_UNORM",
+       PIPE_FORMAT_A1R5G5B5_UNORM: "PIPE_FORMAT_A1R5G5B5_UNORM",
+       PIPE_FORMAT_A4R4G4B4_UNORM: "PIPE_FORMAT_A4R4G4B4_UNORM",
+       PIPE_FORMAT_R5G6B5_UNORM: "PIPE_FORMAT_R5G6B5_UNORM",
+       PIPE_FORMAT_L8_UNORM: "PIPE_FORMAT_L8_UNORM",
+       PIPE_FORMAT_A8_UNORM: "PIPE_FORMAT_A8_UNORM",
+       PIPE_FORMAT_I8_UNORM: "PIPE_FORMAT_I8_UNORM",
+       PIPE_FORMAT_A8L8_UNORM: "PIPE_FORMAT_A8L8_UNORM",
+       PIPE_FORMAT_YCBCR: "PIPE_FORMAT_YCBCR",
+       PIPE_FORMAT_YCBCR_REV: "PIPE_FORMAT_YCBCR_REV",
+       PIPE_FORMAT_Z16_UNORM: "PIPE_FORMAT_Z16_UNORM",
+       PIPE_FORMAT_Z32_UNORM: "PIPE_FORMAT_Z32_UNORM",
+       PIPE_FORMAT_Z32_FLOAT: "PIPE_FORMAT_Z32_FLOAT",
+       PIPE_FORMAT_S8Z24_UNORM: "PIPE_FORMAT_S8Z24_UNORM",
+       PIPE_FORMAT_Z24S8_UNORM: "PIPE_FORMAT_Z24S8_UNORM",
+       PIPE_FORMAT_X8Z24_UNORM: "PIPE_FORMAT_X8Z24_UNORM",
+       PIPE_FORMAT_Z24X8_UNORM: "PIPE_FORMAT_Z24X8_UNORM",
+       PIPE_FORMAT_S8_UNORM: "PIPE_FORMAT_S8_UNORM",
+       PIPE_FORMAT_R64_FLOAT: "PIPE_FORMAT_R64_FLOAT",
+       PIPE_FORMAT_R64G64_FLOAT: "PIPE_FORMAT_R64G64_FLOAT",
+       PIPE_FORMAT_R64G64B64_FLOAT: "PIPE_FORMAT_R64G64B64_FLOAT",
+       PIPE_FORMAT_R64G64B64A64_FLOAT: "PIPE_FORMAT_R64G64B64A64_FLOAT",
+       PIPE_FORMAT_R32_FLOAT: "PIPE_FORMAT_R32_FLOAT",
+       PIPE_FORMAT_R32G32_FLOAT: "PIPE_FORMAT_R32G32_FLOAT",
+       PIPE_FORMAT_R32G32B32_FLOAT: "PIPE_FORMAT_R32G32B32_FLOAT",
+       PIPE_FORMAT_R32G32B32A32_FLOAT: "PIPE_FORMAT_R32G32B32A32_FLOAT",
+       PIPE_FORMAT_R32_UNORM: "PIPE_FORMAT_R32_UNORM",
+       PIPE_FORMAT_R32G32_UNORM: "PIPE_FORMAT_R32G32_UNORM",
+       PIPE_FORMAT_R32G32B32_UNORM: "PIPE_FORMAT_R32G32B32_UNORM",
+       PIPE_FORMAT_R32G32B32A32_UNORM: "PIPE_FORMAT_R32G32B32A32_UNORM",
+       PIPE_FORMAT_R32_USCALED: "PIPE_FORMAT_R32_USCALED",
+       PIPE_FORMAT_R32G32_USCALED: "PIPE_FORMAT_R32G32_USCALED",
+       PIPE_FORMAT_R32G32B32_USCALED: "PIPE_FORMAT_R32G32B32_USCALED",
+       PIPE_FORMAT_R32G32B32A32_USCALED: "PIPE_FORMAT_R32G32B32A32_USCALED",
+       PIPE_FORMAT_R32_SNORM: "PIPE_FORMAT_R32_SNORM",
+       PIPE_FORMAT_R32G32_SNORM: "PIPE_FORMAT_R32G32_SNORM",
+       PIPE_FORMAT_R32G32B32_SNORM: "PIPE_FORMAT_R32G32B32_SNORM",
+       PIPE_FORMAT_R32G32B32A32_SNORM: "PIPE_FORMAT_R32G32B32A32_SNORM",
+       PIPE_FORMAT_R32_SSCALED: "PIPE_FORMAT_R32_SSCALED",
+       PIPE_FORMAT_R32G32_SSCALED: "PIPE_FORMAT_R32G32_SSCALED",
+       PIPE_FORMAT_R32G32B32_SSCALED: "PIPE_FORMAT_R32G32B32_SSCALED",
+       PIPE_FORMAT_R32G32B32A32_SSCALED: "PIPE_FORMAT_R32G32B32A32_SSCALED",
+       PIPE_FORMAT_R16_UNORM: "PIPE_FORMAT_R16_UNORM",
+       PIPE_FORMAT_R16G16_UNORM: "PIPE_FORMAT_R16G16_UNORM",
+       PIPE_FORMAT_R16G16B16_UNORM: "PIPE_FORMAT_R16G16B16_UNORM",
+       PIPE_FORMAT_R16G16B16A16_UNORM: "PIPE_FORMAT_R16G16B16A16_UNORM",
+       PIPE_FORMAT_R16_USCALED: "PIPE_FORMAT_R16_USCALED",
+       PIPE_FORMAT_R16G16_USCALED: "PIPE_FORMAT_R16G16_USCALED",
+       PIPE_FORMAT_R16G16B16_USCALED: "PIPE_FORMAT_R16G16B16_USCALED",
+       PIPE_FORMAT_R16G16B16A16_USCALED: "PIPE_FORMAT_R16G16B16A16_USCALED",
+       PIPE_FORMAT_R16_SNORM: "PIPE_FORMAT_R16_SNORM",
+       PIPE_FORMAT_R16G16_SNORM: "PIPE_FORMAT_R16G16_SNORM",
+       PIPE_FORMAT_R16G16B16_SNORM: "PIPE_FORMAT_R16G16B16_SNORM",
+       PIPE_FORMAT_R16G16B16A16_SNORM: "PIPE_FORMAT_R16G16B16A16_SNORM",
+       PIPE_FORMAT_R16_SSCALED: "PIPE_FORMAT_R16_SSCALED",
+       PIPE_FORMAT_R16G16_SSCALED: "PIPE_FORMAT_R16G16_SSCALED",
+       PIPE_FORMAT_R16G16B16_SSCALED: "PIPE_FORMAT_R16G16B16_SSCALED",
+       PIPE_FORMAT_R16G16B16A16_SSCALED: "PIPE_FORMAT_R16G16B16A16_SSCALED",
+       PIPE_FORMAT_R8_UNORM: "PIPE_FORMAT_R8_UNORM",
+       PIPE_FORMAT_R8G8_UNORM: "PIPE_FORMAT_R8G8_UNORM",
+       PIPE_FORMAT_R8G8B8_UNORM: "PIPE_FORMAT_R8G8B8_UNORM",
+       PIPE_FORMAT_R8G8B8A8_UNORM: "PIPE_FORMAT_R8G8B8A8_UNORM",
+       PIPE_FORMAT_R8G8B8X8_UNORM: "PIPE_FORMAT_R8G8B8X8_UNORM",
+       PIPE_FORMAT_R8_USCALED: "PIPE_FORMAT_R8_USCALED",
+       PIPE_FORMAT_R8G8_USCALED: "PIPE_FORMAT_R8G8_USCALED",
+       PIPE_FORMAT_R8G8B8_USCALED: "PIPE_FORMAT_R8G8B8_USCALED",
+       PIPE_FORMAT_R8G8B8A8_USCALED: "PIPE_FORMAT_R8G8B8A8_USCALED",
+       PIPE_FORMAT_R8G8B8X8_USCALED: "PIPE_FORMAT_R8G8B8X8_USCALED",
+       PIPE_FORMAT_R8_SNORM: "PIPE_FORMAT_R8_SNORM",
+       PIPE_FORMAT_R8G8_SNORM: "PIPE_FORMAT_R8G8_SNORM",
+       PIPE_FORMAT_R8G8B8_SNORM: "PIPE_FORMAT_R8G8B8_SNORM",
+       PIPE_FORMAT_R8G8B8A8_SNORM: "PIPE_FORMAT_R8G8B8A8_SNORM",
+       PIPE_FORMAT_R8G8B8X8_SNORM: "PIPE_FORMAT_R8G8B8X8_SNORM",
+       PIPE_FORMAT_R8_SSCALED: "PIPE_FORMAT_R8_SSCALED",
+       PIPE_FORMAT_R8G8_SSCALED: "PIPE_FORMAT_R8G8_SSCALED",
+       PIPE_FORMAT_R8G8B8_SSCALED: "PIPE_FORMAT_R8G8B8_SSCALED",
+       PIPE_FORMAT_R8G8B8A8_SSCALED: "PIPE_FORMAT_R8G8B8A8_SSCALED",
+       PIPE_FORMAT_R8G8B8X8_SSCALED: "PIPE_FORMAT_R8G8B8X8_SSCALED",
+       PIPE_FORMAT_L8_SRGB: "PIPE_FORMAT_L8_SRGB",
+       PIPE_FORMAT_A8_L8_SRGB: "PIPE_FORMAT_A8_L8_SRGB",
+       PIPE_FORMAT_R8G8B8_SRGB: "PIPE_FORMAT_R8G8B8_SRGB",
+       PIPE_FORMAT_R8G8B8A8_SRGB: "PIPE_FORMAT_R8G8B8A8_SRGB",
+       PIPE_FORMAT_R8G8B8X8_SRGB: "PIPE_FORMAT_R8G8B8X8_SRGB",
+       PIPE_FORMAT_DXT1_RGB: "PIPE_FORMAT_DXT1_RGB",
+       PIPE_FORMAT_DXT1_RGBA: "PIPE_FORMAT_DXT1_RGBA",
+       PIPE_FORMAT_DXT3_RGBA: "PIPE_FORMAT_DXT3_RGBA",
+       PIPE_FORMAT_DXT5_RGBA: "PIPE_FORMAT_DXT5_RGBA",
+}
+
+
+def read_header(infile):
+       header_fmt = "IIII"
+       header = infile.read(struct.calcsize(header_fmt))
+       return struct.unpack_from(header_fmt, header)
+
+def read_pixel(infile, fmt, cpp):
+       assert cpp == 4
+       r, g, b, a = map(ord, infile.read(4))
+       return r, g, b, a
+
+
+def process(infilename, outfilename):
+       infile = open(infilename, "rb")
+       format, cpp, width, height = read_header(infile)
+       sys.stderr.write("format = %s, cpp = %u, width = %u, height = %u\n" % (formats[format], cpp, width, height))
+       outimage = Image.new(
+    mode='RGB',
+    size=(width, height),
+    color=(0,0,0))
+       outpixels = outimage.load()
+       for y in range(height):
+               for x in range(width):
+                       r, g, b, a = read_pixel(infile, format, cpp)
+                       outpixels[x, y] = r, g, b
+       outimage.save(outfilename, "PNG")
+
+
+def main():
+       if sys.platform == 'win32':
+               # wildcard expansion
+               from glob import glob
+               args = []
+               for arg in sys.argv[1:]:
+                       args.extend(glob(arg))
+       else:
+               args = sys.argv[1:]
+       for infilename in args:
+               root, ext = os.path.splitext(infilename)
+               outfilename = root + ".png"
+               process(infilename, outfilename)
+
+
+if __name__ == '__main__':
+       main()
diff --git a/bin/win32kprof.py b/bin/win32kprof.py
new file mode 100755 (executable)
index 0000000..836b17e
--- /dev/null
@@ -0,0 +1,269 @@
+#!/usr/bin/env python
+
+import sys
+import optparse
+import re
+import struct
+
+__version__ = '0.1'
+
+
+verbose = False
+
+
+class ParseError(Exception):
+       pass
+
+
+class MsvcDemangler:
+               # http://www.kegel.com/mangle.html
+
+       def __init__(self, symbol):
+               self._symbol = symbol
+               self._pos = 0
+
+       def lookahead(self):
+               return self._symbol[self._pos]
+
+       def consume(self):
+               ret = self.lookahead()
+               self._pos += 1
+               return ret
+       
+       def match(self, c):
+               if self.lookahead() != c:
+                       raise ParseError
+               self.consume()
+
+       def parse(self):
+               self.match('?')
+               name = self.parse_name()
+               qualifications = self.parse_qualifications()
+               return '::'.join(qualifications + [name])
+
+       def parse_name(self):
+               if self.lookahead() == '?':
+                       return self.consume() + self.consume()
+               else:
+                       name = self.parse_id()
+                       self.match('@')
+                       return name
+
+       def parse_qualifications(self):
+               qualifications = []
+               while self.lookahead() != '@':
+                       name = self.parse_id()
+                       qualifications.append(name)
+                       self.match('@')
+               return qualifications
+
+       def parse_id(self):
+               s = ''
+               while True:
+                       c = self.lookahead()
+                       if c.isalnum() or c in '_':
+                               s += c
+                               self.consume()
+                       else:
+                               break
+               return s
+
+
+def demangle(name):
+       if name.startswith('_'):
+               name = name[1:]
+               idx = name.rfind('@')
+               if idx != -1 and name[idx+1:].isdigit():
+                       name = name[:idx]
+               return name
+       if name.startswith('?'):
+               demangler = MsvcDemangler(name)
+               return demangler.parse()
+
+               return name
+       return name
+
+
+class Profile:
+
+       def __init__(self):
+               self.symbols = []
+               self.symbol_cache = {}
+               self.base_addr = None
+               self.functions = {}
+               self.last_stamp = 0
+               self.stamp_base = 0
+       
+       def unwrap_stamp(self, stamp):
+               if stamp < self.last_stamp:
+                       self.stamp_base += 1 << 32
+               self.last_stamp = stamp
+               return self.stamp_base + stamp
+
+       def read_map(self, mapfile):
+               # See http://msdn.microsoft.com/en-us/library/k7xkk3e2.aspx
+               last_addr = 0
+               last_name = 0
+               for line in file(mapfile, "rt"):
+                       fields = line.split()
+                       try:
+                               section_offset, name, addr, type, lib_object = fields
+                       except ValueError:
+                               continue
+                       if type != 'f':
+                               continue
+                       addr = int(addr, 16)
+                       name = demangle(name)
+                       if last_addr == addr:
+                               # TODO: handle collapsed functions
+                               #assert last_name == name
+                               continue
+                       self.symbols.append((addr, name))
+                       last_addr = addr
+                       last_name = name
+
+               # sort symbols
+               self.symbols.sort(key = lambda (addr, name): addr)
+
+       def lookup_addr(self, addr):
+               try:
+                       return self.symbol_cache[addr]
+               except KeyError:
+                       pass
+
+               tolerance = 4196
+               s, e = 0, len(self.symbols)
+               while s != e:
+                       i = (s + e)//2
+                       start_addr, name = self.symbols[i]
+                       try:
+                               end_addr, next_name = self.symbols[i + 1]
+                       except IndexError:
+                               end_addr = start_addr + tolerance
+                       if addr < start_addr:
+                               e = i
+                               continue
+                       if addr == end_addr:
+                               return next_name
+                       if addr > end_addr:
+                               s = i
+                               continue
+                       return name
+               return "0x%08x" % addr
+
+       def lookup_symbol(self, name):
+               for symbol_addr, symbol_name in self.symbols:
+                       if name == symbol_name:
+                               return symbol_addr
+               return 0
+
+       def read_data(self, data):
+               # TODO: compute these automatically
+               caller_overhead = 672 - 2*144 # __debug_profile_reference2 - 2*__debug_profile_reference1
+               callee_overhead = 144 # __debug_profile_reference1
+               callee_overhead -= 48 # tolerance
+               caller_overhead = callee_overhead
+
+               fp = file(data, "rb")
+               entry_format = "II"
+               entry_size = struct.calcsize(entry_format)
+               stack = []
+               last_stamp = 0
+               delta = 0
+               while True:
+                       entry = fp.read(entry_size)
+                       if len(entry) < entry_size:
+                               break
+                       addr_exit, stamp = struct.unpack(entry_format, entry)
+                       if addr_exit == 0 and stamp == 0:
+                               break
+                       addr = addr_exit & 0xfffffffe
+                       exit = addr_exit & 0x00000001
+
+                       if self.base_addr is None:
+                               ref_addr = self.lookup_symbol('__debug_profile_reference2')
+                               if ref_addr:
+                                       self.base_addr = addr - ref_addr
+                               else:
+                                       self.base_addr = 0
+                               #print hex(self.base_addr)
+                       rel_addr = addr - self.base_addr
+                       #print hex(addr - self.base_addr)
+
+                       name = self.lookup_addr(rel_addr)
+                       stamp = self.unwrap_stamp(stamp)
+
+                       delta += stamp - last_stamp
+
+                       if not exit:
+                               if verbose >= 2:
+                                       print "%10u >> 0x%08x" % (stamp, addr)
+                               if verbose:
+                                       print "%10u >> %s" % (stamp, name)
+                               delta -= caller_overhead
+                               stack.append((name, stamp, delta))
+                               delta = 0
+                       else:
+                               if verbose >= 2:
+                                       print "%10u << 0x%08x" % (stamp, addr)
+                               if len(stack):
+                                       self_time = delta - callee_overhead
+                                       entry_name, entry_stamp, delta = stack.pop()
+                                       if entry_name != name:
+                                               if verbose:
+                                                       print "%10u << %s" % (stamp, name)
+                                               #assert entry_name == name
+                                               break
+                                       total_time = stamp - entry_stamp
+                                       self.functions[entry_name] = self.functions.get(entry_name, 0) + self_time
+                                       if verbose:
+                                               print "%10u << %s %+u" % (stamp, name, self_time)
+                               else:
+                                       delta = 0
+
+                       last_stamp = stamp
+
+       def write_report(self):
+               total = sum(self.functions.values())
+               results = self.functions.items()
+               results.sort(key = lambda (name, time): -time)
+               for name, time in results:
+                       perc = float(time)/float(total)*100.0
+                       print "%6.03f %s" % (perc, name)
+
+
+def main():
+               parser = optparse.OptionParser(
+                       usage="\n\t%prog [options] [file] ...",
+                       version="%%prog %s" % __version__)
+               parser.add_option(
+                       '-m', '--map', metavar='FILE',
+                       type="string", dest="map",
+                       help="map file")
+               parser.add_option(
+                       '-b', '--base', metavar='FILE',
+                       type="string", dest="base",
+                       help="base addr")
+               parser.add_option(
+                       '-v', '--verbose',
+                       action="count",
+                       dest="verbose", default=0,
+                       help="verbose output")
+               (options, args) = parser.parse_args(sys.argv[1:])
+
+               global verbose
+               verbose = options.verbose
+
+               profile = Profile()
+               if options.base is not None:
+                       profile.base_addr = int(options.base, 16)
+               if options.map is not None:
+                       profile.read_map(options.map)
+               for arg in args:
+                       profile.read_data(arg)
+               profile.write_report()
+
+
+if __name__ == '__main__':
+       main()
+
index 6de181739bab0baf1c47566d43eef516cbdc98e0..d3c0261d71ea049e000a24ce536d3c7f44feb9a3 100644 (file)
--- a/common.py
+++ b/common.py
@@ -52,7 +52,8 @@ def AddOptions(opts):
                from SCons.Options.EnumOption import EnumOption
        except ImportError:
                from SCons.Variables.EnumVariable import EnumVariable as EnumOption
-       opts.Add(BoolOption('debug', 'build debug version', 'no'))
+       opts.Add(BoolOption('debug', 'debug build', 'no'))
+       opts.Add(BoolOption('profile', 'profile build', 'no'))
        #opts.Add(BoolOption('quiet', 'quiet command lines', 'no'))
        opts.Add(EnumOption('machine', 'use machine-specific assembly code', default_machine,
                                                                                         allowed_values=('generic', 'x86', 'x86_64')))
@@ -125,6 +126,8 @@ def make_build_dir(env):
                build_subdir += '-' + env['machine']
        if env['debug']:
                build_subdir += "-debug"
+       if env['profile']:
+               build_subdir += "-profile"
        build_dir = os.path.join(build_topdir, build_subdir)
        # Place the .sconsign file on the builddir too, to avoid issues with different scons
        # versions building the same source file
@@ -154,6 +157,8 @@ def generate(env):
                cppdefines += ['DEBUG']
        else:
                cppdefines += ['NDEBUG']
+       if env['profile']:
+               cppdefines += ['PROFILE']
        if platform == 'windows':
                cppdefines += [
                        'WIN32', 
@@ -204,6 +209,8 @@ def generate(env):
                        cflags += ['-O0', '-g3']
                else:
                        cflags += ['-O3', '-g3']
+               if env['profile']:
+                       cflags += ['-pg']
                cflags += [
                        '-Wall', 
                        '-Wmissing-prototypes',
@@ -228,6 +235,11 @@ def generate(env):
                          '/Oi', # enable intrinsic functions
                          '/Os', # favor code space
                        ]
+               if env['profile']:
+                       cflags += [
+                               '/Gh', # enable _penter hook function
+                               '/GH', # enable _pexit hook function
+                       ]
                if platform == 'windows':
                        cflags += [
                                # TODO
@@ -245,12 +257,11 @@ def generate(env):
                                '/GX-', # disable C++ EH
                                '/GR-', # disable C++ RTTI
                                '/GF', # enable read-only string pooling
-                               '/GS', # enable security checks
                                '/G6', # optimize for PPro, P-II, P-III
                                '/Ze', # enable extensions
-                               #'/Gi-', # ???
+                               '/Gi-', # disable incremental compilation
                                '/QIfdiv-', # disable Pentium FDIV fix
-                               #'/hotpatch', # ???
+                               '/hotpatch', # prepares an image for hotpatching.
                                #'/Z7', #enable old-style debug info
                        ]
                # Put debugging information in a separate .pdb file for each object file as
index 4f7ab1e28cf0decd32dfe61a1a7fb6ed17c77988..112b730ecc24f3917f4ddc3e776bb020ae9b22df 100644 (file)
@@ -17,7 +17,6 @@ Status
 
 Version
 
-    $Id: MESA_packed_depth_stencil.spec,v 1.2 2003/09/19 14:58:21 brianp Exp $
 
 Number
 
index 391d39fa70a5951f8f61c1af592a0e89e774a06d..7694fdcc42546d58bdd3f5d50222ce342cbd6637 100644 (file)
@@ -18,7 +18,6 @@ Version
 
     Last Modified Date: July 20, 2003
     Author Revision: 1.0
-    $Date: 2004/03/25 01:42:41 $ $Revision: 1.4 $
 
 Number
 
index f79d29c405ac886cc2c41838670cf83491fbd004..533d017c9a91270febb18a201862c8d2b057dfab 100644 (file)
@@ -16,7 +16,6 @@ Status
 
 Version
 
-    $Id: MESA_resize_buffers.spec,v 1.3 2004/03/25 01:42:42 brianp Exp $
 
 Number
 
index dbd22b3c667ef5c038454bac7db6c2d2971a46a6..1f7d42ac91446e6fa3d1e8b62cff58756c7922db 100644 (file)
@@ -19,7 +19,6 @@ Version
 
     Last Modified Date: July 30, 2006
     Author Revision: 0.2
-    $Date: 2006/07/30 14:28:38 $ $Revision: 1.2 $
 
 Number
 
index 9422ff57295c89b50d7d2614adb54102c3e19373..b50d78e9e7bbd7118d0d7743dceb487d5b0488ad 100644 (file)
@@ -16,7 +16,6 @@ Status
 
 Version
 
-    $Id: MESA_sprite_point.spec,v 1.2 2003/09/19 14:58:21 brianp Exp $
 
 Number
 
index d3b77521151a8bc9c60eb82e07f2ff969629926e..9dee65b045d5cda51c61e9a5a49d0237da37e900 100644 (file)
@@ -20,7 +20,6 @@ Status
 
 Version
 
-    $Date: 2007/05/16$ $Revision: 0.4$
 
 Number
 
index f0a79c7df99c96339dcaa8767cefca509f49e0e2..dc4166e6b6e31f4e1a4a533718d0e4982b85ab7d 100644 (file)
@@ -17,7 +17,6 @@ Status
 
 Version
 
-    $Id: MESA_trace.spec,v 1.4 2004/03/25 01:42:42 brianp Exp $
 
 Number
 
index eb1d0d1f06827218602bbde3be00122c54a8038a..4d01f1814c1110efafb4575ee209b235742af22d 100644 (file)
@@ -16,7 +16,6 @@ Status
 
 Version
 
-    $Id: MESA_window_pos.spec,v 1.4 2004/03/25 01:42:42 brianp Exp $
 
 Number
 
index 5847730af07dc117271dd4b808b9b85041520b92..efd84e888cba808d75fc9392ddc93c0e14334052 100644 (file)
@@ -134,4 +134,3 @@ as of February, 1999.
 
 
 ----------------------------------------------------------------------
-$Id: README.BEOS,v 1.12 2004/10/13 00:35:55 phoudoin Exp $
index 5a13b7a49812d53724b800b3e5c73560ca291464..e90c76a083e8b703376c4f2a7b58f26ff5d868a2 100644 (file)
@@ -205,4 +205,3 @@ http://www.linuxgames.com/quake2/
 
 
 ----------------------------------------------------------------------
-$Id: README.QUAKE,v 1.3 1998/08/23 15:26:26 brianp Exp $
index 4d6e3c2f44b75b23e661949c3e64ffe7a412fc80..65324eb496d09a9b6510ba734e44f020ae6dd75a 100644 (file)
@@ -143,4 +143,3 @@ code).  Anyone want to help?
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.1,v 1.2 2000/04/07 17:08:06 brianp Exp $
index 7737c28e80fafa434591a62dce716a2b362716f0..ec7d4f8dc3975cb02bb5e6f7d670599d6c165fb8 100644 (file)
@@ -9,4 +9,3 @@ have been added.  For a list of bug fixes please read the VERSIONS file.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.2,v 1.2 2000/04/07 17:08:06 brianp Exp $
index 2ad5b9046a1a3bc8071533a0cd4b1818a6a6d9ab..d34efcc8673bd31384581f9acbe5048d219b6638 100644 (file)
@@ -29,4 +29,3 @@ GLU library.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.2.1,v 1.2 2000/07/21 16:32:33 brianp Exp $
index 362a74ee31d8f7ad5e8099535936cbecab61fa10..3850767bb1df47207ad63cd9cccdb3ecde805964 100644 (file)
@@ -268,4 +268,3 @@ image convolution.  This will (hopefully) be done for Mesa 3.5/3.6.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.3,v 1.8 2000/07/21 16:26:41 brianp Exp $
index 4aa607a37cc7b9ee38b8c6fd047bbb194ec1f643..657ccdaab641cae47be73fb7b67b4501866b0f99 100644 (file)
@@ -19,4 +19,3 @@ see the VERSIONS file.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.4,v 1.2 2002/03/23 02:37:17 brianp Exp $
index 18443507c28a304fb1687993481eef956d930386..73d75c64d234621b43cc7e16843c2d9962cb612c 100644 (file)
@@ -19,4 +19,3 @@ the Mesa 3.4 release.  For details, see the VERSIONS file.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.4.1,v 1.2 2001/05/23 14:45:01 brianp Exp $
index 894ed199ff7f4c15f170089289e3672e5c670c1b..9caea900d87f1320607eb6c677e0c2da9b6cb89f 100644 (file)
@@ -19,4 +19,3 @@ the Mesa 3.4.1 release.  For details, see the VERSIONS file.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.4.2,v 1.2 2001/05/23 14:45:01 brianp Exp $
index 52097a1cd6e4f3e3a7bb3bc8954d8f9fa6073576..b2aa1b852ead2331cae680f521e2aaa0d65608cd 100644 (file)
@@ -225,4 +225,3 @@ In the future I hope to implement support for 32-bit, floating point
 color channels.
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-3.5,v 1.14 2001/06/20 19:02:48 brianp Exp $
index e4249cfa1759583431ef805c207b9910d1fa2691..2f729db158f388643a62da4a7c252fcb187a6908 100644 (file)
@@ -160,4 +160,3 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 4.0.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-4.0,v 3.2 2001/10/17 14:59:21 brianp Exp $
index b4d7efca8121ee3cc6193240de40db0f776fccc1..e84df6bf89b10cf46f7fe721f0aa5ade631e8884 100644 (file)
@@ -19,4 +19,3 @@ Mesa 4.0.1 only contains bug fixes since version 4.0.
 See the docs/VERSIONS file for the list of bug fixes.
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-4.0.1,v 1.2 2001/12/18 14:08:23 brianp Exp $
index 1b7eaaa8fed32d74ae9ab6718907a6d0c31860fc..b476956ba2d0c35c879068b25bb5829b92852de5 100644 (file)
@@ -47,4 +47,3 @@ D3D                   needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-4.0.2,v 1.2 2002/03/23 02:38:39 brianp Exp $
index c69b6a279ec2c893e6ded6995081680811a28477..0b3e34befe7083a5ae724b132679515d4fac7dc1 100644 (file)
@@ -49,4 +49,3 @@ D3D                   needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-4.0.3,v 1.2 2002/06/26 02:36:34 brianp Exp $
index 92cf9196f06457278edd19f46d102e9cc1eb8c7e..24e9299eb2a234a7c95d26b5ae0b418388cfd7ea 100644 (file)
@@ -305,4 +305,3 @@ are some things to change:
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-4.1,v 1.22 2002/10/29 15:06:37 brianp Exp $
index 565e4ad78e4c1e533933f5d34fd6740db4a50f6c..1b22996d83ba4fcd463d47f47ad1821416e00f9e 100644 (file)
@@ -82,4 +82,3 @@ driver call the _mesa_enable_1_4_extensions() function.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-5.0,v 3.2 2002/11/13 15:33:51 brianp Exp $
index 8d72cc44c11587bdaedc1aab075defdd5fea262e..f37e9c4a7fb6193f381b0e1f7f30aa19c303d879 100644 (file)
@@ -43,4 +43,3 @@ driver call the _mesa_enable_1_4_extensions() function.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-5.0.1,v 3.1 2003/03/30 16:17:54 brianp Exp $
index cfc9ad04fd6328d184f1a9146db75ad18754d58d..d0e05b2c7395642fd0d8432318c660cb4ee7bfbe 100644 (file)
@@ -43,4 +43,3 @@ driver call the _mesa_enable_1_4_extensions() function.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-5.0.2,v 1.1 2003/09/04 23:10:38 brianp Exp $
index de01a879a4c9561ac57fbe9fe2c05df14e7af4f0..1a3c2fb1aa08d3732f3c8ec9f71342f7591aedc3 100644 (file)
@@ -84,4 +84,3 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 6.0.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.0,v 1.3 2004/01/15 15:47:57 brianp Exp $
index e72d9fe891c4ada98e014ae072bf794d8bb6d12c..1444b9fc871c8c510922d6b326970f19672cc3e8 100644 (file)
@@ -47,4 +47,3 @@ D3D                   needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.0.1,v 3.1 2004/04/02 23:37:02 brianp Exp $
index 830f1e47e72412d79799c39c9d191476a358230b..8de64d1f1c379f9455e4c0d96ebe3a35942335fa 100644 (file)
@@ -109,4 +109,3 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 6.1.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.1,v 3.5 2004/08/17 22:58:23 brianp Exp $
index 4043a5655e38feabe6d664768212d7b8a6245d5f..06cfba0c7532e760c0ddf4412fd1a2bca3d5d647 100644 (file)
@@ -49,4 +49,3 @@ D3D                   needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.2,v 3.4 2004/10/02 15:43:14 brianp Exp $
index d72560e5af2ce2c114b9f8c1e535fc8ae23dd51d..c7baa5d421e0358ce0fe797c0d3bb37bc69f1fce 100644 (file)
@@ -47,4 +47,3 @@ D3D                   needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.2.1,v 3.1 2004/12/09 23:21:36 brianp Exp $
index dde335eec11c3a734328f10bdaac4424c2150893..6b4dfaaf9a331763e090b462bbfdc37dffd11ccf 100644 (file)
@@ -112,4 +112,3 @@ D3D                 needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.3,v 3.13 2005/07/21 15:57:29 brianp Exp $
index cc6e8be1b2c8bceb0f7ab4ea31f46701ec24c23f..eacc952aeb00aa0c9faa52f91912c5416a91470b 100644 (file)
@@ -46,4 +46,3 @@ D3D                   needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.3.1,v 3.1 2005/07/21 18:45:54 brianp Exp $
index f2d47bff19aa871b9691f222c4ec71df2fed90ec..e5243ef783c7e7b55b6cb946385e8f285aea5f4c 100644 (file)
@@ -34,4 +34,3 @@ D3D                   needs updating
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.3.2,v 3.2 2005/08/19 16:57:50 brianp Exp $
index a12600c3c83e8da18d9cc864716d88205879cc7a..1a945a103974e693515ec3588dd1ab0ce43a1abe 100644 (file)
@@ -47,4 +47,3 @@ in Mesa 6.3.
 
 
 ----------------------------------------------------------------------
-$Id: RELNOTES-6.4,v 3.1 2005/10/24 23:33:27 brianp Exp $
index 58aca318587630d8e6253d4f39b923762cf0cd86..b766ce7c75146b6d165dd7d32718b4de4d4edba2 100644 (file)
@@ -1117,6 +1117,5 @@ source code</a>.</p>
 
 
 <hr>
-$Id: news.html,v 3.33 2006/12/02 18:18:41 brianp Exp $
 </body>
 </html>
index 77c16e0efe23688ac7e7ddf2ff8b187070c119e2..a0d6084f31dd8b2f3a2c9c69eefd84477bffd22a 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/GL/dri/sarea.h,v 1.11 2002/10/30 12:52:03 alanh Exp $ */
 /**
  * \file sarea.h 
  * SAREA definitions.
@@ -34,7 +33,6 @@
  * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  */
 
-/* $XFree86: xc/programs/Xserver/GL/dri/sarea.h,v 1.11 2002/10/30 12:52:03 alanh Exp $ */
 
 #ifndef _SAREA_H_
 #define _SAREA_H_
index 6b0b9576d663c93623726670f35eb9ed48bcf93f..ae29bb80b2fa8991905c6b74cc9a9ac35f6d5f0d 100644 (file)
@@ -1,4 +1,3 @@
-// $Id: demo.cpp,v 1.2 2004/08/14 09:59:16 phoudoin Exp $
 
 // Simple BeOS GLView demo
 // Written by Brian Paul
index ac2e9f2a6ea9270b84ce0950b1f349f9e15ff772..2b3231d8ae6f654921313be1cde43687a9b4b649 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gears.c,v 1.3 1999/08/22 08:56:50 jtaylor Exp $ */
 
 /*
  * 3-D gear wheels.  This program is in the public domain.
index c82ca6e5f6301fdc93b6840bb7b187ae611c1e32..d4efb96930b3c570d834b7def1f2aae10a69b593 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: glfbdevtest.c,v 1.1 2003/08/06 17:47:15 keithw Exp $ */
 
 /*
  * Test the GLFBDev interface.   Only tested with radeonfb driver!!!!
index 36fa10d222b37da052b9c36055b36c920eba8538..74b06649f6e776e461f12e997bb9f2639c092623 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: manytex.c,v 1.2 2003/08/23 01:28:59 jonsmirl Exp $ */
 
 /*
  * test handling of many texture maps
index 039c04fa40ae27cd6d5065b772c0c6052c3bf242..62456eca25981c1e06049ad491791127eb13ebfa 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sample_server.c,v 1.1 2003/08/06 17:47:15 keithw Exp $ */
 
 /*
  * Sample server that just keeps first available window mapped.
index 58effcf484d494975122514cfac14316fec638cb..efd382a6d93198ec5f087fc3fce54182604ebc76 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sample_server2.c,v 1.2 2003/08/23 01:28:59 jonsmirl Exp $ */
 
 /*
  * Sample server that just keeps first available window mapped.
index d2a97d2876ea2ad3ddf80aec907e2f93d71ec5f5..098077f2474483ceae484accfef74bee549b7b5b 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: texline.c,v 1.1 2003/08/06 17:47:15 keithw Exp $ */
 
 /*
  * Test textured lines.
index 0de6c42e398be4104351d4fe2c532c287ecdb1a9..d42e3cb6549bc9043f9cd3e9516c643dee931076 100644 (file)
@@ -1,4 +1,3 @@
-# $Id: Makefile.win,v 1.1 2002/01/16 01:03:25 kschultz Exp $
 
 # Mesa 3-D graphics library
 # Version:  3.5
index 79b5ab75c5751e09c77675ea3b19da3d2293eece..3a83c34b8d085f89b083eb84c03b74a70722789e 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: antialias.c,v 1.2 2003/03/29 16:42:57 brianp Exp $ */
 
 /*
  * Test multisampling and polygon smoothing.
index c7677990bffef4ee187f016feca65fed584e6568..a47b2a9319a3f6f09975d7360e58ec2760c70c74 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: cva.c,v 1.8 2006/11/22 19:37:21 sroland Exp $ */
 
 /*
  * Trivial CVA test, good for testing driver fastpaths (especially
index 18f28972b6eab70c6216d219945c69f49ff427fc..5283c7e1fd6673b9c6b18b4d9ed0f9c5866dcb8f 100644 (file)
@@ -68,6 +68,7 @@ Display( void )
 
    /* draw to window */
    glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);
+   glDisable(GL_DEPTH_TEST);  /* in case window has depth buffer */
    glWindowPos2iARB(0, 0);
    glDrawPixels(Width, Height, GL_RGBA, GL_UNSIGNED_BYTE, buffer);
 
index d16b2d93d0e45bf4394a0a50c41db4c8b76c4630..8adfc51bd60677ef9f738bd825b1f4084b92ba02 100644 (file)
@@ -1,6 +1,5 @@
 #!/usr/bin/env python
 
-# $Id: getprocaddress.py,v 1.7 2005/06/21 23:42:43 idr Exp $
 
 # Helper for the getprocaddress.c test.
 
index 85bda8d01526593af0dac53322707ab0c8ee8695..08660b8932e2cc8c794e07fb56b11da4e29ce390 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: jkrahntest.c,v 1.2 2006/01/30 17:12:10 brianp Exp $ */
 
 /* This is a good test for glXSwapBuffers on non-current windows,
  * and the glXCopyContext function.  Fixed several Mesa/DRI bugs with
index 900e5834fe89d245763d19180f1a1b78c3643bcf..83c86766571013bd0129cc278b885820e544dfbc 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: manytex.c,v 1.5 2005/09/15 01:58:39 brianp Exp $ */
 
 /*
  * test handling of many texture maps
index c824b38703ac160540478fe68b7ade0d645a850b..52818fca7eea1ccbe96d6c878a077155732f15d6 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: multipal.c,v 1.6 2003/12/08 09:03:36 joukj Exp $ */
 
 /*
  * Test multitexture and paletted textures.
index e004b0336cac567a698d78412265b8c37a0d02b5..b069bea91ccdffa457c6974fc576271dfabc3859 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: multiwindow.c,v 1.1 2001/08/21 14:25:31 brianp Exp $ */
 
 /*
  * A skeleton/template GLUT program
@@ -8,7 +7,6 @@
 
 
 /*
- * $Log: multiwindow.c,v $
  * Revision 1.1  2001/08/21 14:25:31  brianp
  * simple multi-window GLUT test prog
  *
index 7be90d67f55b83620f4f299ade22c6eaf8169b0b..c07ebd719c7c1cce59efa91dfa17093d4cfba33c 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sharedtex.c,v 1.2 2002/01/16 14:32:46 joukj Exp $ */
 
 /*
  * Test sharing of display lists and texture objects between GLX contests.
index 3d59d9ac264c0adfd6431c4387295842b999475e..ee16ed40df216b508f43422e999c188ba67319f4 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: texline.c,v 1.5 2004/01/28 10:07:48 keithw Exp $ */
 
 /*
  * Test textured lines.
index 61c1fdd6b4fa61f2902af5c118c7731aded64b99..43edc491801c3a9398b56ce504ab73d3c247634c 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: texrect.c,v 1.5 2004/05/06 20:27:32 brianp Exp $ */
 
 /* GL_NV_texture_rectangle test
  *
index 6e9fbe0c70ff61a7805172fdd9cbad3038a8a671..8143256f8ae6406e5806119c1d035aacfd15e841 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: texwrap.c,v 1.8 2005/08/25 03:09:12 brianp Exp $ */
 
 /*
  * Test texture wrap modes.
index ca89d34bd3ea2a39ee395fa7b016902434fa6183..ea71ebd2b9668e1ad10623e7e644704091dbff64 100644 (file)
@@ -19,4 +19,3 @@ imagesgi.cpp,.h - read SGI image files
 more to come...
 
 ----------------------------------------------------------------------
-$Id: README,v 1.1 1999/08/19 00:55:42 jtg Exp $
index 4c5db13ec7ca972275f02f584e731daa21846a0f..21d7e4552d27b0b674244f913d3fdf147e30985d 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: glstate.c,v 1.1 1999/08/19 00:55:42 jtg Exp $ */
 
 /*
  * Print GL state information (for debugging)
@@ -21,7 +20,6 @@
 
 
 /*
- * $Log: glstate.c,v $
  * Revision 1.1  1999/08/19 00:55:42  jtg
  * Initial revision
  *
index 1aa4d21d8e82ab0d84629cdd9d1fafdac729791e..9216382b7be690d82c7d7566511eb826b9851403 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: glstate.h,v 1.1 1999/08/19 00:55:42 jtg Exp $ */
 
 /*
  * Print GL state information (for debugging)
@@ -21,7 +20,6 @@
 
 
 /*
- * $Log: glstate.h,v $
  * Revision 1.1  1999/08/19 00:55:42  jtg
  * Initial revision
  *
index ebb57ff3dd6af6be972f2c85fd84942f80ade029..71ec150b889620c37f83c5902f752dd6d393c2cd 100644 (file)
@@ -1,11 +1,9 @@
-# $Id: sampleMakefile,v 1.1 1999/08/19 00:55:42 jtg Exp $
 
 # Sample makefile for compiling OpenGL/Mesa applications on Unix.
 # This example assumes Linux with gcc.
 
 # This makefile is in the public domain
 
-# $Log: sampleMakefile,v $
 # Revision 1.1  1999/08/19 00:55:42  jtg
 # Initial revision
 #
index b33be2c6aee93eb790176f6aa97f3350e1f307c1..154fe55970e5e84417aea98ec7b929213e4dd3b6 100644 (file)
@@ -7,7 +7,6 @@
  */
 
 /*
- * $Log: ugldrawpix.c,v $
  * Revision 1.2  2001/09/10 19:21:13  brianp
  * WindML updates (Stephane Raimbault)
  *
index d2fe687b92613802b903cdf23defae83b70747ee..db66d1ff67bd0ac950f5cc220f39cb45046dcd92 100644 (file)
@@ -7,7 +7,6 @@
  */
 
 /*
- * $Log: ugltexcyl.c,v $
  * Revision 1.2  2001/09/10 19:21:13  brianp
  * WindML updates (Stephane Raimbault)
  *
index 989697fbcaab8d6cb2601f430c046f81167c8714..b90e6b4f3195eb5c3d0c39695dbb4b4599504173 100644 (file)
  * This program tests GLX thread safety.
  * Command line options:
  *  -p                       Open a display connection for each thread
+ *  -l                       Enable application-side locking
  *  -n <num threads>         Number of threads to create (default is 2)
  *  -display <display name>  Specify X display (default is :0.0)
+ *  -t                       Use texture mapping
  *
  * Brian Paul  20 July 2000
  */
 
 
+/*
+ * Notes:
+ * - Each thread gets its own GLX context.
+ *
+ * - The GLX contexts share texture objects.
+ *
+ * - When 't' is pressed to update the texture image, the window/thread which
+ *   has input focus is signalled to change the texture.  The other threads
+ *   should see the updated texture the next time they call glBindTexture.
+ */
+
+
 #if defined(PTHREADS)   /* defined by Mesa on Linux and other platforms */
 
 #include <assert.h>
 #include <GL/gl.h>
 #include <GL/glx.h>
+#include <math.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -55,6 +70,8 @@ struct winthread {
    float Angle;
    int WinWidth, WinHeight;
    GLboolean NewSize;
+   GLboolean Initialized;
+   GLboolean MakeNewTexture;
 };
 
 
@@ -65,8 +82,13 @@ static volatile GLboolean ExitFlag = GL_FALSE;
 
 static GLboolean MultiDisplays = 0;
 static GLboolean Locking = 0;
+static GLboolean Texture = GL_FALSE;
+static GLuint TexObj = 12;
+static GLboolean Animate = GL_TRUE;
 
 static pthread_mutex_t Mutex;
+static pthread_cond_t CondVar;
+static pthread_mutex_t CondMutex;
 
 
 static void
@@ -77,6 +99,59 @@ Error(const char *msg)
 }
 
 
+static void
+signal_redraw(void)
+{
+   pthread_mutex_lock(&CondMutex);
+   pthread_cond_broadcast(&CondVar);
+   pthread_mutex_unlock(&CondMutex);
+}
+
+
+static void
+MakeNewTexture(struct winthread *wt)
+{
+#define TEX_SIZE 128
+   static float step = 0.0;
+   GLfloat image[TEX_SIZE][TEX_SIZE][4];
+   GLint width;
+   int i, j;
+
+   for (j = 0; j < TEX_SIZE; j++) {
+      for (i = 0; i < TEX_SIZE; i++) {
+         float dt = 5.0 * (j - 0.5 * TEX_SIZE) / TEX_SIZE;
+         float ds = 5.0 * (i - 0.5 * TEX_SIZE) / TEX_SIZE;
+         float r = dt * dt + ds * ds + step;
+         image[j][i][0] = 
+         image[j][i][1] = 
+         image[j][i][2] = 0.75 + 0.25 * cos(r);
+         image[j][i][3] = 1.0;
+      }
+   }
+
+   step += 0.5;
+
+   glBindTexture(GL_TEXTURE_2D, TexObj);
+
+   glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_WIDTH, &width);
+   if (width) {
+      assert(width == TEX_SIZE);
+      /* sub-tex replace */
+      glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, TEX_SIZE, TEX_SIZE,
+                   GL_RGBA, GL_FLOAT, image);
+   }
+   else {
+      /* create new */
+      glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
+      glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
+
+      glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, TEX_SIZE, TEX_SIZE, 0, 
+                   GL_RGBA, GL_FLOAT, image);
+   }
+}
+
+
+
 /* draw a colored cube */
 static void
 draw_object(void)
@@ -85,52 +160,61 @@ draw_object(void)
    glScalef(0.75, 0.75, 0.75);
 
    glColor3f(1, 0, 0);
-   glBegin(GL_POLYGON);
-   glVertex3f(1, -1, -1);
-   glVertex3f(1,  1, -1);
-   glVertex3f(1,  1,  1);
-   glVertex3f(1, -1,  1);
-   glEnd();
 
+   if (Texture) {
+      glBindTexture(GL_TEXTURE_2D, TexObj);
+      glEnable(GL_TEXTURE_2D);
+   }
+   else {
+      glDisable(GL_TEXTURE_2D);
+   }
+
+   glBegin(GL_QUADS);
+
+   /* -X */
    glColor3f(0, 1, 1);
-   glBegin(GL_POLYGON);
-   glVertex3f(-1, -1, -1);
-   glVertex3f(-1,  1, -1);
-   glVertex3f(-1,  1,  1);
-   glVertex3f(-1, -1,  1);
-   glEnd();
+   glTexCoord2f(0, 0);  glVertex3f(-1, -1, -1);
+   glTexCoord2f(1, 0);  glVertex3f(-1,  1, -1);
+   glTexCoord2f(1, 1);  glVertex3f(-1,  1,  1);
+   glTexCoord2f(0, 1);  glVertex3f(-1, -1,  1);
 
-   glColor3f(0, 1, 0);
-   glBegin(GL_POLYGON);
-   glVertex3f(-1, 1, -1);
-   glVertex3f( 1, 1, -1);
-   glVertex3f( 1, 1,  1);
-   glVertex3f(-1, 1,  1);
-   glEnd();
+   /* +X */
+   glColor3f(1, 0, 0);
+   glTexCoord2f(0, 0);  glVertex3f(1, -1, -1);
+   glTexCoord2f(1, 0);  glVertex3f(1,  1, -1);
+   glTexCoord2f(1, 1);  glVertex3f(1,  1,  1);
+   glTexCoord2f(0, 1);  glVertex3f(1, -1,  1);
 
+   /* -Y */
    glColor3f(1, 0, 1);
-   glBegin(GL_POLYGON);
-   glVertex3f(-1, -1, -1);
-   glVertex3f( 1, -1, -1);
-   glVertex3f( 1, -1,  1);
-   glVertex3f(-1, -1,  1);
-   glEnd();
+   glTexCoord2f(0, 0);  glVertex3f(-1, -1, -1);
+   glTexCoord2f(1, 0);  glVertex3f( 1, -1, -1);
+   glTexCoord2f(1, 1);  glVertex3f( 1, -1,  1);
+   glTexCoord2f(0, 1);  glVertex3f(-1, -1,  1);
 
-   glColor3f(0, 0, 1);
-   glBegin(GL_POLYGON);
-   glVertex3f(-1, -1, 1);
-   glVertex3f( 1, -1, 1);
-   glVertex3f( 1,  1, 1);
-   glVertex3f(-1,  1, 1);
-   glEnd();
+   /* +Y */
+   glColor3f(0, 1, 0);
+   glTexCoord2f(0, 0);  glVertex3f(-1, 1, -1);
+   glTexCoord2f(1, 0);  glVertex3f( 1, 1, -1);
+   glTexCoord2f(1, 1);  glVertex3f( 1, 1,  1);
+   glTexCoord2f(0, 1);  glVertex3f(-1, 1,  1);
 
+   /* -Z */
    glColor3f(1, 1, 0);
-   glBegin(GL_POLYGON);
-   glVertex3f(-1, -1, -1);
-   glVertex3f( 1, -1, -1);
-   glVertex3f( 1,  1, -1);
-   glVertex3f(-1,  1, -1);
+   glTexCoord2f(0, 0);  glVertex3f(-1, -1, -1);
+   glTexCoord2f(1, 0);  glVertex3f( 1, -1, -1);
+   glTexCoord2f(1, 1);  glVertex3f( 1,  1, -1);
+   glTexCoord2f(0, 1);  glVertex3f(-1,  1, -1);
+
+   /* +Y */
+   glColor3f(0, 0, 1);
+   glTexCoord2f(0, 0);  glVertex3f(-1, -1, 1);
+   glTexCoord2f(1, 0);  glVertex3f( 1, -1, 1);
+   glTexCoord2f(1, 1);  glVertex3f( 1,  1, 1);
+   glTexCoord2f(0, 1);  glVertex3f(-1,  1, 1);
+
    glEnd();
+
    glPopMatrix();
 }
 
@@ -142,6 +226,8 @@ resize(struct winthread *wt, int w, int h)
    wt->NewSize = GL_TRUE;
    wt->WinWidth = w;
    wt->WinHeight = h;
+   if (!Animate)
+      signal_redraw();
 }
 
 
@@ -151,18 +237,19 @@ resize(struct winthread *wt, int w, int h)
 static void
 draw_loop(struct winthread *wt)
 {
-   GLboolean firstIter = GL_TRUE;
-
    while (!ExitFlag) {
 
       if (Locking)
          pthread_mutex_lock(&Mutex);
 
       glXMakeCurrent(wt->Dpy, wt->Win, wt->Context);
-      if (firstIter) {
+      if (!wt->Initialized) {
          printf("glthreads: %d: GL_RENDERER = %s\n", wt->Index,
                 (char *) glGetString(GL_RENDERER));
-         firstIter = GL_FALSE;
+         if (Texture /*&& wt->Index == 0*/) {
+            MakeNewTexture(wt);
+         }
+         wt->Initialized = GL_TRUE;
       }
 
       if (Locking)
@@ -182,10 +269,15 @@ draw_loop(struct winthread *wt)
          wt->NewSize = GL_FALSE;
       }
 
+      if (wt->MakeNewTexture) {
+         MakeNewTexture(wt);
+         wt->MakeNewTexture = GL_FALSE;
+      }
+
       glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
 
       glPushMatrix();
-         glRotatef(wt->Angle, 0, 0, 1);
+         glRotatef(wt->Angle, 0, 1, 0);
          glRotatef(wt->Angle, 1, 0, 0);
          glScalef(0.7, 0.7, 0.7);
          draw_object();
@@ -199,12 +291,63 @@ draw_loop(struct winthread *wt)
       if (Locking)
          pthread_mutex_unlock(&Mutex);
 
-      usleep(5000);
+      if (Animate) {
+         usleep(5000);
+      }
+      else {
+         /* wait for signal to draw */
+         pthread_mutex_lock(&CondMutex);
+         pthread_cond_wait(&CondVar, &CondMutex);
+         pthread_mutex_unlock(&CondMutex);
+      }
       wt->Angle += 1.0;
    }
 }
 
 
+static void
+keypress(XEvent *event, struct winthread *wt)
+{
+   char buf[100];
+   KeySym keySym;
+   XComposeStatus stat;
+
+   XLookupString(&event->xkey, buf, sizeof(buf), &keySym, &stat);
+
+   switch (keySym) {
+   case XK_Escape:
+      /* tell all threads to exit */
+      if (!Animate) {
+         signal_redraw();
+      }
+      ExitFlag = GL_TRUE;
+      /*printf("exit draw_loop %d\n", wt->Index);*/
+      return;
+   case XK_t:
+   case XK_T:
+      if (Texture) {
+         wt->MakeNewTexture = GL_TRUE;
+         if (!Animate)
+            signal_redraw();
+      }
+      break;
+   case XK_a:
+   case XK_A:
+      Animate = !Animate;
+      if (Animate)  /* yes, prev Animate state! */
+         signal_redraw();
+      break;
+   case XK_s:
+   case XK_S:
+      if (!Animate)
+         signal_redraw();
+      break;
+   default:
+      ; /* nop */
+   }
+}
+
+
 /*
  * The main process thread runs this loop.
  * Single display connection for all threads.
@@ -250,10 +393,14 @@ event_loop(Display *dpy)
             }
             break;
          case KeyPress:
-            /* tell all threads to exit */
-            ExitFlag = GL_TRUE;
-            /*printf("exit draw_loop %d\n", wt->Index);*/
-            return;
+            for (i = 0; i < NumWinThreads; i++) {
+               struct winthread *wt = &WinThreads[i];
+               if (event.xkey.window == wt->Win) {
+                  keypress(&event, wt);
+                  break;
+               }
+            }
+            break;
          default:
             /*no-op*/ ;
       }
@@ -281,12 +428,10 @@ event_loop_multi(void)
             resize(wt, event.xconfigure.width, event.xconfigure.height);
             break;
          case KeyPress:
-            /* tell all threads to exit */
-            ExitFlag = GL_TRUE;
-            /*printf("exit draw_loop %d\n", wt->Index);*/
-            return;
+            keypress(&event, wt);
+            break;
          default:
-            /*no-op*/ ;
+            ; /* nop */
          }
       }
       w = (w + 1) % NumWinThreads;
@@ -300,7 +445,7 @@ event_loop_multi(void)
  * we'll call this once for each thread, before the threads are created.
  */
 static void
-create_window(struct winthread *wt)
+create_window(struct winthread *wt, GLXContext shareCtx)
 {
    Window win;
    GLXContext ctx;
@@ -316,9 +461,9 @@ create_window(struct winthread *wt)
    unsigned long mask;
    Window root;
    XVisualInfo *visinfo;
-   int width = 80, height = 80;
-   int xpos = (wt->Index % 10) * 90;
-   int ypos = (wt->Index / 10) * 100;
+   int width = 160, height = 160;
+   int xpos = (wt->Index % 8) * (width + 10);
+   int ypos = (wt->Index / 8) * (width + 20);
 
    scrnum = DefaultScreen(wt->Dpy);
    root = RootWindow(wt->Dpy, scrnum);
@@ -355,7 +500,7 @@ create_window(struct winthread *wt)
    }
 
 
-   ctx = glXCreateContext(wt->Dpy, visinfo, NULL, True);
+   ctx = glXCreateContext(wt->Dpy, visinfo, shareCtx, True);
    if (!ctx) {
       Error("Couldn't create GLX context");
    }
@@ -405,6 +550,25 @@ clean_up(void)
 }
 
 
+static void
+usage(void)
+{
+   printf("glthreads: test of GL thread safety (any key = exit)\n");
+   printf("Usage:\n");
+   printf("  glthreads [options]\n");
+   printf("Options:\n");
+   printf("   -display DISPLAYNAME  Specify display string\n");
+   printf("   -n NUMTHREADS  Number of threads to create\n");
+   printf("   -p  Use a separate display connection for each thread\n");
+   printf("   -l  Use application-side locking\n");
+   printf("   -t  Enable texturing\n");
+   printf("Keyboard:\n");
+   printf("   Esc  Exit\n");
+   printf("   t    Change texture image (requires -t option)\n");
+   printf("   a    Toggle animation\n");
+   printf("   s    Step rotation (when not animating)\n");
+}
+
 
 int
 main(int argc, char *argv[])
@@ -416,9 +580,7 @@ main(int argc, char *argv[])
    Status threadStat;
 
    if (argc == 1) {
-      printf("glthreads: test of GL thread safety (any key = exit)\n");
-      printf("Usage:\n");
-      printf("  glthreads [-display dpyName] [-n numthreads]\n");
+      usage();
    }
    else {
       int i;
@@ -433,6 +595,9 @@ main(int argc, char *argv[])
          else if (strcmp(argv[i], "-l") == 0) {
             Locking = 1;
          }
+         else if (strcmp(argv[i], "-t") == 0) {
+            Texture = 1;
+         }
          else if (strcmp(argv[i], "-n") == 0 && i + 1 < argc) {
             numThreads = atoi(argv[i + 1]);
             if (numThreads < 1)
@@ -442,13 +607,14 @@ main(int argc, char *argv[])
             i++;
          }
          else {
-            fprintf(stderr, "glthreads: unexpected flag: %s\n", argv[i]);
+            usage();
+            exit(1);
          }
       }
    }
    
    if (Locking)
-      printf("glthreads: Using explict locks around Xlib calls.\n");
+      printf("glthreads: Using explicit locks around Xlib calls.\n");
    else
       printf("glthreads: No explict locking.\n");
 
@@ -478,9 +644,9 @@ main(int argc, char *argv[])
       }
    }
 
-   if (Locking) {
-      pthread_mutex_init(&Mutex, NULL);
-   }
+   pthread_mutex_init(&Mutex, NULL);
+   pthread_mutex_init(&CondMutex, NULL);
+   pthread_cond_init(&CondVar, NULL);
 
    printf("glthreads: creating windows\n");
 
@@ -488,6 +654,8 @@ main(int argc, char *argv[])
 
    /* Create the GLX windows and contexts */
    for (i = 0; i < numThreads; i++) {
+      GLXContext share;
+
       if (MultiDisplays) {
          WinThreads[i].Dpy = XOpenDisplay(displayName);
          assert(WinThreads[i].Dpy);
@@ -496,7 +664,11 @@ main(int argc, char *argv[])
          WinThreads[i].Dpy = dpy;
       }
       WinThreads[i].Index = i;
-      create_window(&WinThreads[i]);
+      WinThreads[i].Initialized = GL_FALSE;
+
+      share = (Texture && i > 0) ? WinThreads[0].Context : 0;
+
+      create_window(&WinThreads[i], share);
    }
 
    printf("glthreads: creating threads\n");
@@ -505,7 +677,7 @@ main(int argc, char *argv[])
    for (i = 0; i < numThreads; i++) {
       pthread_create(&WinThreads[i].Thread, NULL, thread_function,
                      (void*) &WinThreads[i]);
-      printf("glthreads: Created thread %u\n", (unsigned int) WinThreads[i].Thread);
+      printf("glthreads: Created thread %p\n", (void *) WinThreads[i].Thread);
    }
 
    if (MultiDisplays)
index 13d030a8bef0b0081c4bf8c76162a5b72d04cbee..f579e8b421d443e37b1f642a098d403752acb768 100644 (file)
@@ -1,4 +1,3 @@
-/* $ID$ */
 
 /*
  * Spinning gears demo for Linux SVGA/Mesa interface in 32K color mode.
index 18a97f449b498aa9e9dc4bd2018aacc058f4f6a8..d5d5987a7ff8fef68fb7657eb667d8077b49a8e3 100644 (file)
@@ -6,7 +6,7 @@
 The state tracker and winsys driver support a rather limited number of
 platforms. However, the pipe drivers are meant to run in a wide number of
 platforms. Hence the pipe drivers, the auxiliary modules, and all public
-headers in general, should stricly follow these guidelines to ensure
+headers in general, should strictly follow these guidelines to ensure
 
 
 = Compiler Support =
index a1a3a9efaf3fef4c33f7e6d679e15aec01840ec7..af4af8ac1d498b704e42939504527b34f121beac 100644 (file)
@@ -292,7 +292,7 @@ enum pipe_error cso_set_blend(struct cso_context *ctx,
       if (!cso)
          return PIPE_ERROR_OUT_OF_MEMORY;
 
-      cso->state = *templ;
+      memcpy(&cso->state, templ, sizeof(*templ));
       cso->data = ctx->pipe->create_blend_state(ctx->pipe, &cso->state);
       cso->delete_state = (cso_state_callback)ctx->pipe->delete_blend_state;
       cso->context = ctx->pipe;
@@ -350,7 +350,7 @@ enum pipe_error cso_single_sampler(struct cso_context *ctx,
          if (!cso)
             return PIPE_ERROR_OUT_OF_MEMORY;
 
-         cso->state = *templ;
+         memcpy(&cso->state, templ, sizeof(*templ));
          cso->data = ctx->pipe->create_sampler_state(ctx->pipe, &cso->state);
          cso->delete_state = (cso_state_callback)ctx->pipe->delete_sampler_state;
          cso->context = ctx->pipe;
@@ -508,7 +508,7 @@ enum pipe_error cso_set_depth_stencil_alpha(struct cso_context *ctx,
       if (!cso)
          return PIPE_ERROR_OUT_OF_MEMORY;
 
-      cso->state = *templ;
+      memcpy(&cso->state, templ, sizeof(*templ));
       cso->data = ctx->pipe->create_depth_stencil_alpha_state(ctx->pipe, &cso->state);
       cso->delete_state = (cso_state_callback)ctx->pipe->delete_depth_stencil_alpha_state;
       cso->context = ctx->pipe;
@@ -564,7 +564,7 @@ enum pipe_error cso_set_rasterizer(struct cso_context *ctx,
       if (!cso)
          return PIPE_ERROR_OUT_OF_MEMORY;
 
-      cso->state = *templ;
+      memcpy(&cso->state, templ, sizeof(*templ));
       cso->data = ctx->pipe->create_rasterizer_state(ctx->pipe, &cso->state);
       cso->delete_state = (cso_state_callback)ctx->pipe->delete_rasterizer_state;
       cso->context = ctx->pipe;
@@ -726,7 +726,7 @@ enum pipe_error cso_set_vertex_shader(struct cso_context *ctx,
       if (!cso)
          return PIPE_ERROR_OUT_OF_MEMORY;
 
-      cso->state = *templ;
+      memcpy(cso->state, templ, sizeof(*templ));
       cso->data = ctx->pipe->create_vs_state(ctx->pipe, &cso->state);
       cso->delete_state = (cso_state_callback)ctx->pipe->delete_vs_state;
       cso->context = ctx->pipe;
@@ -769,8 +769,7 @@ void cso_restore_vertex_shader(struct cso_context *ctx)
 enum pipe_error cso_set_framebuffer(struct cso_context *ctx,
                                     const struct pipe_framebuffer_state *fb)
 {
-   /* XXX this memcmp() fails to detect buffer size changes */
-   if (1/*memcmp(&ctx->fb, fb, sizeof(*fb))*/) {
+   if (memcmp(&ctx->fb, fb, sizeof(*fb)) != 0) {
       ctx->fb = *fb;
       ctx->pipe->set_framebuffer_state(ctx->pipe, fb);
    }
index 346a96e37fdec3c5ce04f5f0e0a2c6306668c54c..b1ed8aa24ea50616dbe9aca83028c18bc861a502 100644 (file)
@@ -415,8 +415,11 @@ aaline_create_texture(struct aaline_stage *aaline)
 
       assert(aaline->texture->width[level] == aaline->texture->height[level]);
 
-      surface = screen->get_tex_surface(screen, aaline->texture, 0, level, 0);
-      data = pipe_surface_map(surface);
+      /* This texture is new, no need to flush. 
+       */
+      surface = screen->get_tex_surface(screen, aaline->texture, 0, level, 0,
+                                        PIPE_BUFFER_USAGE_CPU_WRITE);
+      data = screen->surface_map(screen, surface, PIPE_BUFFER_USAGE_CPU_WRITE);
       if (data == NULL)
          return FALSE;
 
@@ -440,9 +443,8 @@ aaline_create_texture(struct aaline_stage *aaline)
       }
 
       /* unmap */
-      pipe_surface_unmap(surface);
-      pipe_surface_reference(&surface, NULL);
-      pipe->texture_update(pipe, aaline->texture, 0, (1 << level));
+      screen->surface_unmap(screen, surface);
+      screen->tex_surface_release(screen, &surface);
    }
    return TRUE;
 }
index 2dfd1800d550455251603dba959be29ff8b6489d..4c92416eb19e370384922f7ffa1f68ce6a69c5d5 100644 (file)
@@ -376,8 +376,14 @@ pstip_update_texture(struct pstip_stage *pstip)
    uint i, j;
    ubyte *data;
 
-   surface = screen->get_tex_surface(screen, pstip->texture, 0, 0, 0);
-   data = pipe_surface_map(surface);
+   /* XXX: want to avoid flushing just because we use stipple: 
+    */
+   pipe->flush( pipe, PIPE_FLUSH_TEXTURE_CACHE, NULL );
+
+   surface = screen->get_tex_surface(screen, pstip->texture, 0, 0, 0,
+                                     PIPE_BUFFER_USAGE_CPU_WRITE);
+   data = screen->surface_map(screen, surface,
+                              PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /*
     * Load alpha texture.
@@ -399,9 +405,8 @@ pstip_update_texture(struct pstip_stage *pstip)
    }
 
    /* unmap */
-   pipe_surface_unmap(surface);
-   pipe_surface_reference(&surface, NULL);
-   pipe->texture_update(pipe, pstip->texture, 0, 0x1);
+   screen->surface_unmap(screen, surface);
+   screen->tex_surface_release(screen, &surface);
 }
 
 
index 86a7d1c730311a619650c95ffc85ae9fffb1939a..67b9a9503d2d8b36e57c19b6006c2a1693058b18 100644 (file)
@@ -427,9 +427,6 @@ static void vbuf_destroy( struct draw_stage *stage )
    if(vbuf->indices)
       align_free( vbuf->indices );
    
-   if(vbuf->translate)
-      vbuf->translate->release( vbuf->translate );
-
    if (vbuf->render)
       vbuf->render->destroy( vbuf->render );
 
index 100117a9aef6c13958ea57af6dba81610c95c142..b96335b7895bfb8285a68e33c51b86f2682f0dd7 100644 (file)
@@ -184,7 +184,8 @@ struct pt_fetch *draw_pt_fetch_create( struct draw_context *draw )
 
 void draw_pt_fetch_destroy( struct pt_fetch *fetch )
 {
-   translate_cache_destroy(fetch->cache);
+   if (fetch->cache)
+      translate_cache_destroy(fetch->cache);
 
    FREE(fetch);
 }
index b7b970a297fdae81aeb7272c32fe124e421a8f09..4ea7d4359ffde05e2a08fa17b1ab48105f014568 100644 (file)
@@ -268,7 +268,8 @@ static void fetch_emit_destroy( struct draw_pt_middle_end *middle )
 {
    struct fetch_emit_middle_end *feme = (struct fetch_emit_middle_end *)middle;
 
-   translate_cache_destroy(feme->cache);
+   if (feme->cache)
+      translate_cache_destroy(feme->cache);
 
    FREE(middle);
 }
index d654dbcc919aa00511eb9f7ba473b39f8ce2b434..ff09011b660fba6ac96970967230d3133e91cc7c 100644 (file)
@@ -11,6 +11,7 @@ C_SOURCES = \
        pb_bufmgr_mm.c \
        pb_bufmgr_pool.c \
        pb_bufmgr_slab.c \
+       pb_validate.c \
        pb_winsys.c
 
 include ../../Makefile.template
index 604a217982e90be4736678fe01a0d2c417295922..9db0c0eae3b8f9151f8231ec5b7487b6aa495b95 100644 (file)
@@ -10,6 +10,7 @@ pipebuffer = env.ConvenienceLibrary(
                'pb_bufmgr_mm.c',
                'pb_bufmgr_pool.c',
                'pb_bufmgr_slab.c',
+               'pb_validate.c',
                'pb_winsys.c',
        ])
 
index 49705cb862733b30a953b6d77cf7c3dec8fe2bdb..857ea53c7865778526ac92e11576777d9cbdc670 100644 (file)
@@ -146,6 +146,8 @@ pb_map(struct pb_buffer *buf,
        unsigned flags)
 {
    assert(buf);
+   if(!buf)
+      return NULL;
    return buf->vtbl->map(buf, flags);
 }
 
@@ -154,6 +156,8 @@ static INLINE void
 pb_unmap(struct pb_buffer *buf)
 {
    assert(buf);
+   if(!buf)
+      return;
    buf->vtbl->unmap(buf);
 }
 
@@ -163,6 +167,12 @@ pb_get_base_buffer( struct pb_buffer *buf,
                    struct pb_buffer **base_buf,
                    unsigned *offset )
 {
+   assert(buf);
+   if(!buf) {
+      base_buf = NULL;
+      offset = 0;
+      return;
+   }
    buf->vtbl->get_base_buffer(buf, base_buf, offset);
 }
 
@@ -171,7 +181,8 @@ static INLINE void
 pb_destroy(struct pb_buffer *buf)
 {
    assert(buf);
-   assert(buf->vtbl);
+   if(!buf)
+      return;
    buf->vtbl->destroy(buf);
 }
 
index 2fa08429715dcc59dcc144cae702acab0983262d..7f236887a9063df2e746a40639d914365e177d1f 100644 (file)
@@ -168,6 +168,28 @@ _fenced_buffer_remove(struct fenced_buffer *fenced_buf)
 }
 
 
+static INLINE enum pipe_error
+_fenced_buffer_finish(struct fenced_buffer *fenced_buf)
+{
+   struct fenced_buffer_list *fenced_list = fenced_buf->list;
+   struct pipe_winsys *winsys = fenced_list->winsys;
+
+   debug_warning("waiting for GPU");
+
+   assert(fenced_buf->fence);
+   if(fenced_buf->fence) {
+      if(winsys->fence_finish(winsys, fenced_buf->fence, 0) != 0) {
+        return PIPE_ERROR;
+      }
+      /* Remove from the fenced list */
+      _fenced_buffer_remove(fenced_buf); /* TODO: remove consequents */
+   }
+
+   fenced_buf->flags &= ~PIPE_BUFFER_USAGE_GPU_READ_WRITE;
+   return PIPE_OK;
+}
+
+
 /**
  * Free as many fenced buffers from the list head as possible. 
  */
@@ -207,40 +229,6 @@ _fenced_buffer_list_check_free(struct fenced_buffer_list *fenced_list,
 }
 
 
-/**
- * Serialize writes, but allow concurrent reads.
- */
-static INLINE enum pipe_error
-fenced_buffer_serialize(struct fenced_buffer *fenced_buf, unsigned flags)
-{
-   struct fenced_buffer_list *fenced_list = fenced_buf->list;
-   struct pipe_winsys *winsys = fenced_list->winsys;
-
-   /* Allow concurrent reads */
-   if(((fenced_buf->flags | flags) & PIPE_BUFFER_USAGE_WRITE) == 0)
-      return PIPE_OK;
-
-   /* Wait for the CPU to finish */
-   if(fenced_buf->mapcount) {
-      /* FIXME: Use thread conditions variables to signal when mapcount 
-       * reaches zero */
-      debug_warning("attemp to write concurrently to buffer");
-      /* XXX: we must not fail here in order to support texture mipmap generation
-      return PIPE_ERROR_RETRY;
-       */
-   }
-
-   /* Wait for the GPU to finish */
-   if(fenced_buf->fence) {
-      if(winsys->fence_finish(winsys, fenced_buf->fence, 0) != 0)
-        return PIPE_ERROR_RETRY; 
-      _fenced_buffer_remove(fenced_buf);
-   }
-
-   return PIPE_OK;
-}
-
-
 static void
 fenced_buffer_destroy(struct pb_buffer *buf)
 {
@@ -280,15 +268,28 @@ fenced_buffer_map(struct pb_buffer *buf,
 {
    struct fenced_buffer *fenced_buf = fenced_buffer(buf);
    void *map;
-   assert((flags & ~PIPE_BUFFER_USAGE_CPU_READ_WRITE) == 0);
+
+   assert(!(flags & ~PIPE_BUFFER_USAGE_CPU_READ_WRITE));
+   flags &= PIPE_BUFFER_USAGE_CPU_READ_WRITE;
    
-   if(fenced_buffer_serialize(fenced_buf, flags) != PIPE_OK)
-      return NULL;
+   /* Check for GPU read/write access */
+   if(fenced_buf->flags & PIPE_BUFFER_USAGE_GPU_WRITE) {
+      /* Wait for the GPU to finish writing */
+      _fenced_buffer_finish(fenced_buf);
+   }
+
+   /* Check for CPU write access (read is OK) */
+   if(fenced_buf->flags & PIPE_BUFFER_USAGE_CPU_READ_WRITE) {
+      /* this is legal -- just for debugging */
+      debug_warning("concurrent CPU writes");
+   }
    
    map = pb_map(fenced_buf->buffer, flags);
-   if(map)
+   if(map) {
       ++fenced_buf->mapcount;
-   fenced_buf->flags |= flags & PIPE_BUFFER_USAGE_CPU_READ_WRITE;
+      fenced_buf->flags |= flags;
+   }
+
    return map;
 }
 
@@ -298,10 +299,12 @@ fenced_buffer_unmap(struct pb_buffer *buf)
 {
    struct fenced_buffer *fenced_buf = fenced_buffer(buf);
    assert(fenced_buf->mapcount);
-   pb_unmap(fenced_buf->buffer);
-   --fenced_buf->mapcount;
-   if(!fenced_buf->mapcount)
-      fenced_buf->flags &= ~PIPE_BUFFER_USAGE_CPU_READ_WRITE;
+   if(fenced_buf->mapcount) {
+      pb_unmap(fenced_buf->buffer);
+      --fenced_buf->mapcount;
+      if(!fenced_buf->mapcount)
+        fenced_buf->flags &= ~PIPE_BUFFER_USAGE_CPU_READ_WRITE;
+   }
 }
 
 
@@ -334,8 +337,10 @@ fenced_buffer_create(struct fenced_buffer_list *fenced_list,
       return NULL;
    
    buf = CALLOC_STRUCT(fenced_buffer);
-   if(!buf)
+   if(!buf) {
+      pb_reference(&buffer, NULL);
       return NULL;
+   }
    
    buf->base.base.refcount = 1;
    buf->base.base.alignment = buffer->base.alignment;
@@ -374,7 +379,7 @@ buffer_fence(struct pb_buffer *buf,
    fenced_list = fenced_buf->list;
    winsys = fenced_list->winsys;
    
-   if(fence == fenced_buf->fence) {
+   if(!fence || fence == fenced_buf->fence) {
       /* Handle the same fence case specially, not only because it is a fast 
        * path, but mostly to avoid serializing two writes with the same fence, 
        * as that would bring the hardware down to synchronous operation without
@@ -384,11 +389,6 @@ buffer_fence(struct pb_buffer *buf,
       return;
    }
    
-   if(fenced_buffer_serialize(fenced_buf, flags) != PIPE_OK) {
-      /* FIXME: propagate error */
-      (void)0;
-   }
-   
    _glthread_LOCK_MUTEX(fenced_list->mutex);
    if (fenced_buf->fence)
       _fenced_buffer_remove(fenced_buf);
index 8de286e3f945d69483a37ddf9c800224285b6bc1..f6cc7a525b7bab55e8ee250f504ab8377e6f236b 100644 (file)
@@ -50,7 +50,8 @@
 #define PB_BUFMGR_H_
 
 
-#include <stddef.h>
+#include "pipe/p_compiler.h"
+#include "pipe/p_error.h"
 
 
 #ifdef __cplusplus
@@ -68,7 +69,6 @@ struct pipe_winsys;
  */
 struct pb_manager
 {
-   /* XXX: we will likely need more allocation flags */
    struct pb_buffer *
    (*create_buffer)( struct pb_manager *mgr, 
                     size_t size,
index b931455056e4b6013a15d37f19cade8470a74b55..45ba158a4d98f2c01686d78e7c267d7a71c9bc14 100644 (file)
@@ -47,9 +47,6 @@
 #include "pb_bufmgr.h"
 
 
-#define DRI_SLABPOOL_ALLOC_RETRIES 100
-
-
 struct pb_slab;
 
 struct pb_slab_buffer
@@ -313,7 +310,6 @@ pb_slab_manager_create_buffer(struct pb_manager *_mgr,
    static struct pb_slab_buffer *buf;
    struct pb_slab *slab;
    struct list_head *list;
-   int count = DRI_SLABPOOL_ALLOC_RETRIES;
 
    /* check size */
    assert(size == mgr->bufSize);
@@ -331,23 +327,14 @@ pb_slab_manager_create_buffer(struct pb_manager *_mgr,
    /* XXX: check for compatible buffer usage too? */
    
    _glthread_LOCK_MUTEX(mgr->mutex);
-   while (mgr->slabs.next == &mgr->slabs && count > 0) {
-      if (mgr->slabs.next != &mgr->slabs)
-        break;
-
-      _glthread_UNLOCK_MUTEX(mgr->mutex);
-      if (count != DRI_SLABPOOL_ALLOC_RETRIES)
-        util_time_sleep(1);
-      _glthread_LOCK_MUTEX(mgr->mutex);
+   if (mgr->slabs.next == &mgr->slabs) {
       (void) pb_slab_create(mgr);
-      count--;
+      if (mgr->slabs.next == &mgr->slabs) {
+        _glthread_UNLOCK_MUTEX(mgr->mutex);
+        return NULL;
+      }
    }
-
    list = mgr->slabs.next;
-   if (list == &mgr->slabs) {
-      _glthread_UNLOCK_MUTEX(mgr->mutex);
-      return NULL;
-   }
    slab = LIST_ENTRY(struct pb_slab, list, head);
    if (--slab->numFree == 0)
       LIST_DELINIT(list);
diff --git a/src/gallium/auxiliary/pipebuffer/pb_validate.c b/src/gallium/auxiliary/pipebuffer/pb_validate.c
new file mode 100644 (file)
index 0000000..362fd89
--- /dev/null
@@ -0,0 +1,153 @@
+/**************************************************************************
+ *
+ * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
+ * All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ *
+ **************************************************************************/
+
+/**
+ * @file
+ * Buffer validation.
+ * 
+ * @author Jose Fonseca <jrfonseca@tungstengraphics.com>
+ */
+
+
+#include "pipe/p_compiler.h"
+#include "pipe/p_error.h"
+#include "pipe/p_util.h"
+#include "pipe/p_debug.h"
+
+#include "pb_buffer.h"
+#include "pb_buffer_fenced.h"
+#include "pb_validate.h"
+
+
+#define PB_VALIDATE_INITIAL_SIZE 1 /* 512 */ 
+
+
+struct pb_validate
+{
+   struct pb_buffer **buffers;
+   unsigned used;
+   unsigned size;
+};
+
+
+enum pipe_error
+pb_validate_add_buffer(struct pb_validate *vl,
+                       struct pb_buffer *buf)
+{
+   assert(buf);
+   if(!buf)
+      return PIPE_ERROR;
+
+   /* We only need to store one reference for each buffer, so avoid storing
+    * consecutive references for the same buffer. It might not be the more 
+    * common pasttern, but it is easy to implement.
+    */
+   if(vl->used && vl->buffers[vl->used - 1] == buf) {
+      return PIPE_OK;
+   }
+   
+   /* Grow the table */
+   if(vl->used == vl->size) {
+      unsigned new_size;
+      struct pb_buffer **new_buffers;
+      
+      new_size = vl->size * 2;
+      if(!new_size)
+        return PIPE_ERROR_OUT_OF_MEMORY;
+
+      new_buffers = (struct pb_buffer **)REALLOC(vl->buffers,
+                                                 vl->size*sizeof(struct pb_buffer *),
+                                                 new_size*sizeof(struct pb_buffer *));
+      if(!new_buffers)
+         return PIPE_ERROR_OUT_OF_MEMORY;
+      
+      memset(new_buffers + vl->size, 0, (new_size - vl->size)*sizeof(struct pb_buffer *));
+      
+      vl->size = new_size;
+      vl->buffers = new_buffers;
+   }
+   
+   assert(!vl->buffers[vl->used]);
+   pb_reference(&vl->buffers[vl->used], buf);
+   ++vl->used;
+   
+   return PIPE_OK;
+}
+
+
+enum pipe_error
+pb_validate_validate(struct pb_validate *vl) 
+{
+   /* FIXME: go through each buffer, ensure its not mapped, its address is 
+    * available -- requires a new pb_buffer interface */
+   return PIPE_OK;
+}
+
+
+void
+pb_validate_fence(struct pb_validate *vl,
+                  struct pipe_fence_handle *fence)
+{
+   unsigned i;
+   for(i = 0; i < vl->used; ++i) {
+      buffer_fence(vl->buffers[i], fence);
+      pb_reference(&vl->buffers[i], NULL);
+   }
+   vl->used = 0;
+}
+
+
+void
+pb_validate_destroy(struct pb_validate *vl)
+{
+   unsigned i;
+   for(i = 0; i < vl->used; ++i)
+      pb_reference(&vl->buffers[i], NULL);
+   FREE(vl->buffers);
+   FREE(vl);
+}
+
+
+struct pb_validate *
+pb_validate_create()
+{
+   struct pb_validate *vl;
+   
+   vl = CALLOC_STRUCT(pb_validate);
+   if(!vl)
+      return NULL;
+   
+   vl->size = PB_VALIDATE_INITIAL_SIZE;
+   vl->buffers = (struct pb_buffer **)CALLOC(vl->size, sizeof(struct pb_buffer *));
+   if(!vl->buffers) {
+      FREE(vl);
+      return NULL;
+   }
+
+   return vl;
+}
+
diff --git a/src/gallium/auxiliary/pipebuffer/pb_validate.h b/src/gallium/auxiliary/pipebuffer/pb_validate.h
new file mode 100644 (file)
index 0000000..3db1d53
--- /dev/null
@@ -0,0 +1,91 @@
+/**************************************************************************
+ *
+ * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
+ * All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ *
+ **************************************************************************/
+
+/**
+ * @file
+ * Buffer validation.
+ * 
+ * @author Jose Fonseca <jrfonseca@tungstengraphics.com>
+ */
+
+#ifndef PB_VALIDATE_H_
+#define PB_VALIDATE_H_
+
+
+#include "pipe/p_compiler.h"
+#include "pipe/p_error.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+struct pb_buffer;
+struct pipe_fence_handle;
+
+
+/**
+ * Buffer validation list.
+ * 
+ * It holds a list of buffers to be validated and fenced when flushing.
+ */
+struct pb_validate;
+
+
+enum pipe_error
+pb_validate_add_buffer(struct pb_validate *vl,
+                       struct pb_buffer *buf);
+
+/**
+ * Validate all buffers for hardware access.
+ * 
+ * Should be called right before issuing commands to the hardware.
+ */
+enum pipe_error
+pb_validate_validate(struct pb_validate *vl);
+
+/**
+ * Fence all buffers and clear the list.
+ * 
+ * Should be called right before issuing commands to the hardware.
+ */
+void
+pb_validate_fence(struct pb_validate *vl,
+                  struct pipe_fence_handle *fence);
+
+struct pb_validate *
+pb_validate_create(void);
+
+void
+pb_validate_destroy(struct pb_validate *vl);
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /*PB_VALIDATE_H_*/
index d55d2c708187431e237d7aba93524f6d8ea4fff9..0309de1ac22eca29ba009e3c3e2ee56ca7d70d75 100644 (file)
@@ -5,6 +5,7 @@ util = env.ConvenienceLibrary(
        source = [
                'p_debug.c',
                'p_debug_mem.c',
+               'p_debug_prof.c',
                'p_tile.c',
                'p_util.c',
                'u_blit.c',
index 4ec17466624a7f3a7add760063552472be5f214e..ce7fb589562fbe18cbf0e63856a281720bcc3b7a 100644 (file)
@@ -67,7 +67,7 @@ void _debug_vprintf(const char *format, va_list ap)
    static char buf[512 + 1] = {'\0'};
    size_t len = strlen(buf);
    int ret = util_vsnprintf(buf + len, sizeof(buf) - len, format, ap);
-   if(ret > (int)(sizeof(buf) - len - 1) || strchr(buf + len, '\n')) {
+   if(ret > (int)(sizeof(buf) - len - 1) || util_strchr(buf + len, '\n')) {
       _EngDebugPrint("%s", buf);
       buf[0] = '\0';
    }
@@ -154,6 +154,7 @@ debug_get_option(const char *name, const char *dfault)
 {
    const char *result;
 #ifdef PIPE_SUBSYSTEM_WINDOWS_DISPLAY
+#ifdef DEBUG
    ULONG_PTR iFile = 0;
    const void *pMap = NULL;
    const char *sol, *eol, *sep;
@@ -183,6 +184,9 @@ debug_get_option(const char *name, const char *dfault)
       }
       EngUnmapFile(iFile);
    }
+#else
+   result = dfault;
+#endif
 #else
    
    result = getenv(name);
@@ -203,15 +207,15 @@ debug_get_bool_option(const char *name, boolean dfault)
    
    if(str == NULL)
       result = dfault;
-   else if(!strcmp(str, "n"))
+   else if(!util_strcmp(str, "n"))
       result = FALSE;
-   else if(!strcmp(str, "no"))
+   else if(!util_strcmp(str, "no"))
       result = FALSE;
-   else if(!strcmp(str, "0"))
+   else if(!util_strcmp(str, "0"))
       result = FALSE;
-   else if(!strcmp(str, "f"))
+   else if(!util_strcmp(str, "f"))
       result = FALSE;
-   else if(!strcmp(str, "false"))
+   else if(!util_strcmp(str, "false"))
       result = FALSE;
    else
       result = TRUE;
@@ -244,7 +248,7 @@ debug_get_flags_option(const char *name,
    else {
       result = 0;
       while( flags->name ) {
-        if (!strcmp(str, "all") || strstr(str, flags->name ))
+        if (!util_strcmp(str, "all") || util_strstr(str, flags->name ))
            result |= flags->value;
         ++flags;
       }
@@ -299,10 +303,10 @@ debug_dump_flags(const struct debug_named_value *names,
    while(names->name) {
       if((names->value & value) == names->value) {
         if (!first)
-           strncat(output, "|", sizeof(output));
+           util_strncat(output, "|", sizeof(output));
         else
            first = 0;
-        strncat(output, names->name, sizeof(output));
+        util_strncat(output, names->name, sizeof(output));
         value &= ~names->value;
       }
       ++names;
@@ -310,12 +314,12 @@ debug_dump_flags(const struct debug_named_value *names,
    
    if (value) {
       if (!first)
-        strncat(output, "|", sizeof(output));
+        util_strncat(output, "|", sizeof(output));
       else
         first = 0;
       
       util_snprintf(rest, sizeof(rest), "0x%08lx", value);
-      strncat(output, rest, sizeof(output));
+      util_strncat(output, rest, sizeof(output));
    }
    
    if(first)
@@ -325,101 +329,159 @@ debug_dump_flags(const struct debug_named_value *names,
 }
 
 
+static const struct debug_named_value pipe_format_names[] = {
+#ifdef DEBUG
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_NONE),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_A8R8G8B8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_X8R8G8B8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_B8G8R8A8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_B8G8R8X8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_A1R5G5B5_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_A4R4G4B4_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R5G6B5_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_L8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_A8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_I8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_A8L8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_YCBCR),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_YCBCR_REV),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_Z16_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_Z32_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_Z32_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_S8Z24_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_Z24S8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_X8Z24_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_Z24X8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_S8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R64_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R64G64_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R64G64B64_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R64G64B64A64_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32A32_FLOAT),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32A32_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32A32_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32A32_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R32G32B32A32_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16A16_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16A16_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16A16_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R16G16B16A16_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8A8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8X8_UNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8A8_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8X8_USCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8A8_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8X8_SNORM),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8A8_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8X8_SSCALED),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_L8_SRGB),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_A8_L8_SRGB),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8_SRGB),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8A8_SRGB),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_R8G8B8X8_SRGB),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_DXT1_RGB),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_DXT1_RGBA),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_DXT3_RGBA),
+   DEBUG_NAMED_VALUE(PIPE_FORMAT_DXT5_RGBA),
+#endif
+   DEBUG_NAMED_VALUE_END
+};
 
-
-
+#ifdef DEBUG
+void debug_print_format(const char *msg, unsigned fmt )
+{
+   debug_printf("%s: %s\n", msg, debug_dump_enum(pipe_format_names, fmt)); 
+}
+#endif
 
 char *pf_sprint_name( char *str, enum pipe_format format )
 {
-   strcpy( str, "PIPE_FORMAT_" );
-   switch (pf_layout( format )) {
-   case PIPE_FORMAT_LAYOUT_RGBAZS:
-      {
-         pipe_format_rgbazs_t rgbazs = (pipe_format_rgbazs_t) format;
-         uint                 i;
-         uint                 scale = 1 << (pf_exp8( rgbazs ) * 3);
-
-         for (i = 0; i < 4; i++) {
-            uint  size = pf_size_xyzw( rgbazs, i );
-
-            if (size == 0) {
-               break;
-            }
-            switch (pf_swizzle_xyzw( rgbazs, i )) {
-            case PIPE_FORMAT_COMP_R:
-               strcat( str, "R" );
-               break;
-            case PIPE_FORMAT_COMP_G:
-               strcat( str, "G" );
-               break;
-            case PIPE_FORMAT_COMP_B:
-               strcat( str, "B" );
-               break;
-            case PIPE_FORMAT_COMP_A:
-               strcat( str, "A" );
-               break;
-            case PIPE_FORMAT_COMP_0:
-               strcat( str, "0" );
-               break;
-            case PIPE_FORMAT_COMP_1:
-               strcat( str, "1" );
-               break;
-            case PIPE_FORMAT_COMP_Z:
-               strcat( str, "Z" );
-               break;
-            case PIPE_FORMAT_COMP_S:
-               strcat( str, "S" );
-               break;
-            }
-            util_snprintf( &str[strlen( str )], 32, "%u", size * scale );
-         }
-         if (i != 0) {
-            strcat( str, "_" );
-         }
-         switch (pf_type( rgbazs )) {
-         case PIPE_FORMAT_TYPE_UNKNOWN:
-            strcat( str, "NONE" );
-            break;
-         case PIPE_FORMAT_TYPE_FLOAT:
-            strcat( str, "FLOAT" );
-            break;
-         case PIPE_FORMAT_TYPE_UNORM:
-            strcat( str, "UNORM" );
-            break;
-         case PIPE_FORMAT_TYPE_SNORM:
-            strcat( str, "SNORM" );
-            break;
-         case PIPE_FORMAT_TYPE_USCALED:
-            strcat( str, "USCALED" );
-            break;
-         case PIPE_FORMAT_TYPE_SSCALED:
-            strcat( str, "SSCALED" );
-            break;
-         }
-      }
-      break;
-   case PIPE_FORMAT_LAYOUT_YCBCR:
-      {
-         pipe_format_ycbcr_t  ycbcr = (pipe_format_ycbcr_t) format;
-
-         strcat( str, "YCBCR" );
-         if (pf_rev( ycbcr )) {
-            strcat( str, "_REV" );
-         }
-      }
-      break;
-   }
+   strcpy( str, debug_dump_enum(pipe_format_names, format) );
    return str;
 }
 
 
 #ifdef DEBUG
-void debug_print_format(const char *msg, unsigned fmt )
+void debug_dump_image(const char *prefix,
+                      unsigned format, unsigned cpp,
+                      unsigned width, unsigned height,
+                      unsigned pitch,
+                      const void *data)     
 {
-   char fmtstr[80];
-   pf_sprint_name(fmtstr, (enum pipe_format)fmt);
+#ifdef PIPE_SUBSYSTEM_WINDOWS_DISPLAY
+   static unsigned no = 0; 
+   char filename[256];
+   WCHAR wfilename[sizeof(filename)];
+   ULONG_PTR iFile = 0;
+   struct {
+      unsigned format;
+      unsigned cpp;
+      unsigned width;
+      unsigned height;
+   } header;
+   unsigned char *pMap = NULL;
+   unsigned i;
 
-   debug_printf("%s: %s\n", msg, fmtstr); 
+   util_snprintf(filename, sizeof(filename), "\\??\\c:\\%03u%s.raw", ++no, prefix);
+   for(i = 0; i < sizeof(filename); ++i)
+      wfilename[i] = (WCHAR)filename[i];
+   
+   pMap = (unsigned char *)EngMapFile(wfilename, sizeof(header) + cpp*width*height, &iFile);
+   if(!pMap)
+      return;
+   
+   header.format = format;
+   header.cpp = cpp;
+   header.width = width;
+   header.height = height;
+   memcpy(pMap, &header, sizeof(header));
+   pMap += sizeof(header);
+   
+   for(i = 0; i < height; ++i) {
+      memcpy(pMap, (unsigned char *)data + cpp*pitch*i, cpp*width);
+      pMap += cpp*width;
+   }
+      
+   EngUnmapFile(iFile);
+#endif
 }
 #endif
index 3b5e4fbaeea9539f757408448878eab4d7c18f4c..78497c5f6af8b29253b6fac9f66409a4636cee04 100644 (file)
@@ -211,6 +211,7 @@ debug_memory_begin(void)
 void 
 debug_memory_end(unsigned long start_no)
 {
+   size_t total_size = 0;
    struct list_head *entry;
 
    entry = list.prev;
@@ -220,9 +221,15 @@ debug_memory_end(unsigned long start_no)
       hdr = LIST_ENTRY(struct debug_memory_header, entry, head);
       ptr = data_from_header(hdr);
       if(start_no <= hdr->no && hdr->no < last_no ||
-        last_no < start_no && (hdr->no < last_no || start_no <= hdr->no))
+        last_no < start_no && (hdr->no < last_no || start_no <= hdr->no)) {
         debug_printf("%s:%u:%s: %u bytes at %p not freed\n",
                      hdr->file, hdr->line, hdr->function,
                      hdr->size, ptr);
+        total_size += hdr->size;
+      }
+   }
+   if(total_size) {
+      debug_printf("Total of %u KB of system memory apparently leaked\n",
+                  (total_size + 1023)/1024);
    }
 }
diff --git a/src/gallium/auxiliary/util/p_debug_prof.c b/src/gallium/auxiliary/util/p_debug_prof.c
new file mode 100644 (file)
index 0000000..958f99c
--- /dev/null
@@ -0,0 +1,175 @@
+/**************************************************************************
+ * 
+ * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
+ * All Rights Reserved.
+ * 
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ * 
+ **************************************************************************/
+
+/**
+ * @file
+ * Poor-man profiling.
+ * 
+ * @author José Fonseca <jrfonseca@tungstengraphics.com>
+ * 
+ * @sa http://blogs.msdn.com/joshpoley/archive/2008/03/12/poor-man-s-profiler.aspx
+ * @sa http://www.johnpanzer.com/aci_cuj/index.html
+ */
+
+#include "pipe/p_config.h" 
+
+#if defined(PROFILE) && defined(PIPE_SUBSYSTEM_WINDOWS_DISPLAY)
+
+#include <windows.h>
+#include <winddi.h>
+
+#include "pipe/p_debug.h" 
+#include "util/u_string.h" 
+
+
+#define PROFILE_FILE_SIZE 4*1024*1024
+#define FILE_NAME_SIZE 256
+
+static WCHAR wFileName[FILE_NAME_SIZE];
+static ULONG_PTR iFile = 0;
+static void *pMap = NULL;
+static void *pMapEnd = NULL;
+
+
+/**
+ * Called at the start of every method or function.
+ * 
+ * @sa http://msdn.microsoft.com/en-us/library/c63a9b7h.aspx
+ */
+void __declspec(naked) __cdecl 
+_penter(void) {
+   _asm {
+      push ebx
+      mov ebx, [pMap]
+      test ebx, ebx
+      jz done
+      cmp ebx, [pMapEnd]
+      je done
+      push eax
+      push edx
+      mov eax, [esp+12]
+      and eax, 0xfffffffe
+      mov [ebx], eax
+      add ebx, 4
+      rdtsc
+      mov [ebx], eax
+      add ebx, 4
+      mov [pMap], ebx
+      pop edx
+      pop eax
+done:
+      pop ebx
+      ret  
+   }
+}
+
+
+/**
+ * Called at the end of Calls the end of every method or function.
+ * 
+ * @sa http://msdn.microsoft.com/en-us/library/xc11y76y.aspx
+ */
+void __declspec(naked) __cdecl 
+_pexit(void) {
+   _asm {
+      push ebx
+      mov ebx, [pMap]
+      test ebx, ebx
+      jz done
+      cmp ebx, [pMapEnd]
+      je done
+      push eax
+      push edx
+      mov eax, [esp+12]
+      or eax, 0x00000001
+      mov [ebx], eax
+      add ebx, 4
+      rdtsc
+      mov [ebx], eax
+      add ebx, 4
+      mov [pMap], ebx
+      pop edx
+      pop eax
+done:
+      pop ebx
+      ret
+   }
+}
+
+
+void __declspec(naked) 
+__debug_profile_reference1(void) {
+   _asm {
+      call _penter
+      call _pexit
+      ret
+   }
+}
+
+
+void __declspec(naked) 
+__debug_profile_reference2(void) {
+   _asm {
+      call _penter
+      call __debug_profile_reference1
+      call _pexit
+      ret
+   }
+}
+
+
+void
+debug_profile_start(void)
+{
+   static unsigned no = 0; 
+   char filename[FILE_NAME_SIZE];
+   unsigned i;
+
+   util_snprintf(filename, sizeof(filename), "\\??\\c:\\%03u.prof", ++no);
+   for(i = 0; i < FILE_NAME_SIZE; ++i)
+      wFileName[i] = (WCHAR)filename[i];
+   
+   pMap = EngMapFile(wFileName, PROFILE_FILE_SIZE, &iFile);
+   if(pMap) {
+      pMapEnd = (unsigned char*)pMap + PROFILE_FILE_SIZE;
+      /* reference functions for calibration purposes */
+      __debug_profile_reference2();
+   }
+}
+
+void 
+debug_profile_stop(void)
+{
+   if(iFile) {
+      EngUnmapFile(iFile);
+      /* TODO: truncate file */
+   }
+   iFile = 0;
+   pMapEnd = pMap = NULL; 
+}
+
+#endif /* PROFILE */
index 63e1cc6013a82dac2e5bd076154ff9ab812adfae..5728757d2fb492a2f98a15cdc070eb9a2367cb67 100644 (file)
@@ -50,6 +50,7 @@ pipe_get_tile_raw(struct pipe_context *pipe,
                   uint x, uint y, uint w, uint h,
                   void *p, int dst_stride)
 {
+   struct pipe_screen *screen = pipe->screen;
    const uint cpp = ps->cpp;
    const ubyte *pSrc;
    const uint src_stride = ps->pitch * cpp;
@@ -63,7 +64,11 @@ pipe_get_tile_raw(struct pipe_context *pipe,
    if (pipe_clip_tile(x, y, &w, &h, ps))
       return;
 
-   pSrc = (const ubyte *) pipe_surface_map(ps) + (y * ps->pitch + x) * cpp;
+   pSrc = (const ubyte *) screen->surface_map(screen, ps,
+                                              PIPE_BUFFER_USAGE_CPU_READ);
+   assert(pSrc);                /* XXX: proper error handling! */
+
+   pSrc += (y * ps->pitch + x) * cpp;
    pDest = (ubyte *) p;
 
    for (i = 0; i < h; i++) {
@@ -72,7 +77,7 @@ pipe_get_tile_raw(struct pipe_context *pipe,
       pSrc += src_stride;
    }
 
-   pipe_surface_unmap(ps);
+   screen->surface_unmap(screen, ps);
 }
 
 
@@ -86,6 +91,7 @@ pipe_put_tile_raw(struct pipe_context *pipe,
                   uint x, uint y, uint w, uint h,
                   const void *p, int src_stride)
 {
+   struct pipe_screen *screen = pipe->screen;
    const uint cpp = ps->cpp;
    const ubyte *pSrc;
    const uint dst_stride = ps->pitch * cpp;
@@ -100,7 +106,11 @@ pipe_put_tile_raw(struct pipe_context *pipe,
       return;
 
    pSrc = (const ubyte *) p;
-   pDest = (ubyte *) pipe_surface_map(ps) + (y * ps->pitch + x) * cpp;
+
+   pDest = screen->surface_map(screen, ps, PIPE_BUFFER_USAGE_CPU_WRITE);
+   assert(pDest);               /* XXX: proper error handling */
+
+   pDest += (y * ps->pitch + x) * cpp;
 
    for (i = 0; i < h; i++) {
       memcpy(pDest, pSrc, w * cpp);
@@ -108,7 +118,7 @@ pipe_put_tile_raw(struct pipe_context *pipe,
       pSrc += src_stride;
    }
 
-   pipe_surface_unmap(ps);
+   screen->surface_unmap(screen, ps);
 }
 
 
@@ -834,18 +844,26 @@ pipe_get_tile_z(struct pipe_context *pipe,
                 uint x, uint y, uint w, uint h,
                 uint *z)
 {
+   struct pipe_screen *screen = pipe->screen;
    const uint dstStride = w;
+   void *map;
    uint *pDest = z;
    uint i, j;
 
    if (pipe_clip_tile(x, y, &w, &h, ps))
       return;
 
+   map = screen->surface_map(screen, ps, PIPE_BUFFER_USAGE_CPU_READ);
+   if (!map) {
+      assert(0);
+      return;
+   }
+
    switch (ps->format) {
    case PIPE_FORMAT_Z32_UNORM:
       {
          const uint *pSrc
-            = (const uint *) pipe_surface_map(ps) + (y * ps->pitch + x);
+            = (const uint *)map  + (y * ps->pitch + x);
          for (i = 0; i < h; i++) {
             memcpy(pDest, pSrc, 4 * w);
             pDest += dstStride;
@@ -857,7 +875,7 @@ pipe_get_tile_z(struct pipe_context *pipe,
    case PIPE_FORMAT_X8Z24_UNORM:
       {
          const uint *pSrc
-            = (const uint *) pipe_surface_map(ps) + (y * ps->pitch + x);
+            = (const uint *)map + (y * ps->pitch + x);
          for (i = 0; i < h; i++) {
             for (j = 0; j < w; j++) {
                /* convert 24-bit Z to 32-bit Z */
@@ -871,7 +889,7 @@ pipe_get_tile_z(struct pipe_context *pipe,
    case PIPE_FORMAT_Z16_UNORM:
       {
          const ushort *pSrc
-            = (const ushort *) pipe_surface_map(ps) + (y * ps->pitch + x);
+            = (const ushort *)map + (y * ps->pitch + x);
          for (i = 0; i < h; i++) {
             for (j = 0; j < w; j++) {
                /* convert 16-bit Z to 32-bit Z */
@@ -886,7 +904,7 @@ pipe_get_tile_z(struct pipe_context *pipe,
       assert(0);
    }
 
-   pipe_surface_unmap(ps);
+   screen->surface_unmap(screen, ps);
 }
 
 
@@ -896,17 +914,25 @@ pipe_put_tile_z(struct pipe_context *pipe,
                 uint x, uint y, uint w, uint h,
                 const uint *zSrc)
 {
+   struct pipe_screen *screen = pipe->screen;
    const uint srcStride = w;
    const uint *pSrc = zSrc;
+   void *map;
    uint i, j;
 
    if (pipe_clip_tile(x, y, &w, &h, ps))
       return;
 
+   map = screen->surface_map(screen, ps, PIPE_BUFFER_USAGE_CPU_WRITE);
+   if (!map) {
+      assert(0);
+      return;
+   }
+
    switch (ps->format) {
    case PIPE_FORMAT_Z32_UNORM:
       {
-         uint *pDest = (uint *) pipe_surface_map(ps) + (y * ps->pitch + x);
+         uint *pDest = (uint *) map + (y * ps->pitch + x);
          for (i = 0; i < h; i++) {
             memcpy(pDest, pSrc, 4 * w);
             pDest += ps->pitch;
@@ -917,7 +943,7 @@ pipe_put_tile_z(struct pipe_context *pipe,
    case PIPE_FORMAT_S8Z24_UNORM:
    case PIPE_FORMAT_X8Z24_UNORM:
       {
-         uint *pDest = (uint *) pipe_surface_map(ps) + (y * ps->pitch + x);
+         uint *pDest = (uint *) map + (y * ps->pitch + x);
          for (i = 0; i < h; i++) {
             for (j = 0; j < w; j++) {
                /* convert 32-bit Z to 24-bit Z (0 stencil) */
@@ -930,7 +956,7 @@ pipe_put_tile_z(struct pipe_context *pipe,
       break;
    case PIPE_FORMAT_Z16_UNORM:
       {
-         ushort *pDest = (ushort *) pipe_surface_map(ps) + (y * ps->pitch + x);
+         ushort *pDest = (ushort *) map + (y * ps->pitch + x);
          for (i = 0; i < h; i++) {
             for (j = 0; j < w; j++) {
                /* convert 32-bit Z to 16-bit Z */
@@ -945,7 +971,7 @@ pipe_put_tile_z(struct pipe_context *pipe,
       assert(0);
    }
 
-   pipe_surface_unmap(ps);
+   screen->surface_unmap(screen, ps);
 }
 
 
index 568d62ced190bf2dc48e39d86079f33902b6f922..999a3e50995e929aaf66601d9b04727d85f55855 100644 (file)
@@ -287,7 +287,8 @@ util_blit_pixels(struct blit_state *ctx,
    if (!tex)
       return;
 
-   texSurf = screen->get_tex_surface(screen, tex, 0, 0, 0);
+   texSurf = screen->get_tex_surface(screen, tex, 0, 0, 0, 
+                                     PIPE_BUFFER_USAGE_GPU_WRITE);
 
    /* load temp texture */
    pipe->surface_copy(pipe, FALSE,
@@ -295,7 +296,9 @@ util_blit_pixels(struct blit_state *ctx,
                       src, srcLeft, srcTop, /* src */
                       srcW, srcH);     /* size */
 
-   pipe->texture_update(pipe, tex, 0, 1 << 0);
+   /* free the surface, update the texture if necessary.
+    */
+   screen->tex_surface_release(screen, &texSurf);
 
    /* save state (restored below) */
    cso_save_blend(ctx->cso);
@@ -356,8 +359,6 @@ util_blit_pixels(struct blit_state *ctx,
    cso_restore_vertex_shader(ctx->cso);
    cso_restore_viewport(ctx->cso);
 
-   /* free the texture */
-   pipe_surface_reference(&texSurf, NULL);
    screen->texture_release(screen, &tex);
 }
 
index e659edb0881013ce4a24eb3b905ccc73f8fa04c2..bf143815d8b762442df0dc3948ee964c124f69a7 100644 (file)
@@ -82,52 +82,51 @@ util_draw_texquad(struct pipe_context *pipe,
 {
    struct pipe_buffer *vbuf;
    uint numAttribs = 2, vertexBytes, i, j;
-   float *v;
 
    vertexBytes = 4 * (4 * numAttribs * sizeof(float));
 
    /* XXX create one-time */
    vbuf = pipe->winsys->buffer_create(pipe->winsys, 32,
                                       PIPE_BUFFER_USAGE_VERTEX, vertexBytes);
-   assert(vbuf);
-
-   v = (float *) pipe->winsys->buffer_map(pipe->winsys, vbuf,
-                                          PIPE_BUFFER_USAGE_CPU_WRITE);
-
-   /*
-    * Load vertex buffer
-    */
-   for (i = j = 0; i < 4; i++) {
-      v[j + 2] = z;   /* z */
-      v[j + 3] = 1.0; /* w */
-      v[j + 6] = 0.0; /* r */
-      v[j + 7] = 1.0; /* q */
-      j += 8;
+   if (vbuf) {
+      float *v = (float *) pipe->winsys->buffer_map(pipe->winsys, vbuf,
+                                             PIPE_BUFFER_USAGE_CPU_WRITE);
+      if (v) {
+         /*
+          * Load vertex buffer
+          */
+         for (i = j = 0; i < 4; i++) {
+            v[j + 2] = z;   /* z */
+            v[j + 3] = 1.0; /* w */
+            v[j + 6] = 0.0; /* r */
+            v[j + 7] = 1.0; /* q */
+            j += 8;
+         }
+
+         v[0] = x0;
+         v[1] = y0;
+         v[4] = 0.0; /*s*/
+         v[5] = 0.0; /*t*/
+
+         v[8] = x1;
+         v[9] = y0;
+         v[12] = 1.0;
+         v[13] = 0.0;
+
+         v[16] = x1;
+         v[17] = y1;
+         v[20] = 1.0;
+         v[21] = 1.0;
+
+         v[24] = x0;
+         v[25] = y1;
+         v[28] = 0.0;
+         v[29] = 1.0;
+
+         pipe->winsys->buffer_unmap(pipe->winsys, vbuf);
+         util_draw_vertex_buffer(pipe, vbuf, PIPE_PRIM_TRIANGLE_FAN, 4, 2);
+      }
+
+      pipe_buffer_reference(pipe->winsys, &vbuf, NULL);
    }
-
-   v[0] = x0;
-   v[1] = y0;
-   v[4] = 0.0; /*s*/
-   v[5] = 0.0; /*t*/
-
-   v[8] = x1;
-   v[9] = y0;
-   v[12] = 1.0;
-   v[13] = 0.0;
-
-   v[16] = x1;
-   v[17] = y1;
-   v[20] = 1.0;
-   v[21] = 1.0;
-
-   v[24] = x0;
-   v[25] = y1;
-   v[28] = 0.0;
-   v[29] = 1.0;
-
-   pipe->winsys->buffer_unmap(pipe->winsys, vbuf);
-
-   util_draw_vertex_buffer(pipe, vbuf, PIPE_PRIM_TRIANGLE_FAN, 4, 2);
-
-   pipe_buffer_reference(pipe->winsys, &vbuf, NULL);
 }
index c53c51226818b54c839d5d8824ff4340923e41d8..7d71aefda9d88eb047c61a11c120733a626974f0 100644 (file)
@@ -589,8 +589,11 @@ make_1d_mipmap(struct gen_mipmap_state *ctx,
       struct pipe_surface *srcSurf, *dstSurf;
       void *srcMap, *dstMap;
       
-      srcSurf = screen->get_tex_surface(screen, pt, face, srcLevel, zslice);
-      dstSurf = screen->get_tex_surface(screen, pt, face, dstLevel, zslice);
+      srcSurf = screen->get_tex_surface(screen, pt, face, srcLevel, zslice,
+                                        PIPE_BUFFER_USAGE_CPU_READ);
+
+      dstSurf = screen->get_tex_surface(screen, pt, face, dstLevel, zslice,
+                                        PIPE_BUFFER_USAGE_CPU_WRITE);
 
       srcMap = ((ubyte *) winsys->buffer_map(winsys, srcSurf->buffer,
                                             PIPE_BUFFER_USAGE_CPU_READ)
@@ -629,8 +632,10 @@ make_2d_mipmap(struct gen_mipmap_state *ctx,
       struct pipe_surface *srcSurf, *dstSurf;
       ubyte *srcMap, *dstMap;
       
-      srcSurf = screen->get_tex_surface(screen, pt, face, srcLevel, zslice);
-      dstSurf = screen->get_tex_surface(screen, pt, face, dstLevel, zslice);
+      srcSurf = screen->get_tex_surface(screen, pt, face, srcLevel, zslice,
+                                        PIPE_BUFFER_USAGE_CPU_READ);
+      dstSurf = screen->get_tex_surface(screen, pt, face, dstLevel, zslice,
+                                        PIPE_BUFFER_USAGE_CPU_WRITE);
 
       srcMap = ((ubyte *) winsys->buffer_map(winsys, srcSurf->buffer,
                                             PIPE_BUFFER_USAGE_CPU_READ)
@@ -891,10 +896,14 @@ util_gen_mipmap(struct gen_mipmap_state *ctx,
    for (dstLevel = baseLevel + 1; dstLevel <= lastLevel; dstLevel++) {
       const uint srcLevel = dstLevel - 1;
 
+      struct pipe_surface *surf = 
+         screen->get_tex_surface(screen, pt, face, dstLevel, zslice,
+                                 PIPE_BUFFER_USAGE_GPU_WRITE);
+
       /*
        * Setup framebuffer / dest surface
        */
-      fb.cbufs[0] = screen->get_tex_surface(screen, pt, face, dstLevel, zslice);
+      fb.cbufs[0] = surf;
       fb.width = pt->width[dstLevel];
       fb.height = pt->height[dstLevel];
       cso_set_framebuffer(ctx->cso, &fb);
@@ -925,7 +934,7 @@ util_gen_mipmap(struct gen_mipmap_state *ctx,
       pipe->flush(pipe, PIPE_FLUSH_RENDER_CACHE, NULL);
 
       /* need to signal that the texture has changed _after_ rendering to it */
-      pipe->texture_update(pipe, pt, face, (1 << dstLevel));
+      pipe_surface_reference( &surf, NULL );
    }
 
    /* restore state we changed */
index f3f16a8d94f606f437f365927de4062a7addece8..dd5eca7fca357811d2fecf47a9f9d4ce5673df9e 100644 (file)
@@ -67,6 +67,13 @@ struct hash_table_item
 };
 
 
+static INLINE struct hash_table_item *
+hash_table_item(struct cso_hash_iter iter)
+{
+   return (struct hash_table_item *)cso_hash_iter_data(iter);
+}
+
+
 struct hash_table *
 hash_table_create(unsigned (*hash)(void *key),
                   int (*compare)(void *key1, void *key2))
@@ -90,7 +97,27 @@ hash_table_create(unsigned (*hash)(void *key),
 }
 
 
-static struct hash_table_item *
+static INLINE struct cso_hash_iter
+hash_table_find_iter(struct hash_table *ht,
+                     void *key, 
+                     unsigned key_hash)
+{
+   struct cso_hash_iter iter;
+   struct hash_table_item *item;
+   
+   iter = cso_hash_find(ht->cso, key_hash);
+   while (!cso_hash_iter_is_null(iter)) {
+      item = (struct hash_table_item *)cso_hash_iter_data(iter);
+      if (!ht->compare(item->key, key))
+         break;
+      iter = cso_hash_iter_next(iter);
+   }
+   
+   return iter;
+}
+
+
+static INLINE struct hash_table_item *
 hash_table_find_item(struct hash_table *ht,
                      void *key, 
                      unsigned key_hash)
@@ -117,6 +144,7 @@ hash_table_set(struct hash_table *ht,
 {
    unsigned key_hash;
    struct hash_table_item *item;
+   struct cso_hash_iter iter;
 
    assert(ht);
 
@@ -136,9 +164,8 @@ hash_table_set(struct hash_table *ht,
    item->key = key;
    item->value = value;
    
-   cso_hash_insert(ht->cso, key_hash, item);
-   /* FIXME: there is no OOM propagation in cso_hash */
-   if(0) {
+   iter = cso_hash_insert(ht->cso, key_hash, item);
+   if(cso_hash_iter_is_null(iter)) {
       FREE(item);
       return PIPE_ERROR_OUT_OF_MEMORY;
    }
@@ -171,19 +198,39 @@ hash_table_remove(struct hash_table *ht,
                   void *key)
 {
    unsigned key_hash;
+   struct cso_hash_iter iter;
    struct hash_table_item *item;
 
    assert(ht);
 
    key_hash = ht->hash(key);
 
-   item = hash_table_find_item(ht, key, key_hash);
-   if(!item)
+   iter = hash_table_find_iter(ht, key, key_hash);
+   if(cso_hash_iter_is_null(iter))
       return;
    
-   /* FIXME: cso_hash_take takes the first element of the collision list 
-    * indiscriminately, so we can not take the item down. */
-   item->value = NULL;
+   item = hash_table_item(iter);
+   assert(item);
+   FREE(item);
+   
+   cso_hash_erase(ht->cso, iter);
+}
+
+
+void 
+hash_table_clear(struct hash_table *ht)
+{
+   struct cso_hash_iter iter;
+   struct hash_table_item *item;
+
+   assert(ht);
+   
+   iter = cso_hash_first_node(ht->cso);
+   while (!cso_hash_iter_is_null(iter)) {
+      item = (struct hash_table_item *)cso_hash_take(ht->cso, cso_hash_iter_key(iter));
+      FREE(item);
+      iter = cso_hash_first_node(ht->cso);
+   }
 }
 
 
@@ -196,6 +243,8 @@ hash_table_foreach(struct hash_table *ht,
    struct hash_table_item *item;
    enum pipe_error result;
    
+   assert(ht);
+   
    iter = cso_hash_first_node(ht->cso);
    while (!cso_hash_iter_is_null(iter)) {
       item = (struct hash_table_item *)cso_hash_iter_data(iter);
@@ -212,7 +261,17 @@ hash_table_foreach(struct hash_table *ht,
 void
 hash_table_destroy(struct hash_table *ht)
 {
+   struct cso_hash_iter iter;
+   struct hash_table_item *item;
+   
    assert(ht);
+   
+   iter = cso_hash_first_node(ht->cso);
+   while (!cso_hash_iter_is_null(iter)) {
+      item = (struct hash_table_item *)cso_hash_iter_data(iter);
+      FREE(item);
+      iter = cso_hash_iter_next(iter);
+   }
 
    cso_hash_delete(ht->cso);
    
index 1583bd7548c32b3be9d8680f5adc75a0da5fdc32..feee881582e1b891d456fcdc0be82d5bf917dbb0 100644 (file)
@@ -75,6 +75,10 @@ hash_table_remove(struct hash_table *ht,
                   void *key);
 
 
+void
+hash_table_clear(struct hash_table *ht);
+
+
 enum pipe_error
 hash_table_foreach(struct hash_table *ht,
                    enum pipe_error (*callback)(void *key, void *value, void *data),
index 0b917c005f1526b0a8c8770ec0db0f1bdcff154d..655e2c825925e6bc89db6c032650186fbb42c169 100644 (file)
@@ -101,6 +101,19 @@ util_pack_color_ub(ubyte r, ubyte g, ubyte b, ubyte a,
          *d = ((a & 0xf0) << 8) | ((r & 0xf0) << 4) | ((g & 0xf0) << 0) | (b >> 4);
       }
       return;
+   case PIPE_FORMAT_A8_UNORM:
+      {
+         ubyte *d = (ubyte *) dest;
+         *d = a;
+      }
+      return;
+   case PIPE_FORMAT_L8_UNORM:
+   case PIPE_FORMAT_I8_UNORM:
+      {
+         ubyte *d = (ubyte *) dest;
+         *d = r;
+      }
+      return;
    case PIPE_FORMAT_R32G32B32A32_FLOAT:
       {
          float *d = (float *) dest;
@@ -198,6 +211,19 @@ util_pack_color(const float rgba[4], enum pipe_format format, void *dest)
          *d = ((a & 0xf0) << 8) | ((r & 0xf0) << 4) | ((g & 0xf0) << 0) | (b >> 4);
       }
       return;
+   case PIPE_FORMAT_A8_UNORM:
+      {
+         ubyte *d = (ubyte *) dest;
+         *d = a;
+      }
+      return;
+   case PIPE_FORMAT_L8_UNORM:
+   case PIPE_FORMAT_I8_UNORM:
+      {
+         ubyte *d = (ubyte *) dest;
+         *d = r;
+      }
+      return;
    case PIPE_FORMAT_R32G32B32A32_FLOAT:
       {
          float *d = (float *) dest;
index b99d4e8021cbb479521a46709365a47d11596b60..73c88d87b4c643c79d815ea674813b6a5b3f2cc3 100644 (file)
@@ -41,6 +41,8 @@
 #include <stddef.h>
 #include <stdarg.h>
 
+#include "pipe/p_compiler.h"
+
 
 #ifdef __cplusplus
 extern "C" {
@@ -48,11 +50,129 @@ extern "C" {
 
    
 #ifdef WIN32
+   
 int util_vsnprintf(char *, size_t, const char *, va_list);
 int util_snprintf(char *str, size_t size, const char *format, ...);
+
+static INLINE void 
+util_vsprintf(char *str, const char *format, va_list ap)
+{
+   util_vsnprintf(str, (size_t)-1, format, ap);
+}
+
+static INLINE void 
+util_sprintf(char *str, const char *format, ...)
+{
+   va_list ap;
+   va_start(ap, format);
+   util_vsnprintf(str, (size_t)-1, format, ap);
+   va_end(ap);
+}
+
+static INLINE char *
+util_strchr(const char *s, char c)
+{
+   while(*s) {
+      if(*s == c)
+        return (char *)s;
+      ++s;
+   }
+   return NULL;
+}
+
+static INLINE char*
+util_strncat(char *dst, const char *src, size_t n)
+{
+   char *p = dst + strlen(dst);
+   const char *q = src;
+   size_t i;
+
+   for (i = 0; i < n && *q != '\0'; ++i)
+       *p++ = *q++;
+   *p = '\0';
+
+   return dst;
+}
+
+static INLINE int
+util_strcmp(const char *s1, const char *s2)
+{
+   unsigned char u1, u2;
+
+   while (1) {
+      u1 = (unsigned char) *s1++;
+      u2 = (unsigned char) *s2++;
+      if (u1 != u2)
+        return u1 - u2;
+      if (u1 == '\0')
+        return 0;
+   }
+   return 0;
+}
+
+static INLINE int
+util_strncmp(const char *s1, const char *s2, size_t n)
+{
+   unsigned char u1, u2;
+
+   while (n-- > 0) {
+      u1 = (unsigned char) *s1++;
+      u2 = (unsigned char) *s2++;
+      if (u1 != u2)
+        return u1 - u2;
+      if (u1 == '\0')
+        return 0;
+   }
+   return 0;
+}
+
+static INLINE char *
+util_strstr(const char *haystack, const char *needle)
+{
+   const char *p = haystack;
+   int len = strlen(needle);
+
+   for (; (p = util_strchr(p, *needle)) != 0; p++) {
+      if (util_strncmp(p, needle, len) == 0) {
+        return (char *)p;
+      }
+   }
+   return NULL;
+}
+
+static INLINE void *
+util_memmove(void *dest, const void *src, size_t n)
+{
+   char *p = (char *)dest;
+   const char *q = (const char *)src;
+   if (dest < src) {
+      while (n--)
+        *p++ = *q++;
+   }
+   else
+   {
+      p += n;
+      q += n;
+      while (n--)
+        *--p = *--q;
+   }
+   return dest;
+}
+
+
 #else
+
 #define util_vsnprintf vsnprintf
 #define util_snprintf snprintf
+#define util_vsprintf vsprintf
+#define util_sprintf sprintf
+#define util_strchr strchr
+#define util_strcmp strcmp
+#define util_strncmp strncmp
+#define util_strncat strncat
+#define util_strstr strstr
+#define util_memmove memmove
+
 #endif
 
 
index cb95ba516f905b09cecc9f7c1c4cb96d22523f15..014a3e31d5055a3cb27792a609f60264380aa7b8 100644 (file)
@@ -147,8 +147,8 @@ struct pipe_context *failover_create( struct pipe_context *hw,
    failover->pipe.texture_create = hw->texture_create;
    failover->pipe.texture_release = hw->texture_release;
    failover->pipe.get_tex_surface = hw->get_tex_surface;
-#endif
    failover->pipe.texture_update = hw->texture_update;
+#endif
 
    failover->pipe.flush = hw->flush;
 
index 38e6a348845a13c0c63d248c6e33f692477ac6ff..53fc5ed0795c4144c6ed988db1bbdf9fdaeb5e28 100644 (file)
- /**************************************************************************\r
- * \r
- * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.\r
- * All Rights Reserved.\r
- * \r
- * Permission is hereby granted, free of charge, to any person obtaining a\r
- * copy of this software and associated documentation files (the\r
- * "Software"), to deal in the Software without restriction, including\r
- * without limitation the rights to use, copy, modify, merge, publish,\r
- * distribute, sub license, and/or sell copies of the Software, and to\r
- * permit persons to whom the Software is furnished to do so, subject to\r
- * the following conditions:\r
- * \r
- * The above copyright notice and this permission notice (including the\r
- * next paragraph) shall be included in all copies or substantial portions\r
- * of the Software.\r
- * \r
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS\r
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.\r
- * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR\r
- * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\r
- * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\r
- * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\r
- * \r
- **************************************************************************/\r
-\r
-#ifndef I915_CONTEXT_H\r
-#define I915_CONTEXT_H\r
-\r
-\r
-#include "pipe/p_context.h"\r
-#include "pipe/p_defines.h"\r
-#include "pipe/p_state.h"\r
-\r
-#include "draw/draw_vertex.h"\r
-\r
-#include "tgsi/util/tgsi_scan.h"\r
-\r
-\r
-#define I915_TEX_UNITS 8\r
-\r
-#define I915_DYNAMIC_MODES4       0\r
-#define I915_DYNAMIC_DEPTHSCALE_0 1 /* just the header */\r
-#define I915_DYNAMIC_DEPTHSCALE_1 2 \r
-#define I915_DYNAMIC_IAB          3\r
-#define I915_DYNAMIC_BC_0         4 /* just the header */\r
-#define I915_DYNAMIC_BC_1         5\r
-#define I915_DYNAMIC_BFO_0        6 \r
-#define I915_DYNAMIC_BFO_1        7\r
-#define I915_DYNAMIC_STP_0        8 \r
-#define I915_DYNAMIC_STP_1        9 \r
-#define I915_DYNAMIC_SC_ENA_0     10 \r
-#define I915_DYNAMIC_SC_RECT_0    11 \r
-#define I915_DYNAMIC_SC_RECT_1    12 \r
-#define I915_DYNAMIC_SC_RECT_2    13 \r
-#define I915_MAX_DYNAMIC          14\r
-\r
-\r
-#define I915_IMMEDIATE_S0         0\r
-#define I915_IMMEDIATE_S1         1\r
-#define I915_IMMEDIATE_S2         2\r
-#define I915_IMMEDIATE_S3         3\r
-#define I915_IMMEDIATE_S4         4\r
-#define I915_IMMEDIATE_S5         5\r
-#define I915_IMMEDIATE_S6         6\r
-#define I915_IMMEDIATE_S7         7\r
-#define I915_MAX_IMMEDIATE        8\r
-\r
-/* These must mach the order of LI0_STATE_* bits, as they will be used\r
- * to generate hardware packets:\r
- */\r
-#define I915_CACHE_STATIC         0 \r
-#define I915_CACHE_DYNAMIC        1 /* handled specially */\r
-#define I915_CACHE_SAMPLER        2\r
-#define I915_CACHE_MAP            3\r
-#define I915_CACHE_PROGRAM        4\r
-#define I915_CACHE_CONSTANTS      5\r
-#define I915_MAX_CACHE            6\r
-\r
-#define I915_MAX_CONSTANT  32\r
-\r
-\r
-/** See constant_flags[] below */\r
-#define I915_CONSTFLAG_USER 0x1f\r
-\r
-\r
-/**\r
- * Subclass of pipe_shader_state\r
- */\r
-struct i915_fragment_shader\r
-{\r
-   struct pipe_shader_state state;\r
-\r
-   struct tgsi_shader_info info;\r
-\r
-   uint *program;\r
-   uint program_len;\r
-\r
-   /**\r
-    * constants introduced during translation.\r
-    * These are placed at the end of the constant buffer and grow toward\r
-    * the beginning (eg: slot 31, 30 29, ...)\r
-    * User-provided constants start at 0.\r
-    * This allows both types of constants to co-exist (until there's too many)\r
-    * and doesn't require regenerating/changing the fragment program to\r
-    * shuffle constants around.\r
-    */\r
-   uint num_constants;\r
-   float constants[I915_MAX_CONSTANT][4];\r
-\r
-   /**\r
-    * Status of each constant\r
-    * if I915_CONSTFLAG_PARAM, the value must be taken from the corresponding\r
-    * slot of the user's constant buffer. (set by pipe->set_constant_buffer())\r
-    * Else, the bitmask indicates which components are occupied by immediates.\r
-    */\r
-   ubyte constant_flags[I915_MAX_CONSTANT];\r
-};\r
-\r
-\r
-struct i915_cache_context;\r
-\r
-/* Use to calculate differences between state emitted to hardware and\r
- * current driver-calculated state.  \r
- */\r
-struct i915_state \r
-{\r
-   unsigned immediate[I915_MAX_IMMEDIATE];\r
-   unsigned dynamic[I915_MAX_DYNAMIC];\r
-\r
-   float constants[PIPE_SHADER_TYPES][I915_MAX_CONSTANT][4];\r
-   /** number of constants passed in through a constant buffer */\r
-   uint num_user_constants[PIPE_SHADER_TYPES];\r
-\r
-   /* texture sampler state */\r
-   unsigned sampler[I915_TEX_UNITS][3];\r
-   unsigned sampler_enable_flags;\r
-   unsigned sampler_enable_nr;\r
-\r
-   /* texture image buffers */\r
-   unsigned texbuffer[I915_TEX_UNITS][2];\r
-\r
-   /** Describes the current hardware vertex layout */\r
-   struct vertex_info vertex_info;\r
-   \r
-   unsigned id;                        /* track lost context events */\r
-};\r
-\r
-struct i915_blend_state {\r
-   unsigned iab;\r
-   unsigned modes4;\r
-   unsigned LIS5;\r
-   unsigned LIS6;\r
-};\r
-\r
-struct i915_depth_stencil_state {\r
-   unsigned stencil_modes4;\r
-   unsigned bfo[2];\r
-   unsigned stencil_LIS5;\r
-   unsigned depth_LIS6;\r
-};\r
-\r
-struct i915_rasterizer_state {\r
-   int light_twoside : 1;\r
-   unsigned st;\r
-   enum interp_mode color_interp;\r
-\r
-   unsigned LIS4;\r
-   unsigned LIS7;\r
-   unsigned sc[1];\r
-\r
-   const struct pipe_rasterizer_state *templ;\r
-\r
-   union { float f; unsigned u; } ds[2];\r
-};\r
-\r
-struct i915_sampler_state {\r
-   unsigned state[3];\r
-   const struct pipe_sampler_state *templ;\r
-};\r
-\r
-\r
-struct i915_texture {\r
-   struct pipe_texture base;\r
-\r
-   /* Derived from the above:\r
-    */\r
-   unsigned pitch;\r
-   unsigned depth_pitch;          /* per-image on i945? */\r
-   unsigned total_height;\r
-\r
-   unsigned nr_images[PIPE_MAX_TEXTURE_LEVELS];\r
-\r
-   /* Explicitly store the offset of each image for each cube face or\r
-    * depth value.  Pretty much have to accept that hardware formats\r
-    * are going to be so diverse that there is no unified way to\r
-    * compute the offsets of depth/cube images within a mipmap level,\r
-    * so have to store them as a lookup table:\r
-    */\r
-   unsigned *image_offset[PIPE_MAX_TEXTURE_LEVELS];   /**< array [depth] of offsets */\r
-\r
-   /* Includes image offset tables:\r
-    */\r
-   unsigned level_offset[PIPE_MAX_TEXTURE_LEVELS];\r
-\r
-   /* The data is held here:\r
-    */\r
-   struct pipe_buffer *buffer;\r
-};\r
-\r
-struct i915_context\r
-{\r
-   struct pipe_context pipe;\r
-   struct i915_winsys *winsys;\r
-   struct draw_context *draw;\r
-\r
-   /* The most recent drawing state as set by the driver:\r
-    */\r
-   const struct i915_blend_state           *blend;\r
-   const struct i915_sampler_state         *sampler[PIPE_MAX_SAMPLERS];\r
-   const struct i915_depth_stencil_state   *depth_stencil;\r
-   const struct i915_rasterizer_state      *rasterizer;\r
-\r
-   struct i915_fragment_shader *fs;\r
-\r
-   struct pipe_blend_color blend_color;\r
-   struct pipe_clip_state clip;\r
-   struct pipe_constant_buffer constants[PIPE_SHADER_TYPES];\r
-   struct pipe_framebuffer_state framebuffer;\r
-   struct pipe_poly_stipple poly_stipple;\r
-   struct pipe_scissor_state scissor;\r
-   struct i915_texture *texture[PIPE_MAX_SAMPLERS];\r
-   struct pipe_viewport_state viewport;\r
-   struct pipe_vertex_buffer vertex_buffer[PIPE_MAX_ATTRIBS];\r
-\r
-   unsigned dirty;\r
-\r
-   unsigned num_samplers;\r
-   unsigned num_textures;\r
-   unsigned num_vertex_elements;\r
-   unsigned num_vertex_buffers;\r
-\r
-   unsigned *batch_start;\r
-\r
-   /** Vertex buffer */\r
-   struct pipe_buffer *vbo;\r
-\r
-   struct i915_state current;\r
-   unsigned hardware_dirty;\r
-   \r
-   unsigned debug;\r
-};\r
-\r
-/* A flag for each state_tracker state object:\r
- */\r
-#define I915_NEW_VIEWPORT      0x1\r
-#define I915_NEW_RASTERIZER    0x2\r
-#define I915_NEW_FS            0x4\r
-#define I915_NEW_BLEND         0x8\r
-#define I915_NEW_CLIP          0x10\r
-#define I915_NEW_SCISSOR       0x20\r
-#define I915_NEW_STIPPLE       0x40\r
-#define I915_NEW_FRAMEBUFFER   0x80\r
-#define I915_NEW_ALPHA_TEST    0x100\r
-#define I915_NEW_DEPTH_STENCIL 0x200\r
-#define I915_NEW_SAMPLER       0x400\r
-#define I915_NEW_TEXTURE       0x800\r
-#define I915_NEW_CONSTANTS     0x1000\r
-#define I915_NEW_VBO           0x2000\r
-#define I915_NEW_VS            0x4000\r
-\r
-\r
-/* Driver's internally generated state flags:\r
- */\r
-#define I915_NEW_VERTEX_FORMAT    0x10000\r
-\r
-\r
-/* Dirty flags for hardware emit\r
- */\r
-#define I915_HW_STATIC            (1<<I915_CACHE_STATIC)\r
-#define I915_HW_DYNAMIC           (1<<I915_CACHE_DYNAMIC)\r
-#define I915_HW_SAMPLER           (1<<I915_CACHE_SAMPLER)\r
-#define I915_HW_MAP               (1<<I915_CACHE_MAP)\r
-#define I915_HW_PROGRAM           (1<<I915_CACHE_PROGRAM)\r
-#define I915_HW_CONSTANTS         (1<<I915_CACHE_CONSTANTS)\r
-#define I915_HW_IMMEDIATE         (1<<(I915_MAX_CACHE+0))\r
-#define I915_HW_INVARIENT         (1<<(I915_MAX_CACHE+1))\r
-\r
-\r
-/***********************************************************************\r
- * i915_prim_emit.c: \r
- */\r
-struct draw_stage *i915_draw_render_stage( struct i915_context *i915 );\r
-\r
-\r
-/***********************************************************************\r
- * i915_prim_vbuf.c: \r
- */\r
-struct draw_stage *i915_draw_vbuf_stage( struct i915_context *i915 );\r
-\r
-\r
-/***********************************************************************\r
- * i915_state_emit.c: \r
- */\r
-void i915_emit_hardware_state(struct i915_context *i915 );\r
-\r
-\r
-\r
-/***********************************************************************\r
- * i915_clear.c: \r
- */\r
-void i915_clear(struct pipe_context *pipe, struct pipe_surface *ps,\r
-               unsigned clearValue);\r
-\r
-\r
-/***********************************************************************\r
- * i915_surface.c: \r
- */\r
-void i915_init_surface_functions( struct i915_context *i915 );\r
-\r
-void i915_init_state_functions( struct i915_context *i915 );\r
-void i915_init_flush_functions( struct i915_context *i915 );\r
-void i915_init_string_functions( struct i915_context *i915 );\r
-\r
-\r
-\r
-\r
-/***********************************************************************\r
- * Inline conversion functions.  These are better-typed than the\r
- * macros used previously:\r
- */\r
-static INLINE struct i915_context *\r
-i915_context( struct pipe_context *pipe )\r
-{\r
-   return (struct i915_context *)pipe;\r
-}\r
-\r
-\r
-\r
-#endif\r
+ /**************************************************************************
+ * 
+ * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.
+ * All Rights Reserved.
+ * 
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ * 
+ **************************************************************************/
+
+#ifndef I915_CONTEXT_H
+#define I915_CONTEXT_H
+
+
+#include "pipe/p_context.h"
+#include "pipe/p_defines.h"
+#include "pipe/p_state.h"
+
+#include "draw/draw_vertex.h"
+
+#include "tgsi/util/tgsi_scan.h"
+
+
+#define I915_TEX_UNITS 8
+
+#define I915_DYNAMIC_MODES4       0
+#define I915_DYNAMIC_DEPTHSCALE_0 1 /* just the header */
+#define I915_DYNAMIC_DEPTHSCALE_1 2 
+#define I915_DYNAMIC_IAB          3
+#define I915_DYNAMIC_BC_0         4 /* just the header */
+#define I915_DYNAMIC_BC_1         5
+#define I915_DYNAMIC_BFO_0        6 
+#define I915_DYNAMIC_BFO_1        7
+#define I915_DYNAMIC_STP_0        8 
+#define I915_DYNAMIC_STP_1        9 
+#define I915_DYNAMIC_SC_ENA_0     10 
+#define I915_DYNAMIC_SC_RECT_0    11 
+#define I915_DYNAMIC_SC_RECT_1    12 
+#define I915_DYNAMIC_SC_RECT_2    13 
+#define I915_MAX_DYNAMIC          14
+
+
+#define I915_IMMEDIATE_S0         0
+#define I915_IMMEDIATE_S1         1
+#define I915_IMMEDIATE_S2         2
+#define I915_IMMEDIATE_S3         3
+#define I915_IMMEDIATE_S4         4
+#define I915_IMMEDIATE_S5         5
+#define I915_IMMEDIATE_S6         6
+#define I915_IMMEDIATE_S7         7
+#define I915_MAX_IMMEDIATE        8
+
+/* These must mach the order of LI0_STATE_* bits, as they will be used
+ * to generate hardware packets:
+ */
+#define I915_CACHE_STATIC         0 
+#define I915_CACHE_DYNAMIC        1 /* handled specially */
+#define I915_CACHE_SAMPLER        2
+#define I915_CACHE_MAP            3
+#define I915_CACHE_PROGRAM        4
+#define I915_CACHE_CONSTANTS      5
+#define I915_MAX_CACHE            6
+
+#define I915_MAX_CONSTANT  32
+
+
+/** See constant_flags[] below */
+#define I915_CONSTFLAG_USER 0x1f
+
+
+/**
+ * Subclass of pipe_shader_state
+ */
+struct i915_fragment_shader
+{
+   struct pipe_shader_state state;
+
+   struct tgsi_shader_info info;
+
+   uint *program;
+   uint program_len;
+
+   /**
+    * constants introduced during translation.
+    * These are placed at the end of the constant buffer and grow toward
+    * the beginning (eg: slot 31, 30 29, ...)
+    * User-provided constants start at 0.
+    * This allows both types of constants to co-exist (until there's too many)
+    * and doesn't require regenerating/changing the fragment program to
+    * shuffle constants around.
+    */
+   uint num_constants;
+   float constants[I915_MAX_CONSTANT][4];
+
+   /**
+    * Status of each constant
+    * if I915_CONSTFLAG_PARAM, the value must be taken from the corresponding
+    * slot of the user's constant buffer. (set by pipe->set_constant_buffer())
+    * Else, the bitmask indicates which components are occupied by immediates.
+    */
+   ubyte constant_flags[I915_MAX_CONSTANT];
+};
+
+
+struct i915_cache_context;
+
+/* Use to calculate differences between state emitted to hardware and
+ * current driver-calculated state.  
+ */
+struct i915_state 
+{
+   unsigned immediate[I915_MAX_IMMEDIATE];
+   unsigned dynamic[I915_MAX_DYNAMIC];
+
+   float constants[PIPE_SHADER_TYPES][I915_MAX_CONSTANT][4];
+   /** number of constants passed in through a constant buffer */
+   uint num_user_constants[PIPE_SHADER_TYPES];
+
+   /* texture sampler state */
+   unsigned sampler[I915_TEX_UNITS][3];
+   unsigned sampler_enable_flags;
+   unsigned sampler_enable_nr;
+
+   /* texture image buffers */
+   unsigned texbuffer[I915_TEX_UNITS][2];
+
+   /** Describes the current hardware vertex layout */
+   struct vertex_info vertex_info;
+   
+   unsigned id;                        /* track lost context events */
+};
+
+struct i915_blend_state {
+   unsigned iab;
+   unsigned modes4;
+   unsigned LIS5;
+   unsigned LIS6;
+};
+
+struct i915_depth_stencil_state {
+   unsigned stencil_modes4;
+   unsigned bfo[2];
+   unsigned stencil_LIS5;
+   unsigned depth_LIS6;
+};
+
+struct i915_rasterizer_state {
+   int light_twoside : 1;
+   unsigned st;
+   enum interp_mode color_interp;
+
+   unsigned LIS4;
+   unsigned LIS7;
+   unsigned sc[1];
+
+   const struct pipe_rasterizer_state *templ;
+
+   union { float f; unsigned u; } ds[2];
+};
+
+struct i915_sampler_state {
+   unsigned state[3];
+   const struct pipe_sampler_state *templ;
+};
+
+
+struct i915_texture {
+   struct pipe_texture base;
+
+   /* Derived from the above:
+    */
+   unsigned pitch;
+   unsigned depth_pitch;          /* per-image on i945? */
+   unsigned total_height;
+
+   unsigned nr_images[PIPE_MAX_TEXTURE_LEVELS];
+
+   /* Explicitly store the offset of each image for each cube face or
+    * depth value.  Pretty much have to accept that hardware formats
+    * are going to be so diverse that there is no unified way to
+    * compute the offsets of depth/cube images within a mipmap level,
+    * so have to store them as a lookup table:
+    */
+   unsigned *image_offset[PIPE_MAX_TEXTURE_LEVELS];   /**< array [depth] of offsets */
+
+   /* Includes image offset tables:
+    */
+   unsigned level_offset[PIPE_MAX_TEXTURE_LEVELS];
+
+   /* The data is held here:
+    */
+   struct pipe_buffer *buffer;
+};
+
+struct i915_context
+{
+   struct pipe_context pipe;
+   struct i915_winsys *winsys;
+   struct draw_context *draw;
+
+   /* The most recent drawing state as set by the driver:
+    */
+   const struct i915_blend_state           *blend;
+   const struct i915_sampler_state         *sampler[PIPE_MAX_SAMPLERS];
+   const struct i915_depth_stencil_state   *depth_stencil;
+   const struct i915_rasterizer_state      *rasterizer;
+
+   struct i915_fragment_shader *fs;
+
+   struct pipe_blend_color blend_color;
+   struct pipe_clip_state clip;
+   struct pipe_constant_buffer constants[PIPE_SHADER_TYPES];
+   struct pipe_framebuffer_state framebuffer;
+   struct pipe_poly_stipple poly_stipple;
+   struct pipe_scissor_state scissor;
+   struct i915_texture *texture[PIPE_MAX_SAMPLERS];
+   struct pipe_viewport_state viewport;
+   struct pipe_vertex_buffer vertex_buffer[PIPE_MAX_ATTRIBS];
+
+   unsigned dirty;
+
+   unsigned num_samplers;
+   unsigned num_textures;
+   unsigned num_vertex_elements;
+   unsigned num_vertex_buffers;
+
+   unsigned *batch_start;
+
+   /** Vertex buffer */
+   struct pipe_buffer *vbo;
+
+   struct i915_state current;
+   unsigned hardware_dirty;
+   
+   unsigned debug;
+};
+
+/* A flag for each state_tracker state object:
+ */
+#define I915_NEW_VIEWPORT      0x1
+#define I915_NEW_RASTERIZER    0x2
+#define I915_NEW_FS            0x4
+#define I915_NEW_BLEND         0x8
+#define I915_NEW_CLIP          0x10
+#define I915_NEW_SCISSOR       0x20
+#define I915_NEW_STIPPLE       0x40
+#define I915_NEW_FRAMEBUFFER   0x80
+#define I915_NEW_ALPHA_TEST    0x100
+#define I915_NEW_DEPTH_STENCIL 0x200
+#define I915_NEW_SAMPLER       0x400
+#define I915_NEW_TEXTURE       0x800
+#define I915_NEW_CONSTANTS     0x1000
+#define I915_NEW_VBO           0x2000
+#define I915_NEW_VS            0x4000
+
+
+/* Driver's internally generated state flags:
+ */
+#define I915_NEW_VERTEX_FORMAT    0x10000
+
+
+/* Dirty flags for hardware emit
+ */
+#define I915_HW_STATIC            (1<<I915_CACHE_STATIC)
+#define I915_HW_DYNAMIC           (1<<I915_CACHE_DYNAMIC)
+#define I915_HW_SAMPLER           (1<<I915_CACHE_SAMPLER)
+#define I915_HW_MAP               (1<<I915_CACHE_MAP)
+#define I915_HW_PROGRAM           (1<<I915_CACHE_PROGRAM)
+#define I915_HW_CONSTANTS         (1<<I915_CACHE_CONSTANTS)
+#define I915_HW_IMMEDIATE         (1<<(I915_MAX_CACHE+0))
+#define I915_HW_INVARIENT         (1<<(I915_MAX_CACHE+1))
+
+
+/***********************************************************************
+ * i915_prim_emit.c: 
+ */
+struct draw_stage *i915_draw_render_stage( struct i915_context *i915 );
+
+
+/***********************************************************************
+ * i915_prim_vbuf.c: 
+ */
+struct draw_stage *i915_draw_vbuf_stage( struct i915_context *i915 );
+
+
+/***********************************************************************
+ * i915_state_emit.c: 
+ */
+void i915_emit_hardware_state(struct i915_context *i915 );
+
+
+
+/***********************************************************************
+ * i915_clear.c: 
+ */
+void i915_clear(struct pipe_context *pipe, struct pipe_surface *ps,
+               unsigned clearValue);
+
+
+/***********************************************************************
+ * i915_surface.c: 
+ */
+void i915_init_surface_functions( struct i915_context *i915 );
+
+void i915_init_state_functions( struct i915_context *i915 );
+void i915_init_flush_functions( struct i915_context *i915 );
+void i915_init_string_functions( struct i915_context *i915 );
+
+
+
+
+/***********************************************************************
+ * Inline conversion functions.  These are better-typed than the
+ * macros used previously:
+ */
+static INLINE struct i915_context *
+i915_context( struct pipe_context *pipe )
+{
+   return (struct i915_context *)pipe;
+}
+
+
+
+#endif
index 646cfd921d1698f6889bba57e49cf4c2ef831c65..ba8f183bdf022586d6f84a1aea1fec22f0da3f43 100644 (file)
@@ -201,6 +201,35 @@ i915_destroy_screen( struct pipe_screen *screen )
 }
 
 
+static void *
+i915_surface_map( struct pipe_screen *screen,
+                  struct pipe_surface *surface,
+                  unsigned flags )
+{
+   char *map = screen->winsys->buffer_map( screen->winsys, surface->buffer, flags );
+   if (map == NULL)
+      return NULL;
+
+   if (surface->texture &&
+       (flags & PIPE_BUFFER_USAGE_CPU_WRITE)) 
+   {
+      /* Do something to notify contexts of a texture change.  
+       */
+      /* i915_screen(screen)->timestamp++; */
+   }
+   
+   return map + surface->offset;
+}
+
+static void
+i915_surface_unmap(struct pipe_screen *screen,
+                   struct pipe_surface *surface)
+{
+   screen->winsys->buffer_unmap( screen->winsys, surface->buffer );
+}
+
+
+
 /**
  * Create a new i915_screen object
  */
@@ -244,6 +273,8 @@ i915_create_screen(struct pipe_winsys *winsys, uint pci_id)
    i915screen->screen.get_param = i915_get_param;
    i915screen->screen.get_paramf = i915_get_paramf;
    i915screen->screen.is_format_supported = i915_is_format_supported;
+   i915screen->screen.surface_map = i915_surface_map;
+   i915screen->screen.surface_unmap = i915_surface_unmap;
 
    i915_init_screen_texture_functions(&i915screen->screen);
 
index 964bd7c871cc94a2b4d5f699f3c044c4880a7baa..e6c4671700e09b4aabb010278d28959d164b22f8 100644 (file)
@@ -466,7 +466,7 @@ void i915_delete_fs_state(struct pipe_context *pipe, void *shader)
       FREE(ifs->program);
    ifs->program_len = 0;
 
-   FREE(ifs->state.tokens);
+   FREE((struct tgsi_token *)ifs->state.tokens);
 
    FREE(ifs);
 }
index f4fbedbe9bc07166f1b2f30847099f4893a27614..98367ac0739a6e360bec4841fbfa8a933a507245 100644 (file)
@@ -51,17 +51,25 @@ i915_surface_copy(struct pipe_context *pipe,
    assert( dst->cpp == src->cpp );
 
    if (0) {
-      pipe_copy_rect(pipe_surface_map(dst),
+      void *dst_map = pipe->screen->surface_map( pipe->screen,
+                                                 dst,
+                                                 PIPE_BUFFER_USAGE_CPU_WRITE );
+      
+      const void *src_map = pipe->screen->surface_map( pipe->screen,
+                                                       src,
+                                                       PIPE_BUFFER_USAGE_CPU_READ );
+      
+      pipe_copy_rect(dst_map,
                      dst->cpp,
                      dst->pitch,
                      dstx, dsty, 
                      width, height, 
-                     pipe_surface_map(src)
+                     src_map
                      do_flip ? -(int) src->pitch : src->pitch, 
                      srcx, do_flip ? 1 - srcy - height : srcy);
 
-      pipe_surface_unmap(src);
-      pipe_surface_unmap(dst);
+      pipe->screen->surface_unmap(pipe->screen, src);
+      pipe->screen->surface_unmap(pipe->screen, dst);
    }
    else {
       i915_copy_blit( i915_context(pipe),
@@ -92,7 +100,10 @@ i915_surface_fill(struct pipe_context *pipe,
 {
    if (0) {
       unsigned i, j;
-      void *dst_map = pipe_surface_map(dst);
+      void *dst_map = pipe->screen->surface_map( pipe->screen,
+                                                 dst,
+                                                 PIPE_BUFFER_USAGE_CPU_WRITE );
+
 
       switch (dst->cpp) {
       case 1: {
@@ -126,7 +137,7 @@ i915_surface_fill(struct pipe_context *pipe,
         break;
       }
 
-      pipe_surface_unmap( dst );
+      pipe->screen->surface_unmap(pipe->screen, dst);
    }
    else {
       i915_fill_blit( i915_context(pipe),
index c39e747705b040243608b4017a0e76b0b7df217d..df11ba0544c644d313ec08d2e9fbe921103bd912 100644 (file)
@@ -105,6 +105,51 @@ i915_miptree_set_image_offset(struct i915_texture *tex,
 }
 
 
+/* Hack it up to use the old winsys->surface_alloc_storage()
+ * method for now:
+ */
+static boolean
+i915_displaytarget_layout(struct pipe_screen *screen,
+                          struct i915_texture *tex)
+{
+   struct pipe_winsys *ws = screen->winsys;
+   struct pipe_surface surf;
+   unsigned flags = (PIPE_BUFFER_USAGE_CPU_READ |
+                     PIPE_BUFFER_USAGE_CPU_WRITE |
+                     PIPE_BUFFER_USAGE_GPU_READ |
+                     PIPE_BUFFER_USAGE_GPU_WRITE);
+
+
+   memset(&surf, 0, sizeof(surf));
+
+   ws->surface_alloc_storage( ws, 
+                              &surf,
+                              tex->base.width[0], 
+                              tex->base.height[0],
+                              tex->base.format,
+                              flags,
+                              tex->base.tex_usage);
+      
+   /* Now extract the goodies: 
+    */
+   i915_miptree_set_level_info( tex, 0, 1, 0, 0,
+                                tex->base.width[0],
+                                tex->base.height[0],
+                                1 );
+   i915_miptree_set_image_offset( tex, 0, 0, 0, 0 );
+
+   tex->buffer = surf.buffer;
+   tex->pitch = surf.pitch;
+   tex->total_height = 0;
+
+
+   return tex->buffer != NULL;
+}
+
+
+
+
+
 static void
 i945_miptree_layout_2d( struct i915_texture *tex )
 {
@@ -480,39 +525,54 @@ i945_miptree_layout(struct i915_texture * tex)
 
 
 static struct pipe_texture *
-i915_texture_create_screen(struct pipe_screen *screen,
-                           const struct pipe_texture *templat)
+i915_texture_create(struct pipe_screen *screen,
+                    const struct pipe_texture *templat)
 {
+   struct i915_screen *i915screen = i915_screen(screen);
+   struct pipe_winsys *ws = screen->winsys;
    struct i915_texture *tex = CALLOC_STRUCT(i915_texture);
 
-   if (tex) {
-      struct i915_screen *i915screen = i915_screen(screen);
-      struct pipe_winsys *ws = screen->winsys;
-
-      tex->base = *templat;
-      tex->base.refcount = 1;
-      tex->base.screen = screen;
+   if (!tex) 
+      return NULL;
 
-      if (i915screen->is_i945 ? i945_miptree_layout(tex) :
-         i915_miptree_layout(tex))
-        tex->buffer = ws->buffer_create(ws, 64,
-                                         PIPE_BUFFER_USAGE_PIXEL,
-                                         tex->pitch * tex->base.cpp *
-                                         tex->total_height);
+   tex->base = *templat;
+   tex->base.refcount = 1;
+   tex->base.screen = screen;
 
-      if (!tex->buffer) {
-        FREE(tex);
-        return NULL;
+   if (tex->base.tex_usage & PIPE_TEXTURE_USAGE_DISPLAY_TARGET) {
+      if (!i915_displaytarget_layout(screen, tex))
+         goto fail;
+   }
+   else {
+      if (i915screen->is_i945) {
+         if (!i945_miptree_layout(tex))
+            goto fail;
       }
+      else {
+         if (!i915_miptree_layout(tex))
+            goto fail;
+      }
+      
+      tex->buffer = ws->buffer_create(ws, 64,
+                                      PIPE_BUFFER_USAGE_PIXEL,
+                                      tex->pitch * tex->base.cpp *
+                                      tex->total_height);
+
+      if (!tex->buffer) 
+         goto fail;
    }
 
    return &tex->base;
+
+ fail:
+   FREE(tex);
+   return NULL;
 }
 
 
 static void
-i915_texture_release_screen(struct pipe_screen *screen,
-                            struct pipe_texture **pt)
+i915_texture_release(struct pipe_screen *screen,
+                     struct pipe_texture **pt)
 {
    if (!*pt)
       return;
@@ -541,21 +601,15 @@ i915_texture_release_screen(struct pipe_screen *screen,
 }
 
 
-static void
-i915_texture_update(struct pipe_context *pipe, struct pipe_texture *texture,
-                    uint face, uint levelsMask)
-{
-   /* no-op? */
-}
-
 
 /*
  * XXX note: same as code in sp_surface.c
  */
 static struct pipe_surface *
-i915_get_tex_surface_screen(struct pipe_screen *screen,
-                            struct pipe_texture *pt,
-                            unsigned face, unsigned level, unsigned zslice)
+i915_get_tex_surface(struct pipe_screen *screen,
+                     struct pipe_texture *pt,
+                     unsigned face, unsigned level, unsigned zslice,
+                     unsigned flags)
 {
    struct i915_texture *tex = (struct i915_texture *)pt;
    struct pipe_winsys *ws = screen->winsys;
@@ -579,6 +633,7 @@ i915_get_tex_surface_screen(struct pipe_screen *screen,
    if (ps) {
       assert(ps->refcount);
       assert(ps->winsys);
+      pipe_texture_reference(&ps->texture, pt);
       pipe_buffer_reference(ws, &ps->buffer, tex->buffer);
       ps->format = pt->format;
       ps->cpp = pt->cpp;
@@ -586,6 +641,7 @@ i915_get_tex_surface_screen(struct pipe_screen *screen,
       ps->height = pt->height[level];
       ps->pitch = tex->pitch;
       ps->offset = offset;
+      ps->usage = flags;
    }
    return ps;
 }
@@ -594,14 +650,38 @@ i915_get_tex_surface_screen(struct pipe_screen *screen,
 void
 i915_init_texture_functions(struct i915_context *i915)
 {
-   i915->pipe.texture_update = i915_texture_update;
+//   i915->pipe.texture_update = i915_texture_update;
 }
 
+static void
+i915_tex_surface_release(struct pipe_screen *screen,
+                         struct pipe_surface **surface)
+{
+   struct pipe_surface *surf = *surface;
+
+   if (--surf->refcount == 0) {
+
+      /* This really should not be possible, but it's actually
+       * happening quite a bit...  Will fix.
+       */
+      if (surf->status == PIPE_SURFACE_STATUS_CLEAR) {
+         debug_printf("XXX destroying a surface with pending clears...\n");
+         assert(0);
+      }
+
+      pipe_texture_reference(&surf->texture, NULL);
+      pipe_buffer_reference(screen->winsys, &surf->buffer, NULL);
+      FREE(surf);
+   }
+
+   *surface = NULL;
+}
 
 void
 i915_init_screen_texture_functions(struct pipe_screen *screen)
 {
-   screen->texture_create = i915_texture_create_screen;
-   screen->texture_release = i915_texture_release_screen;
-   screen->get_tex_surface = i915_get_tex_surface_screen;
+   screen->texture_create = i915_texture_create;
+   screen->texture_release = i915_texture_release;
+   screen->get_tex_surface = i915_get_tex_surface;
+   screen->tex_surface_release = i915_tex_surface_release;
 }
index eeccf367856870d00232f787afca6abe5d83920c..8ac6b4e689729a3d0c720f3768d209e34fd1c975 100644 (file)
-/*\r
- Copyright (C) Intel Corp.  2006.  All Rights Reserved.\r
- Intel funded Tungsten Graphics (http://www.tungstengraphics.com) to\r
- develop this 3D driver.\r
-\r
- Permission is hereby granted, free of charge, to any person obtaining\r
- a copy of this software and associated documentation files (the\r
- "Software"), to deal in the Software without restriction, including\r
- without limitation the rights to use, copy, modify, merge, publish,\r
- distribute, sublicense, and/or sell copies of the Software, and to\r
- permit persons to whom the Software is furnished to do so, subject to\r
- the following conditions:\r
-\r
- The above copyright notice and this permission notice (including the\r
- next paragraph) shall be included in all copies or substantial\r
- portions of the Software.\r
-\r
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\r
- IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE\r
- LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\r
- OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\r
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\r
-\r
- **********************************************************************/\r
- /*\r
-  * Authors:\r
-  *   Keith Whitwell <keith@tungstengraphics.com>\r
-  */\r
-\r
-\r
-#ifndef BRWCONTEXT_INC\r
-#define BRWCONTEXT_INC\r
-\r
-\r
-#include "pipe/p_context.h"\r
-#include "pipe/p_defines.h"\r
-#include "pipe/p_state.h"\r
-\r
-#include "tgsi/util/tgsi_scan.h"\r
-\r
-#include "brw_structs.h"\r
-#include "brw_winsys.h"\r
-\r
-\r
-/* Glossary:\r
- *\r
- * URB - uniform resource buffer.  A mid-sized buffer which is\r
- * partitioned between the fixed function units and used for passing\r
- * values (vertices, primitives, constants) between them.\r
- *\r
- * CURBE - constant URB entry.  An urb region (entry) used to hold\r
- * constant values which the fixed function units can be instructed to\r
- * preload into the GRF when spawining a thread.\r
- *\r
- * VUE - vertex URB entry.  An urb entry holding a vertex and usually\r
- * a vertex header.  The header contains control information and\r
- * things like primitive type, Begin/end flags and clip codes.\r
- *\r
- * PUE - primitive URB entry.  An urb entry produced by the setup (SF)\r
- * unit holding rasterization and interpolation parameters.\r
- *\r
- * GRF - general register file.  One of several register files\r
- * addressable by programmed threads.  The inputs (r0, payload, curbe,\r
- * urb) of the thread are preloaded to this area before the thread is\r
- * spawned.  The registers are individually 8 dwords wide and suitable\r
- * for general usage.  Registers holding thread input values are not\r
- * special and may be overwritten.\r
- *\r
- * MRF - message register file.  Threads communicate (and terminate)\r
- * by sending messages.  Message parameters are placed in contigous\r
- * MRF registers.  All program output is via these messages.  URB\r
- * entries are populated by sending a message to the shared URB\r
- * function containing the new data, together with a control word,\r
- * often an unmodified copy of R0.\r
- *\r
- * R0 - GRF register 0.  Typically holds control information used when\r
- * sending messages to other threads.\r
- *\r
- * EU or GEN4 EU: The name of the programmable subsystem of the\r
- * i965 hardware.  Threads are executed by the EU, the registers\r
- * described above are part of the EU architecture.\r
- *\r
- * Fixed function units:\r
- *\r
- * CS - Command streamer.  Notional first unit, little software\r
- * interaction.  Holds the URB entries used for constant data, ie the\r
- * CURBEs.\r
- *\r
- * VF/VS - Vertex Fetch / Vertex Shader.  The fixed function part of\r
- * this unit is responsible for pulling vertices out of vertex buffers\r
- * in vram and injecting them into the processing pipe as VUEs.  If\r
- * enabled, it first passes them to a VS thread which is a good place\r
- * for the driver to implement any active vertex shader.\r
- *\r
- * GS - Geometry Shader.  This corresponds to a new DX10 concept.  If\r
- * enabled, incoming strips etc are passed to GS threads in individual\r
- * line/triangle/point units.  The GS thread may perform arbitary\r
- * computation and emit whatever primtives with whatever vertices it\r
- * chooses.  This makes GS an excellent place to implement GL's\r
- * unfilled polygon modes, though of course it is capable of much\r
- * more.  Additionally, GS is used to translate away primitives not\r
- * handled by latter units, including Quads and Lineloops.\r
- *\r
- * CS - Clipper.  Mesa's clipping algorithms are imported to run on\r
- * this unit.  The fixed function part performs cliptesting against\r
- * the 6 fixed clipplanes and makes descisions on whether or not the\r
- * incoming primitive needs to be passed to a thread for clipping.\r
- * User clip planes are handled via cooperation with the VS thread.\r
- *\r
- * SF - Strips Fans or Setup: Triangles are prepared for\r
- * rasterization.  Interpolation coefficients are calculated.\r
- * Flatshading and two-side lighting usually performed here.\r
- *\r
- * WM - Windower.  Interpolation of vertex attributes performed here.\r
- * Fragment shader implemented here.  SIMD aspects of EU taken full\r
- * advantage of, as pixels are processed in blocks of 16.\r
- *\r
- * CC - Color Calculator.  No EU threads associated with this unit.\r
- * Handles blending and (presumably) depth and stencil testing.\r
- */\r
-\r
-#define BRW_MAX_CURBE                    (32*16)\r
-\r
-struct brw_context;\r
-struct brw_winsys;\r
-\r
-\r
-/* Raised when we receive new state across the pipe interface:\r
- */\r
-#define BRW_NEW_VIEWPORT                0x1\r
-#define BRW_NEW_RASTERIZER              0x2\r
-#define BRW_NEW_FS                      0x4\r
-#define BRW_NEW_BLEND                   0x8\r
-#define BRW_NEW_CLIP                    0x10\r
-#define BRW_NEW_SCISSOR                 0x20\r
-#define BRW_NEW_STIPPLE                 0x40\r
-#define BRW_NEW_FRAMEBUFFER             0x80\r
-#define BRW_NEW_ALPHA_TEST              0x100\r
-#define BRW_NEW_DEPTH_STENCIL           0x200\r
-#define BRW_NEW_SAMPLER                 0x400\r
-#define BRW_NEW_TEXTURE                 0x800\r
-#define BRW_NEW_CONSTANTS               0x1000\r
-#define BRW_NEW_VBO                     0x2000\r
-#define BRW_NEW_VS                      0x4000\r
-\r
-/* Raised for other internal events:\r
- */\r
-#define BRW_NEW_URB_FENCE               0x10000\r
-#define BRW_NEW_PSP                     0x20000\r
-#define BRW_NEW_CURBE_OFFSETS           0x40000\r
-#define BRW_NEW_REDUCED_PRIMITIVE       0x80000\r
-#define BRW_NEW_PRIMITIVE               0x100000\r
-#define BRW_NEW_SCENE                 0x200000\r
-#define BRW_NEW_SF_LINKAGE              0x400000\r
-\r
-extern int BRW_DEBUG;\r
-\r
-#define DEBUG_TEXTURE  0x1\r
-#define DEBUG_STATE    0x2\r
-#define DEBUG_IOCTL    0x4\r
-#define DEBUG_PRIMS    0x8\r
-#define DEBUG_VERTS    0x10\r
-#define DEBUG_FALLBACKS        0x20\r
-#define DEBUG_VERBOSE  0x40\r
-#define DEBUG_DRI       0x80\r
-#define DEBUG_DMA       0x100\r
-#define DEBUG_SANITY    0x200\r
-#define DEBUG_SYNC      0x400\r
-#define DEBUG_SLEEP     0x800\r
-#define DEBUG_PIXEL     0x1000\r
-#define DEBUG_STATS     0x2000\r
-#define DEBUG_TILE      0x4000\r
-#define DEBUG_SINGLE_THREAD   0x8000\r
-#define DEBUG_WM        0x10000\r
-#define DEBUG_URB       0x20000\r
-#define DEBUG_VS        0x40000\r
-#define DEBUG_BATCH    0x80000\r
-#define DEBUG_BUFMGR   0x100000\r
-#define DEBUG_BLIT     0x200000\r
-#define DEBUG_REGION   0x400000\r
-#define DEBUG_MIPTREE  0x800000\r
-\r
-#define DBG(...) do {                                          \\r
-   if (BRW_DEBUG & FILE_DEBUG_FLAG)                            \\r
-      debug_printf(__VA_ARGS__);                               \\r
-} while(0)\r
-\r
-#define PRINT(...) do {                                                \\r
-   debug_printf(brw->pipe.winsys, __VA_ARGS__);                        \\r
-} while(0)\r
-\r
-struct brw_state_flags {\r
-   unsigned cache;\r
-   unsigned brw;\r
-};\r
-\r
-\r
-struct brw_vertex_program {\r
-   struct pipe_shader_state program;\r
-   struct tgsi_shader_info info;\r
-   int id;\r
-};\r
-\r
-\r
-struct brw_fragment_program {\r
-   struct pipe_shader_state program;\r
-   struct tgsi_shader_info info;\r
-   \r
-   boolean UsesDepth; /* XXX add this to tgsi_shader_info? */\r
-   int id;\r
-};\r
-\r
-\r
-struct pipe_setup_linkage {\r
-   struct {\r
-      unsigned vp_output:5;\r
-      unsigned interp_mode:4;\r
-      unsigned bf_vp_output:5;\r
-   } fp_input[PIPE_MAX_SHADER_INPUTS];\r
-\r
-   unsigned fp_input_count:5;\r
-   unsigned max_vp_output:5;\r
-};\r
-   \r
-\r
-\r
-struct brw_texture {\r
-   struct pipe_texture base;\r
-\r
-   /* Derived from the above:\r
-    */\r
-   unsigned pitch;\r
-   unsigned depth_pitch;          /* per-image on i945? */\r
-   unsigned total_height;\r
-\r
-   unsigned nr_images[PIPE_MAX_TEXTURE_LEVELS];\r
-\r
-   /* Explicitly store the offset of each image for each cube face or\r
-    * depth value.  Pretty much have to accept that hardware formats\r
-    * are going to be so diverse that there is no unified way to\r
-    * compute the offsets of depth/cube images within a mipmap level,\r
-    * so have to store them as a lookup table:\r
-    */\r
-   unsigned *image_offset[PIPE_MAX_TEXTURE_LEVELS];   /**< array [depth] of offsets */\r
-\r
-   /* Includes image offset tables:\r
-    */\r
-   unsigned level_offset[PIPE_MAX_TEXTURE_LEVELS];\r
-\r
-   /* The data is held here:\r
-    */\r
-   struct pipe_buffer *buffer;\r
-};\r
-\r
-/* Data about a particular attempt to compile a program.  Note that\r
- * there can be many of these, each in a different GL state\r
- * corresponding to a different brw_wm_prog_key struct, with different\r
- * compiled programs:\r
- */\r
-/* Data about a particular attempt to compile a program.  Note that\r
- * there can be many of these, each in a different GL state\r
- * corresponding to a different brw_wm_prog_key struct, with different\r
- * compiled programs:\r
- */\r
-\r
-struct brw_wm_prog_data {\r
-   unsigned curb_read_length;\r
-   unsigned urb_read_length;\r
-\r
-   unsigned first_curbe_grf;\r
-   unsigned total_grf;\r
-   unsigned total_scratch;\r
-\r
-   /* Internally generated constants for the CURBE.  These are loaded\r
-    * ahead of the data from the constant buffer.\r
-    */\r
-   const float internal_const[8];\r
-   unsigned nr_internal_consts;\r
-   unsigned max_const;\r
-\r
-   boolean error;\r
-};\r
-\r
-struct brw_sf_prog_data {\r
-   unsigned urb_read_length;\r
-   unsigned total_grf;\r
-\r
-   /* Each vertex may have upto 12 attributes, 4 components each,\r
-    * except WPOS which requires only 2.  (11*4 + 2) == 44 ==> 11\r
-    * rows.\r
-    *\r
-    * Actually we use 4 for each, so call it 12 rows.\r
-    */\r
-   unsigned urb_entry_size;\r
-};\r
-\r
-struct brw_clip_prog_data {\r
-   unsigned curb_read_length;  /* user planes? */\r
-   unsigned clip_mode;\r
-   unsigned urb_read_length;\r
-   unsigned total_grf;\r
-};\r
-\r
-struct brw_gs_prog_data {\r
-   unsigned urb_read_length;\r
-   unsigned total_grf;\r
-};\r
-\r
-struct brw_vs_prog_data {\r
-   unsigned curb_read_length;\r
-   unsigned urb_read_length;\r
-   unsigned total_grf;\r
-   unsigned outputs_written;\r
-\r
-   unsigned inputs_read;\r
-\r
-   unsigned max_const;\r
-\r
-   float    imm_buf[PIPE_MAX_CONSTANT][4];\r
-   unsigned num_imm;\r
-   unsigned num_consts;\r
-\r
-   /* Used for calculating urb partitions:\r
-    */\r
-   unsigned urb_entry_size;\r
-};\r
-\r
-\r
-#define BRW_MAX_TEX_UNIT 8\r
-#define BRW_WM_MAX_SURF BRW_MAX_TEX_UNIT + 1\r
-\r
-/* Create a fixed sized struct for caching binding tables:\r
- */\r
-struct brw_surface_binding_table {\r
-   unsigned surf_ss_offset[BRW_WM_MAX_SURF];\r
-};\r
-\r
-\r
-struct brw_cache;\r
-\r
-struct brw_mem_pool {\r
-   struct pipe_buffer *buffer;\r
-\r
-   unsigned size;\r
-   unsigned offset;            /* offset of first free byte */\r
-\r
-   struct brw_context *brw;\r
-};\r
-\r
-struct brw_cache_item {\r
-   unsigned hash;\r
-   unsigned key_size;          /* for variable-sized keys */\r
-   const void *key;\r
-\r
-   unsigned offset;            /* offset within pool's buffer */\r
-   unsigned data_size;\r
-\r
-   struct brw_cache_item *next;\r
-};\r
-\r
-\r
-\r
-struct brw_cache {\r
-   unsigned id;\r
-\r
-   const char *name;\r
-\r
-   struct brw_context *brw;\r
-   struct brw_mem_pool *pool;\r
-\r
-   struct brw_cache_item **items;\r
-   unsigned size, n_items;\r
-\r
-   unsigned key_size;          /* for fixed-size keys */\r
-   unsigned aux_size;\r
-\r
-   unsigned last_addr;                 /* offset of active item */\r
-};\r
-\r
-\r
-\r
-\r
-/* Considered adding a member to this struct to document which flags\r
- * an update might raise so that ordering of the state atoms can be\r
- * checked or derived at runtime.  Dropped the idea in favor of having\r
- * a debug mode where the state is monitored for flags which are\r
- * raised that have already been tested against.\r
- */\r
-struct brw_tracked_state {\r
-   struct brw_state_flags dirty;\r
-   void (*update)( struct brw_context *brw );\r
-};\r
-\r
-\r
-/* Flags for brw->state.cache.\r
- */\r
-#define CACHE_NEW_CC_VP                  (1<<BRW_CC_VP)\r
-#define CACHE_NEW_CC_UNIT                (1<<BRW_CC_UNIT)\r
-#define CACHE_NEW_WM_PROG                (1<<BRW_WM_PROG)\r
-#define CACHE_NEW_SAMPLER_DEFAULT_COLOR  (1<<BRW_SAMPLER_DEFAULT_COLOR)\r
-#define CACHE_NEW_SAMPLER                (1<<BRW_SAMPLER)\r
-#define CACHE_NEW_WM_UNIT                (1<<BRW_WM_UNIT)\r
-#define CACHE_NEW_SF_PROG                (1<<BRW_SF_PROG)\r
-#define CACHE_NEW_SF_VP                  (1<<BRW_SF_VP)\r
-#define CACHE_NEW_SF_UNIT                (1<<BRW_SF_UNIT)\r
-#define CACHE_NEW_VS_UNIT                (1<<BRW_VS_UNIT)\r
-#define CACHE_NEW_VS_PROG                (1<<BRW_VS_PROG)\r
-#define CACHE_NEW_GS_UNIT                (1<<BRW_GS_UNIT)\r
-#define CACHE_NEW_GS_PROG                (1<<BRW_GS_PROG)\r
-#define CACHE_NEW_CLIP_VP                (1<<BRW_CLIP_VP)\r
-#define CACHE_NEW_CLIP_UNIT              (1<<BRW_CLIP_UNIT)\r
-#define CACHE_NEW_CLIP_PROG              (1<<BRW_CLIP_PROG)\r
-#define CACHE_NEW_SURFACE                (1<<BRW_SS_SURFACE)\r
-#define CACHE_NEW_SURF_BIND              (1<<BRW_SS_SURF_BIND)\r
-\r
-\r
-\r
-\r
-enum brw_mempool_id {\r
-   BRW_GS_POOL,\r
-   BRW_SS_POOL,\r
-   BRW_MAX_POOL\r
-};\r
-\r
-\r
-struct brw_cached_batch_item {\r
-   struct header *header;\r
-   unsigned sz;\r
-   struct brw_cached_batch_item *next;\r
-};\r
-\r
-\r
-\r
-/* Protect against a future where PIPE_MAX_ATTRIBS > 32.  Wouldn't life\r
- * be easier if C allowed arrays of packed elements?\r
- */\r
-#define ATTRIB_BIT_DWORDS  ((PIPE_MAX_ATTRIBS+31)/32)\r
-\r
-\r
-\r
-\r
-struct brw_vertex_info {\r
-   unsigned varying;  /* varying:1[PIPE_MAX_ATTRIBS] */\r
-   unsigned sizes[ATTRIB_BIT_DWORDS * 2]; /* sizes:2[PIPE_MAX_ATTRIBS] */\r
-};\r
-\r
-\r
-\r
-\r
-\r
-struct brw_context\r
-{\r
-   struct pipe_context pipe;\r
-   struct brw_winsys *winsys;\r
-\r
-   unsigned primitive;\r
-   unsigned reduced_primitive;\r
-\r
-   boolean emit_state_always;\r
-\r
-   struct {\r
-      struct brw_state_flags dirty;\r
-   } state;\r
-\r
-\r
-   struct {\r
-      const struct pipe_blend_state         *Blend;\r
-      const struct pipe_depth_stencil_alpha_state *DepthStencil;\r
-      const struct pipe_poly_stipple        *PolygonStipple;\r
-      const struct pipe_rasterizer_state    *Raster;\r
-      const struct pipe_sampler_state       *Samplers[PIPE_MAX_SAMPLERS];\r
-      const struct brw_vertex_program       *VertexProgram;\r
-      const struct brw_fragment_program     *FragmentProgram;\r
-\r
-      struct pipe_clip_state          Clip;\r
-      struct pipe_blend_color         BlendColor;\r
-      struct pipe_scissor_state       Scissor;\r
-      struct pipe_viewport_state      Viewport;\r
-      struct pipe_framebuffer_state   FrameBuffer;\r
-\r
-      const struct pipe_constant_buffer *Constants[2];\r
-      const struct brw_texture          *Texture[PIPE_MAX_SAMPLERS];\r
-   } attribs;\r
-\r
-   unsigned num_samplers;\r
-   unsigned num_textures;\r
-\r
-   struct brw_mem_pool pool[BRW_MAX_POOL];\r
-   struct brw_cache cache[BRW_MAX_CACHE];\r
-   struct brw_cached_batch_item *cached_batch_items;\r
-\r
-   struct {\r
-\r
-      /* Arrays with buffer objects to copy non-bufferobj arrays into\r
-       * for upload:\r
-       */\r
-      const struct pipe_vertex_buffer *vbo_array[PIPE_MAX_ATTRIBS];\r
-\r
-      struct brw_vertex_element_state inputs[PIPE_MAX_ATTRIBS];\r
-\r
-#define BRW_NR_UPLOAD_BUFS 17\r
-#define BRW_UPLOAD_INIT_SIZE (128*1024)\r
-\r
-      /* Summary of size and varying of active arrays, so we can check\r
-       * for changes to this state:\r
-       */\r
-      struct brw_vertex_info info;\r
-   } vb;\r
-\r
-\r
-   unsigned hardware_dirty;\r
-   unsigned dirty;\r
-   unsigned pci_id;\r
-   /* BRW_NEW_URB_ALLOCATIONS:\r
-    */\r
-   struct {\r
-      unsigned vsize;          /* vertex size plus header in urb registers */\r
-      unsigned csize;          /* constant buffer size in urb registers */\r
-      unsigned sfsize;         /* setup data size in urb registers */\r
-\r
-      boolean constrained;\r
-\r
-      unsigned nr_vs_entries;\r
-      unsigned nr_gs_entries;\r
-      unsigned nr_clip_entries;\r
-      unsigned nr_sf_entries;\r
-      unsigned nr_cs_entries;\r
-\r
-/*       unsigned vs_size; */\r
-/*       unsigned gs_size; */\r
-/*       unsigned clip_size; */\r
-/*       unsigned sf_size; */\r
-/*       unsigned cs_size; */\r
-\r
-      unsigned vs_start;\r
-      unsigned gs_start;\r
-      unsigned clip_start;\r
-      unsigned sf_start;\r
-      unsigned cs_start;\r
-   } urb;\r
-\r
-\r
-   /* BRW_NEW_CURBE_OFFSETS:\r
-    */\r
-   struct {\r
-      unsigned wm_start;\r
-      unsigned wm_size;\r
-      unsigned clip_start;\r
-      unsigned clip_size;\r
-      unsigned vs_start;\r
-      unsigned vs_size;\r
-      unsigned total_size;\r
-\r
-      unsigned gs_offset;\r
-\r
-      float *last_buf;\r
-      unsigned last_bufsz;\r
-   } curbe;\r
-\r
-   struct {\r
-      struct brw_vs_prog_data *prog_data;\r
-\r
-      unsigned prog_gs_offset;\r
-      unsigned state_gs_offset;\r
-   } vs;\r
-\r
-   struct {\r
-      struct brw_gs_prog_data *prog_data;\r
-\r
-      boolean prog_active;\r
-      unsigned prog_gs_offset;\r
-      unsigned state_gs_offset;\r
-   } gs;\r
-\r
-   struct {\r
-      struct brw_clip_prog_data *prog_data;\r
-\r
-      unsigned prog_gs_offset;\r
-      unsigned vp_gs_offset;\r
-      unsigned state_gs_offset;\r
-   } clip;\r
-\r
-\r
-   struct {\r
-      struct brw_sf_prog_data *prog_data;\r
-\r
-      struct pipe_setup_linkage linkage;\r
-\r
-      unsigned prog_gs_offset;\r
-      unsigned vp_gs_offset;\r
-      unsigned state_gs_offset;\r
-   } sf;\r
-\r
-   struct {\r
-      struct brw_wm_prog_data *prog_data;\r
-\r
-//      struct brw_wm_compiler *compile_data;\r
-\r
-\r
-      /**\r
-       * Array of sampler state uploaded at sampler_gs_offset of BRW_SAMPLER\r
-       * cache\r
-       */\r
-      struct brw_sampler_state sampler[BRW_MAX_TEX_UNIT];\r
-\r
-      unsigned render_surf;\r
-      unsigned nr_surfaces;\r
-\r
-      unsigned max_threads;\r
-      struct pipe_buffer *scratch_buffer;\r
-      unsigned scratch_buffer_size;\r
-\r
-      unsigned sampler_count;\r
-      unsigned sampler_gs_offset;\r
-\r
-      struct brw_surface_binding_table bind;\r
-      unsigned bind_ss_offset;\r
-\r
-      unsigned prog_gs_offset;\r
-      unsigned state_gs_offset;\r
-   } wm;\r
-\r
-\r
-   struct {\r
-      unsigned vp_gs_offset;\r
-      unsigned state_gs_offset;\r
-   } cc;\r
-\r
-\r
-   /* Used to give every program string a unique id\r
-    */\r
-   unsigned program_id;\r
-};\r
-\r
-\r
-#define BRW_PACKCOLOR8888(r,g,b,a)  ((r<<24) | (g<<16) | (b<<8) | a)\r
-\r
-\r
-/*======================================================================\r
- * brw_vtbl.c\r
- */\r
-void brw_do_flush( struct brw_context *brw,\r
-                  unsigned flags );\r
-\r
-\r
-/*======================================================================\r
- * brw_state.c\r
- */\r
-void brw_validate_state(struct brw_context *brw);\r
-void brw_init_state(struct brw_context *brw);\r
-void brw_destroy_state(struct brw_context *brw);\r
-\r
-\r
-/*======================================================================\r
- * brw_tex.c\r
- */\r
-void brwUpdateTextureState( struct brw_context *brw );\r
-\r
-\r
-/* brw_urb.c\r
- */\r
-void brw_upload_urb_fence(struct brw_context *brw);\r
-\r
-void brw_upload_constant_buffer_state(struct brw_context *brw);\r
-\r
-void brw_init_surface_functions(struct brw_context *brw);\r
-void brw_init_state_functions(struct brw_context *brw);\r
-void brw_init_flush_functions(struct brw_context *brw);\r
-void brw_init_string_functions(struct brw_context *brw);\r
-\r
-/*======================================================================\r
- * Inline conversion functions.  These are better-typed than the\r
- * macros used previously:\r
- */\r
-static inline struct brw_context *\r
-brw_context( struct pipe_context *ctx )\r
-{\r
-   return (struct brw_context *)ctx;\r
-}\r
-\r
-#endif\r
-\r
+/*
+ Copyright (C) Intel Corp.  2006.  All Rights Reserved.
+ Intel funded Tungsten Graphics (http://www.tungstengraphics.com) to
+ develop this 3D driver.
+
+ Permission is hereby granted, free of charge, to any person obtaining
+ a copy of this software and associated documentation files (the
+ "Software"), to deal in the Software without restriction, including
+ without limitation the rights to use, copy, modify, merge, publish,
+ distribute, sublicense, and/or sell copies of the Software, and to
+ permit persons to whom the Software is furnished to do so, subject to
+ the following conditions:
+
+ The above copyright notice and this permission notice (including the
+ next paragraph) shall be included in all copies or substantial
+ portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+ IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+ **********************************************************************/
+ /*
+  * Authors:
+  *   Keith Whitwell <keith@tungstengraphics.com>
+  */
+
+
+#ifndef BRWCONTEXT_INC
+#define BRWCONTEXT_INC
+
+
+#include "pipe/p_context.h"
+#include "pipe/p_defines.h"
+#include "pipe/p_state.h"
+
+#include "tgsi/util/tgsi_scan.h"
+
+#include "brw_structs.h"
+#include "brw_winsys.h"
+
+
+/* Glossary:
+ *
+ * URB - uniform resource buffer.  A mid-sized buffer which is
+ * partitioned between the fixed function units and used for passing
+ * values (vertices, primitives, constants) between them.
+ *
+ * CURBE - constant URB entry.  An urb region (entry) used to hold
+ * constant values which the fixed function units can be instructed to
+ * preload into the GRF when spawining a thread.
+ *
+ * VUE - vertex URB entry.  An urb entry holding a vertex and usually
+ * a vertex header.  The header contains control information and
+ * things like primitive type, Begin/end flags and clip codes.
+ *
+ * PUE - primitive URB entry.  An urb entry produced by the setup (SF)
+ * unit holding rasterization and interpolation parameters.
+ *
+ * GRF - general register file.  One of several register files
+ * addressable by programmed threads.  The inputs (r0, payload, curbe,
+ * urb) of the thread are preloaded to this area before the thread is
+ * spawned.  The registers are individually 8 dwords wide and suitable
+ * for general usage.  Registers holding thread input values are not
+ * special and may be overwritten.
+ *
+ * MRF - message register file.  Threads communicate (and terminate)
+ * by sending messages.  Message parameters are placed in contigous
+ * MRF registers.  All program output is via these messages.  URB
+ * entries are populated by sending a message to the shared URB
+ * function containing the new data, together with a control word,
+ * often an unmodified copy of R0.
+ *
+ * R0 - GRF register 0.  Typically holds control information used when
+ * sending messages to other threads.
+ *
+ * EU or GEN4 EU: The name of the programmable subsystem of the
+ * i965 hardware.  Threads are executed by the EU, the registers
+ * described above are part of the EU architecture.
+ *
+ * Fixed function units:
+ *
+ * CS - Command streamer.  Notional first unit, little software
+ * interaction.  Holds the URB entries used for constant data, ie the
+ * CURBEs.
+ *
+ * VF/VS - Vertex Fetch / Vertex Shader.  The fixed function part of
+ * this unit is responsible for pulling vertices out of vertex buffers
+ * in vram and injecting them into the processing pipe as VUEs.  If
+ * enabled, it first passes them to a VS thread which is a good place
+ * for the driver to implement any active vertex shader.
+ *
+ * GS - Geometry Shader.  This corresponds to a new DX10 concept.  If
+ * enabled, incoming strips etc are passed to GS threads in individual
+ * line/triangle/point units.  The GS thread may perform arbitary
+ * computation and emit whatever primtives with whatever vertices it
+ * chooses.  This makes GS an excellent place to implement GL's
+ * unfilled polygon modes, though of course it is capable of much
+ * more.  Additionally, GS is used to translate away primitives not
+ * handled by latter units, including Quads and Lineloops.
+ *
+ * CS - Clipper.  Mesa's clipping algorithms are imported to run on
+ * this unit.  The fixed function part performs cliptesting against
+ * the 6 fixed clipplanes and makes descisions on whether or not the
+ * incoming primitive needs to be passed to a thread for clipping.
+ * User clip planes are handled via cooperation with the VS thread.
+ *
+ * SF - Strips Fans or Setup: Triangles are prepared for
+ * rasterization.  Interpolation coefficients are calculated.
+ * Flatshading and two-side lighting usually performed here.
+ *
+ * WM - Windower.  Interpolation of vertex attributes performed here.
+ * Fragment shader implemented here.  SIMD aspects of EU taken full
+ * advantage of, as pixels are processed in blocks of 16.
+ *
+ * CC - Color Calculator.  No EU threads associated with this unit.
+ * Handles blending and (presumably) depth and stencil testing.
+ */
+
+#define BRW_MAX_CURBE                    (32*16)
+
+struct brw_context;
+struct brw_winsys;
+
+
+/* Raised when we receive new state across the pipe interface:
+ */
+#define BRW_NEW_VIEWPORT                0x1
+#define BRW_NEW_RASTERIZER              0x2
+#define BRW_NEW_FS                      0x4
+#define BRW_NEW_BLEND                   0x8
+#define BRW_NEW_CLIP                    0x10
+#define BRW_NEW_SCISSOR                 0x20
+#define BRW_NEW_STIPPLE                 0x40
+#define BRW_NEW_FRAMEBUFFER             0x80
+#define BRW_NEW_ALPHA_TEST              0x100
+#define BRW_NEW_DEPTH_STENCIL           0x200
+#define BRW_NEW_SAMPLER                 0x400
+#define BRW_NEW_TEXTURE                 0x800
+#define BRW_NEW_CONSTANTS               0x1000
+#define BRW_NEW_VBO                     0x2000
+#define BRW_NEW_VS                      0x4000
+
+/* Raised for other internal events:
+ */
+#define BRW_NEW_URB_FENCE               0x10000
+#define BRW_NEW_PSP                     0x20000
+#define BRW_NEW_CURBE_OFFSETS           0x40000
+#define BRW_NEW_REDUCED_PRIMITIVE       0x80000
+#define BRW_NEW_PRIMITIVE               0x100000
+#define BRW_NEW_SCENE                 0x200000
+#define BRW_NEW_SF_LINKAGE              0x400000
+
+extern int BRW_DEBUG;
+
+#define DEBUG_TEXTURE  0x1
+#define DEBUG_STATE    0x2
+#define DEBUG_IOCTL    0x4
+#define DEBUG_PRIMS    0x8
+#define DEBUG_VERTS    0x10
+#define DEBUG_FALLBACKS        0x20
+#define DEBUG_VERBOSE  0x40
+#define DEBUG_DRI       0x80
+#define DEBUG_DMA       0x100
+#define DEBUG_SANITY    0x200
+#define DEBUG_SYNC      0x400
+#define DEBUG_SLEEP     0x800
+#define DEBUG_PIXEL     0x1000
+#define DEBUG_STATS     0x2000
+#define DEBUG_TILE      0x4000
+#define DEBUG_SINGLE_THREAD   0x8000
+#define DEBUG_WM        0x10000
+#define DEBUG_URB       0x20000
+#define DEBUG_VS        0x40000
+#define DEBUG_BATCH    0x80000
+#define DEBUG_BUFMGR   0x100000
+#define DEBUG_BLIT     0x200000
+#define DEBUG_REGION   0x400000
+#define DEBUG_MIPTREE  0x800000
+
+#define DBG(...) do {                                          \
+   if (BRW_DEBUG & FILE_DEBUG_FLAG)                            \
+      debug_printf(__VA_ARGS__);                               \
+} while(0)
+
+#define PRINT(...) do {                                                \
+   debug_printf(brw->pipe.winsys, __VA_ARGS__);                        \
+} while(0)
+
+struct brw_state_flags {
+   unsigned cache;
+   unsigned brw;
+};
+
+
+struct brw_vertex_program {
+   struct pipe_shader_state program;
+   struct tgsi_shader_info info;
+   int id;
+};
+
+
+struct brw_fragment_program {
+   struct pipe_shader_state program;
+   struct tgsi_shader_info info;
+   
+   boolean UsesDepth; /* XXX add this to tgsi_shader_info? */
+   int id;
+};
+
+
+struct pipe_setup_linkage {
+   struct {
+      unsigned vp_output:5;
+      unsigned interp_mode:4;
+      unsigned bf_vp_output:5;
+   } fp_input[PIPE_MAX_SHADER_INPUTS];
+
+   unsigned fp_input_count:5;
+   unsigned max_vp_output:5;
+};
+   
+
+
+struct brw_texture {
+   struct pipe_texture base;
+
+   /* Derived from the above:
+    */
+   unsigned pitch;
+   unsigned depth_pitch;          /* per-image on i945? */
+   unsigned total_height;
+
+   unsigned nr_images[PIPE_MAX_TEXTURE_LEVELS];
+
+   /* Explicitly store the offset of each image for each cube face or
+    * depth value.  Pretty much have to accept that hardware formats
+    * are going to be so diverse that there is no unified way to
+    * compute the offsets of depth/cube images within a mipmap level,
+    * so have to store them as a lookup table:
+    */
+   unsigned *image_offset[PIPE_MAX_TEXTURE_LEVELS];   /**< array [depth] of offsets */
+
+   /* Includes image offset tables:
+    */
+   unsigned level_offset[PIPE_MAX_TEXTURE_LEVELS];
+
+   /* The data is held here:
+    */
+   struct pipe_buffer *buffer;
+};
+
+/* Data about a particular attempt to compile a program.  Note that
+ * there can be many of these, each in a different GL state
+ * corresponding to a different brw_wm_prog_key struct, with different
+ * compiled programs:
+ */
+/* Data about a particular attempt to compile a program.  Note that
+ * there can be many of these, each in a different GL state
+ * corresponding to a different brw_wm_prog_key struct, with different
+ * compiled programs:
+ */
+
+struct brw_wm_prog_data {
+   unsigned curb_read_length;
+   unsigned urb_read_length;
+
+   unsigned first_curbe_grf;
+   unsigned total_grf;
+   unsigned total_scratch;
+
+   /* Internally generated constants for the CURBE.  These are loaded
+    * ahead of the data from the constant buffer.
+    */
+   const float internal_const[8];
+   unsigned nr_internal_consts;
+   unsigned max_const;
+
+   boolean error;
+};
+
+struct brw_sf_prog_data {
+   unsigned urb_read_length;
+   unsigned total_grf;
+
+   /* Each vertex may have upto 12 attributes, 4 components each,
+    * except WPOS which requires only 2.  (11*4 + 2) == 44 ==> 11
+    * rows.
+    *
+    * Actually we use 4 for each, so call it 12 rows.
+    */
+   unsigned urb_entry_size;
+};
+
+struct brw_clip_prog_data {
+   unsigned curb_read_length;  /* user planes? */
+   unsigned clip_mode;
+   unsigned urb_read_length;
+   unsigned total_grf;
+};
+
+struct brw_gs_prog_data {
+   unsigned urb_read_length;
+   unsigned total_grf;
+};
+
+struct brw_vs_prog_data {
+   unsigned curb_read_length;
+   unsigned urb_read_length;
+   unsigned total_grf;
+   unsigned outputs_written;
+
+   unsigned inputs_read;
+
+   unsigned max_const;
+
+   float    imm_buf[PIPE_MAX_CONSTANT][4];
+   unsigned num_imm;
+   unsigned num_consts;
+
+   /* Used for calculating urb partitions:
+    */
+   unsigned urb_entry_size;
+};
+
+
+#define BRW_MAX_TEX_UNIT 8
+#define BRW_WM_MAX_SURF BRW_MAX_TEX_UNIT + 1
+
+/* Create a fixed sized struct for caching binding tables:
+ */
+struct brw_surface_binding_table {
+   unsigned surf_ss_offset[BRW_WM_MAX_SURF];
+};
+
+
+struct brw_cache;
+
+struct brw_mem_pool {
+   struct pipe_buffer *buffer;
+
+   unsigned size;
+   unsigned offset;            /* offset of first free byte */
+
+   struct brw_context *brw;
+};
+
+struct brw_cache_item {
+   unsigned hash;
+   unsigned key_size;          /* for variable-sized keys */
+   const void *key;
+
+   unsigned offset;            /* offset within pool's buffer */
+   unsigned data_size;
+
+   struct brw_cache_item *next;
+};
+
+
+
+struct brw_cache {
+   unsigned id;
+
+   const char *name;
+
+   struct brw_context *brw;
+   struct brw_mem_pool *pool;
+
+   struct brw_cache_item **items;
+   unsigned size, n_items;
+
+   unsigned key_size;          /* for fixed-size keys */
+   unsigned aux_size;
+
+   unsigned last_addr;                 /* offset of active item */
+};
+
+
+
+
+/* Considered adding a member to this struct to document which flags
+ * an update might raise so that ordering of the state atoms can be
+ * checked or derived at runtime.  Dropped the idea in favor of having
+ * a debug mode where the state is monitored for flags which are
+ * raised that have already been tested against.
+ */
+struct brw_tracked_state {
+   struct brw_state_flags dirty;
+   void (*update)( struct brw_context *brw );
+};
+
+
+/* Flags for brw->state.cache.
+ */
+#define CACHE_NEW_CC_VP                  (1<<BRW_CC_VP)
+#define CACHE_NEW_CC_UNIT                (1<<BRW_CC_UNIT)
+#define CACHE_NEW_WM_PROG                (1<<BRW_WM_PROG)
+#define CACHE_NEW_SAMPLER_DEFAULT_COLOR  (1<<BRW_SAMPLER_DEFAULT_COLOR)
+#define CACHE_NEW_SAMPLER                (1<<BRW_SAMPLER)
+#define CACHE_NEW_WM_UNIT                (1<<BRW_WM_UNIT)
+#define CACHE_NEW_SF_PROG                (1<<BRW_SF_PROG)
+#define CACHE_NEW_SF_VP                  (1<<BRW_SF_VP)
+#define CACHE_NEW_SF_UNIT                (1<<BRW_SF_UNIT)
+#define CACHE_NEW_VS_UNIT                (1<<BRW_VS_UNIT)
+#define CACHE_NEW_VS_PROG                (1<<BRW_VS_PROG)
+#define CACHE_NEW_GS_UNIT                (1<<BRW_GS_UNIT)
+#define CACHE_NEW_GS_PROG                (1<<BRW_GS_PROG)
+#define CACHE_NEW_CLIP_VP                (1<<BRW_CLIP_VP)
+#define CACHE_NEW_CLIP_UNIT              (1<<BRW_CLIP_UNIT)
+#define CACHE_NEW_CLIP_PROG              (1<<BRW_CLIP_PROG)
+#define CACHE_NEW_SURFACE                (1<<BRW_SS_SURFACE)
+#define CACHE_NEW_SURF_BIND              (1<<BRW_SS_SURF_BIND)
+
+
+
+
+enum brw_mempool_id {
+   BRW_GS_POOL,
+   BRW_SS_POOL,
+   BRW_MAX_POOL
+};
+
+
+struct brw_cached_batch_item {
+   struct header *header;
+   unsigned sz;
+   struct brw_cached_batch_item *next;
+};
+
+
+
+/* Protect against a future where PIPE_MAX_ATTRIBS > 32.  Wouldn't life
+ * be easier if C allowed arrays of packed elements?
+ */
+#define ATTRIB_BIT_DWORDS  ((PIPE_MAX_ATTRIBS+31)/32)
+
+
+
+
+struct brw_vertex_info {
+   unsigned varying;  /* varying:1[PIPE_MAX_ATTRIBS] */
+   unsigned sizes[ATTRIB_BIT_DWORDS * 2]; /* sizes:2[PIPE_MAX_ATTRIBS] */
+};
+
+
+
+
+
+struct brw_context
+{
+   struct pipe_context pipe;
+   struct brw_winsys *winsys;
+
+   unsigned primitive;
+   unsigned reduced_primitive;
+
+   boolean emit_state_always;
+
+   struct {
+      struct brw_state_flags dirty;
+   } state;
+
+
+   struct {
+      const struct pipe_blend_state         *Blend;
+      const struct pipe_depth_stencil_alpha_state *DepthStencil;
+      const struct pipe_poly_stipple        *PolygonStipple;
+      const struct pipe_rasterizer_state    *Raster;
+      const struct pipe_sampler_state       *Samplers[PIPE_MAX_SAMPLERS];
+      const struct brw_vertex_program       *VertexProgram;
+      const struct brw_fragment_program     *FragmentProgram;
+
+      struct pipe_clip_state          Clip;
+      struct pipe_blend_color         BlendColor;
+      struct pipe_scissor_state       Scissor;
+      struct pipe_viewport_state      Viewport;
+      struct pipe_framebuffer_state   FrameBuffer;
+
+      const struct pipe_constant_buffer *Constants[2];
+      const struct brw_texture          *Texture[PIPE_MAX_SAMPLERS];
+   } attribs;
+
+   unsigned num_samplers;
+   unsigned num_textures;
+
+   struct brw_mem_pool pool[BRW_MAX_POOL];
+   struct brw_cache cache[BRW_MAX_CACHE];
+   struct brw_cached_batch_item *cached_batch_items;
+
+   struct {
+
+      /* Arrays with buffer objects to copy non-bufferobj arrays into
+       * for upload:
+       */
+      const struct pipe_vertex_buffer *vbo_array[PIPE_MAX_ATTRIBS];
+
+      struct brw_vertex_element_state inputs[PIPE_MAX_ATTRIBS];
+
+#define BRW_NR_UPLOAD_BUFS 17
+#define BRW_UPLOAD_INIT_SIZE (128*1024)
+
+      /* Summary of size and varying of active arrays, so we can check
+       * for changes to this state:
+       */
+      struct brw_vertex_info info;
+   } vb;
+
+
+   unsigned hardware_dirty;
+   unsigned dirty;
+   unsigned pci_id;
+   /* BRW_NEW_URB_ALLOCATIONS:
+    */
+   struct {
+      unsigned vsize;          /* vertex size plus header in urb registers */
+      unsigned csize;          /* constant buffer size in urb registers */
+      unsigned sfsize;         /* setup data size in urb registers */
+
+      boolean constrained;
+
+      unsigned nr_vs_entries;
+      unsigned nr_gs_entries;
+      unsigned nr_clip_entries;
+      unsigned nr_sf_entries;
+      unsigned nr_cs_entries;
+
+/*       unsigned vs_size; */
+/*       unsigned gs_size; */
+/*       unsigned clip_size; */
+/*       unsigned sf_size; */
+/*       unsigned cs_size; */
+
+      unsigned vs_start;
+      unsigned gs_start;
+      unsigned clip_start;
+      unsigned sf_start;
+      unsigned cs_start;
+   } urb;
+
+
+   /* BRW_NEW_CURBE_OFFSETS:
+    */
+   struct {
+      unsigned wm_start;
+      unsigned wm_size;
+      unsigned clip_start;
+      unsigned clip_size;
+      unsigned vs_start;
+      unsigned vs_size;
+      unsigned total_size;
+
+      unsigned gs_offset;
+
+      float *last_buf;
+      unsigned last_bufsz;
+   } curbe;
+
+   struct {
+      struct brw_vs_prog_data *prog_data;
+
+      unsigned prog_gs_offset;
+      unsigned state_gs_offset;
+   } vs;
+
+   struct {
+      struct brw_gs_prog_data *prog_data;
+
+      boolean prog_active;
+      unsigned prog_gs_offset;
+      unsigned state_gs_offset;
+   } gs;
+
+   struct {
+      struct brw_clip_prog_data *prog_data;
+
+      unsigned prog_gs_offset;
+      unsigned vp_gs_offset;
+      unsigned state_gs_offset;
+   } clip;
+
+
+   struct {
+      struct brw_sf_prog_data *prog_data;
+
+      struct pipe_setup_linkage linkage;
+
+      unsigned prog_gs_offset;
+      unsigned vp_gs_offset;
+      unsigned state_gs_offset;
+   } sf;
+
+   struct {
+      struct brw_wm_prog_data *prog_data;
+
+//      struct brw_wm_compiler *compile_data;
+
+
+      /**
+       * Array of sampler state uploaded at sampler_gs_offset of BRW_SAMPLER
+       * cache
+       */
+      struct brw_sampler_state sampler[BRW_MAX_TEX_UNIT];
+
+      unsigned render_surf;
+      unsigned nr_surfaces;
+
+      unsigned max_threads;
+      struct pipe_buffer *scratch_buffer;
+      unsigned scratch_buffer_size;
+
+      unsigned sampler_count;
+      unsigned sampler_gs_offset;
+
+      struct brw_surface_binding_table bind;
+      unsigned bind_ss_offset;
+
+      unsigned prog_gs_offset;
+      unsigned state_gs_offset;
+   } wm;
+
+
+   struct {
+      unsigned vp_gs_offset;
+      unsigned state_gs_offset;
+   } cc;
+
+
+   /* Used to give every program string a unique id
+    */
+   unsigned program_id;
+};
+
+
+#define BRW_PACKCOLOR8888(r,g,b,a)  ((r<<24) | (g<<16) | (b<<8) | a)
+
+
+/*======================================================================
+ * brw_vtbl.c
+ */
+void brw_do_flush( struct brw_context *brw,
+                  unsigned flags );
+
+
+/*======================================================================
+ * brw_state.c
+ */
+void brw_validate_state(struct brw_context *brw);
+void brw_init_state(struct brw_context *brw);
+void brw_destroy_state(struct brw_context *brw);
+
+
+/*======================================================================
+ * brw_tex.c
+ */
+void brwUpdateTextureState( struct brw_context *brw );
+
+
+/* brw_urb.c
+ */
+void brw_upload_urb_fence(struct brw_context *brw);
+
+void brw_upload_constant_buffer_state(struct brw_context *brw);
+
+void brw_init_surface_functions(struct brw_context *brw);
+void brw_init_state_functions(struct brw_context *brw);
+void brw_init_flush_functions(struct brw_context *brw);
+void brw_init_string_functions(struct brw_context *brw);
+
+/*======================================================================
+ * Inline conversion functions.  These are better-typed than the
+ * macros used previously:
+ */
+static inline struct brw_context *
+brw_context( struct pipe_context *ctx )
+{
+   return (struct brw_context *)ctx;
+}
+
+#endif
+
index ac243b7e4f9b1963e56180b8d1e8e318b4da70c1..caeeba4630059d094c4def1f81906e1b035ce056 100644 (file)
-/**************************************************************************\r
- *\r
- * Copyright 2007 Tungsten Graphics, Inc., Cedar Park, Texas.\r
- * All Rights Reserved.\r
- *\r
- * Permission is hereby granted, free of charge, to any person obtaining a\r
- * copy of this software and associated documentation files (the\r
- * "Software"), to deal in the Software without restriction, including\r
- * without limitation the rights to use, copy, modify, merge, publish,\r
- * distribute, sub license, and/or sell copies of the Software, and to\r
- * permit persons to whom the Software is furnished to do so, subject to\r
- * the following conditions:\r
- *\r
- * The above copyright notice and this permission notice (including the\r
- * next paragraph) shall be included in all copies or substantial portions\r
- * of the Software.\r
- *\r
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS\r
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.\r
- * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR\r
- * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\r
- * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\r
- * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\r
- *\r
- **************************************************************************/\r
-\r
-/* Authors:  Zack Rusin <zack@tungstengraphics.com>\r
- *           Keith Whitwell <keith@tungstengraphics.com>\r
- */\r
-\r
-\r
-#include "pipe/p_winsys.h"\r
-#include "pipe/p_util.h"\r
-#include "pipe/p_inlines.h"\r
-#include "pipe/p_shader_tokens.h"\r
-#include "tgsi/util/tgsi_dump.h"\r
-#include "tgsi/util/tgsi_parse.h"\r
-\r
-#include "brw_context.h"\r
-#include "brw_defines.h"\r
-#include "brw_state.h"\r
-#include "brw_draw.h"\r
-\r
-\r
-#define DUP( TYPE, VAL )                        \\r
-do {                                            \\r
-   struct TYPE *x = malloc(sizeof(*x));         \\r
-   memcpy(x, VAL, sizeof(*x) );                 \\r
-   return x;                                    \\r
-} while (0)\r
-\r
-/************************************************************************\r
- * Blend \r
- */\r
-static void *\r
-brw_create_blend_state(struct pipe_context *pipe,\r
-                        const struct pipe_blend_state *blend)\r
-{   \r
-   DUP( pipe_blend_state, blend );\r
-}\r
-\r
-static void brw_bind_blend_state(struct pipe_context *pipe,\r
-                                 void *blend)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.Blend = (struct pipe_blend_state*)blend;\r
-   brw->state.dirty.brw |= BRW_NEW_BLEND;\r
-}\r
-\r
-\r
-static void brw_delete_blend_state(struct pipe_context *pipe, void *blend)\r
-{\r
-   free(blend);\r
-}\r
-\r
-static void brw_set_blend_color( struct pipe_context *pipe,\r
-                            const struct pipe_blend_color *blend_color )\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.BlendColor = *blend_color;\r
-\r
-   brw->state.dirty.brw |= BRW_NEW_BLEND;\r
-}\r
-\r
-/************************************************************************\r
- * Sampler \r
- */\r
-\r
-static void *\r
-brw_create_sampler_state(struct pipe_context *pipe,\r
-                          const struct pipe_sampler_state *sampler)\r
-{\r
-   DUP( pipe_sampler_state, sampler );\r
-}\r
-\r
-static void brw_bind_sampler_states(struct pipe_context *pipe,\r
-                                    unsigned num, void **sampler)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   assert(num <= PIPE_MAX_SAMPLERS);\r
-\r
-   /* Check for no-op */\r
-   if (num == brw->num_samplers &&\r
-       !memcmp(brw->attribs.Samplers, sampler, num * sizeof(void *)))\r
-      return;\r
-\r
-   memcpy(brw->attribs.Samplers, sampler, num * sizeof(void *));\r
-   memset(&brw->attribs.Samplers[num], 0, (PIPE_MAX_SAMPLERS - num) *\r
-          sizeof(void *));\r
-\r
-   brw->num_samplers = num;\r
-\r
-   brw->state.dirty.brw |= BRW_NEW_SAMPLER;\r
-}\r
-\r
-static void brw_delete_sampler_state(struct pipe_context *pipe,\r
-                                      void *sampler)\r
-{\r
-   free(sampler);\r
-}\r
-\r
-\r
-/************************************************************************\r
- * Depth stencil \r
- */\r
-\r
-static void *\r
-brw_create_depth_stencil_state(struct pipe_context *pipe,\r
-                           const struct pipe_depth_stencil_alpha_state *depth_stencil)\r
-{\r
-   DUP( pipe_depth_stencil_alpha_state, depth_stencil );\r
-}\r
-\r
-static void brw_bind_depth_stencil_state(struct pipe_context *pipe,\r
-                                         void *depth_stencil)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.DepthStencil = (const struct pipe_depth_stencil_alpha_state *)depth_stencil;\r
-\r
-   brw->state.dirty.brw |= BRW_NEW_DEPTH_STENCIL;\r
-}\r
-\r
-static void brw_delete_depth_stencil_state(struct pipe_context *pipe,\r
-                                           void *depth_stencil)\r
-{\r
-   free(depth_stencil);\r
-}\r
-\r
-/************************************************************************\r
- * Scissor\r
- */\r
-static void brw_set_scissor_state( struct pipe_context *pipe,\r
-                                 const struct pipe_scissor_state *scissor )\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   memcpy( &brw->attribs.Scissor, scissor, sizeof(*scissor) );\r
-   brw->state.dirty.brw |= BRW_NEW_SCISSOR;\r
-}\r
-\r
-\r
-/************************************************************************\r
- * Stipple\r
- */\r
-\r
-static void brw_set_polygon_stipple( struct pipe_context *pipe,\r
-                                   const struct pipe_poly_stipple *stipple )\r
-{\r
-}\r
-\r
-\r
-/************************************************************************\r
- * Fragment shader\r
- */\r
-\r
-static void * brw_create_fs_state(struct pipe_context *pipe,\r
-                                   const struct pipe_shader_state *shader)\r
-{\r
-   struct brw_fragment_program *brw_fp = CALLOC_STRUCT(brw_fragment_program);\r
-\r
-   brw_fp->program.tokens = tgsi_dup_tokens(shader->tokens);\r
-   brw_fp->id = brw_context(pipe)->program_id++;\r
-\r
-   tgsi_scan_shader(shader->tokens, &brw_fp->info);\r
-\r
-#if 0\r
-   brw_shader_info(shader->tokens,\r
-                  &brw_fp->info2);\r
-#endif\r
-\r
-   tgsi_dump(shader->tokens, 0);\r
-\r
-\r
-   return (void *)brw_fp;\r
-}\r
-\r
-static void brw_bind_fs_state(struct pipe_context *pipe, void *shader)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.FragmentProgram = (struct brw_fragment_program *)shader;\r
-   brw->state.dirty.brw |= BRW_NEW_FS;\r
-}\r
-\r
-static void brw_delete_fs_state(struct pipe_context *pipe, void *shader)\r
-{\r
-   struct brw_fragment_program *brw_fp = (struct brw_fragment_program *) shader;\r
-\r
-   FREE((void *) brw_fp->program.tokens);\r
-   FREE(brw_fp);\r
-}\r
-\r
-\r
-/************************************************************************\r
- * Vertex shader and other TNL state \r
- */\r
-\r
-static void *brw_create_vs_state(struct pipe_context *pipe,\r
-                                 const struct pipe_shader_state *shader)\r
-{\r
-   struct brw_vertex_program *brw_vp = CALLOC_STRUCT(brw_vertex_program);\r
-\r
-   brw_vp->program.tokens = tgsi_dup_tokens(shader->tokens);\r
-   brw_vp->id = brw_context(pipe)->program_id++;\r
-\r
-   tgsi_scan_shader(shader->tokens, &brw_vp->info);\r
-\r
-#if 0\r
-   brw_shader_info(shader->tokens,\r
-                  &brw_vp->info2);\r
-#endif\r
-   tgsi_dump(shader->tokens, 0);\r
-\r
-   return (void *)brw_vp;\r
-}\r
-\r
-static void brw_bind_vs_state(struct pipe_context *pipe, void *vs)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.VertexProgram = (struct brw_vertex_program *)vs;\r
-   brw->state.dirty.brw |= BRW_NEW_VS;\r
-\r
-   debug_printf("YYYYYYYYYYYYY BINDING VERTEX SHADER\n");\r
-}\r
-\r
-static void brw_delete_vs_state(struct pipe_context *pipe, void *shader)\r
-{\r
-   struct brw_vertex_program *brw_vp = (struct brw_vertex_program *) shader;\r
-\r
-   FREE((void *) brw_vp->program.tokens);\r
-   FREE(brw_vp);\r
-}\r
-\r
-\r
-static void brw_set_clip_state( struct pipe_context *pipe,\r
-                                const struct pipe_clip_state *clip )\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.Clip = *clip;\r
-}\r
-\r
-\r
-static void brw_set_viewport_state( struct pipe_context *pipe,\r
-                                    const struct pipe_viewport_state *viewport )\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.Viewport = *viewport; /* struct copy */\r
-   brw->state.dirty.brw |= BRW_NEW_VIEWPORT;\r
-\r
-   /* pass the viewport info to the draw module */\r
-   //draw_set_viewport_state(brw->draw, viewport);\r
-}\r
-\r
-\r
-static void brw_set_vertex_buffers(struct pipe_context *pipe,\r
-                                  unsigned count,\r
-                                  const struct pipe_vertex_buffer *buffers)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-   memcpy(brw->vb.vbo_array, buffers, count * sizeof(buffers[0]));\r
-}\r
-\r
-static void brw_set_vertex_elements(struct pipe_context *pipe,\r
-                                    unsigned count,\r
-                                    const struct pipe_vertex_element *elements)\r
-{\r
-   /* flush ? */\r
-   struct brw_context *brw = brw_context(pipe);\r
-   uint i;\r
-\r
-   assert(count <= PIPE_MAX_ATTRIBS);\r
-\r
-   for (i = 0; i < count; i++) {\r
-      struct brw_vertex_element_state el;\r
-      memset(&el, 0, sizeof(el));\r
-\r
-      el.ve0.src_offset = elements[i].src_offset;\r
-      el.ve0.src_format = brw_translate_surface_format(elements[i].src_format);\r
-      el.ve0.valid = 1;\r
-      el.ve0.vertex_buffer_index = elements[i].vertex_buffer_index;\r
-\r
-      el.ve1.dst_offset   = i * 4;\r
-\r
-      el.ve1.vfcomponent3 = BRW_VFCOMPONENT_STORE_SRC;\r
-      el.ve1.vfcomponent2 = BRW_VFCOMPONENT_STORE_SRC;\r
-      el.ve1.vfcomponent1 = BRW_VFCOMPONENT_STORE_SRC;\r
-      el.ve1.vfcomponent0 = BRW_VFCOMPONENT_STORE_SRC;\r
-\r
-      switch (elements[i].nr_components) {\r
-      case 1: el.ve1.vfcomponent1 = BRW_VFCOMPONENT_STORE_0;\r
-      case 2: el.ve1.vfcomponent2 = BRW_VFCOMPONENT_STORE_0;\r
-      case 3: el.ve1.vfcomponent3 = BRW_VFCOMPONENT_STORE_1_FLT;\r
-         break;\r
-      }\r
-\r
-      brw->vb.inputs[i] = el;\r
-   }\r
-}\r
-\r
-\r
-\r
-/************************************************************************\r
- * Constant buffers\r
- */\r
-\r
-static void brw_set_constant_buffer(struct pipe_context *pipe,\r
-                                     uint shader, uint index,\r
-                                     const struct pipe_constant_buffer *buf)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   assert(buf == 0 || index == 0);\r
-\r
-   brw->attribs.Constants[shader] = buf;\r
-   brw->state.dirty.brw |= BRW_NEW_CONSTANTS;\r
-}\r
-\r
-\r
-/************************************************************************\r
- * Texture surfaces\r
- */\r
-\r
-\r
-static void brw_set_sampler_textures(struct pipe_context *pipe,\r
-                                     unsigned num,\r
-                                     struct pipe_texture **texture)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-   uint i;\r
-\r
-   assert(num <= PIPE_MAX_SAMPLERS);\r
-\r
-   /* Check for no-op */\r
-   if (num == brw->num_textures &&\r
-       !memcmp(brw->attribs.Texture, texture, num *\r
-               sizeof(struct pipe_texture *)))\r
-      return;\r
-\r
-   for (i = 0; i < num; i++)\r
-      pipe_texture_reference((struct pipe_texture **) &brw->attribs.Texture[i],\r
-                             texture[i]);\r
-\r
-   for (i = num; i < brw->num_textures; i++)\r
-      pipe_texture_reference((struct pipe_texture **) &brw->attribs.Texture[i],\r
-                             NULL);\r
-\r
-   brw->num_textures = num;\r
-\r
-   brw->state.dirty.brw |= BRW_NEW_TEXTURE;\r
-}\r
-\r
-\r
-/************************************************************************\r
- * Render targets, etc\r
- */\r
-\r
-static void brw_set_framebuffer_state(struct pipe_context *pipe,\r
-                                      const struct pipe_framebuffer_state *fb)\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.FrameBuffer = *fb; /* struct copy */\r
-\r
-   brw->state.dirty.brw |= BRW_NEW_FRAMEBUFFER;\r
-}\r
-\r
-\r
-\r
-/************************************************************************\r
- * Rasterizer state\r
- */\r
-\r
-static void *\r
-brw_create_rasterizer_state(struct pipe_context *pipe,\r
-                             const struct pipe_rasterizer_state *rasterizer)\r
-{\r
-   DUP(pipe_rasterizer_state, rasterizer);\r
-}\r
-\r
-static void brw_bind_rasterizer_state( struct pipe_context *pipe,\r
-                                        void *setup )\r
-{\r
-   struct brw_context *brw = brw_context(pipe);\r
-\r
-   brw->attribs.Raster = (struct pipe_rasterizer_state *)setup;\r
-\r
-   /* Also pass-through to draw module:\r
-    */\r
-   //draw_set_rasterizer_state(brw->draw, setup);\r
-\r
-   brw->state.dirty.brw |= BRW_NEW_RASTERIZER;\r
-}\r
-\r
-static void brw_delete_rasterizer_state(struct pipe_context *pipe,\r
-                                         void *setup)\r
-{\r
-   free(setup);\r
-}\r
-\r
-\r
-\r
-void\r
-brw_init_state_functions( struct brw_context *brw )\r
-{\r
-   brw->pipe.create_blend_state = brw_create_blend_state;\r
-   brw->pipe.bind_blend_state = brw_bind_blend_state;\r
-   brw->pipe.delete_blend_state = brw_delete_blend_state;\r
-\r
-   brw->pipe.create_sampler_state = brw_create_sampler_state;\r
-   brw->pipe.bind_sampler_states = brw_bind_sampler_states;\r
-   brw->pipe.delete_sampler_state = brw_delete_sampler_state;\r
-\r
-   brw->pipe.create_depth_stencil_alpha_state = brw_create_depth_stencil_state;\r
-   brw->pipe.bind_depth_stencil_alpha_state = brw_bind_depth_stencil_state;\r
-   brw->pipe.delete_depth_stencil_alpha_state = brw_delete_depth_stencil_state;\r
-\r
-   brw->pipe.create_rasterizer_state = brw_create_rasterizer_state;\r
-   brw->pipe.bind_rasterizer_state = brw_bind_rasterizer_state;\r
-   brw->pipe.delete_rasterizer_state = brw_delete_rasterizer_state;\r
-   brw->pipe.create_fs_state = brw_create_fs_state;\r
-   brw->pipe.bind_fs_state = brw_bind_fs_state;\r
-   brw->pipe.delete_fs_state = brw_delete_fs_state;\r
-   brw->pipe.create_vs_state = brw_create_vs_state;\r
-   brw->pipe.bind_vs_state = brw_bind_vs_state;\r
-   brw->pipe.delete_vs_state = brw_delete_vs_state;\r
-\r
-   brw->pipe.set_blend_color = brw_set_blend_color;\r
-   brw->pipe.set_clip_state = brw_set_clip_state;\r
-   brw->pipe.set_constant_buffer = brw_set_constant_buffer;\r
-   brw->pipe.set_framebuffer_state = brw_set_framebuffer_state;\r
-\r
-//   brw->pipe.set_feedback_state = brw_set_feedback_state;\r
-//   brw->pipe.set_feedback_buffer = brw_set_feedback_buffer;\r
-\r
-   brw->pipe.set_polygon_stipple = brw_set_polygon_stipple;\r
-   brw->pipe.set_scissor_state = brw_set_scissor_state;\r
-   brw->pipe.set_sampler_textures = brw_set_sampler_textures;\r
-   brw->pipe.set_viewport_state = brw_set_viewport_state;\r
-   brw->pipe.set_vertex_buffers = brw_set_vertex_buffers;\r
-   brw->pipe.set_vertex_elements = brw_set_vertex_elements;\r
-}\r
+/**************************************************************************
+ *
+ * Copyright 2007 Tungsten Graphics, Inc., Cedar Park, Texas.
+ * All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ *
+ **************************************************************************/
+
+/* Authors:  Zack Rusin <zack@tungstengraphics.com>
+ *           Keith Whitwell <keith@tungstengraphics.com>
+ */
+
+
+#include "pipe/p_winsys.h"
+#include "pipe/p_util.h"
+#include "pipe/p_inlines.h"
+#include "pipe/p_shader_tokens.h"
+#include "tgsi/util/tgsi_dump.h"
+#include "tgsi/util/tgsi_parse.h"
+
+#include "brw_context.h"
+#include "brw_defines.h"
+#include "brw_state.h"
+#include "brw_draw.h"
+
+
+#define DUP( TYPE, VAL )                        \
+do {                                            \
+   struct TYPE *x = malloc(sizeof(*x));         \
+   memcpy(x, VAL, sizeof(*x) );                 \
+   return x;                                    \
+} while (0)
+
+/************************************************************************
+ * Blend 
+ */
+static void *
+brw_create_blend_state(struct pipe_context *pipe,
+                        const struct pipe_blend_state *blend)
+{   
+   DUP( pipe_blend_state, blend );
+}
+
+static void brw_bind_blend_state(struct pipe_context *pipe,
+                                 void *blend)
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.Blend = (struct pipe_blend_state*)blend;
+   brw->state.dirty.brw |= BRW_NEW_BLEND;
+}
+
+
+static void brw_delete_blend_state(struct pipe_context *pipe, void *blend)
+{
+   free(blend);
+}
+
+static void brw_set_blend_color( struct pipe_context *pipe,
+                            const struct pipe_blend_color *blend_color )
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.BlendColor = *blend_color;
+
+   brw->state.dirty.brw |= BRW_NEW_BLEND;
+}
+
+/************************************************************************
+ * Sampler 
+ */
+
+static void *
+brw_create_sampler_state(struct pipe_context *pipe,
+                          const struct pipe_sampler_state *sampler)
+{
+   DUP( pipe_sampler_state, sampler );
+}
+
+static void brw_bind_sampler_states(struct pipe_context *pipe,
+                                    unsigned num, void **sampler)
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   assert(num <= PIPE_MAX_SAMPLERS);
+
+   /* Check for no-op */
+   if (num == brw->num_samplers &&
+       !memcmp(brw->attribs.Samplers, sampler, num * sizeof(void *)))
+      return;
+
+   memcpy(brw->attribs.Samplers, sampler, num * sizeof(void *));
+   memset(&brw->attribs.Samplers[num], 0, (PIPE_MAX_SAMPLERS - num) *
+          sizeof(void *));
+
+   brw->num_samplers = num;
+
+   brw->state.dirty.brw |= BRW_NEW_SAMPLER;
+}
+
+static void brw_delete_sampler_state(struct pipe_context *pipe,
+                                      void *sampler)
+{
+   free(sampler);
+}
+
+
+/************************************************************************
+ * Depth stencil 
+ */
+
+static void *
+brw_create_depth_stencil_state(struct pipe_context *pipe,
+                           const struct pipe_depth_stencil_alpha_state *depth_stencil)
+{
+   DUP( pipe_depth_stencil_alpha_state, depth_stencil );
+}
+
+static void brw_bind_depth_stencil_state(struct pipe_context *pipe,
+                                         void *depth_stencil)
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.DepthStencil = (const struct pipe_depth_stencil_alpha_state *)depth_stencil;
+
+   brw->state.dirty.brw |= BRW_NEW_DEPTH_STENCIL;
+}
+
+static void brw_delete_depth_stencil_state(struct pipe_context *pipe,
+                                           void *depth_stencil)
+{
+   free(depth_stencil);
+}
+
+/************************************************************************
+ * Scissor
+ */
+static void brw_set_scissor_state( struct pipe_context *pipe,
+                                 const struct pipe_scissor_state *scissor )
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   memcpy( &brw->attribs.Scissor, scissor, sizeof(*scissor) );
+   brw->state.dirty.brw |= BRW_NEW_SCISSOR;
+}
+
+
+/************************************************************************
+ * Stipple
+ */
+
+static void brw_set_polygon_stipple( struct pipe_context *pipe,
+                                   const struct pipe_poly_stipple *stipple )
+{
+}
+
+
+/************************************************************************
+ * Fragment shader
+ */
+
+static void * brw_create_fs_state(struct pipe_context *pipe,
+                                   const struct pipe_shader_state *shader)
+{
+   struct brw_fragment_program *brw_fp = CALLOC_STRUCT(brw_fragment_program);
+
+   brw_fp->program.tokens = tgsi_dup_tokens(shader->tokens);
+   brw_fp->id = brw_context(pipe)->program_id++;
+
+   tgsi_scan_shader(shader->tokens, &brw_fp->info);
+
+#if 0
+   brw_shader_info(shader->tokens,
+                  &brw_fp->info2);
+#endif
+
+   tgsi_dump(shader->tokens, 0);
+
+
+   return (void *)brw_fp;
+}
+
+static void brw_bind_fs_state(struct pipe_context *pipe, void *shader)
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.FragmentProgram = (struct brw_fragment_program *)shader;
+   brw->state.dirty.brw |= BRW_NEW_FS;
+}
+
+static void brw_delete_fs_state(struct pipe_context *pipe, void *shader)
+{
+   struct brw_fragment_program *brw_fp = (struct brw_fragment_program *) shader;
+
+   FREE((void *) brw_fp->program.tokens);
+   FREE(brw_fp);
+}
+
+
+/************************************************************************
+ * Vertex shader and other TNL state 
+ */
+
+static void *brw_create_vs_state(struct pipe_context *pipe,
+                                 const struct pipe_shader_state *shader)
+{
+   struct brw_vertex_program *brw_vp = CALLOC_STRUCT(brw_vertex_program);
+
+   brw_vp->program.tokens = tgsi_dup_tokens(shader->tokens);
+   brw_vp->id = brw_context(pipe)->program_id++;
+
+   tgsi_scan_shader(shader->tokens, &brw_vp->info);
+
+#if 0
+   brw_shader_info(shader->tokens,
+                  &brw_vp->info2);
+#endif
+   tgsi_dump(shader->tokens, 0);
+
+   return (void *)brw_vp;
+}
+
+static void brw_bind_vs_state(struct pipe_context *pipe, void *vs)
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.VertexProgram = (struct brw_vertex_program *)vs;
+   brw->state.dirty.brw |= BRW_NEW_VS;
+
+   debug_printf("YYYYYYYYYYYYY BINDING VERTEX SHADER\n");
+}
+
+static void brw_delete_vs_state(struct pipe_context *pipe, void *shader)
+{
+   struct brw_vertex_program *brw_vp = (struct brw_vertex_program *) shader;
+
+   FREE((void *) brw_vp->program.tokens);
+   FREE(brw_vp);
+}
+
+
+static void brw_set_clip_state( struct pipe_context *pipe,
+                                const struct pipe_clip_state *clip )
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.Clip = *clip;
+}
+
+
+static void brw_set_viewport_state( struct pipe_context *pipe,
+                                    const struct pipe_viewport_state *viewport )
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.Viewport = *viewport; /* struct copy */
+   brw->state.dirty.brw |= BRW_NEW_VIEWPORT;
+
+   /* pass the viewport info to the draw module */
+   //draw_set_viewport_state(brw->draw, viewport);
+}
+
+
+static void brw_set_vertex_buffers(struct pipe_context *pipe,
+                                  unsigned count,
+                                  const struct pipe_vertex_buffer *buffers)
+{
+   struct brw_context *brw = brw_context(pipe);
+   memcpy(brw->vb.vbo_array, buffers, count * sizeof(buffers[0]));
+}
+
+static void brw_set_vertex_elements(struct pipe_context *pipe,
+                                    unsigned count,
+                                    const struct pipe_vertex_element *elements)
+{
+   /* flush ? */
+   struct brw_context *brw = brw_context(pipe);
+   uint i;
+
+   assert(count <= PIPE_MAX_ATTRIBS);
+
+   for (i = 0; i < count; i++) {
+      struct brw_vertex_element_state el;
+      memset(&el, 0, sizeof(el));
+
+      el.ve0.src_offset = elements[i].src_offset;
+      el.ve0.src_format = brw_translate_surface_format(elements[i].src_format);
+      el.ve0.valid = 1;
+      el.ve0.vertex_buffer_index = elements[i].vertex_buffer_index;
+
+      el.ve1.dst_offset   = i * 4;
+
+      el.ve1.vfcomponent3 = BRW_VFCOMPONENT_STORE_SRC;
+      el.ve1.vfcomponent2 = BRW_VFCOMPONENT_STORE_SRC;
+      el.ve1.vfcomponent1 = BRW_VFCOMPONENT_STORE_SRC;
+      el.ve1.vfcomponent0 = BRW_VFCOMPONENT_STORE_SRC;
+
+      switch (elements[i].nr_components) {
+      case 1: el.ve1.vfcomponent1 = BRW_VFCOMPONENT_STORE_0;
+      case 2: el.ve1.vfcomponent2 = BRW_VFCOMPONENT_STORE_0;
+      case 3: el.ve1.vfcomponent3 = BRW_VFCOMPONENT_STORE_1_FLT;
+         break;
+      }
+
+      brw->vb.inputs[i] = el;
+   }
+}
+
+
+
+/************************************************************************
+ * Constant buffers
+ */
+
+static void brw_set_constant_buffer(struct pipe_context *pipe,
+                                     uint shader, uint index,
+                                     const struct pipe_constant_buffer *buf)
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   assert(buf == 0 || index == 0);
+
+   brw->attribs.Constants[shader] = buf;
+   brw->state.dirty.brw |= BRW_NEW_CONSTANTS;
+}
+
+
+/************************************************************************
+ * Texture surfaces
+ */
+
+
+static void brw_set_sampler_textures(struct pipe_context *pipe,
+                                     unsigned num,
+                                     struct pipe_texture **texture)
+{
+   struct brw_context *brw = brw_context(pipe);
+   uint i;
+
+   assert(num <= PIPE_MAX_SAMPLERS);
+
+   /* Check for no-op */
+   if (num == brw->num_textures &&
+       !memcmp(brw->attribs.Texture, texture, num *
+               sizeof(struct pipe_texture *)))
+      return;
+
+   for (i = 0; i < num; i++)
+      pipe_texture_reference((struct pipe_texture **) &brw->attribs.Texture[i],
+                             texture[i]);
+
+   for (i = num; i < brw->num_textures; i++)
+      pipe_texture_reference((struct pipe_texture **) &brw->attribs.Texture[i],
+                             NULL);
+
+   brw->num_textures = num;
+
+   brw->state.dirty.brw |= BRW_NEW_TEXTURE;
+}
+
+
+/************************************************************************
+ * Render targets, etc
+ */
+
+static void brw_set_framebuffer_state(struct pipe_context *pipe,
+                                      const struct pipe_framebuffer_state *fb)
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.FrameBuffer = *fb; /* struct copy */
+
+   brw->state.dirty.brw |= BRW_NEW_FRAMEBUFFER;
+}
+
+
+
+/************************************************************************
+ * Rasterizer state
+ */
+
+static void *
+brw_create_rasterizer_state(struct pipe_context *pipe,
+                             const struct pipe_rasterizer_state *rasterizer)
+{
+   DUP(pipe_rasterizer_state, rasterizer);
+}
+
+static void brw_bind_rasterizer_state( struct pipe_context *pipe,
+                                        void *setup )
+{
+   struct brw_context *brw = brw_context(pipe);
+
+   brw->attribs.Raster = (struct pipe_rasterizer_state *)setup;
+
+   /* Also pass-through to draw module:
+    */
+   //draw_set_rasterizer_state(brw->draw, setup);
+
+   brw->state.dirty.brw |= BRW_NEW_RASTERIZER;
+}
+
+static void brw_delete_rasterizer_state(struct pipe_context *pipe,
+                                         void *setup)
+{
+   free(setup);
+}
+
+
+
+void
+brw_init_state_functions( struct brw_context *brw )
+{
+   brw->pipe.create_blend_state = brw_create_blend_state;
+   brw->pipe.bind_blend_state = brw_bind_blend_state;
+   brw->pipe.delete_blend_state = brw_delete_blend_state;
+
+   brw->pipe.create_sampler_state = brw_create_sampler_state;
+   brw->pipe.bind_sampler_states = brw_bind_sampler_states;
+   brw->pipe.delete_sampler_state = brw_delete_sampler_state;
+
+   brw->pipe.create_depth_stencil_alpha_state = brw_create_depth_stencil_state;
+   brw->pipe.bind_depth_stencil_alpha_state = brw_bind_depth_stencil_state;
+   brw->pipe.delete_depth_stencil_alpha_state = brw_delete_depth_stencil_state;
+
+   brw->pipe.create_rasterizer_state = brw_create_rasterizer_state;
+   brw->pipe.bind_rasterizer_state = brw_bind_rasterizer_state;
+   brw->pipe.delete_rasterizer_state = brw_delete_rasterizer_state;
+   brw->pipe.create_fs_state = brw_create_fs_state;
+   brw->pipe.bind_fs_state = brw_bind_fs_state;
+   brw->pipe.delete_fs_state = brw_delete_fs_state;
+   brw->pipe.create_vs_state = brw_create_vs_state;
+   brw->pipe.bind_vs_state = brw_bind_vs_state;
+   brw->pipe.delete_vs_state = brw_delete_vs_state;
+
+   brw->pipe.set_blend_color = brw_set_blend_color;
+   brw->pipe.set_clip_state = brw_set_clip_state;
+   brw->pipe.set_constant_buffer = brw_set_constant_buffer;
+   brw->pipe.set_framebuffer_state = brw_set_framebuffer_state;
+
+//   brw->pipe.set_feedback_state = brw_set_feedback_state;
+//   brw->pipe.set_feedback_buffer = brw_set_feedback_buffer;
+
+   brw->pipe.set_polygon_stipple = brw_set_polygon_stipple;
+   brw->pipe.set_scissor_state = brw_set_scissor_state;
+   brw->pipe.set_sampler_textures = brw_set_sampler_textures;
+   brw->pipe.set_viewport_state = brw_set_viewport_state;
+   brw->pipe.set_vertex_buffers = brw_set_vertex_buffers;
+   brw->pipe.set_vertex_elements = brw_set_vertex_elements;
+}
index c99a91dcf76478f61ddf83af81f40a2309edbe56..3e3736b28065cac9df63fab4e55ae6e878128a3e 100644 (file)
 #include "util/p_tile.h"
 
 
-/* Upload data to a rectangular sub-region.  Lots of choices how to do this:
- *
- * - memcpy by span to current destination
- * - upload data as new buffer and blit
- *
- * Currently always memcpy.
- */
-static void
-brw_surface_data(struct pipe_context *pipe,
-                 struct pipe_surface *dst,
-                 unsigned dstx, unsigned dsty,
-                 const void *src, unsigned src_pitch,
-                 unsigned srcx, unsigned srcy, unsigned width, unsigned height)
-{
-   pipe_copy_rect(pipe_surface_map(dst) + dst->offset,
-                  dst->cpp, dst->pitch,
-                  dstx, dsty, width, height, src, src_pitch, srcx, srcy);
-
-   pipe_surface_unmap(dst);
-}
-
 
 /* Assumes all values are within bounds -- no checking at this level -
  * do it higher up if required.
@@ -72,17 +51,25 @@ brw_surface_copy(struct pipe_context *pipe,
    assert(dst->cpp == src->cpp);
 
    if (0) {
-      pipe_copy_rect(pipe_surface_map(dst) + dst->offset,
+      void *dst_map = pipe->screen->surface_map( pipe->screen,
+                                                 dst,
+                                                 PIPE_BUFFER_USAGE_CPU_WRITE );
+      
+      const void *src_map = pipe->screen->surface_map( pipe->screen,
+                                                       src,
+                                                       PIPE_BUFFER_USAGE_CPU_READ );
+      
+      pipe_copy_rect(dst_map,
                      dst->cpp,
                      dst->pitch,
-                     dstx, dsty,
-                     width, height,
-                     pipe_surface_map(src) + src->offset,
-                     do_flip ? -src->pitch : src->pitch,
+                     dstx, dsty, 
+                     width, height, 
+                     src_map, 
+                     do_flip ? -(int) src->pitch : src->pitch, 
                      srcx, do_flip ? 1 - srcy - height : srcy);
 
-      pipe_surface_unmap(src);
-      pipe_surface_unmap(dst);
+      pipe->screen->surface_unmap(pipe->screen, src);
+      pipe->screen->surface_unmap(pipe->screen, dst);
    }
    else {
       brw_copy_blit(brw_context(pipe),
@@ -113,7 +100,10 @@ brw_surface_fill(struct pipe_context *pipe,
 {
    if (0) {
       unsigned i, j;
-      void *dst_map = pipe_surface_map(dst);
+      void *dst_map = pipe->screen->surface_map( pipe->screen,
+                                                 dst,
+                                                 PIPE_BUFFER_USAGE_CPU_WRITE );
+
 
       switch (dst->cpp) {
       case 1: {
@@ -147,7 +137,7 @@ brw_surface_fill(struct pipe_context *pipe,
         break;
       }
 
-      pipe_surface_unmap( dst );
+      pipe->screen->surface_unmap(pipe->screen, dst);
    }
    else {
       brw_fill_blit(brw_context(pipe),
@@ -164,7 +154,6 @@ brw_surface_fill(struct pipe_context *pipe,
 void
 brw_init_surface_functions(struct brw_context *brw)
 {
-   (void) brw_surface_data; /* silence warning */
    brw->pipe.surface_copy  = brw_surface_copy;
    brw->pipe.surface_fill  = brw_surface_fill;
 }
index b580f98204c745c19fd6e729f43aec4590c4bcc8..78ae0b1223e25362aca3abb39af738b058de2a8e 100644 (file)
@@ -357,14 +357,6 @@ brw_texture_release_screen(struct pipe_screen *screen,
 }
 
 
-static void
-brw_texture_update(struct pipe_context *pipe, struct pipe_texture *texture,
-                   uint face, uint levelsMask)
-{
-   /* no-op? */
-}
-
-
 static struct pipe_surface *
 brw_get_tex_surface_screen(struct pipe_screen *screen,
                            struct pipe_texture *pt,
@@ -407,7 +399,7 @@ brw_get_tex_surface_screen(struct pipe_screen *screen,
 void
 brw_init_texture_functions(struct brw_context *brw)
 {
-   brw->pipe.texture_update = brw_texture_update;
+//   brw->pipe.texture_update = brw_texture_update;
 }
 
 
index fe9cd8375e39ef26175d869e48629a43c22f13e5..2af0db37143752f521c5b6cdeb3457707e30aa0e 100644 (file)
@@ -192,11 +192,11 @@ softpipe_create( struct pipe_screen *screen,
     * Must be before quad stage setup!
     */
    for (i = 0; i < PIPE_MAX_COLOR_BUFS; i++)
-      softpipe->cbuf_cache[i] = sp_create_tile_cache();
-   softpipe->zsbuf_cache = sp_create_tile_cache();
+      softpipe->cbuf_cache[i] = sp_create_tile_cache( screen );
+   softpipe->zsbuf_cache = sp_create_tile_cache( screen );
 
    for (i = 0; i < PIPE_MAX_SAMPLERS; i++)
-      softpipe->tex_cache[i] = sp_create_tile_cache();
+      softpipe->tex_cache[i] = sp_create_tile_cache( screen );
 
 
    /* setup quad rendering stages */
index 0625b69099b084e378970ed84bb4f37f64bae712..e03994b63b76a53e7ff12afc4145b8b8170f6a90 100644 (file)
@@ -50,25 +50,28 @@ softpipe_flush( struct pipe_context *pipe,
 
    draw_flush(softpipe->draw);
 
-   /* - flush the quad pipeline
-    * - flush the texture cache
-    * - flush the render cache
-    */
+   if (flags & PIPE_FLUSH_TEXTURE_CACHE) {
+      for (i = 0; i < softpipe->num_textures; i++) {
+         sp_flush_tile_cache(softpipe, softpipe->tex_cache[i]);
+      }
+   }
 
-   for (i = 0; i < softpipe->framebuffer.num_cbufs; i++)
-      if (softpipe->cbuf_cache[i])
-         sp_flush_tile_cache(softpipe, softpipe->cbuf_cache[i]);
+   if (flags & PIPE_FLUSH_RENDER_CACHE) {
+      for (i = 0; i < softpipe->framebuffer.num_cbufs; i++)
+         if (softpipe->cbuf_cache[i])
+            sp_flush_tile_cache(softpipe, softpipe->cbuf_cache[i]);
 
-   if (softpipe->zsbuf_cache)
-      sp_flush_tile_cache(softpipe, softpipe->zsbuf_cache);
+      if (softpipe->zsbuf_cache)
+         sp_flush_tile_cache(softpipe, softpipe->zsbuf_cache);
 
-   /* Need this call for hardware buffers before swapbuffers.
-    *
-    * there should probably be another/different flush-type function
-    * that's called before swapbuffers because we don't always want
-    * to unmap surfaces when flushing.
-    */
-   softpipe_unmap_surfaces(softpipe);
+      /* Need this call for hardware buffers before swapbuffers.
+       *
+       * there should probably be another/different flush-type function
+       * that's called before swapbuffers because we don't always want
+       * to unmap surfaces when flushing.
+       */
+      softpipe_unmap_surfaces(softpipe);
+   }
 
    if (fence)
       *fence = NULL;
index 7dacb1c461378ca5c104935789d5c8749d047c0c..e9926bf41f93bc54a3886fd58056e28804e05499 100644 (file)
@@ -33,6 +33,7 @@
 
 #include "sp_texture.h"
 #include "sp_winsys.h"
+#include "sp_screen.h"
 
 
 static const char *
@@ -137,6 +138,7 @@ softpipe_destroy_screen( struct pipe_screen *screen )
 }
 
 
+
 /**
  * Create a new pipe_screen object
  * Note: we're not presently subclassing pipe_screen (no softpipe_screen).
@@ -144,22 +146,22 @@ softpipe_destroy_screen( struct pipe_screen *screen )
 struct pipe_screen *
 softpipe_create_screen(struct pipe_winsys *winsys)
 {
-   struct pipe_screen *screen = CALLOC_STRUCT(pipe_screen);
+   struct softpipe_screen *screen = CALLOC_STRUCT(softpipe_screen);
 
    if (!screen)
       return NULL;
 
-   screen->winsys = winsys;
+   screen->base.winsys = winsys;
 
-   screen->destroy = softpipe_destroy_screen;
+   screen->base.destroy = softpipe_destroy_screen;
 
-   screen->get_name = softpipe_get_name;
-   screen->get_vendor = softpipe_get_vendor;
-   screen->get_param = softpipe_get_param;
-   screen->get_paramf = softpipe_get_paramf;
-   screen->is_format_supported = softpipe_is_format_supported;
+   screen->base.get_name = softpipe_get_name;
+   screen->base.get_vendor = softpipe_get_vendor;
+   screen->base.get_param = softpipe_get_param;
+   screen->base.get_paramf = softpipe_get_paramf;
+   screen->base.is_format_supported = softpipe_is_format_supported;
 
-   softpipe_init_screen_texture_funcs(screen);
+   softpipe_init_screen_texture_funcs(&screen->base);
 
-   return screen;
+   return &screen->base;
 }
diff --git a/src/gallium/drivers/softpipe/sp_screen.h b/src/gallium/drivers/softpipe/sp_screen.h
new file mode 100644 (file)
index 0000000..3d4bfd3
--- /dev/null
@@ -0,0 +1,58 @@
+/**************************************************************************
+ * 
+ * Copyright 2007 Tungsten Graphics, Inc., Cedar Park, Texas.
+ * All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ * 
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ * 
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ * 
+ **************************************************************************/
+
+/* Authors:  Keith Whitwell <keith@tungstengraphics.com>
+ */
+
+#ifndef SP_SCREEN_H
+#define SP_SCREEN_H
+
+#include "pipe/p_screen.h"
+#include "pipe/p_defines.h"
+
+
+
+struct softpipe_screen {
+   struct pipe_screen base;
+
+   /* Increments whenever textures are modified.  Contexts can track
+    * this.
+    */
+   unsigned timestamp;          
+};
+
+
+
+
+static INLINE struct softpipe_screen *
+softpipe_screen( struct pipe_screen *pipe )
+{
+   return (struct softpipe_screen *)pipe;
+}
+
+
+#endif /* SP_SCREEN_H */
index 653449c4f182473a25f02d642bb8753c1545ed33..29a1e92416ee15e1f9b470868dcfb9af1200d32f 100644 (file)
@@ -46,19 +46,28 @@ sp_surface_copy(struct pipe_context *pipe,
                struct pipe_surface *src,
                unsigned srcx, unsigned srcy, unsigned width, unsigned height)
 {
+   void *dst_map = pipe->screen->surface_map( pipe->screen,
+                                              dst,
+                                              PIPE_BUFFER_USAGE_CPU_WRITE );
+
+   const void *src_map = pipe->screen->surface_map( pipe->screen,
+                                                    src,
+                                                    PIPE_BUFFER_USAGE_CPU_READ );
+
    assert( dst->cpp == src->cpp );
+   assert(src_map && dst_map);
 
-   pipe_copy_rect(pipe_surface_map(dst),
+   pipe_copy_rect(dst_map,
                   dst->cpp,
                   dst->pitch,
                   dstx, dsty,
                   width, height,
-                  pipe_surface_map(src),
+                  src_map,
                   do_flip ? -(int) src->pitch : src->pitch,
                   srcx, do_flip ? 1 - srcy - height : srcy);
 
-   pipe_surface_unmap(src);
-   pipe_surface_unmap(dst);
+   pipe->screen->surface_unmap(pipe->screen, src);
+   pipe->screen->surface_unmap(pipe->screen, dst);
 }
 
 
@@ -83,7 +92,9 @@ sp_surface_fill(struct pipe_context *pipe,
                unsigned width, unsigned height, unsigned value)
 {
    unsigned i, j;
-   void *dst_map = pipe_surface_map(dst);
+   void *dst_map = pipe->screen->surface_map( pipe->screen,
+                                              dst,
+                                              PIPE_BUFFER_USAGE_CPU_WRITE );
 
    assert(dst->pitch > 0);
    assert(width <= dst->pitch);
@@ -147,7 +158,7 @@ sp_surface_fill(struct pipe_context *pipe,
       break;
    }
 
-   pipe_surface_unmap( dst );
+   pipe->screen->surface_unmap(pipe->screen, dst);
 }
 
 
index 256586ec886e8026301cd3d6bff068ce4705ccc2..1d7a1fffe4da3ba16a7bd04761aed65c726f4cbe 100644 (file)
@@ -40,6 +40,7 @@
 #include "sp_state.h"
 #include "sp_texture.h"
 #include "sp_tile_cache.h"
+#include "sp_screen.h"
 
 
 /* Simple, maximally packed layout.
@@ -51,40 +52,88 @@ static unsigned minify( unsigned d )
 }
 
 
-static void
-softpipe_texture_layout(struct softpipe_texture * spt)
+/* Conventional allocation path for non-display textures:
+ */
+static boolean
+softpipe_texture_layout(struct pipe_screen *screen,
+                        struct softpipe_texture * spt)
 {
+   struct pipe_winsys *ws = screen->winsys;
    struct pipe_texture *pt = &spt->base;
    unsigned level;
    unsigned width = pt->width[0];
    unsigned height = pt->height[0];
    unsigned depth = pt->depth[0];
 
-   spt->buffer_size = 0;
+   unsigned buffer_size = 0;
 
    for (level = 0; level <= pt->last_level; level++) {
       pt->width[level] = width;
       pt->height[level] = height;
       pt->depth[level] = depth;
+      spt->pitch[level] = width;
 
-      spt->level_offset[level] = spt->buffer_size;
+      spt->level_offset[level] = buffer_size;
 
-      spt->buffer_size += ((pt->compressed) ? MAX2(1, height/4) : height) *
-                         ((pt->target == PIPE_TEXTURE_CUBE) ? 6 : depth) *
-                         width * pt->cpp;
+      buffer_size += (((pt->compressed) ? MAX2(1, height/4) : height) *
+                      ((pt->target == PIPE_TEXTURE_CUBE) ? 6 : depth) *
+                      width * pt->cpp);
 
       width  = minify(width);
       height = minify(height);
       depth = minify(depth);
    }
+
+   spt->buffer = ws->buffer_create(ws, 32,
+                                   PIPE_BUFFER_USAGE_PIXEL,
+                                   buffer_size);
+
+   return spt->buffer != NULL;
+}
+
+
+
+/* Hack it up to use the old winsys->surface_alloc_storage()
+ * method for now:
+ */
+static boolean
+softpipe_displaytarget_layout(struct pipe_screen *screen,
+                              struct softpipe_texture * spt)
+{
+   struct pipe_winsys *ws = screen->winsys;
+   struct pipe_surface surf;
+   unsigned flags = (PIPE_BUFFER_USAGE_CPU_READ |
+                     PIPE_BUFFER_USAGE_CPU_WRITE |
+                     PIPE_BUFFER_USAGE_GPU_READ |
+                     PIPE_BUFFER_USAGE_GPU_WRITE);
+
+
+   memset(&surf, 0, sizeof(surf));
+
+   ws->surface_alloc_storage( ws, 
+                              &surf,
+                              spt->base.width[0], 
+                              spt->base.height[0],
+                              spt->base.format,
+                              flags,
+                              spt->base.tex_usage);
+      
+   /* Now extract the goodies: 
+    */
+   spt->buffer = surf.buffer;
+   spt->pitch[0] = surf.pitch;
+
+   return spt->buffer != NULL;
 }
 
 
+
+
+
 static struct pipe_texture *
 softpipe_texture_create(struct pipe_screen *screen,
                         const struct pipe_texture *templat)
 {
-   struct pipe_winsys *ws = screen->winsys;
    struct softpipe_texture *spt = CALLOC_STRUCT(softpipe_texture);
    if (!spt)
       return NULL;
@@ -93,19 +142,21 @@ softpipe_texture_create(struct pipe_screen *screen,
    spt->base.refcount = 1;
    spt->base.screen = screen;
 
-   softpipe_texture_layout(spt);
-
-   spt->buffer = ws->buffer_create(ws, 32,
-                                   PIPE_BUFFER_USAGE_PIXEL,
-                                   spt->buffer_size);
-   if (!spt->buffer) {
-      FREE(spt);
-      return NULL;
+   if (spt->base.tex_usage & PIPE_TEXTURE_USAGE_DISPLAY_TARGET) {
+      if (!softpipe_displaytarget_layout(screen, spt))
+         goto fail;
    }
-
+   else {
+      if (!softpipe_texture_layout(screen, spt))
+         goto fail;
+   }
+    
    assert(spt->base.refcount == 1);
-
    return &spt->base;
+
+ fail:
+   FREE(spt);
+   return NULL;
 }
 
 
@@ -116,19 +167,10 @@ softpipe_texture_release(struct pipe_screen *screen,
    if (!*pt)
       return;
 
-   /*
-   DBG("%s %p refcount will be %d\n",
-       __FUNCTION__, (void *) *pt, (*pt)->refcount - 1);
-   */
    if (--(*pt)->refcount <= 0) {
       struct softpipe_texture *spt = softpipe_texture(*pt);
 
-      /*
-      DBG("%s deleting %p\n", __FUNCTION__, (void *) spt);
-      */
-
       pipe_buffer_reference(screen->winsys, &spt->buffer, NULL);
-
       FREE(spt);
    }
    *pt = NULL;
@@ -138,7 +180,8 @@ softpipe_texture_release(struct pipe_screen *screen,
 static struct pipe_surface *
 softpipe_get_tex_surface(struct pipe_screen *screen,
                          struct pipe_texture *pt,
-                         unsigned face, unsigned level, unsigned zslice)
+                         unsigned face, unsigned level, unsigned zslice,
+                         unsigned usage)
 {
    struct pipe_winsys *ws = screen->winsys;
    struct softpipe_texture *spt = softpipe_texture(pt);
@@ -157,6 +200,24 @@ softpipe_get_tex_surface(struct pipe_screen *screen,
       ps->height = pt->height[level];
       ps->pitch = ps->width;
       ps->offset = spt->level_offset[level];
+      ps->usage = usage;
+      
+      /* Because we are softpipe, anything that the state tracker
+       * thought was going to be done with the GPU will actually get
+       * done with the CPU.  Let's adjust the flags to take that into
+       * account.
+       */
+      if (ps->usage & PIPE_BUFFER_USAGE_GPU_WRITE)
+         ps->usage |= PIPE_BUFFER_USAGE_CPU_WRITE;
+
+      if (ps->usage & PIPE_BUFFER_USAGE_GPU_READ)
+         ps->usage |= PIPE_BUFFER_USAGE_CPU_READ;
+
+
+      pipe_texture_reference(&ps->texture, pt); 
+      ps->face = face;
+      ps->level = level;
+      ps->zslice = zslice;
 
       if (pt->target == PIPE_TEXTURE_CUBE || pt->target == PIPE_TEXTURE_3D) {
         ps->offset += ((pt->target == PIPE_TEXTURE_CUBE) ? face : zslice) *
@@ -172,25 +233,64 @@ softpipe_get_tex_surface(struct pipe_screen *screen,
 }
 
 
-static void
-softpipe_texture_update(struct pipe_context *pipe,
-                        struct pipe_texture *texture,
-                        uint face, uint levelsMask)
+static void 
+softpipe_tex_surface_release(struct pipe_screen *screen, 
+                             struct pipe_surface **s)
 {
-   struct softpipe_context *softpipe = softpipe_context(pipe);
-   uint unit;
-   for (unit = 0; unit < softpipe->num_textures; unit++) {
-      if (softpipe->texture[unit] == texture) {
-         sp_flush_tile_cache(softpipe, softpipe->tex_cache[unit]);
-      }
+   /* Effectively do the texture_update work here - if texture images
+    * needed post-processing to put them into hardware layout, this is
+    * where it would happen.  For softpipe, nothing to do.
+    */
+   assert ((*s)->texture);
+   pipe_texture_reference(&(*s)->texture, NULL); 
+
+   screen->winsys->surface_release(screen->winsys, s);
+}
+
+
+static void *
+softpipe_surface_map( struct pipe_screen *screen,
+                      struct pipe_surface *surface,
+                      unsigned flags )
+{
+   ubyte *map;
+
+   if (flags & ~surface->usage) {
+      assert(0);
+      return NULL;
+   }
+
+   map = screen->winsys->buffer_map( screen->winsys, surface->buffer, flags );
+   if (map == NULL)
+      return NULL;
+
+   /* May want to different things here depending on read/write nature
+    * of the map:
+    */
+   if (surface->texture &&
+       (flags & PIPE_BUFFER_USAGE_CPU_WRITE)) 
+   {
+      /* Do something to notify sharing contexts of a texture change.
+       * In softpipe, that would mean flushing the texture cache.
+       */
+      softpipe_screen(screen)->timestamp++;
    }
+   
+   return map + surface->offset;
+}
+
+
+static void
+softpipe_surface_unmap(struct pipe_screen *screen,
+                       struct pipe_surface *surface)
+{
+   screen->winsys->buffer_unmap( screen->winsys, surface->buffer );
 }
 
 
 void
-softpipe_init_texture_funcs( struct softpipe_context *softpipe )
+softpipe_init_texture_funcs(struct softpipe_context *sp)
 {
-   softpipe->pipe.texture_update = softpipe_texture_update;
 }
 
 
@@ -199,5 +299,10 @@ softpipe_init_screen_texture_funcs(struct pipe_screen *screen)
 {
    screen->texture_create = softpipe_texture_create;
    screen->texture_release = softpipe_texture_release;
+
    screen->get_tex_surface = softpipe_get_tex_surface;
+   screen->tex_surface_release = softpipe_tex_surface_release;
+
+   screen->surface_map = softpipe_surface_map;
+   screen->surface_unmap = softpipe_surface_unmap;
 }
index a7322144e6f7f857567747c68c537b753dc5350c..779a9d8fc970c0bf070886fe312858b44aa4a235 100644 (file)
@@ -42,11 +42,11 @@ struct softpipe_texture
    struct pipe_texture base;
 
    unsigned long level_offset[PIPE_MAX_TEXTURE_LEVELS];
+   unsigned long pitch[PIPE_MAX_TEXTURE_LEVELS];
 
    /* The data is held here:
     */
    struct pipe_buffer *buffer;
-   unsigned long buffer_size;
 };
 
 
@@ -61,7 +61,6 @@ softpipe_texture(struct pipe_texture *pt)
 extern void
 softpipe_init_texture_funcs( struct softpipe_context *softpipe );
 
-
 extern void
 softpipe_init_screen_texture_funcs(struct pipe_screen *screen);
 
index 1117c0ad4c7a364c02020df17a784db24e144c05..28c29da87c9079edebb7bc18d55aaa8be5933cf3 100644 (file)
@@ -49,6 +49,7 @@
 
 struct softpipe_tile_cache
 {
+   struct pipe_screen *screen;
    struct pipe_surface *surface;  /**< the surface we're caching */
    void *surface_map;
    struct pipe_texture *texture;  /**< if caching a texture */
@@ -109,13 +110,14 @@ clear_clear_flag(uint *bitvec, int x, int y)
    
 
 struct softpipe_tile_cache *
-sp_create_tile_cache(void)
+sp_create_tile_cache( struct pipe_screen *screen )
 {
    struct softpipe_tile_cache *tc;
    uint pos;
 
    tc = CALLOC_STRUCT( softpipe_tile_cache );
    if (tc) {
+      tc->screen = screen;
       for (pos = 0; pos < NUM_ENTRIES; pos++) {
          tc->entries[pos].x =
          tc->entries[pos].y = -1;
@@ -154,16 +156,17 @@ sp_tile_cache_set_surface(struct softpipe_tile_cache *tc,
    assert(!tc->texture);
 
    if (tc->surface_map) {
-      /*assert(tc->surface != ps);*/
-      pipe_surface_unmap(tc->surface);
+      tc->screen->surface_unmap(tc->screen, tc->surface);
       tc->surface_map = NULL;
    }
 
    pipe_surface_reference(&tc->surface, ps);
 
-   if (ps) {
-      if (tc->surface_map)
-        tc->surface_map = pipe_surface_map(ps);
+   if (tc->surface) {
+      if (tc->surface_map) /* XXX: this is always NULL!? */
+        tc->surface_map = tc->screen->surface_map(tc->screen, tc->surface,
+                                                   PIPE_BUFFER_USAGE_CPU_READ | 
+                                                   PIPE_BUFFER_USAGE_CPU_WRITE);
 
       tc->depth_stencil = (ps->format == PIPE_FORMAT_S8Z24_UNORM ||
                            ps->format == PIPE_FORMAT_Z16_UNORM ||
@@ -187,10 +190,13 @@ void
 sp_tile_cache_map_surfaces(struct softpipe_tile_cache *tc)
 {
    if (tc->surface && !tc->surface_map)
-      tc->surface_map = pipe_surface_map(tc->surface);
+      tc->surface_map = tc->screen->surface_map(tc->screen, tc->surface,
+                                                PIPE_BUFFER_USAGE_CPU_WRITE |
+                                                PIPE_BUFFER_USAGE_CPU_READ);
 
    if (tc->tex_surf && !tc->tex_surf_map)
-      tc->tex_surf_map = pipe_surface_map(tc->tex_surf);
+      tc->tex_surf_map = tc->screen->surface_map(tc->screen, tc->tex_surf,
+                                                 PIPE_BUFFER_USAGE_CPU_READ);
 }
 
 
@@ -198,12 +204,12 @@ void
 sp_tile_cache_unmap_surfaces(struct softpipe_tile_cache *tc)
 {
    if (tc->surface_map) {
-      pipe_surface_unmap(tc->surface);
+      tc->screen->surface_unmap(tc->screen, tc->surface);
       tc->surface_map = NULL;
    }
 
    if (tc->tex_surf_map) {
-      pipe_surface_unmap(tc->tex_surf);
+      tc->screen->surface_unmap(tc->screen, tc->tex_surf);
       tc->tex_surf_map = NULL;
    }
 }
@@ -224,7 +230,7 @@ sp_tile_cache_set_texture(struct pipe_context *pipe,
    pipe_texture_reference(&tc->texture, texture);
 
    if (tc->tex_surf_map) {
-      pipe_surface_unmap(tc->tex_surf);
+      tc->screen->surface_unmap(tc->screen, tc->tex_surf);
       tc->tex_surf_map = NULL;
    }
    pipe_surface_reference(&tc->tex_surf, NULL);
@@ -514,10 +520,12 @@ sp_get_cached_tile_tex(struct pipe_context *pipe,
          /* get new surface (view into texture) */
 
         if (tc->tex_surf_map)
-            pipe_surface_unmap(tc->tex_surf);
+            tc->screen->surface_unmap(tc->screen, tc->tex_surf);
 
-         tc->tex_surf = screen->get_tex_surface(screen, tc->texture, face, level, z);
-         tc->tex_surf_map = pipe_surface_map(tc->tex_surf);
+         tc->tex_surf = screen->get_tex_surface(screen, tc->texture, face, level, z, 
+                                                PIPE_BUFFER_USAGE_CPU_READ);
+         tc->tex_surf_map = screen->surface_map(screen, tc->tex_surf,
+                                                PIPE_BUFFER_USAGE_CPU_READ);
 
          tc->tex_face = face;
          tc->tex_level = level;
index 2631e29a3a6620dcac80b1ad397dcefee40bf2b2..bc96c941f61887d4b44e199a7cd639410a1c9258 100644 (file)
@@ -61,7 +61,7 @@ struct softpipe_cached_tile
 
 
 extern struct softpipe_tile_cache *
-sp_create_tile_cache(void);
+sp_create_tile_cache( struct pipe_screen *screen );
 
 extern void
 sp_destroy_tile_cache(struct softpipe_tile_cache *tc);
index f3a9c2cd8b27e5da451240a581f1799ad27ecc69..0f68f592f77072859276bc78c17147a7cbc8b4b0 100644 (file)
@@ -198,12 +198,6 @@ struct pipe_context {
    /*@}*/
 
 
-   /** Called when texture data is changed */
-   void (*texture_update)(struct pipe_context *pipe,
-                          struct pipe_texture *texture,
-                          uint face, uint dirtyLevelsMask);
-
-
    /** Flush rendering (flags = bitmask of PIPE_FLUSH_x tokens) */
    void (*flush)( struct pipe_context *pipe,
                   unsigned flags,
index 7a7312ea1228dbeb37c81c893da8355fc90e4852..0af635be5737617b05f36ef52f7bb7dab2b150bd 100644 (file)
@@ -313,6 +313,28 @@ void
 debug_memory_end(unsigned long beginning);
 
 
+#if defined(PROFILE) && defined(PIPE_SUBSYSTEM_WINDOWS_DISPLAY)
+
+void
+debug_profile_start(void);
+
+void 
+debug_profile_stop(void);
+
+#endif
+
+
+#ifdef DEBUG
+void debug_dump_image(const char *prefix,
+                      unsigned format, unsigned cpp,
+                      unsigned width, unsigned height,
+                      unsigned pitch,
+                      const void *data);
+#else
+#define debug_dump_image(prefix, format, cpp, width, height, pitch, data) ((void)0)
+#endif
+
+
 #ifdef __cplusplus
 }
 #endif
index 46a355daa216038aa31fa92e177b23bc2779459e..83330ef22febd7adaaa4d528232abdaa148e5016 100644 (file)
@@ -173,6 +173,12 @@ enum pipe_texture_target {
 #define PIPE_SURFACE        2  /**< user-created surfaces */
 
 
+/**
+ * Surface layout
+ */
+#define PIPE_SURFACE_LAYOUT_LINEAR  0
+
+
 /**
  * Surface status
  */
index a4bd23c302ae554f2b5dfb5147584d4cc1168e25..9ba00f8d7b69cfdde06b8ff6fde20f3505d7135d 100644 (file)
@@ -307,6 +307,9 @@ enum pipe_format {
    PIPE_FORMAT_R8G8B8_SNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SNORM ),
    PIPE_FORMAT_R8G8B8A8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM ),
    PIPE_FORMAT_R8G8B8X8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM ),
+   PIPE_FORMAT_B6G5R5_SNORM          = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_BGR1, 6, 5, 5, 0, PIPE_FORMAT_TYPE_SNORM ),
+   PIPE_FORMAT_A8B8G8R8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGRA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM ),
+   PIPE_FORMAT_X8B8G8R8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM ),
    PIPE_FORMAT_R8_SSCALED            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED ),
    PIPE_FORMAT_R8G8_SSCALED          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_SSCALED ),
    PIPE_FORMAT_R8G8B8_SSCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SSCALED ),
index 8eb604e73f1c5e42f267f13820ab6b64bdcb605a..1e4b98edb4883eca0c05794968ae00e87e5807e7 100644 (file)
@@ -39,21 +39,40 @@ extern "C" {
 #endif
 
 
+/* XXX: these are a kludge.  will fix when all surfaces are views into
+ * textures, and free-floating winsys surfaces go away.
+ */
 static INLINE void *
-pipe_surface_map(struct pipe_surface *surface)
+pipe_surface_map( struct pipe_surface *surf, unsigned flags )
 {
-   return (char *)surface->winsys->buffer_map( surface->winsys, surface->buffer,
-                                              PIPE_BUFFER_USAGE_CPU_WRITE |
-                                              PIPE_BUFFER_USAGE_CPU_READ )
-      + surface->offset;
+   if (surf->texture) {
+      struct pipe_screen *screen = surf->texture->screen;
+      return surf->texture->screen->surface_map( screen, surf, flags );
+   }
+   else {
+      struct pipe_winsys *winsys = surf->winsys;
+      char *map = (char *)winsys->buffer_map( winsys, surf->buffer, flags );
+      if (map == NULL)
+         return NULL;
+      return (void *)(map + surf->offset);
+   }
 }
 
 static INLINE void
-pipe_surface_unmap(struct pipe_surface *surface)
+pipe_surface_unmap( struct pipe_surface *surf )
 {
-   surface->winsys->buffer_unmap( surface->winsys, surface->buffer );
+   if (surf->texture) {
+      struct pipe_screen *screen = surf->texture->screen;
+      surf->texture->screen->surface_unmap( screen, surf );
+   }
+   else {
+      struct pipe_winsys *winsys = surf->winsys;
+      winsys->buffer_unmap( winsys, surf->buffer );
+   }
 }
 
+
+
 /**
  * Set 'ptr' to point to 'surf' and update reference counting.
  * The old thing pointed to, if any, will be unreferenced first.
@@ -66,9 +85,20 @@ pipe_surface_reference(struct pipe_surface **ptr, struct pipe_surface *surf)
    if (surf) 
       surf->refcount++;
 
-   if (*ptr /* && --(*ptr)->refcount == 0 */) {
-      struct pipe_winsys *winsys = (*ptr)->winsys;
-      winsys->surface_release(winsys, ptr);
+   if (*ptr) {
+
+      /* There are currently two sorts of surfaces... This needs to be
+       * fixed so that all surfaces are views into a texture.
+       */
+      if ((*ptr)->texture) {
+         struct pipe_screen *screen = (*ptr)->texture->screen;
+         screen->tex_surface_release( screen, ptr );
+      }
+      else {
+         struct pipe_winsys *winsys = (*ptr)->winsys;
+         winsys->surface_release(winsys, ptr);
+      }
+
       assert(!*ptr);
    }
 
index 26ac99d287d4bfe87e8b0bbcbb7f3bf5ffe3a4fb..cc8430dae1695c90295bf3b0e85332660f9902f1 100644 (file)
@@ -89,6 +89,18 @@ struct pipe_screen {
    struct pipe_texture * (*texture_create)(struct pipe_screen *,
                                            const struct pipe_texture *templat);
 
+   /**
+    * Create a new texture object, using the given template info, but on top of 
+    * existing memory.
+    * 
+    * It is assumed that the buffer data is layed out according to the expected
+    * by the hardware. NULL will be returned if any inconsistency is found.  
+    */
+   struct pipe_texture * (*texture_blanket)(struct pipe_screen *,
+                                            const struct pipe_texture *templat,
+                                            const unsigned *pitch,
+                                            struct pipe_buffer *buffer);
+
    void (*texture_release)(struct pipe_screen *,
                            struct pipe_texture **pt);
 
@@ -96,7 +108,22 @@ struct pipe_screen {
    struct pipe_surface *(*get_tex_surface)(struct pipe_screen *,
                                            struct pipe_texture *texture,
                                            unsigned face, unsigned level,
-                                           unsigned zslice);
+                                           unsigned zslice,
+                                           unsigned usage );
+
+   /* Surfaces allocated by the above must be released here:
+    */
+   void (*tex_surface_release)( struct pipe_screen *,
+                                struct pipe_surface ** );
+   
+
+   void *(*surface_map)( struct pipe_screen *,
+                         struct pipe_surface *surface,
+                         unsigned flags );
+
+   void (*surface_unmap)( struct pipe_screen *,
+                          struct pipe_surface *surface );
+   
 };
 
 
index 912d84e7b997aef8b50e8194b55af82c26ef7a2e..e7ee8c97ed73e076c982d69c804446914bc579e9 100644 (file)
@@ -271,12 +271,26 @@ struct pipe_surface
    unsigned width;
    unsigned height;
    unsigned pitch;               /**< in pixels */
+   unsigned layout;              /**< PIPE_SURFACE_LAYOUT_x */
    unsigned offset;              /**< offset from start of buffer, in bytes */
    unsigned refcount;
+   unsigned usage;              /**< PIPE_BUFFER_USAGE_*  */
+
    struct pipe_winsys *winsys;   /**< winsys which owns/created the surface */
+
+   struct pipe_texture *texture; /**< optional texture into which this is a view  */
+   unsigned face;
+   unsigned level;
+   unsigned zslice;
 };
 
 
+#define PIPE_TEXTURE_USAGE_RENDER_TARGET   0x1
+#define PIPE_TEXTURE_USAGE_DISPLAY_TARGET  0x2 /* ie a backbuffer */
+#define PIPE_TEXTURE_USAGE_PRIMARY         0x4 /* ie a frontbuffer */
+#define PIPE_TEXTURE_USAGE_DEPTH_STENCIL   0x8
+#define PIPE_TEXTURE_USAGE_SAMPLER         0x10
+
 /**
  * Texture object.
  */
@@ -292,6 +306,8 @@ struct pipe_texture
    unsigned cpp:8;
    unsigned last_level:8;    /**< Index of last mipmap level present/defined */
    unsigned compressed:1;
+   
+   unsigned tex_usage;          /* PIPE_TEXTURE_USAGE_* */
 
    /* These are also refcounted:
     */
index a66ab765f72875ec5a12b94e048e851c0b176607..597354ca96cf45587447fad28e1613b9f5651510 100644 (file)
@@ -204,7 +204,6 @@ mem_dup(const void *src, uint size)
 #define MIN2( A, B )   ( (A)<(B) ? (A) : (B) )
 #define MAX2( A, B )   ( (A)>(B) ? (A) : (B) )
 
-/* JB stop warnings */
 #ifndef Elements
 #define Elements(x) (sizeof(x)/sizeof((x)[0]))
 #endif
index 3005ec2d94181d130adab4530b663093c850f83b..7ebc2851928580d804b1fbd8bda32e1111fa0932 100644 (file)
@@ -86,11 +86,12 @@ struct pipe_winsys
                                 struct pipe_surface *surf,
                                 unsigned width, unsigned height,
                                 enum pipe_format format,
-                                unsigned flags);
+                                unsigned flags,
+                                unsigned tex_usage);
    
    void (*surface_release)(struct pipe_winsys *ws, struct pipe_surface **s);
 
-   
+
    /**
     * Buffer management. Buffer attributes are mostly fixed over its lifetime.
     *
index 6a42c790337205e4aace515353b041e9e4bcd982..10e1a84cc1270f01d1f692f227a0da62580321df 100644 (file)
@@ -220,7 +220,8 @@ intel_i915_surface_alloc_storage(struct pipe_winsys *winsys,
                                  struct pipe_surface *surf,
                                  unsigned width, unsigned height,
                                  enum pipe_format format, 
-                                 unsigned flags)
+                                 unsigned flags,
+                                 unsigned tex_usage)
 {
    const unsigned alignment = 64;
    //int ret;
index f1fd3939ab9966a243f285c261bc80089ba69e66..f84f4533093ed06163bb42ad79d12fefa6f90b05 100644 (file)
@@ -26,7 +26,6 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i830_common.h,v 1.1 2002/09/11 00:29:32 dawes Exp $ */
 
 #ifndef _I830_COMMON_H_
 #define _I830_COMMON_H_
index c2a3af8cbf7be1410ef4feb09bfa1b61506fc55f..685de4a551b3252892a422556665bfb1e31758b4 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i830_dri.h,v 1.4 2002/10/30 12:52:18 alanh Exp $ */
 
 #ifndef _I830_DRI_H
 #define _I830_DRI_H
index 14c3892559b9828c71ce6fbc81bdd97f05db1a5b..b14758f333656ac9fa37ae9d55cb5d01df548e01 100644 (file)
@@ -489,7 +489,8 @@ xm_surface_alloc_storage(struct pipe_winsys *winsys,
                          struct pipe_surface *surf,
                          unsigned width, unsigned height,
                          enum pipe_format format, 
-                         unsigned flags)
+                         unsigned flags,
+                         unsigned tex_usage)
 {
    const unsigned alignment = 64;
 
@@ -498,6 +499,7 @@ xm_surface_alloc_storage(struct pipe_winsys *winsys,
    surf->format = format;
    surf->cpp = pf_get_size(format);
    surf->pitch = round_up(width, alignment / surf->cpp);
+   surf->usage = flags;
 
 #ifdef GALLIUM_CELL /* XXX a bit of a hack */
    height = round_up(height, TILE_SIZE);
@@ -551,6 +553,7 @@ static void
 xm_surface_release(struct pipe_winsys *winsys, struct pipe_surface **s)
 {
    struct pipe_surface *surf = *s;
+   assert(!surf->texture);
    surf->refcount--;
    if (surf->refcount == 0) {
       if (surf->buffer)
index f42f7fcc5f1ad547774b587b1f7f22eb823f1da4..77376099f0d01a3d6b1c07e204604bddc3476463 100644 (file)
@@ -276,7 +276,8 @@ aub_i915_surface_alloc_storage(struct pipe_winsys *winsys,
                                struct pipe_surface *surf,
                                unsigned width, unsigned height,
                                enum pipe_format format,
-                               unsigned flags)
+                               unsigned flags,
+                               unsigned tex_usage)
 {
     const unsigned alignment = 64;
 
index d626bee937fa550a1a21f65863bf4621f509c13d..874c9359254e4f96781bd5ad18245274d861f744 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: all.h,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 5c7722c5f0b376c034363f14526bdee4c6603089..31429e3343a8a0045635886bfd196c99b50768ab 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: glu.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 85fbc33c625b508c647badccb09a4c72bc7c3230..a39edce41f6154f441060a0d4230dffc8c2fe3cf 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gluP.h,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 97297729e787c22f970be7aa4cfbbae759f5ba07..a655d214e3a5b92667ad1ae0a24dc8e964184593 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: mipmap.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 93c0dd3ce2321fb051034bef0b037298ae26862e..9f39cacb41dcc391d6b2dc9f9b70c4952610f0b6 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: nurbs.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index c9c9c094f1a5a4c6cb26c24879b8410491e540a9..3642e213a8c4a8aa84b01c4ec4cacbd4eb58dda7 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: nurbs.h,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 62d91b46d3f13aa5bde6ebf7cc1e15f0c951819e..e80468fdb0334afa4c14a5d3a441b28224530536 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: nurbscrv.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 52f272a3cb4d326780e2444091fafa28357bd2f1..1ff966f61ced3590384ca587b501678db2e5e559 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: polytest.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index a2747de55f2da1a2ea7ebef54c6d486e85b1f2f9..6fa03267e5394acab0cd0911106c910015f64986 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: project.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 015552e123759e1525c1c331b6adf6dd3b781fa2..0484890ef69ff96f0c1fcc462bce62c18048036e 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: quadric.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 1a384239be0152ea0de0998b35d17edea7757eec..341d29bae3a8e8067cc3da1ece656fe9b33b20e1 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: tess.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 908e20972cf3546e4765e6bbb15ee9e1c86bef7c..4e51dddd37da6d4bba07a65f222779c6298dbab9 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: tess.h,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index a1102e6e5a6bdfb0b0a18564c56f0d58989c8a98..47d230073fdb26433d310b3dac318a4e228b4b57 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: tesselat.c,v 1.2 2003/08/22 20:11:43 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index fac5a63b760962191c370ee02c99ca7605bbb506..bd905a2608ffa6a226231db66e07e233c83e5e5b 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: dummy.cc,v 1.1 2001/03/18 13:06:19 pesco Exp $ */
 /*
  * This file contains nothing. It's just there so there's at least a single
  * source file for libGLU.la in this directory.
index 1a9f3c78e7692e699fe141bfbc3e7f87c5631d5c..adecfe9b2fbfc9ab536040467abacc6775634585 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/bezierEval.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
 */
 
 #ifndef _BEZIEREVAL_H
index 836ae94e0a6354c6630016d9c3a64b32a804cf85..fa1daed52e95ea768062e13cf888a3bd95dc4909 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/bezierPatch.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
 */
 
 #include "gluos.h"
index 31c97ba08f6bc761164e8ec3cfc649fc618576a3..ad0f8b0d2a4bd9581ebdae22131fe2b0a83eec80 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/bezierPatch.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
 */
 
 #ifndef _BEZIERPATCH_H
index 9ff416ad6e6b967e8af4b3152983ebdedc564aca..3dc16313fff51c16dbdb26ae630bfb45d9f46d37 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/bezierPatchMesh.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
 */
 
 #include "gluos.h"
index 74cf0988586f41eeaeaeb4e8af05700040bed59d..2ab24dff5b0dc951fb2d85727c21f71a3377b459 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/bezierPatchMesh.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
 */
 
 #ifndef _BEZIERPATCHMESH_H
index 32e4704137d5073978081112b9d05517ab668521..b6591dba0d4bc6a951c9e36544027163ec1695eb 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * glcurveval.c++
  *
- * $Date: 2006/03/29 18:46:46 $ $Revision: 1.7 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/glcurveval.cc,v 1.7 2006/03/29 18:46:46 brianp Exp $
  */
 
 /* Polynomial Evaluator Interface */
index 9a9d3e32c9374c6f0784f7dc5c0b3ddcba8bcf0d..2c307f63e87fee07522c4b9c171cc0f844fc938b 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * glimports.h
  *
- * $Date: 2001/03/19 17:52:02 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/glimports.h,v 1.3 2001/03/19 17:52:02 pesco Exp $
  */
 
 #ifndef __gluimports_h_
index dfd16d17222b7b17fd1dfe665fa6448cf5c99607..ba64bcd2dcf8cb47a5dcde025611cac4b5428759 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/07/16 15:46:42 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/glinterface.cc,v 1.2 2001/07/16 15:46:42 brianp Exp $
 */
 
 #include "gluos.h"
index 30f07632a484bdef114dfb4cc79e40d07dfdd294..8fc23125e0f1608c46bc753470b93f3d7cc8e49e 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * glrenderer.h
  *
- * $Date: 2004/02/26 14:58:11 $ $Revision: 1.4 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/glrenderer.h,v 1.4 2004/02/26 14:58:11 brianp Exp $
  */
 
 #ifndef __gluglrenderer_h_
index 336cca0508e49a87736db8608c655f16a0ceebf5..96ea8896ae740d6899ace0d86ba1d3e4fcee8101 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2004/05/12 15:29:36 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/incurveeval.cc,v 1.2 2004/05/12 15:29:36 brianp Exp $
 */
 
 #include <stdlib.h>
index b314699c7af2c53f010943ed65d0ebddbd88411c..78d8bece13e73974922a1f2b2212e7ff4eefcc05 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2004/05/12 15:29:36 $ $Revision: 1.3 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/insurfeval.cc,v 1.3 2004/05/12 15:29:36 brianp Exp $
 */
 
 #include "gluos.h"
index 6d737257f7e062e045beaaf9bac5363002008c38..e9947ea39372b5a73ad58b301abdb4e4527b7efd 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mystdio.h
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.4 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/mystdio.h,v 1.4 2006/03/14 15:08:52 brianp Exp $
  */
 
 #ifndef __glumystdio_h_
index 0ebbc1299f89b9cc96a43c72312fc6f4e7c96914..2520b41e0af94b34bef1e6085dba15b6f881b45a 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mystdlib.h
  *
- * $Date: 2001/03/19 17:52:02 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/interface/mystdlib.h,v 1.3 2001/03/19 17:52:02 pesco Exp $
  */
 
 #ifndef __glumystdlib_h_
index b700a1e826897b55a805f29a93eff5ef0c1937ed..bbed33c64976c0a6ae213fb1483e7b990a828953 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * arc.h
  *
- * $Date: 2001/08/07 17:34:11 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/arc.h,v 1.2 2001/08/07 17:34:11 brianp Exp $
  */
 
 #ifndef __gluarc_h_
index 1a7f4c69115655497104cf3ff0dc7cf118506b4f..1f85cb7108a6e9bc979db557be8971b50764660c 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * arcsorter.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/arcsorter.cc,v 1.2 2006/03/14 15:08:52 brianp Exp $
  */
 
 #ifndef __gluarcsorter_c_
index 989f80a43cb1df2c095c184f45ea4839459c2045..1025d30b5db14aaeb6a370ba3e9403b31cbd9fe8 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * arcsorter.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/arcsorter.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __gluarcsorter_h_
index fc42ea5eb74ea1bbb667c2e2aa9c50e23dc5cf4e..d3ea2071ea13bfe149c0e29a9b2dc1505c11a1c5 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * arctess.h
  *
- * $Date: 2001/08/07 17:34:11 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/arctess.h,v 1.2 2001/08/07 17:34:11 brianp Exp $
  */
 
 #ifndef __gluarctess_h_
index 97775a9768432001451f5c8c5948cd74e7b7d5e2..69c46b2d52a42100ccc427c13ce56edd4f419760 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * backend.c++
  *
- * $Date: 2004/05/12 15:29:36 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/backend.cc,v 1.2 2004/05/12 15:29:36 brianp Exp $
  */
 
 /* Bezier surface backend
index c1f00b1a01176da57c842c753bdb54c020089db7..fb03859f2775ec01ab7e8ce70a1399bd0c2ed0b5 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * backend.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/backend.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __glubackend_h_
index 0a5f66c201223eca01fd2fae59f1490359ff6964..41abedbb2001850dc26054e0db609f60819d9809 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * basiccurveeval.h
  *
- * $Date: 2006/03/29 18:54:00 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/basiccrveval.h,v 1.2 2006/03/29 18:54:00 brianp Exp $
  */
 
 #ifndef __glubasiccrveval_h_
index a67ded97b56eee2a960637d163a7bb1eca49c72c..2fe76ad67dfcbedae2b2e38553daa2b74d065032 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * basicsurfeval.h
  *
- * $Date: 2006/03/29 18:54:00 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/basicsurfeval.h,v 1.2 2006/03/29 18:54:00 brianp Exp $
  */
 
 #ifndef __glubasicsurfeval_h_
index 64dd31d87d325c410164ae789c072697a122280f..a6d5a13ee682cae8fda548cf0d898a6e20b85ac8 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * bezierarc.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/bezierarc.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __glubezierarc_h
index ed427567f9100d6c6dd372ea0a7d340ebde94176..54b406147be43444cdb215995ae2192f96207f61 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * bin.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/bin.cc,v 1.3 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include "glimports.h"
index 17d146fdf1255eb7e9ceb748cdcd2426d0ea8121..ecdf9b83b83339934869846218e1356968c4c0f7 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * bin.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/bin.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __glubin_h_
index d8d9c23db311ad101d1e3a58bff9c5594dc86683..f60f7dc7b17bfc8956de5a0a3444bfa394d1b4a3 100644 (file)
@@ -35,8 +35,6 @@
 /*
  *  bufpool.c++
  *
- * $Date: 2004/05/12 15:29:36 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/bufpool.cc,v 1.2 2004/05/12 15:29:36 brianp Exp $
  */
 
 #include "glimports.h"
index 02e4ff247b69efd73934bde7fec654da19e29ab5..8eaafc4fd03f531616dfec9e768c184e2cba1010 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * bufpool.h
  *
- * $Date: 2006/03/29 18:46:46 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/bufpool.h,v 1.3 2006/03/29 18:46:46 brianp Exp $
  */
 
 #ifndef __glubufpool_h_
index 7245ee3a18e328e23132854484da4dff6c2c0ad5..3fab38c1064dad370894f7ff3f8c5b16dc296749 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * cachingeval.c++
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/cachingeval.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #include "cachingeval.h"
index 578391707aaa938a3340701157fc9bf0a856db66..cb4c83501ad9a787386cf098be87cf3a33127f6c 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * cachingeval.h
  *
- * $Date: 2006/03/29 18:54:00 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/cachingeval.h,v 1.2 2006/03/29 18:54:00 brianp Exp $
  */
 
 #ifndef __glucachingval_h_
index b1bb6276f7469b33124983862f0f0bef4fc92fe1..eb01b7781a778b2d82bc77b6e7a1f20ef30d5446 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * ccw.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/ccw.cc,v 1.3 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include "glimports.h"
index 4f4077e20807a48e051809b691be77ede96ca381..bb682b75c7530fd3bcc02f27f1aaf7b84f4b0dca 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * coveandtiler.h
  *
- * $Date: 2001/07/16 15:46:42 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/coveandtiler.h,v 1.2 2001/07/16 15:46:42 brianp Exp $
  */
 
 #ifndef __glucoveandtiler_h
index 5517afa2db4712bafaad8bc631d83190ff60e1fa..33e27526435c7463a1376d22fba814e1d2b7c6fa 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * curve.c++
  *
- * $Date: 2004/05/12 15:29:36 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/curve.cc,v 1.3 2004/05/12 15:29:36 brianp Exp $
  */
 
 #include "glimports.h"
index 7b7bd3dc890faef1f07b814d23fd2f34d287a177..6f7b1de9c09f55968e40dd2e64a470264bde49ea 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * curve.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/curve.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __glucurve_h_
index e763c6294597817d9c0698f05318e8531b3e2acb..872eb5816d39b7919b5abada2bc1cbdbc17c535e 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * curvelist.c++
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/curvelist.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #include "glimports.h"
index d285fb5b982b7fbd5ef6583a692913391b36a444..afbaa353ece2b597b1f27c0fef9ee30ba23092b2 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * curvelist.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/curvelist.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __glucurvelist_h_
index 11b15e41741b25607d49ce9165513fb29a8623c0..f85acc269a9d2ddd7a98de8153cd051c4d95f7de 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * curvesub.c++
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/curvesub.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #include "glimports.h"
index 822da022286c891e7d569dd5f5191dc1eaa38668..55c0fbb159a45d7af126b27d029ad99ef70b916f 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2005/10/28 13:09:23 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/dataTransform.cc,v 1.2 2005/10/28 13:09:23 brianp Exp $
 */
 
 #include <stdlib.h>
index 1032896f13a5021f4f5f189c5619530d8ba05aaf..08730e174e080754d0737fc9166499933a5e4ba2 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/dataTransform.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
 */
 
 #ifndef _DATA_TRANSFORM_H
index 77b6088accfc6f18515d359a229525285aeef124..aae1682e398d74fb35388b00b21d156f42b55cf4 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * defines.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/defines.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __gludefines_h_
index 4b39a8991de2a5bfd8bbdfa1a1a326d0ba93fce0..48593c6371d0662d7510a593deea8977481c0600 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * displaylist.c++
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/displaylist.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #include "glimports.h"
index 13cadaeae82974853b5273f0442fca8931aaee5f..4bd6d763845763479f94bc3491eb6d4dea90b2a3 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * displaylist.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/displaylist.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __gludisplaylist_h_
index 791434e6d2656cf4f504fb036fd6128ec6094cd7..9289b99b89580da0f18a1ed3d3cfbf88b9ed1074 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/displaymode.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
 */
 
 #ifndef __gludisplaymode_h_
index 21414fd736d5a58f67bab0d808c90db899a620ad..d3162b9f5f57b4b1e2eef940f2546d5afb73b964 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * flist.c++
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/flist.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #include "glimports.h"
index 8450caad45428d656c5d389016a3210c612e9f53..a643db52b844c0006e69a8f283e436c3f31f90ac 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * flist.h
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/flist.h,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #ifndef __gluflist_h_
index 730613224c1fa39fac5bdbe2568ec088ea7502bf..d49bdea3e00300390d2caa562b34ba500d13da18 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * flistsorter.c++
  *
- * $Date: 2001/03/17 00:25:40 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/flistsorter.cc,v 1.1 2001/03/17 00:25:40 brianp Exp $
  */
 
 #include "glimports.h"
index 753ed255b52b56c88a32771ea6729aa167011f9e..d9fe81a85fe13e74b44762a97919abf4b6867c25 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * flistsorter.h
  *
- * $Date: 2006/03/29 18:54:00 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/flistsorter.h,v 1.2 2006/03/29 18:54:00 brianp Exp $
  */
 
 #ifndef __gluflistsorter_h_
index 32b70bbb293c704ce64dcaf929e6f203c433e2f0..eaa87972171f01adb66efbccf9318fc1f5bddfce 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * gridline.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/gridline.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glugridline_h_
index 70a7029c54e815b7c469ec4242b54ea1debc239e..72f737a9dcf7a8a0b8017298241b7f5121bb83d9 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * gridtrimvertex.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/gridtrimvertex.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glugridtrimvertex_h_
index 2eac57386a8c6f90633720558f1d425d83ae8d65..23035a00c5581df12c39a91de78207ef40e8d12e 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * gridvertex.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/gridvertex.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glugridvertex_h_
index 75f7c160d6d55141af93fa9b0f088abb7ecfc4ce..389ba66fb84bcf58a419b503b1cdb97b45ae2b02 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * hull.c++
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/hull.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #include "glimports.h"
index 34f1593a3ee8745b2950d87d4f788d35514ce952..30ffd6bac3b4cb830ffdb16cad506adb381787c1 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * hull.h
  *
- * $Date: 2001/08/07 17:34:11 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/hull.h,v 1.2 2001/08/07 17:34:11 brianp Exp $
  */
 
 #ifndef __gluhull_h_
index 6fb7e3239be00af3e6985300596acd13ed581485..b39ea2121eff5f72d2962da7679cdeeb65f8c67e 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * intersect.c++
  *
- * $Date: 2005/10/28 13:09:23 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/intersect.cc,v 1.3 2005/10/28 13:09:23 brianp Exp $
  */
 
 #include "glimports.h"
index 785234f6c0867ac62946f7cf01168b5d8f0a17f0..3582a607a72a6b2499c03db46b40e6b82fcd8903 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * jarcloc.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/jarcloc.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glujarcloc_h_
index bb1e5933267def7b38721fa8ae04de46160a0a25..508fc4f3450f7765c9970516fb1065df0d6f6fc8 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * knotvector.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/knotvector.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __gluknotvector_h_
index 14d01582b09eafe263ccd33434839a23b14c26c0..d59f8fd395b4330ac6863acd877e0349c4d42cfb 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mapdesc.c++
  *
- * $Date: 2001/11/29 16:16:55 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/mapdesc.cc,v 1.2 2001/11/29 16:16:55 kschultz Exp $
  */
 
 #include <stdio.h>
index 3c4ef6ff6ce7a259b4fba4977d9e6c4c816da988..fe5d650a2af73329a72a9ca8c0a761822aff9f5e 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mapdesc.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/mapdesc.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glumapdesc_h_
index 6e4bb40c90ff14cddf4d6f2b9513cd42bac9bfca..35b38b141b7af5c4f8cd64f8f671dbd760c48443 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mapdescv.c++
  *
- * $Date: 2004/05/12 15:29:36 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/mapdescv.cc,v 1.3 2004/05/12 15:29:36 brianp Exp $
  */
 
 #include "glimports.h"
index 44f8666b7ae659c760d8d647406eab4f67210f56..f944d1529e5c69cd604ca28dec4ce3e626325e99 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * maplist.c++
  *
- * $Date: 2005/10/28 13:09:23 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/maplist.cc,v 1.2 2005/10/28 13:09:23 brianp Exp $
  */
 
 #include "glimports.h"
index ca92def8cac20a32b011e2e9d3c3fab6d9990b74..e86253966d0f63b5f400e3e1a21d57c4a1c54f55 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * maplist.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/maplist.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glumaplist_h_
index 1178eeb5168295db54d7d480c2e79c5aba190836..9cc436adbf3a55742a2417244618c80de9198cf2 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mesher.c++
  *
- * $Date: 2001/11/29 16:16:55 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/mesher.cc,v 1.3 2001/11/29 16:16:55 kschultz Exp $
  */
 
 #include "glimports.h"
index e4cb4466bc8195cbac0db3c77ce10666007dc38e..b9f74f3819d1103dd369ada7b8adf317975d8b33 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mesher.h
  *
- * $Date: 2001/08/07 17:34:11 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/mesher.h,v 1.2 2001/08/07 17:34:11 brianp Exp $
  */
 
 #ifndef __glumesher_h_
index b08cd9157066a1394118b6471967de6cf91b7d9f..2830cc743ca5b390bd73bc4fcf5dea9ed35ac153 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2005/10/28 13:09:23 $ $Revision: 1.3 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/monoTriangulationBackend.cc,v 1.3 2005/10/28 13:09:23 brianp Exp $
 */
 
 #include "monoTriangulation.h"
index 7b6685dd06e7c83eaf3dde6c69986b9b700cb373..5845d310bad3299878ec326da43284e518824af5 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * monotonizer.c++
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/monotonizer.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #include "glimports.h"
index f516207cb5585f429c435ed1576c91110b955c32..7282a8c4913b5ee741e0da67ba7926808fa372c6 100644 (file)
@@ -35,7 +35,6 @@
 /*
  * monotonizer.h
  *
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/monotonizer.h,v 1.2 2006/04/03 22:23:52 ajax Exp $
  */
 
 #ifndef __glumonotonizer_h_
index e222c7e43ef7e735a1b5ca6aa64708e6d0d27273..9b5ee0f353b3977122873d7549f16c278612e720 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * myassert.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/myassert.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glumyassert_h_
index c49f64fa218f11071e7b9272a8d253bee9e07d8f..3625cacd74f4fc787336348ef9d7595e404993d3 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/mycode.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "mymath.h"
index 8b9032bf23066ea96d9760a4f4caad6a7e300ee3..fedf32f114c6af8956c54e04ed4946a4cdca6a42 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mystring.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/mystring.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glumystring_h_
index 7b9dcc39cd316b345ef91545790db2a32724af03..30277d6892e98f9265cfaa7070e8e7b545fd72c5 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * nurbsconsts.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/nurbsconsts.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glunurbsconsts_h_
index adf7c74626df46cfc4045234f730548814624bed..a5bd060fb0e1a79354538e78357632912f60b6b6 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * nurbstess.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/nurbstess.cc,v 1.2 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include "glimports.h"
index 4a524f1de27602afe60d4f18b3e39083772328f4..808baa69e44b807c1121e95e88e631d8c5ea8a97 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * patch.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.4 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/patch.cc,v 1.4 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include <stdio.h>
index a214b571f9ecd2b6576966c9ce959e8c634711d3..d42613b67e007a96adc6013aeb74d1fb7e4b5732 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * patch.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/patch.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glupatch_h_
index a640893f1ba53e99eca3f43322ded63c59cc3c7c..989d2dd00ab01e15b6475ecc5a7d0ecb7d556327 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * patchlist.c++
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/patchlist.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #include <stdio.h>
index 9fb3795c098a55d1acdda73b311831995c96d802..04701c292b2b31aec9942d065e3ec676f696d961 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * patchlist.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/patchlist.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glupatchlist_h_
index 83b7c3f81319ddbc673de1890e5ff9a68339617c..b0422b4ded67f23fd9be47bbfaf02c3187fd96bd 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * pwlarc.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/pwlarc.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glupwlarc_h_
index f693b370ba87a6ca096be59b96f1cb64c925148c..4fc58b747363212103bde7b3a31f2fb68371cadf 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * quilt.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/quilt.cc,v 1.3 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include "glimports.h"
index 336c2574d240e6726f3da14c9c4fd06a2c1ebb76..a23c3c11b1fcb2a6e5c694f37eef66fe14c89358 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * quilt.h
  *
- * $Date: 2001/08/07 17:34:11 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/quilt.h,v 1.2 2001/08/07 17:34:11 brianp Exp $
  */
 
 #ifndef __gluquilt_h_
index 271a32fbc16ea62cc18404940ee11c122fe79c6f..6135eef60eec150fcb8fee511e171b02360a882b 100644 (file)
@@ -35,8 +35,6 @@
 /*
  *  reader.c++
  *
- * $Date: 2002/11/01 23:35:07 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/reader.cc,v 1.2 2002/11/01 23:35:07 brianp Exp $
  */
 
 #include <stdio.h>
index ac86f8a29f76c2cdc5d91b47419488fd5cc30220..c826d3812f2f9a8694aa41b696fff3f66954553f 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * reader.h
  *
- * $Date: 2001/08/07 17:34:11 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/reader.h,v 1.2 2001/08/07 17:34:11 brianp Exp $
  */
 
 #ifndef __glureader_h_
index 6a9d37e01365c891bf62e3a12fda347dc4ed3d95..a3aa62d42cf954364252d316fbef0e8a731db860 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * renderhints.c++
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/renderhints.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #include "glimports.h"
index efa959e3aba96a2e0dd1ea80690564da0140f5b6..e24842292505aca46ad4fd26575a3692b7fff619 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * renderhints.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/renderhints.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glurenderhints_h_
index f2efee35f1396d5f546822101e00862e2298a45a..195471e23e67a53a98821053fe529ec774ef7e52 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * simplemath.h
  *
- * $Date: 2002/11/01 23:35:07 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/simplemath.h,v 1.2 2002/11/01 23:35:07 brianp Exp $
  */
 
 #ifndef __glusimplemath_h_
index 3fc7e2723ad65d472802f4b865b73d55b79a5f76..27d2a650d115700d388bf476f224c27b99066e1a 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * slicer.c++
  *
- * $Date: 2005/10/28 13:09:23 $ $Revision: 1.5 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/slicer.cc,v 1.5 2005/10/28 13:09:23 brianp Exp $
  */
 
 #include <stdlib.h>
index 6027eaa1c015fe9a74682f84fee3a2b4b5fbdfe3..6700024ba2c1af3bba9247308c8da4845cd2932f 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * slicer.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/slicer.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __gluslicer_h_
index bf13a68d72ac06c66b3c03d3192562cf1197d550..7a79941492db89a6c5be1c50332bf532847b0550 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * sorter.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/sorter.cc,v 1.3 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include "glimports.h"
index e9c98affa77f835df08d5fb04ab28a9976ad427f..0f6b43be37be678168fb59576deec44cdded1be6 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2006/03/29 18:54:00 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/sorter.h,v 1.2 2006/03/29 18:54:00 brianp Exp $
 */
 
 #ifndef __glusorter_h_
index 716f6b9aae01ade916a65c8010dde68b7e12067a..1f79d543fbcb25410316e70b12ce94ae120d0374 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * splitarcs.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/splitarcs.cc,v 1.2 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include "glimports.h"
index 48aff36b441cf838fbd0536dbb49540cfb6c1c5b..37970d6942f5222207d964f04d8be135ba114274 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * subdivider.h
  *
- * $Date: 2001/08/07 17:34:11 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/subdivider.h,v 1.2 2001/08/07 17:34:11 brianp Exp $
  */
 
 #ifndef __glusubdivider_h_
index 95ef3b68b4f5df937ac3654942fa165880082657..531f26bc7836999c17d0f28abcbb9fb67e161cbf 100644 (file)
@@ -35,8 +35,6 @@
 /* 
  * tobezier.c++
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/tobezier.cc,v 1.2 2006/03/14 15:08:52 brianp Exp $
  */
 
 #include "glimports.h"
index 231369b6ef5cbd92a2d525a7d526df705843dadb..61f34cd38a007619a11539983922df3e86f0efc6 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * trimline.c++
  *
- * $Date: 2005/10/28 13:09:23 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/trimline.cc,v 1.2 2005/10/28 13:09:23 brianp Exp $
  */
 
 #include "glimports.h"
index d28574d3e588841d2f4f4eb488191b440952ef1d..5d52e30aba66b356a3123ce73b2a51b55af32562 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * trimline.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/trimline.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glutrimline_h_
index 64b4ffc10e327f000b3b540867706d21c3c1f632..efe7893569dd791b938991f27d7b0fba17a7a3fa 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * trimregion.c++
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/trimregion.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #include "glimports.h"
index 263b8d47193f08339421ab573813ef83fe913aed..6534a8c1da9577449929751865ab12b9bf07a974 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * trimregion.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/trimregion.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glutrimregion_h_
index 8ded26a6480a33f789a545cc20b184de20143c00..85f11621670e1e47833622c90c3cdac58226217b 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * trimvertex.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/trimvertex.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glutrimvertex_h_
index 7c12ab399948263e6646cb09f6b6f7e98a3e447e..3e5bd70380607917ddd040ff2b282d54798c170e 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * trimvertexpool.c++
  *
- * $Date: 2003/05/08 15:47:00 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/trimvertpool.cc,v 1.2 2003/05/08 15:47:00 brianp Exp $
  */
 
 #include "glimports.h"
index deb8d4c534f829c88c63d4eec1977567f460598b..2420e8cca480764c2a9ca0530c4a7b5745634750 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * trimvertexpool.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/trimvertpool.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glutrimvertpool_h_
index d8e7751d0b08b2ff238c15ba048a1db4f4ec87d7..3f89e52593517249ae7ac3e953073e32a7c4b2dd 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * types.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/types.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __glutypes_h_
index 0cc3c8d2739473915dc15ff08f823dcfcabee82e..f0e2364373701898b2da7845c820469a27ceaf09 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * uarray.c++
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/uarray.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #include "glimports.h"
index e7a7e00d101a60db7b5913bf2cbc8bf2be465f81..908b8ccfc8639f19df20e6c4fe9a334bdaf003b7 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * uarray.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/uarray.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __gluuarray_h_
index 969bba080e24b036e39f7b929b068d569968d248..31cc73a9d086a4240c5af2a2263aaa02383897e8 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * varray.c++
  *
- * $Date: 2002/11/01 23:35:07 $ $Revision: 1.2 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/varray.cc,v 1.2 2002/11/01 23:35:07 brianp Exp $
  */
 
 #include "glimports.h"
index 5fb25414258908edc900105014682ba62ce73caa..8408f27baeecb0af04075d82095846c71d4f0096 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * varray.h
  *
- * $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/internals/varray.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef __gluvarray_h_
index 216d479b1a341a05e4abff4abb8a6919d9479aec..8dcbf200503b57a5321602cc98c262ac92f6fc9f 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/definitions.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _DEFINITIONS_H
index 009295e61e3236cd503fa931cf860b85c4e916ee..9d68183ad30237fef39c1cd5e05748b47de57d2b 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/directedLine.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _DIRECTEDLINE_H
index cb370218c07f2f12949f0bc87821a39ce2c320a2..2c307f63e87fee07522c4b9c171cc0f844fc938b 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * glimports.h
  *
- * $Date: 2001/03/19 17:52:03 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/glimports.h,v 1.3 2001/03/19 17:52:03 pesco Exp $
  */
 
 #ifndef __gluimports_h_
index 6df10c43856a4942e0afb1114ba4cdc538d872ca..3c92039bae047ed20545bde3d2e370ac6eb33519 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/gridWrap.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 1c8237fe27a05a8b41f0e2508aa99ed4f173f2a3..723988d2d07abbfeccf995e0c02a0a3aba8bef94 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/gridWrap.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _GRIDWRAP_H
index dccbb2bbc0602b8c41980889f1e3f3e25e76292d..814bf32fae019faa3eb943041cc6b32df403285d 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2005/10/28 13:09:23 $ $Revision: 1.3 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/monoChain.cc,v 1.3 2005/10/28 13:09:23 brianp Exp $
 */
 
 #include "gluos.h"
index e25b18028ce4d1a3c8dffbfe1d60db36467fa790..0302ff9ce28e13cfa1148eb5b253f7bf0cddef0d 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/monoChain.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _MONO_CHAIN_H
index 6405d277fe91da571ef3e445568344e3d29424ec..8391205bf7c9623642528a628900b7553fc3abab 100644 (file)
@@ -31,7 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
  *monoPolyPart.C
index b760862dcb7d22ff7f5c59eda892c575ad970439..51a664de3474d2f9999793f43b06ad6aca7e5717 100644 (file)
@@ -31,7 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
  *monoPolyPart.h
index d168374c98a12ed4a86af0f757a9e993d0cad1a3..8e8d49dda7053dbd710b86dbdc52d504109bb840 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2006/03/29 18:46:46 $ $Revision: 1.5 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/monoTriangulation.cc,v 1.5 2006/03/29 18:46:46 brianp Exp $
 */
 
 #include <stdlib.h>
index 002549ecbd7bf2afadb3107683cc46d65d7fc0b9..86b8b7164be1b6544d07a7c09abddf3dcffca7ce 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/monoTriangulation.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _MONO_TRIANGULATION_H
index a7594eecd6d948443abcf33b6cf0d463c6a71d57..e9947ea39372b5a73ad58b301abdb4e4527b7efd 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mystdio.h
  *
- * $Date: 2006/03/14 15:08:52 $ $Revision: 1.4 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/mystdio.h,v 1.4 2006/03/14 15:08:52 brianp Exp $
  */
 
 #ifndef __glumystdio_h_
index d28e70bd51a8e194a13bfc186b1192ce6615d774..2520b41e0af94b34bef1e6085dba15b6f881b45a 100644 (file)
@@ -35,8 +35,6 @@
 /*
  * mystdlib.h
  *
- * $Date: 2001/03/19 17:52:03 $ $Revision: 1.3 $
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/mystdlib.h,v 1.3 2001/03/19 17:52:03 pesco Exp $
  */
 
 #ifndef __glumystdlib_h_
index bfe77123c48db1895acd280818b6732a3cee158a..e25e30b0f39fc822920971b115633e826a123df8 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/partitionX.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include <stdlib.h>
index cd18f0eb024fb2a66203a9de43144bd40243ab78..bef724fe1f3c140474c401b00072fe531c98e87c 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/partitionX.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _PARTITIONX_H
index 216ac07e0605d40b13668945fa5b96155a7f0be0..297c6299766ace3f673f4bfe514469223cc85cc2 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/11/29 16:16:55 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/partitionY.cc,v 1.2 2001/11/29 16:16:55 kschultz Exp $
 */
 
 #include <stdlib.h>
index b810693a5c369f37f6084a5101554a64892afd09..7e62aeaa9d5ed32de40fcb9f80ec091782fff8f8 100644 (file)
@@ -31,7 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
  *partitionY.h:
@@ -53,7 +52,6 @@
  *A vertex is an interior cusp if it is a cusp and a reflex.
  *A vertex is an exterior cusp if it is a cusp but not a reflex.
  *
- * $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/partitionY.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
  */
 
 #ifndef _PARTITIONY_H
index a5125a50d18030a9b944c79142672c75444ed568..832fe05093e5f9d7413d5a2ef29ce0791290205a 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/polyDBG.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _POLYDBG_H
index 1a17bcc78a0d0c228b9d20cf89540089020afc23..f9a27f402ca85b8c4ca6237b9c125617e8f1dd3a 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/polyUtil.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include <stdlib.h>
index 19c76d37d312c75b791f1dbbf988f8e83d859bd5..010838a9cc9bc69be13796ef1337802dfef37366 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/11/29 16:16:55 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/polyUtil.h,v 1.2 2001/11/29 16:16:55 kschultz Exp $
 */
 
 #ifndef _POLYUTIL_H
index 2d54b155ee0e6c6d0f03c98f84f64f2bf7838d77..26d05342f97dafa0a010765ca293b778bf544dba 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/primitiveStream.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 438d4ad6b0853c89d7465a83c52d9e9fe8775534..8063dcd6220d2ea43b0cc97eca81a47c2fbc5acb 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/primitiveStream.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 /*we do not use the constans GL_... so that this file is independent of 
index f411aaa82a5500417681c0941ef6adbc15956bdb..9d0b290b3932f3d0d13668d5caf487926d101d9e 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2002/04/17 19:30:41 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/quicksort.cc,v 1.2 2002/04/17 19:30:41 brianp Exp $
 */
 
 #include <stdlib.h>
index af245615b37620bc773d6f9650d980eb5f3669c5..1a32188ee13b7a4677f7d36655b85407a64f1c15 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/quicksort.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _QUICKSORT_H
index 932683ccac0ece8a8b3bd1409d744d4f9595f49d..f457b1573367ea3045240866420ecfde1e7667e4 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/rectBlock.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index d98b5a03e174065d02abbb045d1c9d39994767ae..ce546442df23fdb69a7eabc60218fabea2e4f8db 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/rectBlock.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _RECTBLOCK_H
index b58de10af701d21da199a6e096ed8aebdf6480d5..861c71bb3805372d75adc797096d61dd413472be 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2005/10/28 13:09:23 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleComp.cc,v 1.2 2005/10/28 13:09:23 brianp Exp $
 */
 
 #include <stdlib.h>
index 8bdc4c41ebe58dc9cb5d261459d3b340d1718565..e35e5e291dbb2005776377e6dccc99f4c31d6c8f 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleComp.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _SAMPLECOMP_H
index b66647aa994f07f57ea467456fa3a7bc05b227ba..e12f88bab12bce73a87c3f9c01485bf2f93fb222 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/11/29 16:16:55 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleCompBot.cc,v 1.2 2001/11/29 16:16:55 kschultz Exp $
 */
 
 #include <stdlib.h>
index f48dceaea6b766a261c58d48102531883a7bdc1e..6debef911947a8b990727c17f0e5b2960f709b0e 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleCompBot.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _SAMPLECOMPBOT_H
index e25b53c1a9b58d62cb716d8f915b0a23f3488b05..d01e50018bf48b09342b2b72c87d9dae9cf0b909 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2006/08/30 19:02:45 $ $Revision: 1.4 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleCompRight.cc,v 1.4 2006/08/30 19:02:45 brianp Exp $
 */
 
 #include <stdlib.h>
index 747e35e6ad1170616c92d536fbe38843496956e4..b4b0e0732ea0e449cfb242697f6c89ab3ec319de 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleCompRight.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _SAMPLECOMPRIGHT_H
index 0d012d47cea711f7f6ce802520b075f0b484420a..b7b929623a2f917e35f2bd3ff88e56d41029ac25 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/11/29 16:16:55 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleCompTop.cc,v 1.2 2001/11/29 16:16:55 kschultz Exp $
 */
 
 #include <stdlib.h>
index 6875ad57e2d835fef64e596d19db61f533d1b2aa..695092c586c38223205d5ded74a10f28a85c55b3 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleCompTop.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _SAMPLECOMPTOP_H
index c1b045437c53696157a34ae8eca600ee45e5b77b..051f241083496e8975ac066b2022023ce738a288 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2005/10/28 13:09:23 $ $Revision: 1.5 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.cc,v 1.5 2005/10/28 13:09:23 brianp Exp $
 */
 
 #include "gluos.h"
index 3bfa0d43939cce20583a9d1f01f8d852038e1af2..777a28fa2b2797285fdb0142887d1232375dd01e 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _SAMPLEMONOPOLY_H
index 15332eb41c1be782e10c24f856dad6678a2226fe..6253a7c09d3767a27a50a8b59d7bded61fa30456 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/11/29 16:16:55 $ $Revision: 1.2 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampledLine.cc,v 1.2 2001/11/29 16:16:55 kschultz Exp $
 */
 
 #include <stdlib.h>
index 8925197ab31d720aad9de4409885dfff1528673a..147b8a5e1244e29e062967b2b42924ed347395d3 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/sampledLine.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _SAMPLEDLINE_H
index 45c2412b48bbc2b28fcceb7b1aa384c5b1a462f3..1865755a484a2ad7cdd151a7cbbf0a72a5b82f77 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/searchTree.cc,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include <stdlib.h>
index 42722485281c8fd1e7c10481ee72b01f31b943c6..246099fbac00db4208ce0e15696b7c8803e4f04a 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/searchTree.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef _SEARCHTREE_H
index 6a3720853bc1135e6af2773c9c92c62563f8d1e4..6891385196777a678196b8d04cf27c0128594bba 100644 (file)
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
 */
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libnurbs/nurbtess/zlassert.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 /*XXXblythe this file should be deleted*/
index 7c314b74a04fd75a26650d106e90f72d6d507f26..66a6011e25d490d727511fe14dbd3f3d68f7c627 100644 (file)
@@ -1,5 +1,4 @@
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/README,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 General Polygon Tesselation
index f51d68ce3b664bc11879c3d50f83f07f11302b08..33fd69728a407b81ce8d8ebf9b397c660af4161b 100644 (file)
@@ -1,5 +1,4 @@
 /*
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/alg-outline,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 This is only a very brief overview.  There is quite a bit of
index f5b82116d80ebab81f7d32a164159dd0400812c1..8cc1069c52a34e353fdccd780f447858bcd59de6 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/dict-list.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __dict_list_h_
index e3750eea225d2d1afaf2fa01233e28d71dc481b9..f42565f2ff30270a1c46f85d1b33da222badd93b 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2006/04/19 14:42:01 $ $Revision: 1.3 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/dict.c,v 1.3 2006/04/19 14:42:01 brianp Exp $
 */
 
 #include <stddef.h>
index ea3b4064ff114b04134f0306f8f79c99b11dcb29..8cc1069c52a34e353fdccd780f447858bcd59de6 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/dict.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __dict_list_h_
index d009e143addc198362c0d732b4c7c25b6cb7567e..455153175170b48ac231bb3e11364129d3d937df 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/geom.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 61fd59aaedfd022dd0442894ac8adf9199af4546..11fd33b3d7ebe63c7e1c8d98c07d491f66aef700 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/memalloc.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "memalloc.h"
index 97f223759d7e1af96ff07f1c840500d8988f803e..5cbdb5342ea38ac809b4bd04a3c0866231325674 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2003/07/24 22:41:17 $ $Revision: 1.4 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/memalloc.h,v 1.4 2003/07/24 22:41:17 brianp Exp $
 */
 
 #ifndef __memalloc_simple_h_
index 045954db915c0b5ef02e895246aea6c0305a2581..4ffe1a61429b3ce9fecfffda1fd2b546424af315 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/mesh.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 6224df415bd1eea96e969caf643d22d7e4692c53..299b1bacb0840016f7d2b2f802464239d0af1864 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/mesh.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __mesh_h_
index c8e334f45f9115803b78c49fc2c98268f8f893f6..9a805d56f90067cc8e081405ab2c00ebe474f75d 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/normal.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __normal_h_
index 6b77155e1e447fd52d6e947aa4841a8614aec9e4..3f8a6f5f0d50178a9959aff3998ae7ee7b4a294c 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/priorityq-heap.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include <stddef.h>
index 39c33c3921e65ca205fa825ab52ee23c0c355eb8..095cc3456cf6295cbee003d80420fcd3da0cf944 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/priorityq-heap.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __priorityq_heap_h_
index 2439238793573c02163fa1b64dc9bcbd4e8fea87..9e62e983e9914b14171afd5d56364645860e625b 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/priorityq-sort.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __priorityq_sort_h_
index fffa1d5255a7a6cd46dac814a413c3811ce8923c..7eac424e96a48539ea36899d3b2a9b0a21213c26 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/priorityq.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 97ed7075784d79d0b14c48cbbd7fe10a7b1f9ba8..9e62e983e9914b14171afd5d56364645860e625b 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/priorityq.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __priorityq_sort_h_
index 97751dc8101ac3ed4b2e342427d0b6b545156afc..c2b12b35c3aee28793981907052e3c7dfbccbc6e 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/render.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 956569bb77484fe58c74258ebff2bcb663f27fe2..271e616c1921f106aaa8c171bf10cd9f4b2822b0 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/render.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __render_h_
index 2223f52f5980e15d140f0b74c90e00d7ba1581c0..74c375c9b32c221c51045bb0a2dca93e2d7be684 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/sweep.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __sweep_h_
index 2ba00b6ddb42e6fe52391b249a555ef985f65660..d705d04c6e7b1044ea1f6c1084f98c622fe9e2f0 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/tess.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __tess_h_
index 77fe0ac61966061f711452bb5a91f633ed477dfa..a2b6eccbacfefac556adff2f8e1b245bc623b637 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/tessmono.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 01f244f6ec0de652524218eb929472187f99d094..cbe8950d2024320b5d3c6e9433aa234545be997f 100644 (file)
@@ -35,8 +35,6 @@
 /*
 ** Author: Eric Veach, July 1994.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libtess/tessmono.h,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #ifndef __tessmono_h_
index 3d1ce9b2101b6e5934851c33899bc78c55e8604d..24d8b70f88c46152e26d5b397fe3f96a7aa92786 100644 (file)
@@ -31,8 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2006/06/20 15:30:26 $ $Revision: 1.3 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libutil/error.c,v 1.3 2006/06/20 15:30:26 brianp Exp $
 */
 
 #include "gluos.h"
index a0471bbe2e7c91949e0362f767679a3a8bda358f..6a4e6c7c6f9d4663ba3fac7bba1aa13e8afa26fe 100644 (file)
@@ -31,8 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/09/24 09:40:40 $ $Revision: 1.3 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libutil/glue.c,v 1.3 2001/09/24 09:40:40 joukj Exp $
 */
 
 #include <stdlib.h>
index f08401df7aedfb15ef046743e64dd2fa92286b43..cd2a56fed9c70cfd456e9040f598622506c85bb1 100644 (file)
@@ -31,8 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/09/20 21:50:53 $ $Revision: 1.2 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libutil/gluint.h,v 1.2 2001/09/20 21:50:53 kschultz Exp $
 */
 
 #ifndef __gluint_h__
index 2b20ad4fb33eb7f9d474aaa435f934be80310c9e..5ba396ca1c012b7fc7fbbbcf64d63fd4184a1576 100644 (file)
@@ -31,8 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2006/05/01 16:01:17 $ $Revision: 1.6 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libutil/project.c,v 1.6 2006/05/01 16:01:17 brianp Exp $
 */
 
 #include "gluos.h"
index e486ffa8ca98c8341ba92da4a9ced35d551d8028..d83d2fef11768b59d2ea8a2e4ce61c13c72ad7f4 100644 (file)
@@ -31,8 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 **
-** $Date: 2001/03/17 00:25:41 $ $Revision: 1.1 $
-** $Header: /home/krh/git/sync/mesa-cvs-repo/Mesa/src/glu/sgi/libutil/registry.c,v 1.1 2001/03/17 00:25:41 brianp Exp $
 */
 
 #include "gluos.h"
index 2d1bc655cbd61be671044c9254fc47995874ee68..4f7ec48ac80ad208d4c145098e912cfb3c62d37a 100644 (file)
@@ -23,7 +23,6 @@ int DisplayHeight() {
 /* the following function was stolen from the X sources as indicated. */
 
 /* Copyright   Massachusetts Institute of Technology  1985, 1986, 1987 */
-/* $XConsortium: XParseGeom.c,v 11.18 91/02/21 17:23:05 rws Exp $ */
 
 /*
 Permission to use, copy, modify, distribute, and sell this software and its
index da329a1d9b26b1f05d3f37026f51b0aacb41f2ad..09fa960670267c25ac628b4e20a23b6dcb0e6f5f 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: debug.h,v 1.1 2000/11/19 07:41:26 jtaylor Exp $
+/* 
 ******************************************************************************
 
    GGIMesa debugging macros
index fc29680bea68873536bed668452de61fbf5e30f6..602b2fae9f7ea54d442b4de1ee7ac7569a904d3f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XConsortium: wfont.h,v 5.1 91/02/16 09:46:37 rws Exp $ */
 
 /*****************************************************************
 Copyright (c) 1989,1990, 1991 by Sun Microsystems, Inc. and the X Consortium.
index 1d138cfa2ac8fa3a6480939e16576e0c00a94f60..d00ccdb12189e15783f7d42c02c372bb26f7bf41 100644 (file)
@@ -263,7 +263,6 @@ XPending(Display* display)
 /* the following function was stolen from the X sources as indicated. */
 
 /* Copyright   Massachusetts Institute of Technology  1985, 1986, 1987 */
-/* $XConsortium: XParseGeom.c,v 11.18 91/02/21 17:23:05 rws Exp $ */
 
 /*
 Permission to use, copy, modify, distribute, and sell this software and its
index 969398bc16fa7f7273cb0985792032c0d1b259ab..a20d5847b3c121a0a68bf086ececd30cebc3fd7a 100644 (file)
@@ -38,7 +38,6 @@
  * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  */
 
-/* $Id: miniglx_events.c,v 1.6 2006/04/03 07:31:27 airlied Exp $ */
 
 
 #include <assert.h>
index 8909a047721167f4b1b39a0d38422c687b810801..9919a40977153bf9613a3dcd3cee23dc772493e3 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/dri/XF86dri.c,v 1.13 2002/10/30 12:51:25 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index bfb263ced14848d89de666f411afc23fd78427cf..888f8e3187e723ded1b321e1995f96c2811046a6 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/clientattrib.c,v 1.5 2001/03/21 16:04:39 dawes Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index b8c162e8acf0eed8adc0709b1e42118ec770a25e..2d124573ef09f7605935f5541ea8dd421254f48e 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/compsize.c,v 1.6 2004/01/28 18:11:38 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index 5cf9923979a0647e4bf672ebbee9b5cb20f7cb50..21e07c19355d1def0f312c1a6fd910a665c5b81a 100644 (file)
@@ -24,7 +24,6 @@ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/dri/dri_glx.c,v 1.14 2003/07/16 00:54:00 dawes Exp $ */
 
 /*
  * Authors:
index 0f94e6da6fd3f6cfbc4944e999f240981cb85b7f..2544c50fceb225547d63a4a754a5a47a7af3f751 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86$ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index 477566cc46469ce5a7da18a268b4db8fa957af41..03e44e5d0489238309fd3067eb0195c8ccaa746c 100644 (file)
@@ -31,7 +31,6 @@
 ** published by SGI, but has not been independently verified as being
 ** compliant with the OpenGL(R) version 1.2.1 Specification.
 */
-/* $XFree86: xc/lib/GL/glx/glxclient.h,v 1.21 2004/02/09 23:46:31 alanh Exp $ */
 
 /**
  * \file glxclient.h
index f52b71ffcd23c10f0576e6687ba27b4adffbc44d..80281896f69f4dc10190add4402a523f782bb8fe 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/glxcmds.c,v 1.30 2004/01/30 20:33:06 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index af3a5166dc6d03a4cc5b5b8b8e298df2360b9c85..2852217ba397daa66393b2feb3cf9f0f25bfa87f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/glxext.c,v 1.22 2003/12/08 17:35:28 dawes Exp $ */
 
 /*
 ** License Applicability. Except to the extent portions of this file are
index 62d04ba6dc219497d24e76190576e03904f38030..72255f13014b3b22ba24249980c33d12a676ff43 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/indirect_init.h,v 1.2 2000/02/08 17:18:33 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index ce2a1616dececdd1450a898d0361ca5156549590..8e3119d1b23363341344be09e763bbb78ea4b601 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/packrender.h,v 1.7tsi Exp $ */
 #ifndef __GLX_packrender_h__
 #define __GLX_packrender_h__
 
index 16b054f1e049930f8fa5e0c79237c9c3cd49b586..c69c543921bfb4566f19584f90d73ee9f4fe3bdd 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/packsingle.h,v 1.5tsi Exp $ */
 #ifndef __GLX_packsingle_h__
 #define __GLX_packsingle_h__
 
index 3b3a1811abb9d84a26cb31c4c0aab238d02be71b..279555bdfdf945a99fb33265485e921d4c5da127 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/pixel.c,v 1.8 2003/09/28 20:15:04 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index 3bf1b35ba3c72bee875f9bd7f84158fb1d865659..6f25ed786ef2ca9f7d4d42f58178e38c5a4070b2 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/pixelstore.c,v 1.4 2004/01/28 18:11:43 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index 21ba2709982ee0d17bd35152afa1ae637c703809..b17ad974c85ce3005ecc806c027247902558e3ea 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/render2.c,v 1.6 2004/01/31 09:29:33 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index b7d01dc67957a0dc5059846390cf3a5aed93f6a6..41a7a2d762ee46af91a9d72db87808e4bd842a05 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/renderpix.c,v 1.5 2003/09/28 20:15:04 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index d535757a9ed997b9735f61f38c0aec1f6a8cc28e..35fe417b62b1251a1c25df0a1b8e797bec4cccaa 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/single2.c,v 1.10 2004/02/11 19:48:16 dawes Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index a7b5b798707482341eaa200ebb1516ad5c2aefd9..cd88684f7098d57ecac4d7b1216c49b086539749 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/singlepix.c,v 1.3 2001/03/21 16:04:39 dawes Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index 483a166ea2bc10281791e6a36b7b7d27e8d3de13..d50560ba1a5ef3838227daa7d00dab3316ba4f9d 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/vertarr.c,v 1.4 2001/03/25 05:32:00 tsi Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
index 0a2bb24971d902301e524f9698a51202e5c47400..c8c878f12742fe6abbb635f6abc375b192120ddb 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/dri/xf86dri.h,v 1.8 2002/10/30 12:51:25 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index ac05b183b3caa8d1cd3cfbaa6b612659220b73df..b834bd1a1a030bf376c4483d3059761e9b78c2a3 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/dri/xf86dristr.h,v 1.10 2002/10/30 12:51:25 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index 5f23a796221067afd67772105791a4a30b102a61..f3e3da3e790d2af0368108b1f3c126ca18badded 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/glx/xfont.c,v 1.6 2001/05/02 15:06:02 dawes Exp $ */
 /*
  * Mesa 3-D graphics library
  * Version:  3.1
index 324fc873d3f3bda08aa7d1a651e1ce1e4800830c..2b10b9ecfe77adbbc68df132379585a1b3ef5387 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/common/stenciltmp.h,v 1.3 2001/03/21 16:14:20 dawes Exp $ */
 
 #include "spantmp_common.h"
 
index b0e8c4c1c2824c871168bfbfd8862c21fd1b586b..a81cc2413d1c7baadd96a04d525d5bf14e7f6a68 100644 (file)
@@ -28,7 +28,6 @@
  *    Kevin E. Martin <kem@users.sourceforge.net>
  *    Gareth Hughes <gareth@nvidia.com>
  */
-/* $XFree86:$ */
 
 /** \file texmem.c
  * Implements all of the device-independent texture memory management.
index 6692efcc3090292d03a3d5347130f7c431e3ecb4..ffed7dd66e69387f9b366c52bc7b3780b35fb45a 100644 (file)
@@ -28,7 +28,6 @@
  *    Kevin E. Martin <kem@users.sourceforge.net>
  *    Gareth Hughes <gareth@nvidia.com>
  */
-/* $XFree86:$ */
 
 /** \file texmem.h
  * Public interface to the DRI texture memory management routines.
index b2bab86e66c69b4d105f1e464e36fad203e36a9e..b28b895627d13b94021286d8ca11e09851e701bf 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Ian Romanick <idr@us.ibm.com>
  */
-/* $XFree86:$ */
 
 #ifndef DRI_DEBUG_H
 #define DRI_DEBUG_H
index e7ed545f13c87a41913d38894d5732e4202e5058..094950d36268a6e2821f3bae854591a02f3fd195 100644 (file)
@@ -25,7 +25,6 @@
  * Authors:
  *    Ian Romanick <idr@us.ibm.com>
  */
-/* $XFree86:$ */
 
 #include "glheader.h"
 #include "xf86drm.h"
index ec83adc78dd1e98efeed9c24d6852215a0f1537d..52c1933ca5b80abd772b76bacd44a00c78605676 100644 (file)
@@ -25,7 +25,6 @@
  * Authors:
  *    Ian Romanick <idr@us.ibm.com>
  */
-/* $XFree86:$ */
 
 #ifndef DRI_VBLANK_H
 #define DRI_VBLANK_H
index 7263e8381342ca27248b9fefcb26231f3cf510f0..1aa66859a6f54ce4831e336a344721f18a730e38 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_bitmap.c,v 1.1 2002/02/22 21:32:58 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2001 David S. Miller
index 4f8d2ea2a6a394fabb104bf385cc49febfb34f21..0ccbc57bd0989e3f056e7b6cbb6916c3ac1109b3 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_bitmap.h,v 1.1 2002/02/22 21:32:58 dawes Exp $ */
 
 #ifndef _FFB_BITMAP_H
 #define _FFB_BITMAP_H
index e8dfcbe2543be13ed6b405fa4553d908ee8b5c55..7de05b5cf0ca9fdf9e872070420357e26f77d2b0 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_clear.c,v 1.2 2002/02/22 21:32:58 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000 David S. Miller
index df1b65d748f5f9b9ed12b5941f31b9b52e1f0bc0..0ab75fce47c86a216f3609a010c18bbf69967241 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_context.h,v 1.2 2002/02/22 21:32:58 dawes Exp $ */
 
 #ifndef _FFB_CONTEXT_H
 #define _FFB_CONTEXT_H
index 53423bbae441512babf2b1c3c88ecc2dbe9ae176..f64a577d1fc7932553b377ff9cd9472ac5a30618 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_dd.c,v 1.4 2002/09/11 19:49:07 tsi Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000, 2001 David S. Miller
index 4ffcbe6666c1bc1632594b4ff8ad2946c873bf5b..e065ebbecd92963c7a586de7e7efc3f52a03f5b6 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_dd.h,v 1.1 2000/06/20 05:08:38 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D.
  * Copyright (C) 2000 David S. Miller
index 68a2450eb7d0d48c9c2148ea22a6bce54be9cf19..cca6212f501481eee150cad0130109b05e685777 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_depth.c,v 1.2 2002/02/22 21:32:58 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000 David S. Miller
index db908e7a6359b2a41298dd770f296d24b343456f..8a1829ed494bf8f240553d067375dde80c6b03d4 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_depth.h,v 1.1 2000/06/20 05:08:38 dawes Exp $ */
 
 #ifndef _FFB_DEPTH_H
 #define _FFB_DEPTH_H
index 886d71b76e6a6e98eb5949b4c34e3665cb081847..a175f38643dc514a70df9da1b630f2ac3a89812a 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_fifo.h,v 1.2 2002/02/22 21:32:58 dawes Exp $ */
 
 #ifndef _FFB_FIFO_H
 #define _FFB_FIFO_H
index da1de18f36815bfa510b7fc5939db72191a35f67..829470146448ca46d9e2877902c6c43dc181df83 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_lines.c,v 1.2 2002/02/22 21:32:58 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000, 2001 David S. Miller
index d508c243ea294f36672898cb5ddc5eee3c253810..ddb93656539ed45d4ac93de6186dd3211feba288 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_lines.h,v 1.2 2002/02/22 21:32:58 dawes Exp $ */
 
 #ifndef _FFB_LINES_H
 #define _FFB_LINES_H
index 0951513ca12873cf60283ad0a28ea460dd123473..e9d8260e1aab96048d8fc710978e982526349ffd 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_linetmp.h,v 1.2 2002/02/22 21:32:58 dawes Exp $ */
 
 static __inline void TAG(ffb_line)(GLcontext *ctx, ffb_vertex *v0, 
                                   ffb_vertex *v1 )
index 7c49f740f8928aad5f1b6998a566ab35b820ed58..1fd3eb551259c0b6e753b561b038c4ef05b81ef2 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_lock.h,v 1.2 2002/02/22 21:32:59 dawes Exp $ */
 
 #ifndef _FFB_LOCK_H
 #define _FFB_LOCK_H
index a7496dd1d642ac697d85f31498773b54ca9107fa..d00255ccee5014f8ef0fdabb7d73a2b3914a7fcf 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_points.c,v 1.2 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000, 2001 David S. Miller
index 7d5c1f8a034ca2b600c38e4cda82303a08783a6d..a7229de7f1998b8b6a756ccc6d3549592e4b28cc 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_points.h,v 1.2 2002/02/22 21:32:59 dawes Exp $ */
 
 #ifndef _FFB_POINTS_H
 #define _FFB_POINTS_H
index 310c95d89bdb58c51ca0e851cd9ff7c7bc086373..2c91426b3a218b566e09e950f1b9ce2e1debf78c 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_pointtmp.h,v 1.3 2002/02/22 21:32:59 dawes Exp $ */
 
 static __inline void TAG(ffb_draw_point)(GLcontext *ctx, ffb_vertex *tmp )
 {
index 26d991b08156b99a5ab444981761ccdb33397836..64141c2c5f69b91f0e00dec70ae0e29bb49f8f1e 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_rendertmp.h,v 1.2 2003/01/29 23:00:40 dawes Exp $ */
 
 #define IMPL_LOCAL_VARS                                                \
        ffbContextPtr fmesa = FFB_CONTEXT(ctx);                 \
index fff7fa1d3f7f58b537467adf34bfd682d2bcc128..59ac41467868e8e1b82839c0b6a0ea742802d2f1 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_span.c,v 1.2 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000 David S. Miller
index 5ae227910d56b7256c515a989dcc6afc91372d3e..37506cf30e6efc8361f31430667abcf2369a43c7 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_span.h,v 1.1 2000/06/20 05:08:39 dawes Exp $ */
 
 #ifndef _FFB_SPAN_H
 #define _FFB_SPAN_H
index eb13478166a8a07657f6681a1b75a308f81674c3..880ad8be0a856eea43e439efe564c08d6de20182 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_state.c,v 1.5 2002/10/30 12:51:27 alanh Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000, 2001 David S. Miller
index 17b6fa20ab0968ed978d49eecf96f6a68351e6bc..19e72085fd144260a4f7325f2516be4a70a6c0b6 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_state.h,v 1.2 2002/02/22 21:32:59 dawes Exp $ */
 
 #ifndef _FFB_STATE_H
 #define _FFB_STATE_H
index 2f13ee9210b6ccbb022a03055a6c7aff45065c36..d535b1b7781be28dd9122ab0e047f38f55e0b8a7 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_stencil.c,v 1.2 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000 David S. Miller
index c7da1ca681f6dee86a9f24c0bfcb2f7b1678afbe..2d529980d16c742256b3cc61fbd67ea7bced22a9 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_stencil.h,v 1.1 2000/06/20 05:08:39 dawes Exp $ */
 
 #ifndef _FFB_STENCIL_H
 #define _FFB_STENCIL_H
index d6763b7cd3ebdeaf54c3a8fed4a4d59b41897cc0..6503b0f4e783609c2a9cd11d47a18cd63fe070db 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_tex.c,v 1.1 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2001 David S. Miller
index dba0e08af68b6e0f270022b261464c8938093ad1..4032e73209d4da454de396b8270206bae57624bc 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_tex.h,v 1.1 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D.
  * Copyright (C) 2001 David S. Miller
index 9fae8c8283e519517519e36e874067f790027d32..c2857f61bdece7f17ca8214e019c8d3b642ac63e 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_tris.c,v 1.3 2002/10/30 12:51:28 alanh Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000, 2001 David S. Miller
index a803174b3ea2ad38b312a5e1e3c2daa650a9b72b..116b8e07f15b2326e723e5429536f1550288e241 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_tris.h,v 1.2 2002/02/22 21:32:59 dawes Exp $ */
 
 #ifndef _FFB_TRIS_H
 #define _FFB_TRIS_H
index 612ef2433f09d5201fa167646aa486cd3be0865e..324a871ec425168215e5859ec2281ba84facea68 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_tritmp.h,v 1.2 2002/02/22 21:32:59 dawes Exp $ */
 
 static void TAG(ffb_triangle)( GLcontext *ctx,         
                               ffb_vertex *v0,
index 6ba1eabbf241c3dbfdb8441f784f9274d365fe89..edc9d79124372bd0278527972e2d9e9f638a99c4 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_vb.c,v 1.4 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000, 2001 David S. Miller
index 9eb6759f6139c4feab33c190b6690577b09937e2..af669bce307102e09de6e85325288d202be837bc 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_vb.h,v 1.2 2002/02/22 21:32:59 dawes Exp $ */
 
 #ifndef _FFB_VB_H
 #define _FFB_VB_H
index a1d1254d979dfc265650bd88a6c0bc7b40f858e4..0495d0e2767d900dd86d5aca31c6549fae9cfe76 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_vbtmp.h,v 1.1 2002/02/22 21:32:59 dawes Exp $ */
 
 static void TAG(emit)(GLcontext *ctx, GLuint start, GLuint end)
 {
index 9c1b770fbd10694b19e15005134af0b8f107bc37..8b60f095c96cbeee0d2c0a676bfff6afb78629e0 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_vtxfmt.c,v 1.1 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2001 David S. Miller
index 063bb4923ef56d596cdf0ab432f76eecb74eda02..4d9125cd15635085ac05219895704f9f763d1337 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_vtxfmt.h,v 1.1 2002/02/22 21:32:59 dawes Exp $ */
 
 #ifndef _FFB_VTXFMT_H
 #define _FFB_VTXFMT_H
index 4c5323d230ee3d33d84b3a824b0999fc46dfc11d..f521de63c02e5a985c2849f81d7f3c293a286850 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_xmesa.c,v 1.4 2002/02/22 21:32:59 dawes Exp $
+/* 
  *
  * GLX Hardware Device Driver for Sun Creator/Creator3D
  * Copyright (C) 2000, 2001 David S. Miller
index b7580780a62bd1958e4c7436c96bc21767b8635f..bc8cfe9f217ae998213d9bf158df94131b7593b4 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/ffb/ffb_xmesa.h,v 1.2 2002/02/22 21:32:59 dawes Exp $ */
 
 #ifndef _FFB_XMESA_H_
 #define _FFB_XMESA_H_
index 08114282e519d163ed30da6ddeb2382df252d71b..ac4a75b4598234bb4a75b48ab931d4262fc3de4e 100644 (file)
@@ -21,7 +21,6 @@
  * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  *
  */
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sunffb/ffb_dac.h,v 1.2 2001/04/05 17:42:33 dawes Exp $ */
 
 #ifndef _FFB_DAC_H
 #define _FFB_DAC_H
index baf2f0d0a6592e7251f1e134bd3a599382119ddd..69fefa3f0a1ac3c2d1839fff3e09c24aa7ac23c4 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sunffb/ffb_drishare.h,v 1.2 2000/06/21 00:47:37 dawes Exp $ */
 
 #ifndef _FFB_DRISHARE_H
 #define _FFB_DRISHARE_H
index 7f383d38d6c180c8e3dd7ba8d0b557deee456508..bda5840d609be5ac4e74b6a9ed9f541488bfe4c4 100644 (file)
@@ -24,7 +24,6 @@
  * USE OR OTHER DEALINGS IN THE SOFTWARE.
  *
  */
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sunffb/ffb_regs.h,v 1.1 2000/05/18 23:21:37 dawes Exp $ */
 
 #ifndef FFBREGS_H
 #define FFBREGS_H
index 1c1a22ebc43c91251f4986e00a546cab83962f34..6dcf2e9438b0c68d92bc08171da9eaef644260b9 100644 (file)
@@ -31,7 +31,6 @@
  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
  * DEALINGS IN THE SOFTWARE.
  * 
- * $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_client.h,v 1.3 2002/02/22 21:33:00 dawes Exp $
  * 
  */
 
index f0ab1c4f05c5319c020088ecf2f6178e61df4d48..fb70df6c37cc54cc6691ad1457d25057da20f899 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_context.h,v 1.6 2002/12/16 16:18:50 dawes Exp $ */
 /*
  * Copyright 2001 by Alan Hourihane.
  *
index 47eb802b4e76735901e7dac5c9907d64a9b11639..79b54aacb5f79149cb8ac25b783bfe86052171a9 100644 (file)
@@ -23,7 +23,6 @@
  *           Kevin E. Martin <martin@valinux.com>
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_inithw.c,v 1.9 2002/10/30 12:51:29 alanh Exp $ */
 
 #include "gamma_context.h"
 #include "glint_dri.h"
index 2ab387fa27d3ebbfcd95f4697324d563ff4c4f10..97eea75541ee5c3189248eadcb1f65f8fe577745 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_lock.c,v 1.4 2002/11/05 17:46:07 tsi Exp $ */
 
 #include "gamma_context.h"
 #include "gamma_lock.h"
index 974fe569df6d7f528c317583f0e2acb9f3dabf8f..c15483b770c05756f66ff1f226a0eeb02da9f38a 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_macros.h,v 1.5 2002/02/22 21:33:02 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index 2edda072270cfac9e56add0310e2bf4176c4a6c2..9e1c735019d551ca8a260f4609be245d9563d63c 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_regs.h,v 1.5 2002/02/22 21:33:02 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index f62bea9b66dade0ba7b8d58f5c48df63710ef45f..012d77782b1804bb2fc5b5b871fb0809d16c3724 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_span.c,v 1.4 2002/11/05 17:46:07 tsi Exp $ */
 
 #include "gamma_context.h"
 #include "gamma_lock.h"
index 8dbe0a97caa408ea5293847ad8e3544230e2b2a2..a0690f64d0ee6d76f2dfad45632963f2aa505383 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_state.c,v 1.5 2002/11/05 17:46:07 tsi Exp $ */
 /*
  * Copyright 2001 by Alan Hourihane.
  *
index d4fc93f86b5a456be714124669450f4d66605fe5..0770cbf694b1faf4956219459e89453e2e8a0f78 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_tex.c,v 1.4 2002/11/05 17:46:07 tsi Exp $ */
 
 #include <stdlib.h>
 #include <stdio.h>
index 506b5c4c8f63a6069ba83adacf355a739a06050a..94ecb5c2f61151365e774a4f1ac8ea05589e5bab 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_texmem.c,v 1.5 2002/11/05 17:46:07 tsi Exp $ */
 
 #include <stdlib.h>
 #include <stdio.h>
index a8d1b253c7b93bb4a996734a6d66a2217f2d9b5d..b9bd6d4cee05d0950cfc2b3a842e686436c2fade 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_texstate.c,v 1.5 2002/11/05 17:46:07 tsi Exp $ */
 
 #include <stdlib.h>
 #include <stdio.h>
index 23459ff156e7ab46107c727bbeef5ac37602b902..56e0a850c8b84111fbcb7cec961c3c75cf409d81 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/extras/Mesa/src/mesa/drivers/dri/gamma/gamma_tritmp.h,v 1.2 2004/12/13 22:40:49 tsi Exp $ */
 
 static void TAG(gamma_point)( gammaContextPtr gmesa, 
                             const gammaVertex *v0 )
index 80d35cba9e931416516194fe90e66996ebb0d9c0..f23f585fc028e6afb42d71bb71dcd1e6177fd55e 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_vb.c,v 1.4 2003/03/26 20:43:48 tsi Exp $ */
 /*
  * Copyright 2001 by Alan Hourihane.
  *
index f41682cea71ad014cad71e149f589bb81a952cfd..4c0ebe18992746d74e8c3be3e90135ad08b52951 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/gamma/gamma_xmesa.c,v 1.14 2002/10/30 12:51:30 alanh Exp $ */
 /*
  * Copyright 2001 by Alan Hourihane.
  *
index ec601f942d78e45afc673c8f0886ae8b28b658c9..36554e4ac22e97507a882cf82dbd6f0359e0ca2f 100644 (file)
@@ -25,7 +25,6 @@
  * Converted to common header format:
  *   Jens Owen <jens@tungstengraphics.com>
  *
- * $XFree86: xc/programs/Xserver/hw/xfree86/drivers/glint/glint_common.h,v 1.2 2003/04/03 16:52:18 dawes Exp $
  *
  */
 
index 3952759f8388c1060fcfac2b5749e081880c4ca0..df1992a5d1ee6a3c34e28bace9f41447092bb4d5 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/glint/glint_dri.h,v 1.7 2002/10/30 12:52:16 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index 7cc59d5c86ae2b4ea688672bef0fc5a2ebecb9ec..2fbeb64978e37cbd74a82e26be8ff5e8bf836fa6 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810_3d_reg.h,v 1.7 2002/02/22 21:33:03 dawes Exp $ */
 
 #ifndef I810_3D_REG_H
 #define I810_3D_REG_H
index 3f7f2cc8a47e2ba1329d73247cf69c9f7cdf1a5a..f90b3682f83832084cb5491b10859f1fb41f03f0 100644 (file)
@@ -24,7 +24,6 @@ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810context.c,v 1.3 2002/10/30 12:51:33 alanh Exp $ */
 
 /*
  * Authors:
index b83500bbd0c1b33576b9153bd7906ce5e4caa55e..47080420595396b5cf311f25186394a4a1ccc470 100644 (file)
@@ -21,7 +21,6 @@
  * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810context.h,v 1.9 2002/12/16 16:18:51 dawes Exp $ */
 
 #ifndef I810CONTEXT_INC
 #define I810CONTEXT_INC
index 57c84193faf42464c42d64ab2650eb87a6fc3108..95726fb2525ab00c68a58e6ee3682768b08f402d 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810ioctl.c,v 1.7 2002/10/30 12:51:33 alanh Exp $ */
 
 #include <unistd.h> /* for usleep() */
 
index 61399ee7b72eebb700b34f889243823cd177b7f3..748d29ae36aec1cf89423faa1ad5bb1ba3f9ce80 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810ioctl.h,v 1.7 2002/10/30 12:51:33 alanh Exp $ */
 
 #ifndef I810_IOCTL_H
 #define I810_IOCTL_H
index f64c10a9ae099110e5476f9dd417140b27fbfad3..695b996319a1ed83047199a914948d360a0e9422 100644 (file)
@@ -24,7 +24,6 @@ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810screen.c,v 1.2 2002/10/30 12:51:33 alanh Exp $ */
 
 /*
  * Authors:
index e0d5b2b4876da5a3f3e0373dfa75bd07dcf0b91f..e203c74f52ddf479cb0a9c59b4849b84018b1ccd 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810state.c,v 1.9 2002/10/30 12:51:33 alanh Exp $ */
 
 #include <stdio.h>
 
index f657abe6711e9d8e4e0294b69b4eb56d65076ff7..730bc90eafdcb281777859a7d6bac689b66fa688 100644 (file)
@@ -21,7 +21,6 @@
  * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810tex.c,v 1.9 2002/10/30 12:51:33 alanh Exp $ */
 
 #include "glheader.h"
 #include "mtypes.h"
index 2c4ee06633d671dc6589481f493c00017b809c43..40ab436b951fdf0df9278c53bfe315b0e599a50e 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810tris.c,v 1.7 2002/10/30 12:51:33 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2001 VA Linux Systems Inc., Fremont, California.
index 06c8b3fcd5378fa69d4ced20307492eea8f2ca5a..3d0dd916ca1260a870d641b6f33ff3a7d872a440 100644 (file)
@@ -22,7 +22,6 @@
  *
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810tris.h,v 1.10 2002/02/22 21:33:04 dawes Exp $ */
 
 #ifndef I810TRIS_INC
 #define I810TRIS_INC
index 5ce98a991de3157e29c1a6f6ecbe4cb7bbc229f3..3439192b0d338d204311af8a0bf28086cdc7797d 100644 (file)
@@ -22,7 +22,6 @@
  *
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810vb.c,v 1.13 2003/03/26 20:43:48 tsi Exp $ */
  
 
 #include "glheader.h"
index 1cced86ab2b89386570778ed835c62fe3ffe832f..55d0d2409e1d46577c00984404fc33ac0a3d0e5e 100644 (file)
@@ -22,7 +22,6 @@
  *
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/i810/i810vb.h,v 1.4 2002/02/22 21:33:04 dawes Exp $ */
 
 #ifndef I810VB_INC
 #define I810VB_INC
index 02e548be0ed2283686b4449e819874c8c9b55357..29be444b45ea7ea0dda2324fd7011dd9dcfa5f12 100644 (file)
@@ -25,7 +25,6 @@
  * Converted to common header format:
  *   Jens Owen <jens@tungstengraphics.com>
  *
- * $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i810_common.h,v 1.1 2002/09/11 00:29:31 dawes Exp $
  *
  */
 
index 408a4ebb4d5a1186dec8b8bed07dca702be523db..4a714f03062c22d7f7314608cf1820462059cadd 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i810_dri.h,v 1.10 2002/12/10 01:27:04 dawes Exp $ */
 
 #ifndef _I810_DRI_
 #define _I810_DRI_
index c935982a784db41259461231db8a882bc8f14966..e7e5081038eed19edf809ef12344af981f8f7e3b 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i810_reg.h,v 1.13 2003/02/06 04:18:04 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
index fb6ceaa52d43ff8b2d4f845dedf3abc038dc733e..2b0fee82a883c5a84fe6c2e7a5820a01ed08f157 100644 (file)
@@ -26,7 +26,6 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i830_common.h,v 1.1 2002/09/11 00:29:32 dawes Exp $ */
 
 #ifndef _I830_COMMON_H_
 #define _I830_COMMON_H_
index 6c9a70902152aa7eb3ca5e916f1e432026e09691..313eb759b0d8a1c98f8a080704fed7887dcecad8 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i830_dri.h,v 1.4 2002/10/30 12:52:18 alanh Exp $ */
 
 #ifndef _I830_DRI_H
 #define _I830_DRI_H
index f320378c2a5674f86f1c0f07038a07bddb088808..49eb145f8bf8b78a7d2d40d3e0b8f456fb84faa7 100644 (file)
@@ -26,7 +26,6 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i830_common.h,v 1.1 2002/09/11 00:29:32 dawes Exp $ */
 
 #ifndef _I830_COMMON_H_
 #define _I830_COMMON_H_
index 22951812ad3ffbb98c9346854b4f1187b03a327d..68213f69f5dc5482731240b394f2560a528c0421 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i810/i830_dri.h,v 1.4 2002/10/30 12:52:18 alanh Exp $ */
 
 #ifndef _I830_DRI_H
 #define _I830_DRI_H
index ad661e198cda9264687102b74c7cf8ba5293bcee..7f558e92bc6405228617a03969be773da3babbc4 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 8d89452412bb3f76b6f44492f988db078d772ed3..e925f18c11473273867aa9a71a66630a4ae60236 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 17e8d74d9fa203024705131cba8045904c6d0d53..7d225ebc888aca25ea63667034314e888a1fa4d4 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 74cf1d304fd96f638d0b8ef3195e8ae42bc47b6c..0a2ce064120344b139caddf97b941ee65822188e 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 36e7d3c5d3defc56ccaea4d50c856d0b77aa6143..6bc2b58ce940bdc388afaaa0f57879c145b86fe3 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 52fe86348456f90e570644a9e651345159f48678..2153ab80d785ecc82c7fcf98fefe9c8d8f3453b1 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index b73e350111fc2fb82a25bae7a9329ff2d52109f0..ea605fb0614c68b61a2c6eabc67ce1573644f240 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 973880ee254f8d679d3e3331fd3a8abf4bc8a923..3130b183e339f650504ced19167365b4a31026ed 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 248fa2a9a29c54d95184d621eaefb046858b320b..99f1a14e171c25ab644df7b099a6389cd4e1e96b 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Mesa 3-D graphics library
  * Version:  3.5
index f64b808ee755ea9e6af62511c4d1540fec775071..684f2acc890849ac4fba0e0ad05927879bc5b7e0 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Mesa 3-D graphics library
  * Version:  3.5
index abbba295a53eafe05b37b8b684d167d903f65999..cb944e102301f86498a624e1f1d625c368b59196 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 4e9e216e7dbd4acb7c83a8c9790947e68e2be3ff..b780ba65eab31a9ae61de6b6956c10f6a718a148 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 5305058e2fb50542ba2621bd680302fd999979b8..7bf7dc474d12f84f56ec92fddc1fb352d1fe17f7 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 3830a28165bcdc0497013432fcb84fd8e55e6a14..5c2403f587f64ba5894eab033d5edbcf26853300 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 0f4c766477dffa87fde27bfa7e5b777c597d6468..65141d05c3d00e5853904d3a6515131797dcec85 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 667a394520633006975ab7406ce19840142665c2..9ac51ee5b1d0bb13ace6c189bc51f0be748fe03b 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 95bcab3653deea6ddbe483ed9c0cc35d9876437b..23081cb2fe96c5df0700fc6587789cf9024d78e6 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 5288d321ceddc49ea8c8f73c5a0fdfadf5d67738..c42588e064a346d3d174648a9550b8f23bc5ee62 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index f6cf1cf80208401da6c7e9c7c50a152b0852fd92..e67661b9706fc788a15b5255c3c61c111bbb99e8 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 3b7b93b98425c4e4e3b7c68ee01a34f77066e3ca..d65b2cda6ad90bf02db01c91b239e1fc35051abd 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
  *                                                Cedar Park, Texas.
index 3ace370d70d1c5379b4902ea19ea529901aa3acd..80c84d67746d9dde6ee690f60c20e75b87aca4cf 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 369f610442890854ddfc5e65d6e783ec62602ebf..e4df01106d35981f3a4e358282695ab9a88facc5 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 208703289ddef5caa4f78cd1bdc03b59aaf8c7dc..4780765a18b4c1abcb627eb0bd6cbcffd8b4afdb 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 83a5f73e6ba80742b8db45e704a5547b1d5a56b3..8aab72a3f3fce18ba233cde3c88ac64f8b7a4f6a 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index bcc4759af35a41add173e9f0a8c70428cb201f36..0d923abce0d8a9982ee5b727896ef7a68b61dc63 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index c1207cacd11e93247c82e96dd953d7ac7348bb6e..938804af9ecb97f6a851c7c683f8d2102458443a 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Mesa 3-D graphics library
  * Version:  3.5
index 139668e3f3e23aa42e01d37ca0820890a393c7cd..1477443f790cbc1c87ff03e1b2468cf969f51c83 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */
+/* -*- mode: c; c-basic-offset: 3 -*- */
 /*
  * Copyright 2000 Gareth Hughes
  * All Rights Reserved.
index 71d264b0f19dbf0933ef0595b76c81d530f4eace..c14ddc95c9a88b3f5d31b837b2d381e1819c3aaf 100644 (file)
@@ -26,7 +26,6 @@
  *    Ian Romanick <idr@us.ibm.com>
  *    Keith Whitwell <keithw@tungstengraphics.com>
  */
-/* $XFree86:$ */
 
 #include <stdlib.h>
 #include "mm.h"
index f4e651afa0c227b988c355e1838188d81db1f5a4..6148f6b48805b4a5727949e5c13825711c17748f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mga_xmesa.c,v 1.19 2003/03/26 20:43:49 tsi Exp $ */
 /*
  * Copyright 2000-2001 VA Linux Systems, Inc.
  * All Rights Reserved.
index 0ab0c63f781b373a5566308b8cb43e2174fff31d..0f81c9cbecca5d0a91184fa030db01771cfdd283 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mga_xmesa.h,v 1.12 2002/12/16 16:18:52 dawes Exp $ */
 
 #ifndef _MGA_INIT_H_
 #define _MGA_INIT_H_
index 2124006ade600b7b6d470aaa6487d864c7270139..6aa92355b8a0a2bdb5570986f666031ef7327186 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgacontext.h,v 1.7 2002/12/16 16:18:52 dawes Exp $*/
 /*
  * Copyright 2000-2001 VA Linux Systems, Inc.
  * All Rights Reserved.
index b1d5e0c48fc11cec5fda020425392b811bd62f43..04336b5ac7578006c1e7f4470d9b7fe1bd6c9c8e 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgadd.c,v 1.14 2002/10/30 12:51:35 alanh Exp $ */
 
 
 #include "mtypes.h"
index f98bfdc8781829bc0e0f583ac019190f630852c3..6830ca67ad21b377c3b403132dd7e232819c1de5 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgadd.h,v 1.3 2002/10/30 12:51:35 alanh Exp $ */
 /*
  * Copyright 2000-2001 VA Linux Systems, Inc.
  * All Rights Reserved.
index f3ae749ca992b56f6777727a9a6304952e1637d7..9aa08c51585b63fa9bee8c23511e2dcbd2a89bd6 100644 (file)
@@ -25,7 +25,6 @@
  *    Keith Whitwell <keith@tungstengraphics.com>
  *    Gareth Hughes <gareth@valinux.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgaioctl.h,v 1.11 2002/10/30 12:51:36 alanh Exp $ */
 
 #ifndef MGA_IOCTL_H
 #define MGA_IOCTL_H
index 2b9da8c1813b52b2c40cffec7000f8f421306413..f309aabbc8e1991c16c0dfd4aade6b5be2dc4c05 100644 (file)
@@ -34,7 +34,6 @@
  * \author Keith Whitwell <keith@tungstengraphics.com>
  * \author Gareth Hughes <gareth@valinux.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgapixel.c,v 1.9 2002/11/05 17:46:08 tsi Exp $ */
 
 #include "mtypes.h"
 #include "macros.h"
index c44fd769a8b80d596b3ed7cddb3dad8ac53c81c0..b52c8670f3a07b2432174a24510b78b31ffd3f5b 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgapixel.h,v 1.5 2002/10/30 12:51:36 alanh Exp $ */
 
 #ifndef MGA_PIXELS_H
 #define MGA_PIXELS_H
index e1291ca01bdb89b3865bd64773bad21366090883..1ef1e6d24c6fcc2e2504be006ca3a6418f4e16cf 100644 (file)
@@ -19,7 +19,6 @@
  * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE 
  * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgaregs.h,v 1.6 2003/01/12 03:55:46 tsi Exp $ */
 
 #ifndef _MGAREGS_H_
 #define _MGAREGS_H_
index 3080cea79feb43657ad797fabc10ccd58c799484..c9e42a8040d134eec6f774433f99df40290b3041 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgarender.c,v 1.4 2002/10/30 12:51:36 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index f133a51c083a4248d6f5c6c0f7bf5370e36ad73f..f5e2e49b8a489d4c386c8b06ed1b7edb5753541f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgaspan.h,v 1.3 2002/10/30 12:51:36 alanh Exp $ */
 /*
  * Copyright 2000-2001 VA Linux Systems, Inc.
  * All Rights Reserved.
index afbe0aaf904459de21ea8a94eea0c28cd4855be9..ec65d4e6cd7d69581d55b88d4dd4ed67b05e8bc0 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgastate.h,v 1.5 2002/10/30 12:51:36 alanh Exp $ */
 /*
  * Copyright 2000-2001 VA Linux Systems, Inc.
  * All Rights Reserved.
index a7d74317a5b7a9bd277d4287767df2ea7c414f90..31ea5046dff235b20a2483a290ef3b5fc419f103 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgatex.c,v 1.14 2002/10/30 12:51:36 alanh Exp $ */
 
 #include "glheader.h"
 #include "mm.h"
index fb7ffcff1675ebb883d7a5d8777d48d0bb470057..789034964a0e3c860617d62413e90aad2982d4c0 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgatex.h,v 1.7 2002/10/30 12:51:36 alanh Exp $ */
 /*
  * Copyright 2000-2001 VA Linux Systems, Inc.
  * All Rights Reserved.
index 18743331c6d0682dcf657e32bdb71bfdef50cebf..559813f5deca11f7c04d709117b2eb9ac0957637 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgatexmem.c,v 1.7 2002/10/30 12:51:36 alanh Exp $ */
 
 #include "glheader.h"
 
index 91b413ae760872b8adc108dbdd6a3ce23cf6e61c..0c8081cfb9637821d6cc8e0d3daadcb87e92fcd4 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgatris.c,v 1.10 2002/10/30 12:51:36 alanh Exp $ */
 
 #include "mtypes.h"
 #include "macros.h"
index f3ece3a053bdf51689b59b20edbd946c0572b600..a40fef8307d52353b1b795bd8cf13786e0772947 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgatris.h,v 1.10 2002/10/30 12:51:36 alanh Exp $ */
 
 #ifndef MGATRIS_INC
 #define MGATRIS_INC
index 902d8bd1c1bb40a58a19957a38fe9fca34084de0..954fd53ae33e3ac6a79deb4dece7dc0499fc0847 100644 (file)
@@ -24,7 +24,6 @@
  * Authors:
  *    Keith Whitwell <keith@tungstengraphics.com>
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgavb.c,v 1.15 2003/03/26 20:43:49 tsi Exp $ */
 
 #include <stdlib.h>
 #include "mgacontext.h"
index 5f6454aca96efabd524b072c17b3606c8161d286..f6580e0db9fe394fc4bfcb12220de1834a278585 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/mga/mgavb.h,v 1.8 2002/10/30 12:51:36 alanh Exp $ */
 /*
  * Copyright 2000-2001 VA Linux Systems, Inc.
  * All Rights Reserved.
index 830d48d85979bbdc2e741a4f94b58463427a8ef7..d7790e47794071afdb2acdb6f5150034c5f7d1c8 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga.h,v 1.85 2002/12/16 16:19:17 dawes Exp $ */
 /*
  * MGA Millennium (MGA2064W) functions
  *
index 8fbf619e349e6ed01088b67a9613162f321eae19..5dcfc1614d49ddd38559313f33b8cfe497827433 100644 (file)
@@ -1,8 +1,6 @@
-/* $XConsortium: mga_bios.h /main/2 1996/10/28 04:48:23 kaleb $ */
 #ifndef MGA_BIOS_H
 #define MGA_BIOS_H
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_bios.h,v 1.3 1998/07/25 16:55:51 dawes Exp $ */
 
 /*
  * MGABiosInfo - This struct describes the video BIOS info block.
index 258ace83a0ebc82478e8f5493f017294c813b3a2..bc575e62ee8c8fe46c42eb0cfe70fc375925be9a 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_dri.c,v 1.28 2003/02/08 21:26:58 dawes Exp $ */
 
 /*
  * Copyright 2000 VA Linux Systems Inc., Fremont, California.
index 03b8414603a1488b545edb46e7115b9aeaae7fe4..1ce07028f17ef552463c143f2aeb174c7e763223 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_dri.h,v 1.8 2002/11/29 11:06:42 eich Exp $ */
 
 /*
  * Copyright 2000 VA Linux Systems Inc., Fremont, California.
index d985081ab66986908e6207309bbffc282b622e1a..189e1415d05b6a8d0cb5f26d523dadda54c7f9bf 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_macros.h,v 1.22 2002/02/20 17:17:50 dawes Exp $ */
 
 #ifndef _MGA_MACROS_H_
 #define _MGA_MACROS_H_
index b8e3499235c034104cf30f97a8908bae213b6c69..d51366d44e26297648e607ace1c8f2a9eae05f92 100644 (file)
@@ -1,8 +1,6 @@
-/* $XConsortium: mgareg.h /main/2 1996/10/25 10:33:21 kaleb $ */
 
 
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_reg.h,v 1.18 2001/09/26 12:59:18 alanh Exp $ */
 
 
 
index 95e54a6af500f1e2faf3f3fcfbfb40fa072d7b66..dfc89a2da7624d807053ff96f9e3c51126d02ce8 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_context.c,v 1.8 2002/10/30 12:51:38 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index c51dd7fa58dc4ce5011850499380e3ae673baf1d..3f96836df110f36d6490ce33b9dca64e37f9af49 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_context.h,v 1.12 2002/12/16 16:18:52 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 54f2b21b5d0dffcc87fefafbff08b3e4270fc440..d8e1c70ab77f231f2da866f8e440b1f73125af72 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_dd.c,v 1.15 2002/10/30 12:51:38 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 7a0abb73f83d64b1468cc4fc4548d8564f39b7c2..ce038853c487086f24486f2bf5cfec97e1037859 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_dd.h,v 1.3 2001/01/08 01:07:20 martin Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index b0dba7d04e12d81eca8f9fcaa82138730b972637..25188061a078ed6c9f3bccb8606f7ee8621f96eb 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_ioctl.c,v 1.10 2002/12/16 16:18:53 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 95779f09bef37ef1d6148139ee5b128d748e4f39..57063c41f5e45178f5c33a08265f1811d76e6e62 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_ioctl.h,v 1.6 2002/12/16 16:18:53 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index ea23b007f3303c47c14be0bded398b80d4b90c15..3478e12ad071c54944427fb069b31e92761f7675 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_lock.c,v 1.5 2002/10/30 12:51:38 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 39bdde98200019b2103bca83b0c289d63aeb557e..1fc8cbe29f0375c1b4ec6ce2410e13bbbafe35a6 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_lock.h,v 1.4 2001/01/08 01:07:21 martin Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 880dee85c25b4d7fd86a151108f533fa3dce6096..0722b80ee518226e19539b0423f8038a022160aa 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_screen.c,v 1.9 2003/03/26 20:43:49 tsi Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 8db8eea3587d3ef54ea7c2e87cdadd853477e9bb..b31e87661b51b0342613b6922f8ff405f6735588 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_screen.h,v 1.7 2002/12/16 16:18:53 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 85798c16013443b574cb370b91f6febeea5288b2..c5b6480db9e3885d1a953164cdf3352480850a87 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_span.c,v 1.8 2002/10/30 12:51:39 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index fd7c2d1394a70558b15410e958f33bcc132936b3..9af40581290a8e16c6297f2559c1968f52266171 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_span.h,v 1.3 2001/01/08 01:07:21 martin Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index e476afa5d828a982d56173102e5cb2e6f0aeace7..58c3a27ee83d5a50977abc5201d93ccb729efaba 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_state.c,v 1.11 2002/10/30 12:51:39 alanh Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 6f0a6a6557348e1c9a6ace32e399dd0bd370c655..a44327dfb39a7aab0e315f041e254cbb434ce9bf 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_state.h,v 1.3 2001/01/08 01:07:21 martin Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 3b2d017c1f21d98506e69a5b0c0c3e9056da54f1..554a92287f7289a07c693347962f7fccf33cb7d9 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_tex.c,v 1.14 2002/11/05 17:46:08 tsi Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 54053b8b31593cb347c731137b7ecb7e6e965da8..994dffb5a9a83cb42f7efa6b1c56a3c8d760b5c4 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_tex.h,v 1.7 2002/02/22 21:44:58 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index d011a75671940917ec0ed7245f041d47fe475336..a7d02806369de9e409f24344e1c22e275c97cf79 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_texmem.c,v 1.1 2002/02/22 21:44:58 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 282e887149917e14c4895b6807a21b8b20f2d08c..08eac87758ba4d693aa3fde7a5ca311b67eef3d0 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_texobj.h,v 1.5 2002/02/22 21:44:58 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index 6b43f21cd47ef080b69d728d1f8ac30daf039e8a..211b9ea2a979d3731092b49f708eff6689ebc9e0 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_texstate.c,v 1.1 2002/02/22 21:44:58 dawes Exp $ */
 /**************************************************************************
 
 Copyright 1999, 2000 ATI Technologies Inc. and Precision Insight, Inc.,
index f406e928c5e5acef4ebb4dbfe267111e43831176..f2f124360c3b738b67f9f28acc2154c4ce07c855 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_tris.c,v 1.8 2002/10/30 12:51:43 alanh Exp $ */ /* -*- c-basic-offset: 3 -*- */
+/* -*- c-basic-offset: 3 -*- */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 755d3320b036a557f00be1dbd9a59a0ade22b075..c8f0a4809b925903888f766cc913236cac235e89 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_tris.h,v 1.8 2002/10/30 12:51:43 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index ce98b1b915c42f08ca5535c83bf0c5487720fab4..ca08d7c86a82b5f6c5c043567fb8def9068c9791 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/r128.h,v 1.24 2002/12/16 16:19:10 dawes Exp $ */
 /*
  * Copyright 1999, 2000 ATI Technologies Inc., Markham, Ontario,
  *                      Precision Insight, Inc., Cedar Park, Texas, and
index 5edf1e10036c23691e0597ef91eaf38158771a37..efe9232dc258d7c9d1aaac1b4a7f87f5fdb12841 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/r128_dri.c,v 1.28 2003/02/07 20:41:14 martin Exp $ */
 /*
  * Copyright 1999, 2000 ATI Technologies Inc., Markham, Ontario,
  *                      Precision Insight, Inc., Cedar Park, Texas, and
index 67ade70de47c3af804be302b1ed8911779b26e89..430e5f580bde306c33b46822a224f552c53305ac 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/r128_dri.h,v 1.7 2002/10/30 12:52:12 alanh Exp $ */
 /*
  * Copyright 1999, 2000 ATI Technologies Inc., Markham, Ontario,
  *                      Precision Insight, Inc., Cedar Park, Texas, and
index 93b7feb02c78270e23d06f607c337d82a9e3a0a6..f7b945da93fc599eceda051c6b9f409fd5911b7e 100644 (file)
@@ -35,7 +35,6 @@
  * DEALINGS IN THE SOFTWARE.
  */
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/R128_reg.h,v 1.20 2002/10/12 01:38:07 martin Exp $ */
 
 #ifndef _R128_MACROS_H_
 #define _R128_MACROS_H_
index 5669452d74e11e43245aa84b37d4ba112939e577..50033540b9dfd21fdcba69a9a1f7a2704ae326f6 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/r128_reg.h,v 1.15 2002/12/16 16:19:11 dawes Exp $ */
 /*
  * Copyright 1999, 2000 ATI Technologies Inc., Markham, Ontario,
  *                      Precision Insight, Inc., Cedar Park, Texas, and
index 589d8d40bce2b4edb5ec77410e07e597ffc5e037..783711ef971c2a71e7a318bddce24eb1fa40e194 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/r128_version.h,v 1.6 2003/01/01 19:16:35 tsi Exp $ */
 /*
  * Copyright 2000 through 2003 by Marc Aurele La France (TSI @ UQV), tsi@xfree86.org
  *
index 1cbe3407ba97327c01b188065b17a381029386b5..bd467fb15b0359827a06a1845d49ac5162dabad6 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86$ */
 /**************************************************************************
 
 Copyright 2002 ATI Technologies Inc., Ontario, Canada, and
index 9451ec4aa5b7668799e42c50a83fb73e33141ca4..ba93a054ae2cfc9dbcb66672103e047eec67f61f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_context.c,v 1.9 2003/09/24 02:43:12 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 4c64bc201ae598a72df3947e39a356e7f667da38..f7e461239e7869f62d2cc030c8e314149639b42f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_ioctl.c,v 1.11 2003/01/29 22:04:59 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 11a7d02b1b7a0b8582adc9f1d36608fe165dbf6a..020a5c21e2d647a93821be5eae63b8026d4fb99f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_ioctl.h,v 1.6 2002/12/16 16:18:58 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 44e00af0ef5abd7ba1072a5b163ddf3826b32c7a..5e9b9c3051bfb112230a5d0c9c2b194bd8250545 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_state.c,v 1.5 2002/09/16 18:05:20 eich Exp $ */
 /*
  * Copyright 2000, 2001 VA Linux Systems Inc., Fremont, California.
  *
index 09039d68403e90fb45c3dad5a36903140bf1e495..b8935e84a050d2a0aa4e2862957770e4d8dd436e 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_maos.h,v 1.1 2002/10/30 12:51:55 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 49118b5e37bd1b29f2965fdca8be123ad06b62f2..b61f5e0f3e4ef388094f988e9631015593350177 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_maos_arrays.c,v 1.1 2002/10/30 12:51:55 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 65dbecf7a6ccff6d1a581fc473ec1d4f13dcc59c..d5ceedfa24e2b402b5758d2ab2155f53d41359b3 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_maos_verts.c,v 1.1 2002/10/30 12:51:55 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 557057784c35d2decdc410c08fdc67129a7fbc1b..bdfb7240d728ddbe7fcde63e423e09095bddf6b2 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_sanity.c,v 1.1 2002/10/30 12:51:55 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2002 ATI Technologies Inc., Ontario, Canada, and
index aa7fb633dd1a8987457f240fce4b30e59c741758..4a4594860886299972bca54a39b090da19350cb5 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_screen.c,v 1.7 2003/03/26 20:43:51 tsi Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 25e6fcf399a0879b7a0956c02b9876f7a27bc607..f8c0cc96dfd19b63318d6bdae49b12ccf08e9610 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_screen.h,v 1.5 2002/12/16 16:18:58 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 4de05c7697d94a43ec787f5150741dbea3d9968a..856d27df75c12bbc566ed02511bdfbcb9324d270 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_state.c,v 1.8 2002/12/16 16:18:58 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 VA Linux Systems Inc., Fremont, California.
index ad7db3b677b7b48cbbedf9053a37928244959045..2171879f759547b80eea10ead7977b1ab13ae964 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_state.h,v 1.5 2002/11/05 17:46:09 tsi Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 5fc34f09331d8bc161f964b186781a1f4c4c8267..c876a596e6e39d67ffac9693b447039a92e687bd 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_state_init.c,v 1.3 2003/02/22 06:21:11 dawes Exp $ */
 /*
  * Copyright 2000, 2001 VA Linux Systems Inc., Fremont, California.
  *
index 7ce1fa67cf67b1bdbfa53ae332e080e1ed6ae540..2b3ae14ff7495f67e5a102ae12c1c512d9f7338b 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_swtcl.c,v 1.6 2003/05/06 23:52:08 daenzer Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 64f9019513d418e437df2c08d60808df85b85e3e..1feedf185dda468bfedae9a394cb193c007d1a90 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86$ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 5ad044c2628e3d729fd757f464f1c85077bc7e5f..d35be1ca884860953d15c5f28a639dab1cfbcd7c 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86$ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 168ab958a2804fe3dfc8d2dbceade837c3d95842..dccbea5fdbd62ad9b7f92f88e1d712f6b3239c33 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_tcl.h,v 1.2 2003/02/08 21:26:45 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index edaea6c209c2bad950df07599e45d9ad04b274e7..f3eb9d8eef862a478dfc5e234436bc1f2fb2c87c 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_tex.c,v 1.6 2002/09/16 18:05:20 eich Exp $ */
 /*
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
                      VA Linux Systems Inc., Fremont, California.
index a806981ae62c9521f437765f22f4e1088ca528c5..bdf086dfeec70b030b722429eb15d3aa5bdbc624 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_tex.h,v 1.3 2002/02/22 21:45:01 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 20f25dd34b4bab0b186947fe84fcdc35fa030dc5..f7520f1dea32e05d844fe360fa5a3578a1c5638b 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_texmem.c,v 1.7 2002/12/16 16:18:59 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 37bb749223a09abec1f3dc7b2844dcc0e3732937..ae8d527cf46e5e6a5e2479ddcf9a4a8d334e1cae 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/radeon/radeon_texstate.c,v 1.6 2002/12/16 16:18:59 dawes Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 6f6c2e6d257bef03f7f905a154155ee824318ad4..3fb1e37c530b65fd8ae7678a4b4adcef2320362a 100644 (file)
@@ -31,7 +31,6 @@
  * DEALINGS IN THE SOFTWARE.
  */
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/radeon.h,v 1.29 2002/10/12 01:38:07 martin Exp $ */
 
 #ifndef _RADEON_H_
 #define _RADEON_H_
index ecd53233394c17fec9f815f4c091a76fb0282b3a..dc51372107572d8924bb2f3d6002a1ecc8571e4e 100644 (file)
@@ -34,7 +34,6 @@
  * DEALINGS IN THE SOFTWARE.
  */
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/radeon_dri.h,v 1.3 2002/04/24 16:20:40 martin Exp $ */
 
 #ifndef _RADEON_DRI_
 #define _RADEON_DRI_
index 60f0fa2d35149300f7e3a4a407d615d07afa5f7a..355262c9babcf16a920e199ea6945137bdaff618 100644 (file)
@@ -35,7 +35,6 @@
  * DEALINGS IN THE SOFTWARE.
  */
 
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/radeon_reg.h,v 1.20 2002/10/12 01:38:07 martin Exp $ */
 
 #ifndef _RADEON_MACROS_H_
 #define _RADEON_MACROS_H_
index 4dcce638460ec5a0fb44ffc2c993ae44f9234f97..596a8aa7157077c9440cac82d5e003b62bc88970 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/radeon_reg.h,v 1.30 2003/10/07 22:47:12 martin Exp $ */
 /*
  * Copyright 2000 ATI Technologies Inc., Markham, Ontario, and
  *                VA Linux Systems Inc., Fremont, California.
index 4ce2f60b4f329d460eb03b7fd25193752639465c..52c7f5fa765902bae98528b5c732b29e86634495 100644 (file)
@@ -1,4 +1,4 @@
-/* $XFree86$ */ /* -*- c-basic-offset: 3 -*- */
+/* -*- c-basic-offset: 3 -*- */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index 00803e7ff370f88723ecf81cfdcd69f4ff4f75c6..b2b3d951c68fd907f9e0499a715e39c1f77d6113 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_tris.h,v 1.4 2001/01/08 01:07:24 martin Exp $ */
 /**************************************************************************
 
 Copyright 2000, 2001 ATI Technologies Inc., Ontario, Canada, and
index cbddf0c737192113deda82028b948f5c3a2da5be..bd9bab846fcf43061c374c44ed348b71704691f6 100644 (file)
@@ -1,4 +1,3 @@
-/* * $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sis/sis_common.h,v 1.1 2003/08/29 08:52:12 twini Exp $ */
 /*
  * Common header definitions for SiS 2D/3D/DRM suite
  *
index a05662430e2ff66695767dabaec7b30476b19a1f..f0171f3c0f804a8a995233a0bd16afe84cd628ed 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sis/sis_dri.h,v 1.9 2003/08/29 08:50:54 twini Exp $ */
 
 /* modified from tdfx_dri.h */
 
index b696eeb51a564e60feb676a856e5266366fd9554..4ca40528034e1977d0743d5e2bbb4af8eaa7ab9b 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_alloc.c,v 1.7 2001/01/08 01:07:29 martin Exp $ */
 
 /*
  * Authors:
index e76fc53fe23805eedc2cfbad5bc8bf3027cd5595..eb784afad9e4f6aa45ab61f412ef9f286cd8a68e 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index fb92d06c7355db63087531a0da379d5ec12e4abc..174f3c07686001d823b0c88d018711cb30e83da2 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_clear.c,v 1.5 2000/09/26 15:56:48 tsi Exp $ */
 
 /*
  * Authors:
index b21df0a61ea9212b1d6adba1040b68dfd3a4c613..04c7464c5e2ea6688fefe6c91a140af559f2a93d 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_ctx.c,v 1.3 2000/09/26 15:56:48 tsi Exp $ */
 
 /*
  * Authors:
index c349bf96ed2ed4a6522273f7c8a451a5b9aaa452..b81812d6cec102bcd6d4644033dcd50f890bb488 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index 8fc7896b8774e2ba65f0a061fe6e21d8995172f0..989c159a809c07adc539f8ee1893c854a380d4be 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_ctx.c,v 1.3 2000/09/26 15:56:48 tsi Exp $ */
 
 /*
  * Authors:
index da76596e92b3e27fd20197275cd95b10a610c050..b141243a59a0ff422e0e7d057f622b68d9afe25d 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index fe9a3c95d62dd9054eaa30fb4087d0b7e2eea94e..ba5ac90851203779b48856db18d16bf1515244ea 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_fog.c,v 1.3 2000/09/26 15:56:48 tsi Exp $ */
 
 /*
  * Authors:
index 70ca8e6cbc616c153f98da57b4a6b9a55b524745..0ea64e3498832e547eb72699bbfb3d7303896c1c 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86$ */
 /**************************************************************************
 
 Copyright 2003 Eric Anholt
index fef99319638fbc613105d467ebb9df11fb33e2cb..54844e9b099b723d35ec96c1cebe48f45e58f8ef 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index 78c6660181e8bdc5652f0cd72dbe34700b4c8eda..e40c4371bfe8a24dba4016f4a6d25f10ee5f02d3 100644 (file)
@@ -25,7 +25,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_reg.h,v 1.3 2000/09/26 15:56:48 tsi Exp $ */
 
 /*
  * Authors:
index 89d734ba786f6e3ce99a249909df4109829dc1e3..d90482f3d714473ddb4a9f0b8db56a16b9b18c79 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86$ */
 /**************************************************************************
 
 Copyright 2003 Eric Anholt
index d5b2101e980409adbe2013ab52d890fa465dab2a..07c29cfa09843f9946872d388bffdfe1cb48bd77 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index ea6db6781d4fba3b59cd6a9fde98ca7604eb1967..dc50bda877b96e821039ceb1ff688a245cc82a73 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_span.c,v 1.5 2001/03/21 16:14:26 dawes Exp $ */
 
 /*
  * Authors:
index 4b0add2ac2b8cc7e234090d182e23eff260404f9..a1f817c44c2f675cd226cdcc12a636d6416f43ac 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index 33a2f089b82e8e7dd10f3b5040c6f2e506da07ce..305c63f73f7e781fbd7d0d7e11fb22b9c44b2e17 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_ctx.c,v 1.3 2000/09/26 15:56:48 tsi Exp $ */
 
 /*
  * Authors:
index 8f7e2acb92d150883959ba0de09d819f1aac1454..2d0ea9c5fb834a8d6008248abd8efe23ac76f138 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index a1ce2966e891a2ef00857d87fb4397a0c91f7e1f..55c0440ebae77d47aacfbbbfa87ddcfc3792a3c3 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86: xc/lib/GL/mesa/src/drv/sis/sis_stencil.c,v 1.3 2000/09/26 15:56:49 tsi Exp $ */
 
 /*
  * Authors:
index 4a36c98f3dbc481769cd4007b73a93f5ed223319..6b556c437812c66cf52964287697875049f21791 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index be87f16e2983cd21201ad2174148b7ccdabe6414..5e10c610f809723afff80df503968f4c6ff90cdc 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index 8ddc7c469ee96781aadd6193a980aba1bb458e13..c499e80e86d992be4753a70c49d245275ef934d5 100644 (file)
@@ -22,7 +22,6 @@ AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index 7ef20f880c533f1c6c22775d25af57a46e5106a3..4f813bb81c3458304d1d8e279be9acbbf1a30da4 100644 (file)
@@ -24,7 +24,6 @@ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
 USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 **************************************************************************/
-/* $XFree86$ */
 
 /*
  * Authors:
index 5e07acc2118cee7fc1579eadaaaeacc340a76fc3..499eb4d24d4e86b3b0e296e17c8973fc02cf2398 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/r128/r128_tris.h,v 1.8 2002/10/30 12:51:43 alanh Exp $ */
 /**************************************************************************
 
 Copyright 2003 Eric Anholt
index 0f4cc45089b9129cb4ff6703b6458289dc409416..500c97c536ac86ac9ddd89716307c346536da9ad 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/X86/fx_3dnow_fastpath.S,v 1.2 2000/09/26 15:56:51 tsi Exp $ */
 
 #include "../../X86/assyntax.h"
 
index 9ec4935d781c7d9faf4e7019cf62a966255cd323..78c5fef74694407d3a63fd30ff76e499ffa54ea9 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/X86/fx_3dnow_fasttmp.h,v 1.2 2000/09/26 15:56:51 tsi Exp $ */
 
 #if !defined(NASM_ASSEMBLER) && !defined(MASM_ASSEMBLER)
 #define TAGLLBL(a) TAG(.L##a)
index 52a53f7dd30a98668db7dbb17016d2f929639d62..3ad2bf68c6e98a303deb7244475a42e7ca0bf06f 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/dri_glide.h,v 1.1 2001/03/21 16:14:26 dawes Exp $ */
 
 /*
  * Original rewrite:
index acd0b9ae5ba38675227119ed23294e18af4f72de..dc29984a272e02acc81824bd70a974e703f28433 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/tdfx/tdfx_dri.h,v 1.5 2001/03/21 17:02:26 dawes Exp $ */
 
 #ifndef _TDFX_DRI_
 #define _TDFX_DRI_
index 89a7a9d6c4e683a92bef898fe9e9f7b08c8cc3c1..05673cd1867f33f1fa0c8f3e174af94b72dea090 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_context.h,v 1.5 2002/02/24 21:51:10 dawes Exp $ */
 
 /*
  * New fixes:
index 5ceba9d5f097f327350744be16f223b9d1271a1d..bd61e1060524390554a6857cb1f58dcc3c538fc6 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_dd.h,v 1.1 2001/03/21 16:14:27 dawes Exp $ */
 
 /*
  * Original rewrite:
index f077aa678b3137bb191bcb54b14171d9c6517ef5..69e5399e72941cf5ae1a4f9ccafdd54197eae02f 100644 (file)
@@ -2,7 +2,6 @@
  * This file defines macros and types necessary for accessing glide3.
  */
 
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_glide.h,v 1.1 2002/02/22 21:45:03 dawes Exp $ */
 
 #ifndef NEWGLIDE_H
 #define NEWGLIDE_H
index a20c91d030ad8fec4bed5b77c65855c34da067f4..17cdc51ee13be889e06fa60fa6f30ce596d30dc0 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_lock.c,v 1.5 2002/12/16 16:19:00 dawes Exp $ */
 
 /*
  * Original rewrite:
index 616e65b2a15147186aad8711c0cf667876fa0418..74e3f5c9cc46887810768d87f27278b3a3e094bc 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_lock.h,v 1.3 2002/02/22 21:45:03 dawes Exp $ */
 
 /*
  * Original rewrite:
index 732270b2bd30501b9bb15794bde3aaecc71c192c..b5c01f6ef2187e9ece183bddfc1769827bfa0c12 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_pixels.c,v 1.4 2002/02/22 21:45:03 dawes Exp $ */
 
 /*
  * Original rewrite:
index c38ce070caead8df966fcfbde4e1665bd13034cb..55f7eedef89294c67aadacee48b3dcf157b8e184 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_pixels.h,v 1.2 2002/02/22 21:45:03 dawes Exp $ */
 
 /*
  * Original rewrite:
index f36c97bfebec1c5ed476ce18d4c16b57b4a674e0..e374f09df3af3d3092679071bc0c9b4fb832ec19 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_render.c,v 1.4 2002/02/22 21:45:03 dawes Exp $ */
 
 /*
  * New fixes:
index 09d0d90197deb91634959d0af11c6ea29f74e667..18c61683335501379709cea750593b4ad1231cab 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_render.h,v 1.1 2001/03/21 16:14:28 dawes Exp $ */
 
 /*
  * Original rewrite:
index 1f9ff4e30cabde97069ff7bd19a35e05e2fe0a33..776166439444ec94b481b24b8afdb038d4ddeba7 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_screen.c,v 1.3 2002/02/22 21:45:03 dawes Exp $ */
 
 /*
  * Original rewrite:
index 90be89a352c754b6be35f88c7fafd53f407a3ac6..5a68898b369a1d6c913ec217c8180000a2bb09bd 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_screen.h,v 1.2 2002/02/22 21:45:03 dawes Exp $ */
 
 /*
  * Original rewrite:
index d9d52d2b6f5dcda6b766d5b30dd2fe70fe1bc3d6..6b38fa5a017b0f610f2ac92b7ea5958d775cd8d1 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_span.c,v 1.7 2002/10/30 12:52:00 alanh Exp $ */
 
 /*
  * Original rewrite:
index 62044144f0a1841cf4817c3259937a9103f8a29b..5af9f9b3014f3acfd45b2ac2c8c0b903a858d171 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_span.h,v 1.1 2001/03/21 16:14:28 dawes Exp $ */
 
 /*
  * Original rewrite:
index 42cb5dfaa383f94e4bc1c73e0f28b7cc2c2e199d..3688c76a5c9d6f26e4f6784a681aaa66ab071dc7 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_state.c,v 1.7 2002/10/30 12:52:00 alanh Exp $ */
 
 /*
  * New fixes:
index b10c38f5910e8c1acfb2b09c445557192e2185de..591ea5b083ff7c5747c5f00ca89a99f3f6faa0d3 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_state.h,v 1.2 2002/02/22 21:45:04 dawes Exp $ */
 
 /*
  * Original rewrite:
index 89865d963795edd990ace72cdd85de8b477022e3..65e665ee39b5c1a10e3dc242b7868ddb82c0dba2 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_tex.c,v 1.7 2002/11/05 17:46:10 tsi Exp $ */
 
 /*
  * New fixes:
index f536c25a2f9046812c429c10ee49b7d315a434a0..a445935a018255c69478d8edaaa5d7698101793d 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_tex.h,v 1.2 2002/02/22 21:45:04 dawes Exp $ */
 
 /*
  * Original rewrite:
index 6f782f687f3e9a52ecd3f8f47a34c833f4b2bc79..f9b2726da29f56e304fa5d166964516af64afebc 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_texman.c,v 1.5 2002/02/22 21:45:04 dawes Exp $ */
 
 /*
  * Original rewrite:
index 739d4e142f61d0cf29533e7f87a75139952ddb7f..a9af4cb7c56f0317816375e2c6f563383dc1aa17 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_texman.h,v 1.2 2002/02/22 21:45:04 dawes Exp $ */
 
 /*
  * Original rewrite:
index fda9ce56849a330332a9f0b29258dac30ebb74c6..bbd2c8cfee94d1563f8290341b5156eda2619ea9 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_texstate.c,v 1.2 2002/02/22 21:45:04 dawes Exp $ */
 
 /*
  * New fixes:
index 234ed4439af717af0734ac3445095e49754ede43..0c5c4101cad9c23e91743cb228d97c7381602012 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_texstate.h,v 1.1 2002/02/22 21:45:04 dawes Exp $ */
 
 /*
  * Original rewrite:
index 7252a7e7dc6402304880c83627be974c74e389b7..59ff35a7fa926ec600508586e2ed3a90a033dacc 100644 (file)
@@ -23,7 +23,6 @@
  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_tris.c,v 1.4 2002/10/30 12:52:01 alanh Exp $ */
 
 /* New fixes:
  *     Daniel Borca <dborca@users.sourceforge.net>, 19 Jul 2004
index 57e5d9b0ae0ad91da4dae899f75462fdf3bfd91f..a591decf1dc1838e21839b038045f9c6548f1add 100644 (file)
@@ -29,7 +29,6 @@
  *     Keith Whitwell <keith@tungstengraphics.com>
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_tris.h,v 1.5 2002/10/30 12:52:01 alanh Exp $ */
 
 #ifndef TDFX_TRIS_INC
 #define TDFX_TRIS_INC
index 0580135d1be3e385eae4333ef432ac5414e3cbcc..62885daaa5bc9c6b462038e3e2bf36ac3d0313b8 100644 (file)
@@ -22,7 +22,6 @@
  *
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_vb.c,v 1.3 2002/10/30 12:52:01 alanh Exp $ */
  
 #include "glheader.h"
 #include "mtypes.h"
index 7b7cd9065aaab99121e2717b2513876fa048bb63..6389ec95b17da043cdc6ea4c4bace608404a792e 100644 (file)
@@ -22,7 +22,6 @@
  *
  *
  */
-/* $XFree86: xc/lib/GL/mesa/src/drv/tdfx/tdfx_vb.h,v 1.2 2002/02/22 21:45:04 dawes Exp $ */
 
 #ifndef TDFXVB_INC
 #define TDFXVB_INC
index 6944bd66f9c023b0c7c07cb1a4e5c42dba3cc214..98331459403e0739d969e097768f102ce872993d 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/via/via_dri.c,v 1.4 2003/09/24 02:43:30 dawes Exp $ */
 /*
  * Copyright 1998-2003 VIA Technologies, Inc. All Rights Reserved.
  * Copyright 2001-2003 S3 Graphics, Inc. All Rights Reserved.
index 997b2e41a702d02464a388e80a463ea98925be25..a643fd9fbb019a9d88b1204255534b7beb53303f 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/via/via_driver.h,v 1.7 2003/11/06 18:38:11 tsi Exp $ */
 /*
  * Copyright 1998-2003 VIA Technologies, Inc. All Rights Reserved.
  * Copyright 2001-2003 S3 Graphics, Inc. All Rights Reserved.
index 587531b37c2a2b1400dfde65df8bd235db6fe6f8..352eac0597d6823a70207d28d04e81962bea487a 100644 (file)
@@ -1,4 +1,3 @@
-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/via/via_priv.h,v 1.3 2003/08/27 15:16:12 tsi Exp $ */
 
 #ifndef _VIA_PRIV_H_
 #define _VIA_PRIV_H_ 1
index 022189138f1f6ac5bb9f22aec037288bdd6b47b4..6d0963416f98d33f515605b76cf11afe462cd43b 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: genkgi.h,v 1.3 1999/08/22 08:56:50 jtaylor Exp $
+/* 
 ******************************************************************************
 
    GGIMesa - KGIcon specific overrides for fbcon-mesa
index 938024789f999cc669a419191f7cae4f55833eb0..f81d6a45bd6f44c7bcedff299efbf94fed1815bc 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: genkgi_mode.c,v 1.4 2000/01/07 08:34:44 jtaylor Exp $
+/* 
 ******************************************************************************
 
    display-fbdev-kgicon-generic-mesa
index 17ef9679bb8b5aa455e3eb98b7a1f2a5ddacd059..d7838cae6e0c00e6df905b4a8b1802d69ef1e82d 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: genkgi_visual.c,v 1.7 2000/06/11 20:11:55 jtaylor Exp $
+/* 
 ******************************************************************************
 
    genkgi_visual.c: visual handling for the generic KGI helper
index 35d11624c64d069b88cbee5c8eab10ffbdeb62ed..f461fee72c614a6cd50d3b1302135e6296422887 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: debug.h,v 1.5 2003/09/22 15:18:51 brianp Exp $
+/* 
 ******************************************************************************
 
    GGIMesa debugging macros
index d13858756905f91b965c7561013f2d459492ebbe..1e4e185d659d0e4ef9af6bb6a5a4c7a31457c27d 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa.c,v 1.27 2006/10/15 18:51:22 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index ae5104d0c018b4de54a0484216c753c8329a2cc4..934aaa33fb3f0be6a2c9ee5151a7485a8573e102 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa15.c,v 1.11.36.1 2006/11/02 12:02:17 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 3ed7db82ee546c98ffa6693ec5e5967fec4f9f07..d453fb8d355f62a2ec5ca01e9b8f9008b9585306 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa15.h,v 1.7 2002/11/11 18:42:39 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index a59937bfb4b003e67cf9f2368d9c9ff2735137d3..9fc8c786e8d9da408872d1cee98687d6ffd383fb 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa16.c,v 1.11.36.1 2006/11/02 12:02:17 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 247c1f40455020ca9823e039c5ef792d2289ae41..b80cd3dd7e497489ae92d5529412483b1b942328 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa16.h,v 1.6 2002/11/11 18:42:41 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index dd15bf38db208474abfcc6dcc1de386eff1f1c38..c7c095333fe3e45ec6de36f5a582c15805de99c7 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa24.c,v 1.12.36.1 2006/11/02 12:02:17 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 54d1a8298ba1875097b45e71171f33e6dce317e3..df5fa68c44e5b4b41d02f5dcfca94048a5704b63 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa24.h,v 1.6 2002/11/11 18:42:41 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 4da18795d8ca46a8df084e868cdc3967971e0bc5..d089c20c050d1d5d6667e5e67871f77080d43a5c 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa32.c,v 1.12.36.1 2006/11/02 12:02:17 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index f518e11ad5be9819f2f961075a88ca758aa3d54e..6cf8315300bd87d8dcf47c68e4799681365aa227 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa32.h,v 1.6 2002/11/11 18:42:42 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 4264fcd9599868fb7fea1ddca4db5103205e0ae0..2f7048a9301a042e15acdf85c50c28cad0a918b2 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa8.c,v 1.9.10.1 2006/11/02 12:02:17 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 1aa25f93fce71f16c15a51e6b6e197cbcd361507..d2b0509480f3c310eb28464a0d320ea64841415e 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgamesa8.h,v 1.4 2001/02/06 00:03:48 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 0b19551bf6e8d1856e4dd05267cbbe685530a8ee..19cb74487daac33d32c2756777ba533d9cb99dbd 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: svgapix.h,v 1.5 2002/11/11 18:42:44 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index dad3dc116043c5bbc752e3bb1bdfd41233069a29..6e00d08abafa616147887db685e090e0aafebb00 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: wgl.c,v 1.12 2006/03/30 07:58:24 kschultz Exp $ */
 
 /*
  * This library is free software; you can redistribute it and/or
index ecc40e8f8b673b33c95fcdc9a0bbc5b5bacab993..72e5e1308cc1ce25e06c7c4bc894a1620ac41ffe 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gld_vb_mesa_render_dx7.c,v 1.6 2005/08/27 13:56:08 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 414a2f64bf7e898ef6795001fb2593a61ace558c..9ab562010cefe445b9c5cc1f4b9cc70733b8425f 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gld_vb_mesa_render_dx8.c,v 1.6 2005/08/27 13:56:08 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index c71fdefbae822be49ddae39e25df92a526909d83..64acab2d2a85f2eae713870a73a709b3cb0d2100 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gld_vb_mesa_render_dx9.c,v 1.6 2005/08/27 13:56:08 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 1eb19ca84b0258892b3982370d8effc5f82a59b3..044d2e66f4949341f130c58d4eefda8326b9c5a5 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gld_debug_clip.c,v 1.1 2004/04/20 11:13:11 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 00c428bd262d02569c5e279d36fb5208098d32f9..c20362bb24b7eb9e3f21fe07adc3c85d49eeb7fc 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gld_debug_norm.c,v 1.1 2004/04/20 11:13:11 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index d6e64b8ffdfce5d4e0d3a5a7976dfc83f0314c42..73439dc3b637d52231b3b9d99517254968c53512 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: gld_debug_xform.c,v 1.1 2004/04/20 11:13:11 alanh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 17371a96cce0388fe1917df5bcae5158a901ae18..9c1f2a054041954e741b8d2ff93f8eb7ebb9c870 100644 (file)
  *  (mark@rsinc.com).
  */
 
-/* $Log: ddcolors.h 1997/6/14 by Li Wei(liwei@aiar.xjtu.edu.cn)
+/*
  * Macros for pixel format defined
  */
 
 /*
- * $Log: colors.h,v $
  * Revision 1.1  2004/04/20 11:13:11  alanh
  * add SciTech's GLDirect driver for Windows.
  *
@@ -46,7 +45,6 @@
  */
 
 /*
- * $Log: colors.h,v $
  * Revision 1.1  2004/04/20 11:13:11  alanh
  * add SciTech's GLDirect driver for Windows.
  *
@@ -69,7 +67,6 @@
  */
  
 /*
- * $Log: colors.h,v $
  * Revision 1.1  2004/04/20 11:13:11  alanh
  * add SciTech's GLDirect driver for Windows.
  *
@@ -520,4 +517,4 @@ char unsigned const aWinGHalftoneTranslation[216] =
   225,
   226,
   255,
-};
\ No newline at end of file
+};
index 097348dae0f3e8467606b45fa900593ea8ccacb6..0f410fc48254bb317e1780eb90bfc2c13d2a80f4 100644 (file)
@@ -1,6 +1,5 @@
 #!/usr/bin/env python
 
-# $Id: mesadef.py,v 1.4 2006/01/25 15:05:36 brianp Exp $
 
 # Mesa 3-D graphics library
 # Version:  4.1
index 713cd5b3754aafc8dd0d891f5ecc3699faf979c6..44950a10a5d84c6132d5e09527816aa790b84c75 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: norm.S,v 1.5 2005/07/28 00:11:11 idr Exp $ */
 
 #include "sparc_matrix.h"
 
index 55ab12122d8c7cbcc7f3a197fbeadd241aac893f..a98e4d0e40072ec8e66afa14fa067c2a1b509b21 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sparc.h,v 1.3 2001/06/06 22:55:28 davem69 Exp $ */
 
 /*
  * Mesa 3-D graphics library
index f44ec794e945c23bd40b3b43f7d87856bbd36bc0..f2b9674bf2d7b28185764eaa1b5a8339d2d9b94e 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: xform.S,v 1.4 2005/07/28 00:11:11 idr Exp $ */
 
        /* TODO
         *
index 18063adc79c16056d1d30620d4ede76b802a8928..ecfd1179189d86fc3abdaae6402858efb059882a 100644 (file)
  */
 static const struct st_tracked_state *atoms[] =
 {
-   &st_update_framebuffer,
    &st_update_depth_stencil_alpha,
    &st_update_clip,
 
+   &st_finalize_textures,
    &st_update_shader,
 
    &st_update_rasterizer,
@@ -58,6 +58,7 @@ static const struct st_tracked_state *atoms[] =
    &st_update_blend,
    &st_update_sampler,
    &st_update_texture,
+   &st_update_framebuffer,
    &st_update_vs_constants,
    &st_update_fs_constants,
    &st_update_pixel_transfer
index c6c6eba812139e301d765171a8e3ff0483636e43..c7cffd85c8a89d03b2c729622108e29bce2077a8 100644 (file)
@@ -55,6 +55,7 @@ extern const struct st_tracked_state st_update_scissor;
 extern const struct st_tracked_state st_update_blend;
 extern const struct st_tracked_state st_update_sampler;
 extern const struct st_tracked_state st_update_texture;
+extern const struct st_tracked_state st_finalize_textures;
 extern const struct st_tracked_state st_update_fs_constants;
 extern const struct st_tracked_state st_update_vs_constants;
 extern const struct st_tracked_state st_update_pixel_transfer;
index 0a6974d8a7fe5f9bb54105bf8db073ea3424b284..d46c3ee16c5d8af9b6f6f3851f1114d18c9d0859 100644 (file)
 #include "st_context.h"
 #include "st_atom.h"
 #include "st_cb_fbo.h"
+#include "st_texture.h"
 #include "pipe/p_context.h"
+#include "pipe/p_inlines.h"
 #include "cso_cache/cso_context.h"
 
 
+
+/**
+ * When doing GL render to texture, we have to be sure that finalize_texture()
+ * didn't yank out the pipe_texture that we earlier created a surface for.
+ * Check for that here and create a new surface if needed.
+ */
+static void
+update_renderbuffer_surface(struct st_context *st,
+                            struct st_renderbuffer *strb)
+{
+   struct pipe_screen *screen = st->pipe->screen;
+   struct pipe_texture *texture = strb->rtt->pt;
+   int rtt_width = strb->Base.Width;
+   int rtt_height = strb->Base.Height;
+
+   if (!strb->surface ||
+       strb->surface->texture != texture ||
+       strb->surface->width != rtt_width ||
+       strb->surface->height != rtt_height) {
+      int level;
+      /* find matching mipmap level size */
+      for (level = 0; level <= texture->last_level; level++) {
+         if (texture->width[level] == rtt_width &&
+             texture->height[level] == rtt_height) {
+
+            pipe_surface_reference(&strb->surface, NULL);
+
+            strb->surface = screen->get_tex_surface(screen,
+                                              texture,
+                                              strb->rtt_face,
+                                              level,
+                                              strb->rtt_slice,
+                                              PIPE_BUFFER_USAGE_GPU_READ |
+                                              PIPE_BUFFER_USAGE_GPU_WRITE);
+#if 0
+            printf("-- alloc new surface %d x %d into tex %p\n",
+                   strb->surface->width, strb->surface->height,
+                   texture);
+#endif
+            break;
+         }
+      }
+   }
+}
+
+
 /**
  * Update framebuffer state (color, depth, stencil, etc. buffers)
- * XXX someday: separate draw/read buffers.
  */
 static void
 update_framebuffer_state( struct st_context *st )
@@ -55,6 +102,8 @@ update_framebuffer_state( struct st_context *st )
    framebuffer->width = fb->Width;
    framebuffer->height = fb->Height;
 
+   /*printf("------ fb size %d x %d\n", fb->Width, fb->Height);*/
+
    /* Examine Mesa's ctx->DrawBuffer->_ColorDrawBuffers state
     * to determine which surfaces to draw to
     */
@@ -62,6 +111,13 @@ update_framebuffer_state( struct st_context *st )
    for (j = 0; j < MAX_DRAW_BUFFERS; j++) {
       for (i = 0; i < fb->_NumColorDrawBuffers[j]; i++) {
          strb = st_renderbuffer(fb->_ColorDrawBuffers[j][i]);
+
+         /*printf("--------- framebuffer surface rtt %p\n", strb->rtt);*/
+         if (strb->rtt) {
+            /* rendering to a GL texture, may have to update surface */
+            update_renderbuffer_surface(st, strb);
+         }
+
          assert(strb->surface);
          framebuffer->cbufs[framebuffer->num_cbufs] = strb->surface;
          framebuffer->num_cbufs++;
@@ -71,6 +127,11 @@ update_framebuffer_state( struct st_context *st )
    strb = st_renderbuffer(fb->Attachment[BUFFER_DEPTH].Renderbuffer);
    if (strb) {
       strb = st_renderbuffer(strb->Base.Wrapped);
+      if (strb->rtt) {
+         /* rendering to a GL texture, may have to update surface */
+         update_renderbuffer_surface(st, strb);
+      }
+
       assert(strb->surface);
       framebuffer->zsbuf = strb->surface;
    }
@@ -99,7 +160,7 @@ const struct st_tracked_state st_update_framebuffer = {
    "st_update_framebuffer",                            /* name */
    {                                                   /* dirty */
       _NEW_BUFFERS,                                    /* mesa */
-      0,                                               /* st */
+      ST_NEW_FRAMEBUFFER,                              /* st */
    },
    update_framebuffer_state                            /* update */
 };
index 999c14844908a10eb6fa052b34a6f30bf2d1c211..e500ac8684df9e0091df70259d9aed5163a0565c 100644 (file)
@@ -126,7 +126,8 @@ create_color_map_texture(GLcontext *ctx)
 
    /* create texture for color map/table */
    pt = st_texture_create(ctx->st, PIPE_TEXTURE_2D, format, 0,
-                          texSize, texSize, 1, 0);
+                          texSize, texSize, 1, 0,
+                          PIPE_TEXTURE_USAGE_SAMPLER);
    return pt;
 }
 
@@ -148,8 +149,10 @@ load_color_map_texture(GLcontext *ctx, struct pipe_texture *pt)
    uint *dest;
    uint i, j;
 
-   surface = screen->get_tex_surface(screen, pt, 0, 0, 0);
-   dest = (uint *) pipe_surface_map(surface);
+   surface = screen->get_tex_surface(screen, pt, 0, 0, 0, 
+                                     PIPE_BUFFER_USAGE_CPU_WRITE);
+   dest = (uint *) screen->surface_map(screen, surface,
+                                       PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* Pack four 1D maps into a 2D texture:
     * R map is placed horizontally, indexed by S, in channel 0
@@ -168,9 +171,8 @@ load_color_map_texture(GLcontext *ctx, struct pipe_texture *pt)
       }
    }
 
-   pipe_surface_unmap(surface);
+   screen->surface_unmap(screen, surface);
    pipe_surface_reference(&surface, NULL);
-   pipe->texture_update(pipe, pt, 0, 0x1);
 }
 
 
index 7745591afbafb05e614c861103c146552ad7e588..a62ea8161c5b581c80d192525926e9330c000938 100644 (file)
@@ -44,6 +44,8 @@
 #include "pipe/p_context.h"
 #include "pipe/p_shader_tokens.h"
 
+#include "util/u_simple_shaders.h"
+
 #include "cso_cache/cso_context.h"
 
 #include "st_context.h"
@@ -252,6 +254,22 @@ st_free_translated_vertex_programs(struct st_context *st,
 }
 
 
+static void *
+get_passthrough_fs(struct st_context *st)
+{
+   struct pipe_shader_state shader;
+
+   if (!st->passthrough_fs) {
+      st->passthrough_fs =
+         util_make_fragment_passthrough_shader(st->pipe, &shader);
+#if 0      /* We actually need to keep the tokens around at this time */
+      free((void *) shader.tokens);
+#endif
+   }
+
+   return st->passthrough_fs;
+}
+
 
 static void
 update_linkage( struct st_context *st )
@@ -277,7 +295,15 @@ update_linkage( struct st_context *st )
    st_reference_fragprog(st, &st->fp, stfp);
 
    cso_set_vertex_shader_handle(st->cso_context, stvp->driver_shader);
-   cso_set_fragment_shader_handle(st->cso_context, stfp->driver_shader);
+
+   if (st->missing_textures) {
+      /* use a pass-through frag shader that uses no textures */
+      void *fs = get_passthrough_fs(st);
+      cso_set_fragment_shader_handle(st->cso_context, fs);
+   }
+   else {
+      cso_set_fragment_shader_handle(st->cso_context, stfp->driver_shader);
+   }
 
    st->vertex_result_to_slot = xvp->output_to_slot;
 }
index 767654f3d0ff9a940ad5c32253fc058eaf3bde96..1ec671ed48fc9b436e356604f85751dad508bb7f 100644 (file)
 #include "pipe/p_context.h"
 #include "pipe/p_inlines.h"
 #include "cso_cache/cso_context.h"
-#include "util/u_simple_shaders.h"
 
 
-static void *
-get_passthrough_fs(struct st_context *st)
-{
-   struct pipe_shader_state shader;
-
-   if (!st->passthrough_fs) {
-      st->passthrough_fs =
-         util_make_fragment_passthrough_shader(st->pipe, &shader);
-      free((void *) shader.tokens);
-   }
-
-   return st->passthrough_fs;
-}
-
-
-/**
- * XXX This needs some work yet....
- * Need to "upload" texture images at appropriate times.
- */
 static void 
 update_textures(struct st_context *st)
 {
    struct gl_fragment_program *fprog = st->ctx->FragmentProgram._Current;
    GLuint su;
-   GLboolean missing_textures = GL_FALSE;
 
    st->state.num_textures = 0;
 
@@ -85,13 +64,11 @@ update_textures(struct st_context *st)
             retval = st_finalize_texture(st->ctx, st->pipe, texObj, &flush);
             if (!retval) {
                /* out of mem */
-               missing_textures = GL_TRUE;
+               /* missing texture */
                continue;
             }
 
             st->state.num_textures = su + 1;
-
-            stObj->teximage_realloc = TRUE;
          }
 
          pt = st_get_stobj_texture(stObj);
@@ -103,12 +80,6 @@ update_textures(struct st_context *st)
    cso_set_sampler_textures(st->cso_context,
                             st->state.num_textures,
                             st->state.sampler_texture);
-
-   if (missing_textures) {
-      /* use a pass-through frag shader that uses no textures */
-      void *fs = get_passthrough_fs(st);
-      cso_set_fragment_shader_handle(st->cso_context, fs);
-   }
 }
 
 
@@ -120,3 +91,52 @@ const struct st_tracked_state st_update_texture = {
    },
    update_textures                                     /* update */
 };
+
+
+
+
+static void 
+finalize_textures(struct st_context *st)
+{
+   struct gl_fragment_program *fprog = st->ctx->FragmentProgram._Current;
+   const GLboolean prev_missing_textures = st->missing_textures;
+   GLuint su;
+
+   st->missing_textures = GL_FALSE;
+
+   for (su = 0; su < st->ctx->Const.MaxTextureCoordUnits; su++) {
+      if (fprog->Base.SamplersUsed & (1 << su)) {
+         const GLuint texUnit = fprog->Base.SamplerUnits[su];
+         struct gl_texture_object *texObj
+            = st->ctx->Texture.Unit[texUnit]._Current;
+         struct st_texture_object *stObj = st_texture_object(texObj);
+
+         if (texObj) {
+            GLboolean flush, retval;
+
+            retval = st_finalize_texture(st->ctx, st->pipe, texObj, &flush);
+            if (!retval) {
+               /* out of mem */
+               st->missing_textures = GL_TRUE;
+               continue;
+            }
+
+            stObj->teximage_realloc = TRUE;
+         }
+      }
+   }
+
+   if (prev_missing_textures != st->missing_textures)
+      st->dirty.st |= ST_NEW_FRAGMENT_PROGRAM;
+}
+
+
+
+const struct st_tracked_state st_finalize_textures = {
+   "st_finalize_textures",             /* name */
+   {                                   /* dirty */
+      _NEW_TEXTURE,                    /* mesa */
+      0,                               /* st */
+   },
+   finalize_textures                   /* update */
+};
index 1636bed91a5ccf7b1ec56c69e59c566795bc60eb..8098d75e18f337a78755f74bb9db78e92f5cda8e 100644 (file)
@@ -105,14 +105,18 @@ void
 st_clear_accum_buffer(GLcontext *ctx, struct gl_renderbuffer *rb)
 {
    struct st_renderbuffer *acc_strb = st_renderbuffer(rb);
-   struct pipe_surface *acc_ps = acc_strb->surface;
+   struct pipe_surface *acc_ps;
+   struct pipe_screen *screen = ctx->st->pipe->screen;
    const GLint xpos = ctx->DrawBuffer->_Xmin;
    const GLint ypos = ctx->DrawBuffer->_Ymin;
    const GLint width = ctx->DrawBuffer->_Xmax - xpos;
    const GLint height = ctx->DrawBuffer->_Ymax - ypos;
    GLvoid *map;
 
-   map = pipe_surface_map(acc_ps);
+   acc_ps = screen->get_tex_surface(screen, acc_strb->texture, 0, 0, 0,
+                                    PIPE_BUFFER_USAGE_CPU_WRITE);
+   map = screen->surface_map(screen, acc_ps,
+                             PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* note acc_strb->format might not equal acc_ps->format */
    switch (acc_strb->format) {
@@ -140,7 +144,8 @@ st_clear_accum_buffer(GLcontext *ctx, struct gl_renderbuffer *rb)
       _mesa_problem(ctx, "unexpected format in st_clear_accum_buffer()");
    }
 
-   pipe_surface_unmap(acc_ps);
+   screen->surface_unmap(screen, acc_ps);
+   pipe_surface_reference(&acc_ps, NULL);
 }
 
 
@@ -150,10 +155,12 @@ accum_mad(GLcontext *ctx, GLfloat scale, GLfloat bias,
           GLint xpos, GLint ypos, GLint width, GLint height,
           struct st_renderbuffer *acc_strb)
 {
+   struct pipe_screen *screen = ctx->st->pipe->screen;
    struct pipe_surface *acc_ps = acc_strb->surface;
    GLvoid *map;
 
-   map = pipe_surface_map(acc_ps);
+   map = screen->surface_map(screen, acc_ps, 
+                             PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* note acc_strb->format might not equal acc_ps->format */
    switch (acc_strb->format) {
@@ -174,77 +181,107 @@ accum_mad(GLcontext *ctx, GLfloat scale, GLfloat bias,
       _mesa_problem(NULL, "unexpected format in st_clear_accum_buffer()");
    }
 
-   pipe_surface_unmap(acc_ps);
+   screen->surface_unmap(screen, acc_ps);
 }
 
 
 static void
 accum_accum(struct pipe_context *pipe, GLfloat value,
             GLint xpos, GLint ypos, GLint width, GLint height,
-            struct pipe_surface *acc_ps,
-            struct pipe_surface *color_ps)
+            struct st_renderbuffer *acc_strb,
+            struct st_renderbuffer *color_strb)
 {
+   struct pipe_screen *screen = pipe->screen;
+   struct pipe_surface *acc_surf, *color_surf;
    GLfloat *colorBuf, *accBuf;
    GLint i;
 
+   acc_surf = screen->get_tex_surface(screen, acc_strb->texture, 0, 0, 0,
+                                      (PIPE_BUFFER_USAGE_CPU_WRITE |
+                                       PIPE_BUFFER_USAGE_CPU_READ));
+
+   color_surf = screen->get_tex_surface(screen, color_strb->texture, 0, 0, 0,
+                                        PIPE_BUFFER_USAGE_CPU_READ);
+
    colorBuf = (GLfloat *) malloc(width * height * 4 * sizeof(GLfloat));
    accBuf = (GLfloat *) malloc(width * height * 4 * sizeof(GLfloat));
 
-   pipe_get_tile_rgba(pipe, color_ps, xpos, ypos, width, height, colorBuf);
-   acc_get_tile_rgba(pipe, acc_ps, xpos, ypos, width, height, accBuf);
+   pipe_get_tile_rgba(pipe, color_surf, xpos, ypos, width, height, colorBuf);
+   acc_get_tile_rgba(pipe, acc_surf, xpos, ypos, width, height, accBuf);
 
    for (i = 0; i < 4 * width * height; i++) {
       accBuf[i] = accBuf[i] + colorBuf[i] * value;
    }
 
-   acc_put_tile_rgba(pipe, acc_ps, xpos, ypos, width, height, accBuf);
+   acc_put_tile_rgba(pipe, acc_surf, xpos, ypos, width, height, accBuf);
 
    free(colorBuf);
    free(accBuf);
+   pipe_surface_reference(&acc_surf, NULL);
+   pipe_surface_reference(&color_surf, NULL);
 }
 
 
 static void
 accum_load(struct pipe_context *pipe, GLfloat value,
            GLint xpos, GLint ypos, GLint width, GLint height,
-           struct pipe_surface *acc_ps,
-           struct pipe_surface *color_ps)
+           struct st_renderbuffer *acc_strb,
+           struct st_renderbuffer *color_strb)
 {
+   struct pipe_screen *screen = pipe->screen;
+   struct pipe_surface *acc_surf, *color_surf;
    GLfloat *buf;
    GLint i;
 
+   acc_surf = screen->get_tex_surface(screen, acc_strb->texture, 0, 0, 0,
+                                      PIPE_BUFFER_USAGE_CPU_WRITE);
+
+   color_surf = screen->get_tex_surface(screen, color_strb->texture, 0, 0, 0,
+                                        PIPE_BUFFER_USAGE_CPU_READ);
+
    buf = (GLfloat *) malloc(width * height * 4 * sizeof(GLfloat));
 
-   pipe_get_tile_rgba(pipe, color_ps, xpos, ypos, width, height, buf);
+   pipe_get_tile_rgba(pipe, color_surf, xpos, ypos, width, height, buf);
 
    for (i = 0; i < 4 * width * height; i++) {
       buf[i] = buf[i] * value;
    }
 
-   acc_put_tile_rgba(pipe, acc_ps, xpos, ypos, width, height, buf);
+   acc_put_tile_rgba(pipe, acc_surf, xpos, ypos, width, height, buf);
 
    free(buf);
+   pipe_surface_reference(&acc_surf, NULL);
+   pipe_surface_reference(&color_surf, NULL);
 }
 
 
 static void
 accum_return(GLcontext *ctx, GLfloat value,
              GLint xpos, GLint ypos, GLint width, GLint height,
-             struct pipe_surface *acc_ps,
-             struct pipe_surface *color_ps)
+             struct st_renderbuffer *acc_strb,
+             struct st_renderbuffer *color_strb)
 {
    struct pipe_context *pipe = ctx->st->pipe;
+   struct pipe_screen *screen = pipe->screen;
    const GLubyte *colormask = ctx->Color.ColorMask;
+   struct pipe_surface *acc_surf, *color_surf;
    GLfloat *abuf, *cbuf = NULL;
    GLint i, ch;
 
    abuf = (GLfloat *) malloc(width * height * 4 * sizeof(GLfloat));
 
-   acc_get_tile_rgba(pipe, acc_ps, xpos, ypos, width, height, abuf);
+   acc_surf = screen->get_tex_surface(screen, acc_strb->texture, 0, 0, 0,
+                                      PIPE_BUFFER_USAGE_CPU_READ);
+
+   color_surf = screen->get_tex_surface(screen, color_strb->texture, 0, 0, 0,
+                                        (PIPE_BUFFER_USAGE_CPU_READ |
+                                         PIPE_BUFFER_USAGE_CPU_WRITE));
+
+   acc_get_tile_rgba(pipe, acc_surf, xpos, ypos, width, height, abuf);
 
    if (!colormask[0] || !colormask[1] || !colormask[2] || !colormask[3]) {
       cbuf = (GLfloat *) malloc(width * height * 4 * sizeof(GLfloat));
-      pipe_get_tile_rgba(pipe, color_ps, xpos, ypos, width, height, cbuf);
+      pipe_get_tile_rgba(pipe, color_surf, xpos, ypos, width, height, cbuf);
    }
 
    for (i = 0; i < width * height; i++) {
@@ -259,11 +296,13 @@ accum_return(GLcontext *ctx, GLfloat value,
       }
    }
 
-   pipe_put_tile_rgba(pipe, color_ps, xpos, ypos, width, height, abuf);
+   pipe_put_tile_rgba(pipe, color_surf, xpos, ypos, width, height, abuf);
 
    free(abuf);
    if (cbuf)
       free(cbuf);
+   pipe_surface_reference(&acc_surf, NULL);
+   pipe_surface_reference(&color_surf, NULL);
 }
 
 
@@ -276,8 +315,6 @@ st_Accum(GLcontext *ctx, GLenum op, GLfloat value)
      = st_renderbuffer(ctx->DrawBuffer->Attachment[BUFFER_ACCUM].Renderbuffer);
    struct st_renderbuffer *color_strb
       = st_renderbuffer(ctx->ReadBuffer->_ColorReadBuffer);
-   struct pipe_surface *acc_ps = acc_strb->surface;
-   struct pipe_surface *color_ps = color_strb->surface;
 
    const GLint xpos = ctx->DrawBuffer->_Xmin;
    const GLint ypos = ctx->DrawBuffer->_Ymin;
@@ -300,14 +337,14 @@ st_Accum(GLcontext *ctx, GLenum op, GLfloat value)
       break;
    case GL_ACCUM:
       if (value != 0.0F) {
-         accum_accum(pipe, value, xpos, ypos, width, height, acc_ps, color_ps);
+         accum_accum(pipe, value, xpos, ypos, width, height, acc_strb, color_strb);
       }
       break;
    case GL_LOAD:
-      accum_load(pipe, value, xpos, ypos, width, height, acc_ps, color_ps);
+      accum_load(pipe, value, xpos, ypos, width, height, acc_strb, color_strb);
       break;
    case GL_RETURN:
-      accum_return(ctx, value, xpos, ypos, width, height, acc_ps, color_ps);
+      accum_return(ctx, value, xpos, ypos, width, height, acc_strb, color_strb);
       break;
    default:
       assert(0);
index e95ff5e2e0d36dc9c145859961732ce784020a25..3a102df67f1f1541bd22d91ff11f6e151c7839db 100644 (file)
@@ -325,16 +325,18 @@ make_bitmap_texture(GLcontext *ctx, GLsizei width, GLsizei height,
     * Create texture to hold bitmap pattern.
     */
    pt = st_texture_create(ctx->st, PIPE_TEXTURE_2D, ctx->st->bitmap.tex_format,
-                          0, width, height, 1, 0);
+                          0, width, height, 1, 0,
+                          PIPE_TEXTURE_USAGE_SAMPLER);
    if (!pt) {
       _mesa_unmap_bitmap_pbo(ctx, unpack);
       return NULL;
    }
 
-   surface = screen->get_tex_surface(screen, pt, 0, 0, 0);
+   surface = screen->get_tex_surface(screen, pt, 0, 0, 0,
+                                     PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* map texture surface */
-   dest = pipe_surface_map(surface);
+   dest = screen->surface_map(screen, surface, PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* Put image into texture surface */
    memset(dest, 0xff, height * surface->pitch);
@@ -344,9 +346,8 @@ make_bitmap_texture(GLcontext *ctx, GLsizei width, GLsizei height,
    _mesa_unmap_bitmap_pbo(ctx, unpack);
 
    /* Release surface */
-   pipe_surface_unmap(surface);
+   screen->surface_unmap(screen, surface);
    pipe_surface_reference(&surface, NULL);
-   pipe->texture_update(pipe, pt, 0, 0x1);
 
    return pt;
 }
@@ -543,13 +544,16 @@ reset_cache(struct st_context *st)
    cache->texture = st_texture_create(st, PIPE_TEXTURE_2D,
                                       st->bitmap.tex_format, 0,
                                       BITMAP_CACHE_WIDTH, BITMAP_CACHE_HEIGHT,
-                                      1, 0);
+                                      1, 0,
+                                      PIPE_TEXTURE_USAGE_SAMPLER);
 
    /* Map the texture surface.
     * Subsequent glBitmap calls will write into the texture image.
     */
-   cache->surf = screen->get_tex_surface(screen, cache->texture, 0, 0, 0);
-   cache->buffer = pipe_surface_map(cache->surf);
+   cache->surf = screen->get_tex_surface(screen, cache->texture, 0, 0, 0,
+                                         PIPE_BUFFER_USAGE_CPU_WRITE);
+   cache->buffer = screen->surface_map(screen, cache->surf,
+                                       PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* init image to all 0xff */
    memset(cache->buffer, 0xff, BITMAP_CACHE_WIDTH * BITMAP_CACHE_HEIGHT);
@@ -566,6 +570,7 @@ st_flush_bitmap_cache(struct st_context *st)
       if (st->ctx->DrawBuffer) {
          struct bitmap_cache *cache = st->bitmap.cache;
          struct pipe_context *pipe = st->pipe;
+         struct pipe_screen *screen = pipe->screen;
 
          assert(cache->xmin <= cache->xmax);
          /*
@@ -578,11 +583,8 @@ st_flush_bitmap_cache(struct st_context *st)
          /* The texture surface has been mapped until now.
           * So unmap and release the texture surface before drawing.
           */
-         pipe_surface_unmap(cache->surf);
-         pipe_surface_reference(&cache->surf, NULL);
-
-         /* XXX is this needed? */
-         pipe->texture_update(pipe, cache->texture, 0, 0x1);
+         screen->surface_unmap(screen, cache->surf);
+         screen->tex_surface_release(screen, &cache->surf);
 
          draw_bitmap_quad(st->ctx,
                           cache->xpos,
@@ -666,6 +668,9 @@ st_Bitmap(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
    struct st_context *st = ctx->st;
    struct pipe_texture *pt;
 
+   if (width == 0 || height == 0)
+      return;
+
    st_validate_state(st);
 
    if (!st->bitmap.vs) {
@@ -746,6 +751,11 @@ void
 st_destroy_bitmap(struct st_context *st)
 {
    struct pipe_context *pipe = st->pipe;
+   struct pipe_screen *screen = pipe->screen;
+   struct bitmap_cache *cache = st->bitmap.cache;
+
+   screen->surface_unmap(screen, cache->surf);
+   screen->tex_surface_release(screen, &cache->surf);
 
    if (st->bitmap.vs) {
       cso_delete_vertex_shader(st->cso_context, st->bitmap.vs);
index fbbe8d2d64ecf8de4f749b4cff7a26f229777787..a486581989c375b5a153759407723278f34ef6b4 100644 (file)
@@ -349,7 +349,8 @@ make_texture(struct st_context *st,
       return NULL;
 
    pt = st_texture_create(st, PIPE_TEXTURE_2D, pipeFormat, 0, width, height,
-                         1, 0);
+                         1, 0,
+                          PIPE_TEXTURE_USAGE_SAMPLER);
    if (!pt) {
       _mesa_unmap_drawpix_pbo(ctx, unpack);
       return NULL;
@@ -365,10 +366,12 @@ make_texture(struct st_context *st,
       /* we'll do pixel transfer in a fragment shader */
       ctx->_ImageTransferState = 0x0;
 
-      surface = screen->get_tex_surface(screen, pt, 0, 0, 0);
+      surface = screen->get_tex_surface(screen, pt, 0, 0, 0,
+                                        PIPE_BUFFER_USAGE_CPU_WRITE);
 
       /* map texture surface */
-      dest = pipe_surface_map(surface);
+      dest = screen->surface_map(screen, surface,
+                                 PIPE_BUFFER_USAGE_CPU_WRITE);
 
       /* Put image into texture surface.
        * Note that the image is actually going to be upside down in
@@ -387,9 +390,8 @@ make_texture(struct st_context *st,
                                     unpack);
 
       /* unmap */
-      pipe_surface_unmap(surface);
+      screen->surface_unmap(screen, surface);
       pipe_surface_reference(&surface, NULL);
-      pipe->texture_update(pipe, pt, 0, 0x1);
 
       assert(success);
 
@@ -485,7 +487,7 @@ draw_quad(GLcontext *ctx, GLfloat x0, GLfloat y0, GLfloat z,
       ubyte *map;
 
       /* allocate/load buffer object with vertex data */
-      buf = pipe_buffer_create(pipe,32, PIPE_BUFFER_USAGE_VERTEX,
+      buf = pipe_buffer_create(pipe, 32, PIPE_BUFFER_USAGE_VERTEX,
                                sizeof(verts));
       map = pipe_buffer_map(pipe, buf, PIPE_BUFFER_USAGE_CPU_WRITE);
       memcpy(map, verts, sizeof(verts));
@@ -495,8 +497,7 @@ draw_quad(GLcontext *ctx, GLfloat x0, GLfloat y0, GLfloat z,
                               PIPE_PRIM_QUADS,
                               4,  /* verts */
                               3); /* attribs/vert */
-
-      pipe_buffer_destroy(pipe, buf);
+      pipe_buffer_reference(pipe->winsys, &buf, NULL);
    }
 }
 
@@ -603,8 +604,10 @@ draw_textured_quad(GLcontext *ctx, GLint x, GLint y, GLfloat z,
    x1 = x + width * ctx->Pixel.ZoomX;
    y0 = y;
    y1 = y + height * ctx->Pixel.ZoomY;
+   //if(!color)
    draw_quad(ctx, x0, y0, z, x1, y1, color, invertTex);
-
+   //else
+   //printf("skip draw quad\n");
    /* restore state */
    cso_restore_rasterizer(cso);
    cso_restore_viewport(cso);
@@ -734,15 +737,23 @@ draw_stencil_pixels(GLcontext *ctx, GLint x, GLint y,
 {
    struct st_context *st = ctx->st;
    struct pipe_context *pipe = st->pipe;
-   struct pipe_surface *ps = st->state.framebuffer.zsbuf;
+   struct pipe_screen *screen = pipe->screen;
+   struct st_renderbuffer *strb;
+   struct pipe_surface *ps;
    const GLboolean zoom = ctx->Pixel.ZoomX != 1.0 || ctx->Pixel.ZoomY != 1.0;
    GLint skipPixels;
    ubyte *stmap;
 
    pipe->flush(pipe, PIPE_FLUSH_RENDER_CACHE, NULL);
 
+   strb = st_renderbuffer(ctx->DrawBuffer->
+                          Attachment[BUFFER_STENCIL].Renderbuffer);
+   ps = screen->get_tex_surface(screen, strb->texture, 0, 0, 0,
+                                PIPE_BUFFER_USAGE_CPU_WRITE);
+
    /* map the stencil buffer */
-   stmap = pipe_surface_map(ps);
+   stmap = screen->surface_map(screen, ps, 
+                               PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* if width > MAX_WIDTH, have to process image in chunks */
    skipPixels = 0;
@@ -799,7 +810,8 @@ draw_stencil_pixels(GLcontext *ctx, GLint x, GLint y,
    }
 
    /* unmap the stencil buffer */
-   pipe_surface_unmap(ps);
+   screen->surface_unmap(screen, ps);
+   pipe_surface_reference(&ps, NULL);
 }
 
 
@@ -872,7 +884,8 @@ copy_stencil_pixels(GLcontext *ctx, GLint srcx, GLint srcy,
                     GLint dstx, GLint dsty)
 {
    struct st_renderbuffer *rbDraw = st_renderbuffer(ctx->DrawBuffer->_StencilBuffer);
-   struct pipe_surface *psDraw = rbDraw->surface;
+   struct pipe_screen *screen = ctx->st->pipe->screen;
+   struct pipe_surface *psDraw;
    ubyte *drawMap;
    ubyte *buffer;
    int i;
@@ -887,8 +900,11 @@ copy_stencil_pixels(GLcontext *ctx, GLint srcx, GLint srcy,
    st_read_stencil_pixels(ctx, srcx, srcy, width, height, GL_UNSIGNED_BYTE,
                           &ctx->DefaultPacking, buffer);
 
+   psDraw = screen->get_tex_surface(screen, rbDraw->texture, 0, 0, 0,
+                                    PIPE_BUFFER_USAGE_CPU_WRITE);
+
    /* map the stencil buffer */
-   drawMap = pipe_surface_map(psDraw);
+   drawMap = screen->surface_map(screen, psDraw, PIPE_BUFFER_USAGE_CPU_WRITE);
 
    /* draw */
    /* XXX PixelZoom not handled yet */
@@ -928,7 +944,8 @@ copy_stencil_pixels(GLcontext *ctx, GLint srcx, GLint srcy,
    free(buffer);
 
    /* unmap the stencil buffer */
-   pipe_surface_unmap(psDraw);
+   screen->surface_unmap(screen, psDraw);
+   pipe_surface_reference(&psDraw, NULL);
 }
 
 
@@ -943,7 +960,6 @@ st_CopyPixels(GLcontext *ctx, GLint srcx, GLint srcy,
    struct st_renderbuffer *rbRead;
    struct st_vertex_program *stvp;
    struct st_fragment_program *stfp;
-   struct pipe_surface *psRead;
    struct pipe_surface *psTex;
    struct pipe_texture *pt;
    GLfloat *color;
@@ -974,8 +990,7 @@ st_CopyPixels(GLcontext *ctx, GLint srcx, GLint srcy,
       stvp = st_make_passthrough_vertex_shader(ctx->st, GL_TRUE);
    }
 
-   psRead = rbRead->surface;
-   srcFormat = psRead->format;
+   srcFormat = rbRead->texture->format;
 
    if (screen->is_format_supported(screen, srcFormat, PIPE_TEXTURE)) {
       texFormat = srcFormat;
@@ -987,54 +1002,72 @@ st_CopyPixels(GLcontext *ctx, GLint srcx, GLint srcy,
          assert(texFormat != PIPE_FORMAT_NONE); /* XXX no depth texture formats??? */
       }
       else {
-         /* todo */
-         assert(0);
+         /* default color format */
+         texFormat = st_choose_format(pipe, GL_RGBA, PIPE_TEXTURE);
+         assert(texFormat != PIPE_FORMAT_NONE);
       }
    }
 
    pt = st_texture_create(ctx->st, PIPE_TEXTURE_2D, texFormat, 0,
-                          width, height, 1, 0);
+                          width, height, 1, 0,
+                          PIPE_TEXTURE_USAGE_SAMPLER);
    if (!pt)
       return;
 
-   psTex = screen->get_tex_surface(screen, pt, 0, 0, 0);
-
    if (st_fb_orientation(ctx->DrawBuffer) == Y_0_TOP) {
       srcy = ctx->DrawBuffer->Height - srcy - height;
    }
 
    if (srcFormat == texFormat) {
       /* copy source framebuffer surface into mipmap/texture */
+      struct pipe_surface *psRead = screen->get_tex_surface(screen,
+                                       rbRead->texture, 0, 0, 0,
+                                       PIPE_BUFFER_USAGE_GPU_READ);
+      psTex = screen->get_tex_surface(screen, pt, 0, 0, 0, 
+                                      PIPE_BUFFER_USAGE_GPU_WRITE );
       pipe->surface_copy(pipe,
                          FALSE,
                         psTex, /* dest */
                         0, 0, /* destx/y */
                         psRead,
                         srcx, srcy, width, height);
+      pipe_surface_reference(&psRead, NULL);
    }
-   else if (type == GL_COLOR) {
-      /* alternate path using get/put_tile() */
-      GLfloat *buf = (GLfloat *) malloc(width * height * 4 * sizeof(GLfloat));
+   else {
+      /* CPU-based fallback/conversion */
+      struct pipe_surface *psRead = screen->get_tex_surface(screen,
+                                       rbRead->texture, 0, 0, 0,
+                                       PIPE_BUFFER_USAGE_CPU_READ);
 
-      pipe_get_tile_rgba(pipe, psRead, srcx, srcy, width, height, buf);
-      pipe_put_tile_rgba(pipe, psTex, 0, 0, width, height, buf);
+      psTex = screen->get_tex_surface(screen, pt, 0, 0, 0, 
+                                      PIPE_BUFFER_USAGE_CPU_WRITE );
 
-      free(buf);
-   }
-   else {
-      /* GL_DEPTH */
-      GLuint *buf = (GLuint *) malloc(width * height * sizeof(GLuint));
-      pipe_get_tile_z(pipe, psRead, srcx, srcy, width, height, buf);
-      pipe_put_tile_z(pipe, psTex, 0, 0, width, height, buf);
-      free(buf);
+      if (type == GL_COLOR) {
+         /* alternate path using get/put_tile() */
+         GLfloat *buf = (GLfloat *) malloc(width * height * 4 * sizeof(GLfloat));
+
+         pipe_get_tile_rgba(pipe, psRead, srcx, srcy, width, height, buf);
+         pipe_put_tile_rgba(pipe, psTex, 0, 0, width, height, buf);
+
+         free(buf);
+      }
+      else {
+         /* GL_DEPTH */
+         GLuint *buf = (GLuint *) malloc(width * height * sizeof(GLuint));
+         pipe_get_tile_z(pipe, psRead, srcx, srcy, width, height, buf);
+         pipe_put_tile_z(pipe, psTex, 0, 0, width, height, buf);
+         free(buf);
+      }
+      pipe_surface_reference(&psRead, NULL);
    }
 
+   pipe_surface_reference(&psTex, NULL);
+
    /* draw textured quad */
    draw_textured_quad(ctx, dstx, dsty, ctx->Current.RasterPos[2],
                       width, height, ctx->Pixel.ZoomX, ctx->Pixel.ZoomY,
                       pt, stvp, stfp, color, GL_TRUE);
 
-   pipe_surface_reference(&psTex, NULL);
    pipe_texture_reference(&pt, NULL);
 }
 
index fc8a5ea7f621c7565a9b0598882108a8b488ae3d..3560a040c859a53af5fc68df6bdc27acee93766b 100644 (file)
@@ -77,7 +77,6 @@ init_renderbuffer_bits(struct st_renderbuffer *strb,
    return info.size;
 }
 
-
 /**
  * gl_renderbuffer::AllocStorage()
  * This is called to allocate the original drawing surface, and
@@ -90,80 +89,94 @@ st_renderbuffer_alloc_storage(GLcontext * ctx, struct gl_renderbuffer *rb,
 {
    struct pipe_context *pipe = ctx->st->pipe;
    struct st_renderbuffer *strb = st_renderbuffer(rb);
-   enum pipe_format pipeFormat;
-   GLbitfield flags = 0x0; /* XXX needed? */
-   int ret;
-
-   if (!strb->surface) {
-      /* first time surface creation */
-      strb->surface = pipe->winsys->surface_alloc(pipe->winsys);
-      assert(strb->surface);
-      assert(strb->surface->refcount);
-      assert(strb->surface->winsys);
-      if (!strb->surface)
-         return GL_FALSE;
+   struct pipe_texture template;
+   unsigned surface_usage;
+
+   /* Free the old surface (and texture if we hold the last
+    * reference):
+    */
+   pipe_surface_reference( &strb->surface, NULL );
+
+   memset(&template, 0, sizeof(template));
+
+   if (strb->format != PIPE_FORMAT_NONE) {
+      template.format = strb->format;
    }
-   else if (strb->surface->buffer) {
-      /* release/discard the old surface buffer */
-      pipe_reference_buffer(pipe, &strb->surface->buffer, NULL);
+   else {
+      template.format = st_choose_renderbuffer_format(pipe, internalFormat);
    }
 
-   /* Determine surface format here */
-   if (strb->format != PIPE_FORMAT_NONE) {
-      assert(strb->format != 0);
-      /* we'll hit this for front/back color bufs */
-      pipeFormat = strb->format;
+   strb->Base.Width  = width;
+   strb->Base.Height = height;
+   init_renderbuffer_bits(strb, template.format);
+
+   template.target = PIPE_TEXTURE_2D;
+   template.compressed = 0;
+   template.cpp = pf_get_size(template.format);
+   template.width[0] = width;
+   template.height[0] = height;
+   template.depth[0] = 1;
+   template.last_level = 0;
+
+   if (pf_is_depth_stencil(template.format)) {
+      template.tex_usage = PIPE_TEXTURE_USAGE_DEPTH_STENCIL;
    }
    else {
-      pipeFormat = st_choose_renderbuffer_format(pipe, internalFormat);
+      template.tex_usage = (PIPE_TEXTURE_USAGE_DISPLAY_TARGET |
+                            PIPE_TEXTURE_USAGE_RENDER_TARGET);
    }
 
-   init_renderbuffer_bits(strb, pipeFormat);
-
-   ret = pipe->winsys->surface_alloc_storage(pipe->winsys,
-                                             strb->surface,
-                                             width,
-                                             height,
-                                             pipeFormat,
-                                             flags);
-   if (ret || !strb->surface->buffer) {
-      if (pipeFormat == DEFAULT_ACCUM_PIPE_FORMAT) {
-         /* Accum buffer.  Try a different surface format.  Since accum
-          * buffers are s/w only for now, the surface pixel format doesn't
-          * really matter, only that the buffer is large enough.
-          */
-         int sz, mult;
-         enum pipe_format accum_format;
-
-         /* allocate a buffer of (typically) double height to get 64bpp */
-         accum_format = st_choose_renderbuffer_format(pipe, GL_RGBA);
-         sz = pf_get_size(accum_format);
-         mult = pf_get_size(DEFAULT_ACCUM_PIPE_FORMAT) / sz;
-
-         ret = pipe->winsys->surface_alloc_storage(pipe->winsys,
-                                                   strb->surface,
-                                                   width, height * mult,
-                                                   accum_format, flags);
-         if (ret)
-            return GL_FALSE; /* we've _really_ failed */
-
-      }
-      else {
-         return GL_FALSE; /* out of memory, try s/w buffer? */
-      }
+
+   /* Probably need dedicated flags for surface usage too: 
+    */
+   surface_usage = (PIPE_BUFFER_USAGE_GPU_READ |
+                    PIPE_BUFFER_USAGE_GPU_WRITE);
+#if 0
+                    PIPE_BUFFER_USAGE_CPU_READ |
+                    PIPE_BUFFER_USAGE_CPU_WRITE);
+#endif
+
+   strb->texture = pipe->screen->texture_create( pipe->screen,
+                                                 &template );
+
+   /* Special path for accum buffers.  
+    *
+    * Try a different surface format.  Since accum buffers are s/w
+    * only for now, the surface pixel format doesn't really matter,
+    * only that the buffer is large enough.
+    */
+   if (!strb->texture && template.format == DEFAULT_ACCUM_PIPE_FORMAT) 
+   {
+      /* Actually, just setting this usage value should be sufficient
+       * to tell the driver to go ahead and allocate the buffer, even
+       * if HW doesn't support the format.
+       */
+      template.tex_usage = 0;
+      surface_usage = (PIPE_BUFFER_USAGE_CPU_READ |
+                       PIPE_BUFFER_USAGE_CPU_WRITE);
+
+      strb->texture = pipe->screen->texture_create( pipe->screen,
+                                                    &template );
+
    }
 
-   ASSERT(strb->surface->buffer);
-   ASSERT(strb->surface->format);
-   ASSERT(strb->surface->cpp);
-   ASSERT(strb->surface->width == width);
-   /*ASSERT(strb->surface->height == height);*/
-   ASSERT(strb->surface->pitch);
+   if (!strb->texture) 
+      return FALSE;
 
-   strb->Base.Width  = width;
-   strb->Base.Height = height;
+   strb->surface = pipe->screen->get_tex_surface( pipe->screen,
+                                                  strb->texture,
+                                                  0, 0, 0,
+                                                  surface_usage );
+
+   assert(strb->surface->buffer);
+   assert(strb->surface->format);
+   assert(strb->surface->cpp);
+   assert(strb->surface->width == width);
+   assert(strb->surface->height == height);
+   assert(strb->surface->pitch);
 
-   return GL_TRUE;
+
+   return strb->surface != NULL;
 }
 
 
@@ -175,10 +188,8 @@ st_renderbuffer_delete(struct gl_renderbuffer *rb)
 {
    struct st_renderbuffer *strb = st_renderbuffer(rb);
    ASSERT(strb);
-   if (strb->surface) {
-      struct pipe_winsys *ws = strb->surface->winsys;
-      ws->surface_release(ws, &strb->surface);
-   }
+   pipe_surface_reference(&strb->surface, NULL);
+   pipe_texture_reference(&strb->texture, NULL);
    free(strb);
 }
 
@@ -341,6 +352,10 @@ st_render_texture(GLcontext *ctx,
    struct pipe_context *pipe = st->pipe;
    struct pipe_screen *screen = pipe->screen;
    struct pipe_texture *pt;
+   struct st_texture_object *stObj;
+   const struct gl_texture_image *texImage =
+      att->Texture->Image[att->CubeMapFace][att->TextureLevel];
+
 
    assert(!att->Renderbuffer);
 
@@ -357,21 +372,27 @@ st_render_texture(GLcontext *ctx,
    strb = st_renderbuffer(rb);
 
    /* get the texture for the texture object */
+   stObj = st_texture_object(att->Texture);
+
+   /* point renderbuffer at texobject */
+   strb->rtt = stObj;
+   strb->rtt_level = att->TextureLevel;
+   strb->rtt_face = att->CubeMapFace;
+   strb->rtt_slice = att->Zoffset;
+
+   rb->Width = texImage->Width2;
+   rb->Height = texImage->Height2;
+   /*printf("***** render to texture level %d: %d x %d\n", att->TextureLevel, rb->Width, rb->Height);*/
+
    pt = st_get_texobj_texture(att->Texture);
    assert(pt);
-   assert(pt->width[att->TextureLevel]);
+   /*printf("***** pipe texture %d x %d\n", pt->width[0], pt->height[0]);*/
+
+   pipe_texture_reference( &strb->texture, pt );
 
-   rb->Width = pt->width[att->TextureLevel];
-   rb->Height = pt->height[att->TextureLevel];
+   pipe_surface_reference(&strb->surface, NULL);
 
-   /* the renderbuffer's surface is inside the texture */
-   strb->surface = screen->get_tex_surface(screen, pt,
-                                           att->CubeMapFace,
-                                           att->TextureLevel,
-                                           att->Zoffset);
-   assert(strb->surface);
-   assert(screen->is_format_supported(screen, strb->surface->format, PIPE_TEXTURE));
-   assert(screen->is_format_supported(screen, strb->surface->format, PIPE_SURFACE));
+   /* the new surface will be created during framebuffer validation */
 
    init_renderbuffer_bits(strb, pt->format);
 
@@ -396,22 +417,22 @@ static void
 st_finish_render_texture(GLcontext *ctx,
                          struct gl_renderbuffer_attachment *att)
 {
+   struct pipe_screen *screen = ctx->st->pipe->screen;
    struct st_renderbuffer *strb = st_renderbuffer(att->Renderbuffer);
 
    assert(strb);
 
    ctx->st->pipe->flush(ctx->st->pipe, PIPE_FLUSH_RENDER_CACHE, NULL);
 
-   ctx->st->pipe->texture_update(ctx->st->pipe,
-                                 st_get_texobj_texture(att->Texture),
-                                 att->CubeMapFace, 1 << att->TextureLevel);
+   if (strb->surface)
+      screen->tex_surface_release( screen, &strb->surface );
+
+   strb->rtt = NULL;
 
    /*
    printf("FINISH RENDER TO TEXTURE surf=%p\n", strb->surface);
    */
 
-   pipe_surface_reference(&strb->surface, NULL);
-
    _mesa_reference_renderbuffer(&att->Renderbuffer, NULL);
 
    /* restore previous framebuffer state */
index c1aa14f9b22ceeef99098c7ba5d13da6a7480b94..87b0734a0c8595dcbe1c8b13e4ec6bab0a8c850e 100644 (file)
 struct st_renderbuffer
 {
    struct gl_renderbuffer Base;
-   struct pipe_surface *surface;
+   struct pipe_texture *texture;
+   struct pipe_surface *surface; /* temporary view into texture */
    enum pipe_format format;  /** preferred format, or PIPE_FORMAT_NONE */
+
+   struct st_texture_object *rtt;  /**< GL render to texture's texture */
+   int rtt_level, rtt_face, rtt_slice;
 };
 
 
index 1b50792bd1cdb260ac4fe0a494bf5f85d8047552..19021411cfc9ec9fc6581d6c4cd2400ad3768d84 100644 (file)
@@ -173,6 +173,12 @@ feedback_reset_stipple_counter( struct draw_stage *stage )
 }
 
 
+static void
+feedback_destroy( struct draw_stage *stage )
+{
+   /* no-op */
+}
+
 /**
  * Create GL feedback drawing stage.
  */
@@ -188,6 +194,7 @@ draw_glfeedback_stage(GLcontext *ctx, struct draw_context *draw)
    fs->stage.tri = feedback_tri;
    fs->stage.flush = feedback_flush;
    fs->stage.reset_stipple_counter = feedback_reset_stipple_counter;
+   fs->stage.destroy = feedback_destroy;
    fs->ctx = ctx;
 
    return &fs->stage;
index 5f753afdd3635b6cc48590d326ce962ff511c71f..11ba5d56f3075429eb05ba561a2306cf06024874 100644 (file)
@@ -182,6 +182,7 @@ st_delete_program(GLcontext *ctx, struct gl_program *prog)
       assert(0); /* problem */
    }
 
+   /* delete base class */
    _mesa_delete_program( ctx, prog );
 }
 
index 745755566e7e312f19d3438599e4961bb3b3e516..08934af3195291fa2aecc2870f56b3ff0ce69ecf 100644 (file)
@@ -61,13 +61,18 @@ st_read_stencil_pixels(GLcontext *ctx, GLint x, GLint y,
                        GLvoid *pixels)
 {
    struct gl_framebuffer *fb = ctx->ReadBuffer;
+   struct pipe_screen *screen = ctx->st->pipe->screen;
    struct st_renderbuffer *strb = st_renderbuffer(fb->_StencilBuffer);
-   struct pipe_surface *ps = strb->surface;
+   struct pipe_surface *ps;
    ubyte *stmap;
    GLint j;
 
+   /* Create a CPU-READ surface/view into the renderbuffer's texture */
+   ps = screen->get_tex_surface(screen, strb->texture,  0, 0, 0,
+                                PIPE_BUFFER_USAGE_CPU_READ);
+
    /* map the stencil buffer */
-   stmap = pipe_surface_map(ps);
+   stmap = screen->surface_map(screen, ps, PIPE_BUFFER_USAGE_CPU_READ);
 
    /* width should never be > MAX_WIDTH since we did clipping earlier */
    ASSERT(width <= MAX_WIDTH);
@@ -124,7 +129,8 @@ st_read_stencil_pixels(GLcontext *ctx, GLint x, GLint y,
 
 
    /* unmap the stencil buffer */
-   pipe_surface_unmap(ps);
+   screen->surface_unmap(screen, ps);
+   pipe_surface_reference(&ps, NULL);
 }
 
 
@@ -168,12 +174,16 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
               GLvoid *dest)
 {
    struct pipe_context *pipe = ctx->st->pipe;
+   struct pipe_screen *screen = pipe->screen;
    GLfloat temp[MAX_WIDTH][4];
    const GLbitfield transferOps = ctx->_ImageTransferState;
    GLint i, yStep, dfStride;
    GLfloat *df;
    struct st_renderbuffer *strb;
    struct gl_pixelstore_attrib clippedPacking = *pack;
+   struct pipe_surface *surf;
+
+   assert(ctx->ReadBuffer->Width > 0);
 
    /* XXX convolution not done yet */
    assert((transferOps & IMAGE_CONVOLUTION_BIT) == 0);
@@ -229,6 +239,10 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
       yStep = 1;
    }
 
+   /* Create a CPU-READ surface/view into the renderbuffer's texture */
+   surf = screen->get_tex_surface(screen, strb->texture,  0, 0, 0,
+                                  PIPE_BUFFER_USAGE_CPU_READ);
+
    /*
     * Copy pixels from pipe_surface to user memory
     */
@@ -240,15 +254,14 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
       const GLint dstStride = _mesa_image_row_stride(&clippedPacking, width,
                                                      format, type);
 
-      if (strb->surface->format == PIPE_FORMAT_S8Z24_UNORM ||
-          strb->surface->format == PIPE_FORMAT_X8Z24_UNORM) {
+      if (surf->format == PIPE_FORMAT_S8Z24_UNORM ||
+          surf->format == PIPE_FORMAT_X8Z24_UNORM) {
          if (format == GL_DEPTH_COMPONENT) {
             for (i = 0; i < height; i++) {
                GLuint ztemp[MAX_WIDTH], j;
                GLfloat zfloat[MAX_WIDTH];
                const double scale = 1.0 / ((1 << 24) - 1);
-               pipe_get_tile_raw(pipe, strb->surface, x, y,
-                                 width, 1, ztemp, 0);
+               pipe_get_tile_raw(pipe, surf, x, y, width, 1, ztemp, 0);
                y += yStep;
                for (j = 0; j < width; j++) {
                   zfloat[j] = (float) (scale * (ztemp[j] & 0xffffff));
@@ -262,18 +275,18 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
             /* untested, but simple: */
             assert(format == GL_DEPTH_STENCIL_EXT);
             for (i = 0; i < height; i++) {
-               pipe_get_tile_raw(pipe, strb->surface, x, y, width, 1, dst, 0);
+               pipe_get_tile_raw(pipe, surf, x, y, width, 1, dst, 0);
                y += yStep;
                dst += dstStride;
             }
          }
       }
-      else if (strb->surface->format == PIPE_FORMAT_Z16_UNORM) {
+      else if (surf->format == PIPE_FORMAT_Z16_UNORM) {
          for (i = 0; i < height; i++) {
             GLushort ztemp[MAX_WIDTH], j;
             GLfloat zfloat[MAX_WIDTH];
             const double scale = 1.0 / 0xffff;
-            pipe_get_tile_raw(pipe, strb->surface, x, y, width, 1, ztemp, 0);
+            pipe_get_tile_raw(pipe, surf, x, y, width, 1, ztemp, 0);
             y += yStep;
             for (j = 0; j < width; j++) {
                zfloat[j] = (float) (scale * ztemp[j]);
@@ -283,12 +296,12 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
             dst += dstStride;
          }
       }
-      else if (strb->surface->format == PIPE_FORMAT_Z32_UNORM) {
+      else if (surf->format == PIPE_FORMAT_Z32_UNORM) {
          for (i = 0; i < height; i++) {
             GLuint ztemp[MAX_WIDTH], j;
             GLfloat zfloat[MAX_WIDTH];
             const double scale = 1.0 / 0xffffffff;
-            pipe_get_tile_raw(pipe, strb->surface, x, y, width, 1, ztemp, 0);
+            pipe_get_tile_raw(pipe, surf, x, y, width, 1, ztemp, 0);
             y += yStep;
             for (j = 0; j < width; j++) {
                zfloat[j] = (float) (scale * ztemp[j]);
@@ -302,7 +315,7 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
          /* RGBA format */
          /* Do a row at a time to flip image data vertically */
          for (i = 0; i < height; i++) {
-            pipe_get_tile_rgba(pipe, strb->surface, x, y, width, 1, df);
+            pipe_get_tile_rgba(pipe, surf, x, y, width, 1, df);
             y += yStep;
             df += dfStride;
             if (!dfStride) {
@@ -314,6 +327,8 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height,
       }
    }
 
+   pipe_surface_reference(&surf, NULL);
+
    _mesa_unmap_readpix_pbo(ctx, &clippedPacking);
 }
 
index cc17bebc6b696188c7f1261edca5dd4ff3ecfceb..e15ccec89b429ecbffb3d4a01b574dab39380d36 100644 (file)
@@ -272,6 +272,7 @@ guess_and_alloc_texture(struct st_context *st,
    GLuint height = stImage->base.Height2;
    GLuint depth = stImage->base.Depth2;
    GLuint i, comp_byte = 0;
+   enum pipe_format fmt;
 
    DBG("%s\n", __FUNCTION__);
 
@@ -306,6 +307,11 @@ guess_and_alloc_texture(struct st_context *st,
          depth <<= 1;
    }
 
+   if (width == 0 || height == 0 || depth == 0) {
+      /* no texture needed */
+      return;
+   }
+
    /* Guess a reasonable value for lastLevel.  This is probably going
     * to be wrong fairly often and might mean that we have to look at
     * resizable buffers, or require that buffers implement lazy
@@ -326,14 +332,19 @@ guess_and_alloc_texture(struct st_context *st,
    if (stImage->base.IsCompressed)
       comp_byte = compressed_num_bytes(stImage->base.TexFormat->MesaFormat);
 
+   fmt = st_mesa_format_to_pipe_format(stImage->base.TexFormat->MesaFormat);
    stObj->pt = st_texture_create(st,
                                  gl_target_to_pipe(stObj->base.Target),
-                                 st_mesa_format_to_pipe_format(stImage->base.TexFormat->MesaFormat),
+                                 fmt,
                                  lastLevel,
                                  width,
                                  height,
                                  depth,
-                                 comp_byte);
+                                 comp_byte,
+                                 ( (pf_is_depth_stencil(fmt) ?
+                                   PIPE_TEXTURE_USAGE_DEPTH_STENCIL :
+                                   PIPE_TEXTURE_USAGE_RENDER_TARGET) |
+                                   PIPE_TEXTURE_USAGE_SAMPLER ));
 
    DBG("%s - success\n", __FUNCTION__);
 }
@@ -478,7 +489,6 @@ st_TexImage(GLcontext * ctx,
             struct gl_texture_image *texImage,
             GLsizei imageSize, int compressed)
 {
-   struct pipe_context *pipe = ctx->st->pipe;
    struct st_texture_object *stObj = st_texture_object(texObj);
    struct st_texture_image *stImage = st_texture_image(texImage);
    GLint postConvWidth, postConvHeight;
@@ -637,8 +647,10 @@ st_TexImage(GLcontext * ctx,
       return;
 
    if (stImage->pt) {
-      texImage->Data = st_texture_image_map(ctx->st, stImage, 0);
-      dstRowStride = stImage->surface->pitch * stImage->surface->cpp;
+      texImage->Data = st_texture_image_map(ctx->st, stImage, 0,
+                                            PIPE_BUFFER_USAGE_CPU_WRITE);
+      if (stImage->surface)
+         dstRowStride = stImage->surface->pitch * stImage->surface->cpp;
    }
    else {
       /* Allocate regular memory and store the image there temporarily.   */
@@ -656,6 +668,11 @@ st_TexImage(GLcontext * ctx,
       texImage->Data = malloc(sizeInBytes);
    }
 
+   if (!texImage->Data) {
+      _mesa_error(ctx, GL_OUT_OF_MEMORY, "glTexImage");
+      return;
+   }
+
    DBG("Upload image %dx%dx%d row_len %x pitch %x\n",
        width, height, depth, width * texelBytes, dstRowStride);
 
@@ -686,8 +703,9 @@ st_TexImage(GLcontext * ctx,
         }
 
         if (stImage->pt && i < depth) {
-           st_texture_image_unmap(stImage);
-           texImage->Data = st_texture_image_map(ctx->st, stImage, i);
+           st_texture_image_unmap(ctx->st, stImage);
+           texImage->Data = st_texture_image_map(ctx->st, stImage, i,
+                                                  PIPE_BUFFER_USAGE_CPU_WRITE);
            src += srcImageStride;
         }
       }
@@ -696,13 +714,10 @@ st_TexImage(GLcontext * ctx,
    _mesa_unmap_teximage_pbo(ctx, unpack);
 
    if (stImage->pt) {
-      st_texture_image_unmap(stImage);
+      st_texture_image_unmap(ctx->st, stImage);
       texImage->Data = NULL;
    }
 
-   if (stObj->pt)
-      pipe->texture_update(pipe, stObj->pt, stImage->face, (1 << level));
-
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
       ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
@@ -795,7 +810,8 @@ st_get_tex_image(GLcontext * ctx, GLenum target, GLint level,
       /* Image is stored in hardware format in a buffer managed by the
        * kernel.  Need to explicitly map and unmap it.
        */
-      texImage->Data = st_texture_image_map(ctx->st, stImage, 0);
+      texImage->Data = st_texture_image_map(ctx->st, stImage, 0,
+                                            PIPE_BUFFER_USAGE_CPU_READ);
       texImage->RowStride = stImage->surface->pitch;
    }
    else {
@@ -825,8 +841,9 @@ st_get_tex_image(GLcontext * ctx, GLenum target, GLint level,
       }
 
       if (stImage->pt && i < depth) {
-        st_texture_image_unmap(stImage);
-        texImage->Data = st_texture_image_map(ctx->st, stImage, i);
+        st_texture_image_unmap(ctx->st, stImage);
+        texImage->Data = st_texture_image_map(ctx->st, stImage, i,
+                                               PIPE_BUFFER_USAGE_CPU_READ);
         dest += dstImageStride;
       }
    }
@@ -835,7 +852,7 @@ st_get_tex_image(GLcontext * ctx, GLenum target, GLint level,
 
    /* Unmap */
    if (stImage->pt) {
-      st_texture_image_unmap(stImage);
+      st_texture_image_unmap(ctx->st, stImage);
       texImage->Data = NULL;
    }
 }
@@ -876,8 +893,6 @@ st_TexSubimage(GLcontext * ctx,
                  struct gl_texture_object *texObj,
                  struct gl_texture_image *texImage)
 {
-   struct pipe_context *pipe = ctx->st->pipe;
-   struct st_texture_object *stObj = st_texture_object(texObj);
    struct st_texture_image *stImage = st_texture_image(texImage);
    GLuint dstRowStride;
    GLuint srcImageStride = _mesa_image_image_stride(packing, width, height,
@@ -899,8 +914,10 @@ st_TexSubimage(GLcontext * ctx,
     * from uploading the buffer under us.
     */
    if (stImage->pt) {
-      texImage->Data = st_texture_image_map(ctx->st, stImage, zoffset);
-      dstRowStride = stImage->surface->pitch * stImage->surface->cpp;
+      texImage->Data = st_texture_image_map(ctx->st, stImage, zoffset, 
+                                            PIPE_BUFFER_USAGE_CPU_WRITE);
+      if (stImage->surface)
+         dstRowStride = stImage->surface->pitch * stImage->surface->cpp;
    }
 
    if (!texImage->Data) {
@@ -924,8 +941,9 @@ st_TexSubimage(GLcontext * ctx,
 
       if (stImage->pt && i < depth) {
          /* map next slice of 3D texture */
-        st_texture_image_unmap(stImage);
-        texImage->Data = st_texture_image_map(ctx->st, stImage, zoffset + i);
+        st_texture_image_unmap(ctx->st, stImage);
+        texImage->Data = st_texture_image_map(ctx->st, stImage, zoffset + i,
+                                               PIPE_BUFFER_USAGE_CPU_WRITE);
         src += srcImageStride;
       }
    }
@@ -937,11 +955,9 @@ st_TexSubimage(GLcontext * ctx,
    _mesa_unmap_teximage_pbo(ctx, packing);
 
    if (stImage->pt) {
-      st_texture_image_unmap(stImage);
+      st_texture_image_unmap(ctx->st, stImage);
       texImage->Data = NULL;
    }
-
-   pipe->texture_update(pipe, stObj->pt, stImage->face, (1 << level));
 }
 
 
@@ -1059,8 +1075,11 @@ fallback_copy_texsubimage(GLcontext *ctx,
    }
 
    src_surf = strb->surface;
+   src_surf = screen->get_tex_surface(screen, strb->texture, face, level, destZ,
+                                       PIPE_BUFFER_USAGE_CPU_READ);
 
-   dest_surf = screen->get_tex_surface(screen, pt, face, level, destZ);
+   dest_surf = screen->get_tex_surface(screen, pt, face, level, destZ,
+                                       PIPE_BUFFER_USAGE_CPU_WRITE);
 
    assert(width <= MAX_WIDTH);
 
@@ -1094,6 +1113,9 @@ fallback_copy_texsubimage(GLcontext *ctx,
          pipe_put_tile_rgba(pipe, dest_surf, destX, destY, width, 1, data);
       }
    }
+
+   screen->tex_surface_release(screen, &dest_surf);
+   screen->tex_surface_release(screen, &src_surf);
 }
 
 
@@ -1121,13 +1143,11 @@ do_copy_texsubimage(GLcontext *ctx,
    struct gl_texture_image *texImage =
       _mesa_select_tex_image(ctx, texObj, target, level);
    struct st_texture_image *stImage = st_texture_image(texImage);
-   struct st_texture_object *stObj = st_texture_object(texObj);
    GLenum baseFormat = texImage->InternalFormat;
    struct gl_framebuffer *fb = ctx->ReadBuffer;
    struct st_renderbuffer *strb;
    struct pipe_context *pipe = ctx->st->pipe;
    struct pipe_screen *screen = pipe->screen;
-   struct pipe_surface *dest_surface;
    uint dest_format, src_format;
    uint do_flip = FALSE;
    GLboolean use_fallback = GL_TRUE;
@@ -1158,12 +1178,7 @@ do_copy_texsubimage(GLcontext *ctx,
    src_format = strb->surface->format;
    dest_format = stImage->pt->format;
 
-   dest_surface = screen->get_tex_surface(screen, stImage->pt, stImage->face,
-                                          stImage->level, destZ);
-
-   if (ctx->_ImageTransferState == 0x0 &&
-       strb->surface->buffer &&
-       dest_surface->buffer) {
+   if (ctx->_ImageTransferState == 0x0) {
       /* do blit-style copy */
 
       /* XXX may need to invert image depending on window
@@ -1186,6 +1201,14 @@ do_copy_texsubimage(GLcontext *ctx,
                         x, y + height, dstx, dsty, width, height,
                         GL_COPY); /* ? */
 #else
+      struct pipe_surface *dest_surface;
+
+      dest_surface = screen->get_tex_surface(screen, stImage->pt, stImage->face,
+                                             stImage->level, destZ,
+                                             PIPE_BUFFER_USAGE_GPU_WRITE);
+
+      assert(strb->surface->buffer);
+      assert(dest_surface->buffer);
 
       if (src_format == dest_format) {
           pipe->surface_copy(pipe,
@@ -1213,6 +1236,8 @@ do_copy_texsubimage(GLcontext *ctx,
                           0.0, PIPE_TEX_MIPFILTER_NEAREST);
          use_fallback = GL_FALSE;
       }
+
+      pipe_surface_reference(&dest_surface, NULL);
 #endif
    }
 
@@ -1223,10 +1248,6 @@ do_copy_texsubimage(GLcontext *ctx,
                                 srcX, srcY, width, height);
    }
 
-   pipe_surface_reference(&dest_surface, NULL);
-
-   pipe->texture_update(pipe, stObj->pt, stImage->face, (1 << level));
-
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
       ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
@@ -1483,20 +1504,28 @@ st_finalize_texture(GLcontext *ctx,
           stObj->pt->cpp != cpp ||
           stObj->pt->compressed != firstImage->base.IsCompressed) {
          pipe_texture_release(&stObj->pt);
+         ctx->st->dirty.st |= ST_NEW_FRAMEBUFFER;
       }
    }
 
    /* May need to create a new gallium texture:
     */
    if (!stObj->pt) {
+      const enum pipe_format fmt =
+         st_mesa_format_to_pipe_format(firstImage->base.TexFormat->MesaFormat);
       stObj->pt = st_texture_create(ctx->st,
                                     gl_target_to_pipe(stObj->base.Target),
-                                    st_mesa_format_to_pipe_format(firstImage->base.TexFormat->MesaFormat),
+                                    fmt,
                                     stObj->lastLevel,
                                     firstImage->base.Width2,
                                     firstImage->base.Height2,
                                     firstImage->base.Depth2,
-                                    comp_byte);
+                                    comp_byte,
+                                    ( (pf_is_depth_stencil(fmt) ?
+                                      PIPE_TEXTURE_USAGE_DEPTH_STENCIL :
+                                      PIPE_TEXTURE_USAGE_RENDER_TARGET) |
+                                      PIPE_TEXTURE_USAGE_SAMPLER ));
+
       if (!stObj->pt) {
          _mesa_error(ctx, GL_OUT_OF_MEMORY, "glTexImage");
          return GL_FALSE;
@@ -1516,7 +1545,6 @@ st_finalize_texture(GLcontext *ctx,
          if (stImage && stObj->pt != stImage->pt) {
             copy_image_data_to_texture(ctx->st, stObj, level, stImage);
            *needFlush = GL_TRUE;
-            pipe->texture_update(pipe, stObj->pt, face, (1 << level));
          }
       }
    }
index 46c16e45e66e817d9a26de57e048bd300249ec91..96333902a914c5d3eb19f60f03b58a99bf735d8d 100644 (file)
@@ -53,6 +53,7 @@ struct bitmap_cache;
 #define ST_NEW_MESA                    0x1 /* Mesa state has changed */
 #define ST_NEW_FRAGMENT_PROGRAM        0x2
 #define ST_NEW_VERTEX_PROGRAM          0x4
+#define ST_NEW_FRAMEBUFFER             0x8
 
 
 struct st_state_flags {
@@ -121,6 +122,8 @@ struct st_context
 
    struct st_state_flags dirty;
 
+   GLboolean missing_textures;
+
    GLfloat polygon_offset_scale; /* ?? */
 
    /** Mapping from VERT_RESULT_x to post-transformed vertex slot */
index 047743689dcfde987cc75aa2ce4a9ddd81af1403..f51eff05dce825dcfa201a02dfd4ebd534c712a0 100644 (file)
@@ -123,8 +123,10 @@ fallback_generate_mipmap(GLcontext *ctx, GLenum target,
       const ubyte *srcData;
       ubyte *dstData;
 
-      srcSurf = screen->get_tex_surface(screen, pt, face, srcLevel, zslice);
-      dstSurf = screen->get_tex_surface(screen, pt, face, dstLevel, zslice);
+      srcSurf = screen->get_tex_surface(screen, pt, face, srcLevel, zslice,
+                                        PIPE_BUFFER_USAGE_CPU_READ);
+      dstSurf = screen->get_tex_surface(screen, pt, face, dstLevel, zslice,
+                                        PIPE_BUFFER_USAGE_CPU_WRITE);
 
       srcData = (ubyte *) pipe_buffer_map(pipe, srcSurf->buffer,
                                           PIPE_BUFFER_USAGE_CPU_READ)
index f68bef1207c3d4e0781a3c813ffe68d14e7c7f70..9553b34e317b178980691d1da27dd79931cfaba2 100644 (file)
@@ -75,7 +75,8 @@ st_texture_create(struct st_context *st,
                  GLuint width0,
                  GLuint height0,
                  GLuint depth0,
-                 GLuint compress_byte)
+                 GLuint compress_byte,
+                  GLuint usage )
 {
    struct pipe_texture pt, *newtex;
    struct pipe_screen *screen = st->pipe->screen;
@@ -98,6 +99,7 @@ st_texture_create(struct st_context *st,
    pt.depth[0] = depth0;
    pt.compressed = compress_byte ? 1 : 0;
    pt.cpp = pt.compressed ? compress_byte : st_sizeof_format(format);
+   pt.tex_usage = usage;
 
    newtex = screen->texture_create(screen, &pt);
 
@@ -184,25 +186,33 @@ st_texture_image_offset(const struct pipe_texture * pt,
  */
 GLubyte *
 st_texture_image_map(struct st_context *st, struct st_texture_image *stImage,
-                    GLuint zoffset)
+                    GLuint zoffset,
+                     GLuint flags )
 {
    struct pipe_screen *screen = st->pipe->screen;
    struct pipe_texture *pt = stImage->pt;
    DBG("%s \n", __FUNCTION__);
 
    stImage->surface = screen->get_tex_surface(screen, pt, stImage->face,
-                                              stImage->level, zoffset);
+                                              stImage->level, zoffset, 
+                                              flags);
 
-   return pipe_surface_map(stImage->surface);
+   if (stImage->surface)
+      return screen->surface_map(screen, stImage->surface, flags);
+   else
+      return NULL;
 }
 
 
 void
-st_texture_image_unmap(struct st_texture_image *stImage)
+st_texture_image_unmap(struct st_context *st,
+                       struct st_texture_image *stImage)
 {
+   struct pipe_screen *screen = st->pipe->screen;
+
    DBG("%s\n", __FUNCTION__);
 
-   pipe_surface_unmap(stImage->surface);
+   screen->surface_unmap(screen, stImage->surface);
 
    pipe_surface_reference(&stImage->surface, NULL);
 }
@@ -224,12 +234,15 @@ st_surface_data(struct pipe_context *pipe,
                const void *src, unsigned src_pitch,
                unsigned srcx, unsigned srcy, unsigned width, unsigned height)
 {
-   pipe_copy_rect(pipe_surface_map(dst),
+   struct pipe_screen *screen = pipe->screen;
+   void *map = screen->surface_map(screen, dst, PIPE_BUFFER_USAGE_CPU_WRITE);
+
+   pipe_copy_rect(map,
                   dst->cpp,
                   dst->pitch,
                   dstx, dsty, width, height, src, src_pitch, srcx, srcy);
 
-   pipe_surface_unmap(dst);
+   screen->surface_unmap(screen, dst);
 }
 
 
@@ -256,7 +269,8 @@ st_texture_image_data(struct pipe_context *pipe,
       if(dst->compressed)
         height /= 4;
 
-      dst_surface = screen->get_tex_surface(screen, dst, face, level, i);
+      dst_surface = screen->get_tex_surface(screen, dst, face, level, i,
+                                            PIPE_BUFFER_USAGE_CPU_WRITE);
 
       st_surface_data(pipe, dst_surface,
                      0, 0,                             /* dstx, dsty */
@@ -265,7 +279,7 @@ st_texture_image_data(struct pipe_context *pipe,
                      0, 0,                             /* source x, y */
                      dst->width[level], height);       /* width, height */
 
-      pipe_surface_reference(&dst_surface, NULL);
+      screen->tex_surface_release(screen, &dst_surface);
 
       srcUB += src_image_pitch * dst->cpp;
    }
@@ -304,8 +318,27 @@ st_texture_image_copy(struct pipe_context *pipe,
       assert(src->width[srcLevel] == width);
       assert(src->height[srcLevel] == height);
 
-      dst_surface = screen->get_tex_surface(screen, dst, face, dstLevel, i);
-      src_surface = screen->get_tex_surface(screen, src, face, srcLevel, i);
+#if 0
+      {
+         src_surface = screen->get_tex_surface(screen, src, face, srcLevel, i,
+                                               PIPE_BUFFER_USAGE_CPU_READ);
+         ubyte *map = screen->surface_map(screen, src_surface, PIPE_BUFFER_USAGE_CPU_READ);
+         map += src_surface->width * src_surface->height * 4 / 2;
+         printf("%s center pixel: %d %d %d %d (pt %p[%d] -> %p[%d])\n",
+                __FUNCTION__,
+                map[0], map[1], map[2], map[3],
+                src, srcLevel, dst, dstLevel);
+
+         screen->surface_unmap(screen, src_surface);
+         pipe_surface_reference(&src_surface, NULL);
+      }
+#endif
+
+      dst_surface = screen->get_tex_surface(screen, dst, face, dstLevel, i,
+                                            PIPE_BUFFER_USAGE_GPU_WRITE);
+
+      src_surface = screen->get_tex_surface(screen, src, face, srcLevel, i,
+                                            PIPE_BUFFER_USAGE_GPU_READ);
 
       pipe->surface_copy(pipe,
                          FALSE,
@@ -315,7 +348,7 @@ st_texture_image_copy(struct pipe_context *pipe,
                         0, 0, /* srcX, Y */
                         width, copyHeight);
 
-      pipe_surface_reference(&dst_surface, NULL);
-      pipe_surface_reference(&src_surface, NULL);
+      screen->tex_surface_release(screen, &src_surface);
+      screen->tex_surface_release(screen, &dst_surface);
    }
 }
index b05762113ccf20b1c181757b584a0fff774adbbd..3febe6a7cb069a0e23398b9246839f90f47b864b 100644 (file)
@@ -93,6 +93,11 @@ st_get_stobj_texture(struct st_texture_object *stObj)
    return stObj ? stObj->pt : NULL;
 }
 
+static INLINE GLboolean pf_is_depth_stencil( enum pipe_format format )
+{
+   return (pf_get_component_bits( format, PIPE_FORMAT_COMP_Z ) +
+           pf_get_component_bits( format, PIPE_FORMAT_COMP_S )) != 0;
+}
 
 
 extern struct pipe_texture *
@@ -103,7 +108,8 @@ st_texture_create(struct st_context *st,
                   GLuint width0,
                   GLuint height0,
                   GLuint depth0,
-                  GLuint compress_byte);
+                  GLuint compress_byte,
+                  GLuint tex_usage );
 
 
 /* Check if an image fits into an existing texture object.
@@ -119,10 +125,12 @@ st_texture_match_image(const struct pipe_texture *pt,
 extern GLubyte *
 st_texture_image_map(struct st_context *st,
                      struct st_texture_image *stImage,
-                    GLuint zoffset);
+                    GLuint zoffset,
+                     GLuint flags);
 
 extern void
-st_texture_image_unmap(struct st_texture_image *stImage);
+st_texture_image_unmap(struct st_context *st,
+                       struct st_texture_image *stImage);
 
 
 /* Return pointers to each 2d slice within an image.  Indexed by depth
index 09508b66d52384c9fff3fbc3fa06dbeff262cf59..dee09fd648d50dd16673f8a4a33f67a014003c32 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86-64.c,v 1.4 2006/10/17 17:03:21 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index fdbd154d5d6f23b3d946c2d7704dae8c64c14de0..1d931fa3450d830529aae4c508ec173578aeefc2 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86-64.h,v 1.1 2005/05/07 16:59:59 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 65328f6666e856966ba3e2e80e5286fd7ca1a2e4..667ecf6e589ac328de5c2ed0de3ef1f869fcecec 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: xform4.S,v 1.2 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 032aa661f44d38993b6671ff49584e1bd21bcfea..4122ee4b0072a5199f2ce41ce8ee0f672b7a3477 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: 3dnow.c,v 1.24 2005/10/07 17:18:52 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 1f2fd8e8b4c23ec02177a1b6ee702ab8272bffb5..df9f2638d76d684f31c61c009515ed4f9d1bb795 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: 3dnow.h,v 1.6 2002/04/09 14:58:03 keithw Exp $ */
 
 /*
  * Mesa 3-D graphics library
index f3bbcb27b7f487b3410745e1e055e06554539c34..693a7864dbd9d942cc4557dfea2e8343dca9f578 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: 3dnow_normal.S,v 1.10 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 22b12cca067094e4d3bc1ae3ce3073e91ee1e58f..7665c0ff8b6f771e36de1e8f69220f13325dc21b 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: 3dnow_xform1.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index d9e96d04e28bcd92c5da918a845adaf1a40e5c5c..b201d1e901cd3e7a31fc9ebc132f33a847779396 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: 3dnow_xform2.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index babee1caa003896541fab73d59936ad7756fc183..46f155697d7c90e95ab1720f56a9cb5d142e8c44 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: 3dnow_xform3.S,v 1.5 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index b16d2b12dd6a249dc88f726a81bcd714b768c237..a0c6b193cdcee6dbb0efebf2f08eef4e48eebd5e 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: 3dnow_xform4.S,v 1.5 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index cccf801981279f989593585a95e7151742aa5e6c..796611fbfd3f11dbf165e855da8353702e70fac4 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: clip_args.h,v 1.5 2002/10/29 20:28:57 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 99772983289105c87832d421b890b569e5c23234..89312b2437989f82335455e76c823c423d4ce602 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: common_x86_asm.h,v 1.12 2005/07/16 00:56:20 ajax Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 90509775cfcd89f0c058ed8d33271e676e34e814..676af8c1f866ff10f61a7c3297a2d18f45a98ff0 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: common_x86_features.h,v 1.6 2003/01/21 16:14:00 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index ba155caae1d371686f09329780315083743df7e5..462f32b3f25355cf3cb653ff71f91b04b71c434c 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: common_x86_macros.h,v 1.3 2002/10/29 20:28:58 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 1b43d57a202412aa3e1ad76042d10ce6cadf5696..5d352838be5b1c9a9af568f75c52a6ba39a5dfe1 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: norm_args.h,v 1.4 2003/11/26 08:32:36 dborca Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 98146a90478725298e3a998eb8a0a701ad00f819..521f91e41179b1c2bb6a3436039b65d30bbda854 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sse.h,v 1.2 2002/04/09 14:58:03 keithw Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 066d46e5efd9335f151a8d67199b12ab813b9173..1c32e3b2fe5cc640ef5c0f3b5da1d03b0820fa03 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sse_normal.S,v 1.6 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 4051f606a7eefc3b4a90c199089b8af9c9477adf..22fd8dd27b5dc2e52756af4b90c6c889f33acf0e 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sse_xform1.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 06fe086bd40569b450e1d50516a0a940c46bb583..52eeb27ef5873d154058e2ed82fc541f240e08bf 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sse_xform2.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index eafbe342887610c094b1b833d3963f59b75cd582..5e0cd8b666c273ece558c271059ccb30a4df798a 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sse_xform3.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 24c323194f1219f08b81ddc67c5250abb9187c5e..13680528db7e9e2e46347c0c6109d257c2bdd95d 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: sse_xform4.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 6b74e9e375f2196e4bf23b90b43c99e706bdb79d..82caa42dbd6e22fed1432035e77188ed48d38638 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86.c,v 1.26 2005/10/07 17:18:52 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
index a646aff46b6a8017a3f38e88445eb47d8b43c2c2..97651ec6ee48128c40d4fc73cbd59794ca4bc1d8 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86.h,v 1.5 2002/04/09 14:58:03 keithw Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 5a45ee6ae60588aa94986f225d4f97cdc9cc27d3..c7a3a9b57e14950e4cc0716a6357bec750202e4f 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86_cliptest.S,v 1.12 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 94f6989d423b981d81c02607741fdf8785d6e12b..e41661d546cb540c5767bf5168a456d737932c71 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86_xform2.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 747e2f4d286bba5c797aea59cbba33e4e2502294..067ddd7d7cfe18b0edaeead6a208da2fd12ae852 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86_xform3.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index def3c1ceb9ed1593198d2a8eb509d701130b14ab..77621ac4bd5f45d40633cbfcea0424f49cd73955 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: x86_xform4.S,v 1.4 2006/04/17 18:58:24 krh Exp $ */
 
 /*
  * Mesa 3-D graphics library
index 89a04205c1f9028651d4469e9c48afa3246ca8db..b773f5198d13f55e21a7d86c933fd7f1a26eee30 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id: xform_args.h,v 1.5 2002/10/29 20:28:58 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library