summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/framebuffer.c
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/mesa into ↵Alan Hourihane2008-09-111-6/+6
|\ | | | | | | | | | | | | | | | | | | | | gallium-0.2 Conflicts: src/mesa/drivers/dri/i915/intel_ioctl.c src/mesa/main/texstore.c src/mesa/tnl/t_vp_build.c src/mesa/vbo/vbo_exec_draw.c
| * fix BUFFER_DEPTH/BUFFER_ACCUM mix-upBrian Paul2008-09-021-6/+6
| |
* | Merge branch 'gallium-0.1' into gallium-0.2Keith Whitwell2008-09-111-1/+79
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A first attempt at moving gallium onto a branch directly off master... It will be interesting to see how much work this takes to get running. Have resolved the conflicts semi-arbitarily, not compiled or tested. Conflicts: .gitignore Makefile configs/config.mgw configs/darwin configs/darwin-x86ppc configs/default configs/freebsd-dri configs/linux-dri configs/linux-dri-xcb configs/linux-fbdev configs/linux-static configs/linux-x86-64-static configs/linux-x86-static doxygen/Makefile include/GL/gl.h progs/demos/Makefile progs/demos/descrip.mms progs/demos/texenv.c progs/egl/.gitignore progs/egl/Makefile progs/glsl/.gitignore progs/glsl/Makefile progs/glsl/convolutions.c progs/samples/Makefile.mgw progs/tests/.gitignore progs/trivial/.gitignore progs/trivial/point-param.c progs/trivial/tri.c progs/xdemos/.gitignore progs/xdemos/glthreads.c src/egl/drivers/demo/Makefile src/egl/drivers/dri/Makefile src/egl/main/Makefile src/glu/Makefile src/glu/sgi/Makefile src/glu/sgi/Makefile.mgw src/glut/glx/Makefile.mgw src/glut/os2/WarpWin.cpp src/glut/os2/glut_cindex.cpp src/glut/os2/glut_gamemode.cpp src/glut/os2/glut_win.cpp src/glut/os2/glut_winmisc.cpp src/glut/os2/os2_glx.cpp src/glut/os2/os2_menu.cpp src/glut/os2/os2_winproc.cpp src/glw/Makefile src/glx/x11/dri_glx.c src/glx/x11/glxext.c src/mesa/Makefile src/mesa/Makefile.mgw src/mesa/descrip.mms src/mesa/drivers/beos/Makefile src/mesa/drivers/common/descrip.mms src/mesa/drivers/common/driverfuncs.c src/mesa/drivers/directfb/Makefile src/mesa/drivers/dri/Makefile.template src/mesa/drivers/dri/common/dri_bufmgr.c src/mesa/drivers/dri/common/dri_bufmgr.h src/mesa/drivers/dri/common/dri_util.c src/mesa/drivers/dri/common/extension_helper.h src/mesa/drivers/dri/common/mmio.h src/mesa/drivers/dri/common/utils.c src/mesa/drivers/dri/common/utils.h src/mesa/drivers/dri/glcore/Makefile src/mesa/drivers/dri/i810/i810screen.c src/mesa/drivers/dri/i915/intel_ioctl.c src/mesa/drivers/dri/i915/intel_ioctl.h src/mesa/drivers/dri/i915/intel_screen.c src/mesa/drivers/dri/i915/server/i830_common.h src/mesa/drivers/dri/i915/server/i830_dri.h src/mesa/drivers/dri/i965/intel_screen.c src/mesa/drivers/dri/i965/server/i830_common.h src/mesa/drivers/dri/i965/server/i830_dri.h src/mesa/drivers/dri/mach64/mach64_screen.c src/mesa/drivers/dri/nouveau/nouveau_context.h src/mesa/drivers/dri/nouveau/nouveau_fifo.c src/mesa/drivers/dri/nouveau/nouveau_fifo.h src/mesa/drivers/dri/nouveau/nouveau_screen.c src/mesa/drivers/dri/nouveau/nouveau_screen.h src/mesa/drivers/dri/r128/r128_tex.h src/mesa/drivers/dri/savage/savageioctl.h src/mesa/drivers/fbdev/Makefile src/mesa/drivers/osmesa/Makefile src/mesa/drivers/osmesa/descrip.mms src/mesa/drivers/x11/Makefile src/mesa/drivers/x11/descrip.mms src/mesa/drivers/x11/xm_dd.c src/mesa/glapi/glapi.c src/mesa/glapi/glthread.c src/mesa/main/api_validate.c src/mesa/main/attrib.c src/mesa/main/bufferobj.c src/mesa/main/bufferobj.h src/mesa/main/buffers.c src/mesa/main/config.h src/mesa/main/context.c src/mesa/main/descrip.mms src/mesa/main/drawpix.c src/mesa/main/enums.c src/mesa/main/fbobject.c src/mesa/main/glheader.h src/mesa/main/imports.c src/mesa/main/mipmap.c src/mesa/main/mm.c src/mesa/main/mm.h src/mesa/main/mtypes.h src/mesa/main/points.c src/mesa/main/sources src/mesa/main/state.c src/mesa/main/texcompress_fxt1.c src/mesa/main/texenvprogram.c src/mesa/main/texobj.c src/mesa/main/texstate.c src/mesa/main/texstore.c src/mesa/math/descrip.mms src/mesa/shader/arbprogram.c src/mesa/shader/descrip.mms src/mesa/shader/prog_execute.c src/mesa/shader/prog_statevars.c src/mesa/shader/prog_statevars.h src/mesa/shader/prog_uniform.c src/mesa/shader/program.c src/mesa/shader/program.h src/mesa/shader/shader_api.c src/mesa/shader/slang/descrip.mms src/mesa/shader/slang/library/slang_vertex_builtin_gc.h src/mesa/sources src/mesa/swrast/descrip.mms src/mesa/swrast/s_drawpix.c src/mesa/swrast/s_fragprog.c src/mesa/swrast/s_readpix.c src/mesa/swrast/s_span.c src/mesa/swrast_setup/descrip.mms src/mesa/tnl/descrip.mms src/mesa/tnl/t_context.h src/mesa/tnl/t_vp_build.c src/mesa/tnl/tnl.h src/mesa/vbo/descrip.mms src/mesa/vbo/vbo_context.c src/mesa/vbo/vbo_exec_array.c src/mesa/x86-64/xform4.S src/mesa/x86/rtasm/x86sse.c src/mesa/x86/rtasm/x86sse.h windows/VC6/progs/glut/glut.dsp windows/VC7/mesa/gdi/gdi.vcproj windows/VC7/mesa/glu/glu.vcproj windows/VC7/mesa/mesa.sln windows/VC7/mesa/mesa/mesa.vcproj windows/VC7/mesa/osmesa/osmesa.vcproj windows/VC7/progs/glut/glut.vcproj windows/VC8/mesa/gdi/gdi.vcproj windows/VC8/mesa/glu/glu.vcproj windows/VC8/mesa/mesa.sln windows/VC8/mesa/mesa/mesa.vcproj windows/VC8/progs/glut/glut.vcproj
| * mesa: Implement mutex/locking around texture object reference counting.Brian Paul2008-07-041-9/+4
| | | | | | | | | | | | | | | | Use new _mesa_reference_texobj() function for referencing/unreferencing textures. Add new assertions/tests to try to detect invalid usage of deleted textures. cherry-picked from master (9e01b915f1243a3f551cb795b7124bd1e52ca15f)
| * mesa: refactor: move _mesa_resizebuffers(), _mesa_ResizeBuffersMESA() to ↵Brian Paul2008-06-091-0/+78
| | | | | | | | framebuffer.c
| * mesa: Apply MSVC portability fixes from Alan Hourihane.José Fonseca2008-05-311-1/+1
| |
* | Fix some issues with glDrawBuffer(GL_NONE), bug 14198Brian2008-01-221-0/+3
| | | | | | | | | | Set _ColorDrawBuffers[0] = NULL if no renderbuffers enabled. Check that _ColorDrawBuffers[0] is non-null before dereferencing in a few places.
* | Replace gl_framebuffer's _ColorDrawBufferMask with _ColorDrawBufferIndexesBrian2008-01-061-32/+13
| | | | | | | | | | | | | | Each array element is now a BUFFER_x token rather than a BUFFER_BIT_x bitmask. The number of active color buffers is specified by _NumColorDrawBuffers. This builds on the previous DrawBuffer changes and will help with drivers implementing GL_ARB_draw_buffers.
* | Simplify ctx->_NumColorDrawBuffers, _ColorDrawBuffers and fix bug 13835.Brian2008-01-061-26/+71
| | | | | | | | | | | | | | | | | | | | | | These fields are no longer indexed by shader output. Now, we just have a simple array of renderbuffer pointers. If the shader writes to gl_FragData[i], send those colors to the N _ColorDrawBuffers. Otherwise, replicate the single gl_FragColor (or the fixed-function color) to the N _ColorDrawBuffers. A few more changes and simplifications can follow from this...
* | Rework the GL_READ_BUFFER, GL_DRAW_BUFFER state repairs that Roland ↵Brian2007-08-161-6/+20
| | | | | | | | | | | | | | | | | | previously did. Basically, in update_framebuffer() (which should be called after an FBO is bound with MakeCurrent or BindFramebuffer) we check if the FBO is a window-system FBO. If it is, update the FBO's GL_READ/DRAW_BUFFER state according to the context state. Old code still in place but disabled with #if 0 / #endif.
* | update comments, etc related to Read/DrawBuffer stateBrian2007-08-161-18/+28
| |
* | Implement mutex/locking around texture object reference counting.Brian2007-08-131-9/+4
|/ | | | | | Use new _mesa_reference_texobj() function for referencing/unreferencing textures. Add new assertions/tests to try to detect invalid usage of deleted textures.
* fix mesa's handling of fbo's / window fb (again)Roland Scheidegger2007-07-191-2/+1
| | | | | | | | Make sure the relevant fields in window fbs get updated at appropriate time (those are NOT the same as fbos!!!), and fix up related code accordingly. This is a bit ugly, but there's a reason the issues section in EXT_fbo is a couple hundred pages long... Hopefully correct now.
* fix up mesa's probably bogus framebuffer updates with different read/write fbsRoland Scheidegger2007-07-191-12/+26
| | | | | | Conflicts: src/mesa/main/framebuffer.c
* Minor clean-up of polygon offset logic. Properly compute _MRD field.Brian2007-07-111-1/+3
|
* Fix some renderbuffer reference counting issues. Also fixes a mem leak.Brian2007-03-251-44/+8
|
* Assorted fixes for dealing with zero-size frame/renderbuffers.Brian2007-03-161-2/+5
| | | | | | | | | | In xmesa_check_and_update_buffer_size() handle xmctx==NULL correctly: still call _mesa_resize_framebufer(). If we don't we can wind up in a situation where the framebuffer size is non-zero but an attached renderbuffer size is still initialized to zero. This inconsistancy can later cause problems. Check for zero-size renderbuffers in update_color_draw_buffers() and update_color_read_buffer(). See bug 7205.
* unreference old framebuffer, if needed, in _mesa_reference_framebuffer()Brian2007-03-061-0/+7
|
* Fix/improve framebuffer object reference counting.Brian2007-03-061-14/+32
| | | | | | | Use _mesa_reference_framebuffer() and _mesa_unreference_framebuffer() functions to be sure reference counting is done correctly. Additional assertions are done too. Note _mesa_dereference_framebuffer() renamed to "unreference" as that's more accurate.
* Take care of texObj reference in _mesa_free_framebuffer_data()Brian2007-03-061-6/+11
|
* assert that fb->RefCount==0 in _mesa_free_framebuffer_data()Brian2007-02-271-0/+1
|
* Do proper framebuffer refcounting in _mesa_make_current().Brian2007-02-261-16/+23
| | | | | | Also, added DeletePending field to gl_framebuffer used when a window has been deleted, but there still may be rendering contexts attached to the gl_framebuffer object.
* Set _NEW_BUFFERS in _mesa_resize_framebuffer(). This makes sure the swrastBrian Paul2006-10-161-2/+7
| | | | | module updates its state (CLIP_BIT) upon resizes. The driver could do this instead, but doing it here is safer.
* init accum buffer fields in _mesa_update_framebuffer_visual()Brian Paul2006-09-111-1/+14
|
* Check for a valid contextAlan Hourihane2006-06-211-1/+2
|
* If DrawBuffer isn't set, return immediatelyAlan Hourihane2006-06-191-0/+3
|
* Added _mesa_dereference_framebuffer() to encapsulate reference countBrian Paul2006-05-201-13/+34
| | | | decrement, delete and locking.
* remove an assertionBrian Paul2006-05-191-2/+0
|
* some tentative code for _mesa_update_framebuffer_visual()Brian Paul2006-04-201-0/+7
|
* do additional checking for setting up depth/stencil wrappersBrian Paul2006-04-061-3/+7
|
* Silence minor compiler warnings (-Wextra).Brian Paul2006-04-051-0/+2
|
* comments regarding assertionsBrian Paul2006-03-301-0/+5
|
* merge from texman branchmesa_20060325Brian Paul2006-03-261-113/+187
|
* fix issue in _mesa_free_framebuffer_data()Brian Paul2006-03-251-1/+1
|
* added some missing formats in _mesa_source/dest_buffer_exists()Brian Paul2006-03-241-2/+16
|
* added _mesa_source/dest_buffer_exists() function to easily test if ↵Brian Paul2006-03-201-1/+122
| | | | particular renderbuffers are present
* additional comments about GL_DEPTH_STENCIL buffersBrian Paul2005-11-161-2/+9
|
* Support for combined depth/stencil renderbuffers (GL_EXT_packed_depth_stencil).Brian Paul2005-11-161-2/+103
| | | | | depthstencil.c provides wrappers for treating depth/stencil buffers either as regular depth or stencil renderbuffers.
* check for ctx==NULL, bug 4087Brian Paul2005-11-151-1/+2
|
* fix GLX server resize/crash when resizing windowsBrian Paul2005-10-211-0/+3
|
* Fix some issues with state updates and renderbuffers. Querying GL_RED_BITS,Brian Paul2005-10-081-15/+27
| | | | etc. after calling glRenderBufferStorageEXT gave undefined results.
* change initialization of renderbuffer DepthBitsBrian Paul2005-10-041-0/+5
|
* disable a warningBrian Paul2005-10-031-1/+1
|
* check for framebuffer completeness, code clean-upBrian Paul2005-09-281-0/+1
|
* remove printfBrian Paul2005-09-231-1/+0
|
* Replace gl_framebuffer's _ColorReadBufferMask with _ColorReadBufferIndex,Brian Paul2005-09-231-31/+18
| | | | Streamline the _mesa_update_framebuffer() function a bit.
* Replace gl_renderbuffer.ComponentSizes[] with separate RedBits, GreenBits,Brian Paul2005-09-221-6/+6
| | | | BlueBits, etc fields.
* Replace GLuint with GLbitfield where appropriate. Also replace GLuintBrian Paul2005-09-151-2/+2
| | | | with GLboolean in a few places.
* Move _mesa_add_soft_renderbuffers() from framebuffer.c to renderbuffer.cBrian Paul2005-09-131-94/+12
| | | | Update some comments, code, etc.
* Remove last remnants of pre-renderbuffer code.Brian Paul2005-09-031-2/+0
|