diff options
author | Keith Whitwell <keith@tungstengraphics.com> | 2004-12-29 20:46:27 +0000 |
---|---|---|
committer | Keith Whitwell <keith@tungstengraphics.com> | 2004-12-29 20:46:27 +0000 |
commit | 490e764d7affc093feff80192ed3f3d4642fcb8f (patch) | |
tree | a35f7ee56cdc3b36953b362d28654aa0df7f8920 /src/mesa/drivers/dri/unichrome/via_ioctl.h | |
parent | ef494c06b6e4dc720f32700f899ddad7cadb0a95 (diff) |
Simplfy clear() and swapbuffers() code.
Fix various mishandling of cliprects.
Allow multiple primitives to be emitted to a single dma buffer, which
was largely impossible previously.
Re-enable the fast unclipped render stage.
Diffstat (limited to 'src/mesa/drivers/dri/unichrome/via_ioctl.h')
-rw-r--r-- | src/mesa/drivers/dri/unichrome/via_ioctl.h | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/src/mesa/drivers/dri/unichrome/via_ioctl.h b/src/mesa/drivers/dri/unichrome/via_ioctl.h index 193aab8a99..ddb75ba6b8 100644 --- a/src/mesa/drivers/dri/unichrome/via_ioctl.h +++ b/src/mesa/drivers/dri/unichrome/via_ioctl.h @@ -29,18 +29,12 @@ void viaFinishPrimitive(viaContextPtr vmesa); -void viaFlushPrims(viaContextPtr vmesa); -void viaFlushPrimsLocked(viaContextPtr vmesa); +void viaFlushDma(viaContextPtr vmesa); +void viaFlushDmaLocked(viaContextPtr vmesa, GLuint flags); void viaInitIoctlFuncs(GLcontext *ctx); void viaCopyBuffer(const __DRIdrawablePrivate *dpriv); void viaPageFlip(const __DRIdrawablePrivate *dpriv); -void viaFillFrontBuffer(viaContextPtr vmesa); -void viaFillFrontPBuffer(viaContextPtr vmesa); -void viaFillBackBuffer(viaContextPtr vmesa); -void viaFillDepthBuffer(viaContextPtr vmesa, GLuint pixel, GLuint mask); -void viaDoSwapBuffers(viaContextPtr vmesa); -void viaDoSwapPBuffers(viaContextPtr vmesa); void viaCheckDma(viaContextPtr vmesa, GLuint bytes); #define VIA_FINISH_PRIM(vmesa) do { \ @@ -50,8 +44,8 @@ void viaCheckDma(viaContextPtr vmesa, GLuint bytes); #define VIA_FLUSH_DMA(vmesa) do { \ VIA_FINISH_PRIM(vmesa); \ - if (vmesa->dmaLow != DMA_OFFSET) \ - viaFlushPrims(vmesa); \ + if (vmesa->dmaLow) \ + viaFlushDma(vmesa); \ } while (0) @@ -59,12 +53,6 @@ GLuint *viaAllocDmaFunc(viaContextPtr vmesa, int bytes, const char *func, int li #define viaAllocDma( v, b ) viaAllocDmaFunc(v, b, __FUNCTION__, __LINE__) - -/* Room for the cliprect and other preamble at the head of each dma - * buffer: (What about buffers which only contain blits?) - */ -#define DMA_OFFSET 32 - #define RING_VARS GLuint *_vb = 0, _nr, _x; #define BEGIN_RING(n) do { \ @@ -76,7 +64,7 @@ GLuint *viaAllocDmaFunc(viaContextPtr vmesa, int bytes, const char *func, int li #define BEGIN_RING_NOCHECK(n) do { \ if (_vb != 0) abort(); \ - _vb = (GLuint *)(vmesa->dmaAddr + vmesa->dmaLow); \ + _vb = (GLuint *)(vmesa->dma + vmesa->dmaLow); \ vmesa->dmaLow += (n) * sizeof(GLuint); \ _nr = (n); \ _x = 0; \ |