aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_framebuffer.c
Commit message (Collapse)AuthorAgeFilesLines
* st/mesa: Remove unnecessary headers from st_framebuffer.c.Vinson Lee2010-01-141-4/+0
|
* st/mesa: create aux buffers according to visualBrian Paul2009-10-091-0/+7
| | | | Fixes bug 24426 for gallium.
* mesa/st: Create front renderbuffer on the fly when supplied with a surfaceNicolai Hähnle2009-09-201-3/+15
| | | | | | | | | | | Normally, the mesa/st would create a fake front buffer out of a client-allocated surface. In the DRI setting, however, st/dri provides a front buffer surface which is created and maintained by the X server. Prefer to use this surface instead, so that front buffer rendering and reading works correctly. Signed-off-by: Nicolai Hähnle <[email protected]>
* Merge branch 'mesa_7_5_branch'Jakob Bornecrantz2009-07-041-1/+2
|\
| * gallium: Only set FRONT_STATUS_COPY_OF_BACK if there is a back buffer.Michel Dänzer2009-07-071-1/+2
| | | | | | | | Fixes potential crash when SwapBuffers is called but there's no back buffer.
* | Merge branch 'mesa_7_5_branch'Brian Paul2009-06-241-10/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/mesa/drivers/dri/i915/i915_tex_layout.c src/mesa/drivers/dri/i965/brw_wm_glsl.c src/mesa/drivers/dri/intel/intel_buffer_objects.c src/mesa/drivers/dri/intel/intel_pixel_bitmap.c src/mesa/drivers/dri/intel/intel_pixel_draw.c src/mesa/main/enums.c src/mesa/main/texstate.c src/mesa/vbo/vbo_exec_array.c
| * mesa: rework viewport/scissor initialization codeBrian Paul2009-06-171-10/+1
| | | | | | | | | | | | | | | | | | | | The first time a context is bound to a drawable, the viewport and scissor bounds are initialized to the buffer's size. This is actually a bit tricky. A new _mesa_check_init_viewport() function is called in several places to check if the viewport has been initialized. We also use a new ctx->ViewportInitialized flag instead of the overloaded ctx->FirstTimeCurrent flag.
* | Merge branch 'mesa_7_5_branch'José Fonseca2009-06-111-8/+9
|\| | | | | | | | | | | Conflicts: src/mesa/state_tracker/st_cb_fbo.c src/mesa/state_tracker/st_framebuffer.c
| * mesa: Pure software accum buffer.José Fonseca2009-06-101-8/+9
| | | | | | | | | | | | | | | | | | | | The existing implementation was already implemented on software, but relied on the pipe driver to always support the R16G16B16A16_SNORM format. This patch eliminates that, without prejudice against a future hardware-only implementation. It also avoids some of the short <-> float conversions, and only does a read transfer of the color buffer on GL_RETURN if absolutely necessary.
* | st: if st_swapbuffers() is called for single-buffered visual don't crashBrian Paul2009-05-011-1/+19
| | | | | | | | Furthermore, return pointer(s) to the front color buffer(s).
* | st: added st_renderbuffer::defined flagBrian Paul2009-05-011-0/+12
| | | | | | | | | | | | | | | | | | | | Indicates whether there's defined image contents, or garbage/don't care. This is set when we draw into a renderbuffer and cleared when we resize/ reallocate a renderbuffer or do a buffer swap (back buffer becomes undefined). We use this to determine whether the front color buffer has been drawn to, and whether to display its contents upon glFlush/Finish(), when the new st_swapbuffers() function is used.
* | set: new st_swapbuffers() which does a true front/back buffer swapBrian Paul2009-05-011-0/+79
| | | | | | | | | | The pointers to the front/back renderbuffers are exchanged. This new function isn't actually used yet...
* | st: when double buffered, only create front color buffer on demandBrian Paul2009-05-011-8/+8
|/ | | | | Before we always created the front color buffer, even if was never used. This can save some memory.
* gallium: Remove some little-used fields from struct pipe_surface.Michel Dänzer2009-03-261-26/+0
|
* mesa: move glViewport and glDepthRange functions into new viewport.c fileBrian Paul2009-03-071-0/+1
| | | | A bit of refactoring with an eye toward ES2 and GL 3.1
* mesa: remove last of _mesa_unreference_framebuffer() callsBrian Paul2009-03-071-1/+1
|
* gallium: Remove some superfluous instances of #include "p_inlines.h".Michel Dänzer2009-03-041-1/+0
|
* mesa: use new ST_CALLOC_STRUCT() macro in gallium state trackerBrian Paul2009-02-121-1/+1
|
* gallium: change the st_get_framebuffer_surface/texture functionsAlan Hourihane2009-01-231-11/+19
| | | | | to return TRUE/FALSE if the st_framebuffer is valid, and if it is return the surface/texture in the passed pointer.
* gallium: Remove unused variables.José Fonseca2008-12-301-1/+0
|
* gallium: set ST_NEW_FRAMEBUFFER when setting new surfacesAlan Hourihane2008-12-191-0/+11
|
* Merge commit 'origin/gallium-0.1' into gallium-0.2Brian Paul2008-12-101-9/+11
|\
| * gallium: only mark back color buffer surfaces as undefined after swapbuffersBrian Paul2008-12-101-9/+11
| | | | | | | | | | Marking all surfaces as undefined was wrong and cause some glean failures because glReadPixels was used after SwapBuffers.
* | Merge commit 'origin/gallium-0.1' into gallium-0.2Brian Paul2008-11-051-1/+2
|\| | | | | | | | | | | | | | | | | Conflicts: src/gallium/auxiliary/rtasm/rtasm_execmem.c src/mesa/shader/slang/slang_emit.c src/mesa/shader/slang/slang_log.c src/mesa/state_tracker/st_atom_framebuffer.c
| * gallium: add some checks for null surface pointers in state trackerBrian Paul2008-10-181-1/+2
| | | | | | | | Fixes some segfaults in low memory situations.
* | gallium: no renderbuffer, so just exit.Alan Hourihane2008-11-031-1/+3
| |
* | st: add prototype for st_get_framebuffer_dimensions()Alan Hourihane2008-09-261-2/+2
| |
* | st: export st_get_framebuffer_dimensions() to retrieveAlan Hourihane2008-09-261-0/+7
| | | | | | | | the width & height of the fb
* | st: change from ** to * for st_unreference_framebuffer()Alan Hourihane2008-09-261-2/+2
|/
* gallium: clean-up/fix msaa override in state trackerBrian Paul2008-09-171-6/+5
|
* gallium: change the conditional which tests for combined Z+stencil buffersBrian Paul2008-08-281-1/+1
| | | | | The caller might be requesting 16-bit Z + 8-bit stencil be placed in a PIPE_FORMAT_S8Z24 or PIPE_FORMAT_Z24S8 buffer.
* mesa: Issue PIPE_FLUSH_FRAME in glSwapBuffers/glFlush/glFinish.José Fonseca2008-08-151-1/+3
|
* add env var to override msaa visual selectionRoland Scheidegger2008-07-221-0/+4
|
* gallium: handle msaaRoland Scheidegger2008-06-271-8/+10
|
* gallium: Add accessor functions to get textures from a st_framebufferJakob Bornecrantz2008-06-231-0/+16
|
* gallium: added new st_set_framebuffer_surface()Brian Paul2008-06-181-0/+56
| | | | | This allows the winsys to explicitly specify gallium surfaces for a framebuffer object.
* gallium: include scissor.hBrian Paul2008-06-091-0/+1
|
* gallium: more elaborate tracking of front color buffer stateBrian Paul2008-04-091-0/+1
| | | | | | | This fixes the case where the app calls SwapBuffers then calls glReadPixels to read the front color buffer. We now keep track of when the front buffer is a _logically_ copy of the back buffer (after SwapBuffers) and read from the back color buffer instead of the front.
* gallium: accum buffer fixesBrian Paul2008-04-071-1/+1
| | | | | | | If the driver can't create a PIPE_FORMAT_R16G16B16A16_SNORM surface, create an accum surface using a shallower format and taller height. Since only the accum buffer code accesses the surface the actual format doesn't really matter, just that there's enough memory.
* gallium: Change pipe->flush() interface to optionally return a fence.Michel Dänzer2008-03-261-1/+2
| | | | | The cell driver still uses an internal CELL_FLUSH_WAIT flag, in the long run proper fencing should be implemented for it.
* gallium: #includes to silence warningsBrian2008-02-261-0/+2
|
* gallium: fix zero-sized viewport bugBrian2008-02-261-0/+11
| | | | | | If st_create_framebuffer() is called with width=0, height=0 and the program never called glViewport, the viewport wasn't properly initalized. This fixes that.
* gallium: add notify_swapbuffers_complete, use it to set surfaces to ↵Keith Whitwell2008-01-261-0/+20
| | | | undefined state
* gallium: specialize glFlush vs other flush semanticsKeith Whitwell2008-01-261-1/+6
|
* gallium: make state tracker explictly ask for rendercache flushesKeith Whitwell2007-12-201-1/+2
|
* Fix problem with initial viewport/scissor size.Brian2007-12-191-55/+54
| | | | | | | | | | | If an app never called glViewport, the viewport size was always 0 by 0 pixels. Now pass initial size to st_create_framebuffer() and initialize the viewport and scissor bounds in st_make_current(). This could also be fixed by ensuring the gl_framebuffers passed to _mesa_make_current() were initialized to the right size. But that involves allocating the renderbuffers/pipe_surfaces earlier and that runs into some other issues ATM. Also remove obsolete createRenderbuffers param to st_create_framebuffer().
* Re-org of st_create_framebuffer() and renderbuffer format selection.Brian2007-12-121-15/+16
| | | | | | | | st_create_framebuffer() now takes pipe_formats for the color, depth, stencil buffers. This avoids a round-about chain of calls to pipe->is_format_supported() for window renderbuffers (their format never changes). Renderbuffer format selection code in st_format.c is simpler now too.
* Add 'type' parameter to is_format_supported() to specify texture vs. drawing ↵Brian2007-12-101-19/+10
| | | | | | surface, etc. Additional types may be added in the future.
* added ST_SURFACE_DEPTHBrian2007-12-071-1/+1
|
* New PIPE_FLUSH_WAIT flag for pipe->flush().Brian2007-11-071-1/+1
| | | | | The state tracker doesn't have to directly call winsys->wait_idle() anymore. glFlush and glFinish both go through pipe->flush() now.