summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i915tex/intel_span.c
diff options
context:
space:
mode:
authorRoland Scheidegger <sroland@tungstengraphics.com>2007-07-12 21:52:02 +0200
committerRoland Scheidegger <sroland@tungstengraphics.com>2007-07-12 21:52:02 +0200
commit8b6517abfc20dc508c2a4cb1f6f22f34a8a70805 (patch)
treef45b11f5e0c06f25a5a49bc8b98ed736085805b4 /src/mesa/drivers/dri/i915tex/intel_span.c
parent9870f7bccc55f9b1728fa8b9ed78a72ab15d7f4f (diff)
don't use driDrawable information directly, don't resize at makecurrent
driDrawable information now isn't used in most parts of the driver. makecurrent only updates fb information when the context is new (driDrawable is still updated by the dri common code).
Diffstat (limited to 'src/mesa/drivers/dri/i915tex/intel_span.c')
-rw-r--r--src/mesa/drivers/dri/i915tex/intel_span.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/src/mesa/drivers/dri/i915tex/intel_span.c b/src/mesa/drivers/dri/i915tex/intel_span.c
index ab0874e4fd..368e0ec3c0 100644
--- a/src/mesa/drivers/dri/i915tex/intel_span.c
+++ b/src/mesa/drivers/dri/i915tex/intel_span.c
@@ -51,8 +51,7 @@
struct intel_renderbuffer *irb = intel_renderbuffer(rb); \
const GLint yScale = irb->RenderToTexture ? 1 : -1; \
const GLint yBias = irb->RenderToTexture ? 0 : irb->Base.Height - 1; \
- GLubyte *buf = (GLubyte *) irb->pfMap \
- + (intel->drawY * irb->pfPitch + intel->drawX) * irb->region->cpp;\
+ GLubyte *buf = (GLubyte *) irb->pfMap; \
GLuint p; \
assert(irb->pfMap);\
(void) p;
@@ -65,10 +64,10 @@
do { \
int _nc = intel->numClipRects; \
while ( _nc-- ) { \
- int minx = intel->pClipRects[_nc].x1 - intel->drawX; \
- int miny = intel->pClipRects[_nc].y1 - intel->drawY; \
- int maxx = intel->pClipRects[_nc].x2 - intel->drawX; \
- int maxy = intel->pClipRects[_nc].y2 - intel->drawY;
+ int minx = intel->pClipRects[_nc].x1; \
+ int miny = intel->pClipRects[_nc].y1; \
+ int maxx = intel->pClipRects[_nc].x2; \
+ int maxy = intel->pClipRects[_nc].y2;
@@ -106,9 +105,7 @@
const GLuint pitch = irb->pfPitch/***XXX region->pitch*/; /* in pixels */ \
const GLint yScale = irb->RenderToTexture ? 1 : -1; \
const GLint yBias = irb->RenderToTexture ? 0 : irb->Base.Height - 1; \
- char *buf = (char *) irb->pfMap/*XXX use region->map*/ + \
- (intel->drawY * pitch + intel->drawX) * irb->region->cpp;
-
+ char *buf = (char *) irb->pfMap/*XXX use region->map*/ ;
#define LOCAL_STENCIL_VARS LOCAL_DEPTH_VARS