summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/i830_dri.c49
-rw-r--r--src/i830_video.c9
2 files changed, 32 insertions, 26 deletions
diff --git a/src/i830_dri.c b/src/i830_dri.c
index ea3d444c..0cc36eab 100644
--- a/src/i830_dri.c
+++ b/src/i830_dri.c
@@ -80,9 +80,10 @@ typedef struct {
#ifndef USE_DRI2_1_1_0
static DRI2BufferPtr
-I830DRI2CreateBuffers(DrawablePtr pDraw, unsigned int *attachments, int count)
+I830DRI2CreateBuffers(DrawablePtr drawable, unsigned int *attachments,
+ int count)
{
- ScreenPtr pScreen = pDraw->pScreen;
+ ScreenPtr pScreen = drawable->pScreen;
ScrnInfoPtr scrn = xf86Screens[pScreen->myNum];
intel_screen_private *intel = intel_get_screen_private(scrn);
DRI2BufferPtr buffers;
@@ -103,7 +104,7 @@ I830DRI2CreateBuffers(DrawablePtr pDraw, unsigned int *attachments, int count)
pDepthPixmap = NULL;
for (i = 0; i < count; i++) {
if (attachments[i] == DRI2BufferFrontLeft) {
- pixmap = get_drawable_pixmap(pDraw);
+ pixmap = get_drawable_pixmap(drawable);
pixmap->refcnt++;
} else if (attachments[i] == DRI2BufferStencil && pDepthPixmap) {
pixmap = pDepthPixmap;
@@ -130,9 +131,10 @@ I830DRI2CreateBuffers(DrawablePtr pDraw, unsigned int *attachments, int count)
hint = 0;
pixmap = (*pScreen->CreatePixmap) (pScreen,
- pDraw->width,
- pDraw->height,
- pDraw->depth, hint);
+ drawable->width,
+ drawable->height,
+ drawable->depth,
+ hint);
}
@@ -160,10 +162,10 @@ I830DRI2CreateBuffers(DrawablePtr pDraw, unsigned int *attachments, int count)
#else
static DRI2Buffer2Ptr
-I830DRI2CreateBuffer(DrawablePtr pDraw, unsigned int attachment,
+I830DRI2CreateBuffer(DrawablePtr drawable, unsigned int attachment,
unsigned int format)
{
- ScreenPtr pScreen = pDraw->pScreen;
+ ScreenPtr pScreen = drawable->pScreen;
ScrnInfoPtr scrn = xf86Screens[pScreen->myNum];
intel_screen_private *intel = intel_get_screen_private(scrn);
DRI2Buffer2Ptr buffer;
@@ -181,7 +183,7 @@ I830DRI2CreateBuffer(DrawablePtr pDraw, unsigned int attachment,
}
if (attachment == DRI2BufferFrontLeft) {
- pixmap = get_drawable_pixmap(pDraw);
+ pixmap = get_drawable_pixmap(drawable);
pixmap->refcnt++;
} else {
unsigned int hint = 0;
@@ -206,10 +208,10 @@ I830DRI2CreateBuffer(DrawablePtr pDraw, unsigned int attachment,
hint = 0;
pixmap = (*pScreen->CreatePixmap) (pScreen,
- pDraw->width,
- pDraw->height,
+ drawable->width,
+ drawable->height,
(format !=
- 0) ? format : pDraw->depth,
+ 0) ? format : drawable->depth,
hint);
}
@@ -236,9 +238,9 @@ I830DRI2CreateBuffer(DrawablePtr pDraw, unsigned int attachment,
#ifndef USE_DRI2_1_1_0
static void
-I830DRI2DestroyBuffers(DrawablePtr pDraw, DRI2BufferPtr buffers, int count)
+I830DRI2DestroyBuffers(DrawablePtr drawable, DRI2BufferPtr buffers, int count)
{
- ScreenPtr pScreen = pDraw->pScreen;
+ ScreenPtr pScreen = drawable->pScreen;
I830DRI2BufferPrivatePtr private;
int i;
@@ -255,11 +257,11 @@ I830DRI2DestroyBuffers(DrawablePtr pDraw, DRI2BufferPtr buffers, int count)
#else
-static void I830DRI2DestroyBuffer(DrawablePtr pDraw, DRI2Buffer2Ptr buffer)
+static void I830DRI2DestroyBuffer(DrawablePtr drawable, DRI2Buffer2Ptr buffer)
{
if (buffer) {
I830DRI2BufferPrivatePtr private = buffer->driverPrivate;
- ScreenPtr pScreen = pDraw->pScreen;
+ ScreenPtr pScreen = drawable->pScreen;
(*pScreen->DestroyPixmap) (private->pixmap);
@@ -271,22 +273,22 @@ static void I830DRI2DestroyBuffer(DrawablePtr pDraw, DRI2Buffer2Ptr buffer)
#endif
static void
-I830DRI2CopyRegion(DrawablePtr pDraw, RegionPtr pRegion,
+I830DRI2CopyRegion(DrawablePtr drawable, RegionPtr pRegion,
DRI2BufferPtr destBuffer, DRI2BufferPtr sourceBuffer)
{
I830DRI2BufferPrivatePtr srcPrivate = sourceBuffer->driverPrivate;
I830DRI2BufferPrivatePtr dstPrivate = destBuffer->driverPrivate;
- ScreenPtr pScreen = pDraw->pScreen;
+ ScreenPtr pScreen = drawable->pScreen;
ScrnInfoPtr scrn = xf86Screens[pScreen->myNum];
intel_screen_private *intel = intel_get_screen_private(scrn);
DrawablePtr src = (srcPrivate->attachment == DRI2BufferFrontLeft)
- ? pDraw : &srcPrivate->pixmap->drawable;
+ ? drawable : &srcPrivate->pixmap->drawable;
DrawablePtr dst = (dstPrivate->attachment == DRI2BufferFrontLeft)
- ? pDraw : &dstPrivate->pixmap->drawable;
+ ? drawable : &dstPrivate->pixmap->drawable;
RegionPtr pCopyClip;
GCPtr pGC;
- pGC = GetScratchGC(pDraw->depth, pScreen);
+ pGC = GetScratchGC(drawable->depth, pScreen);
pCopyClip = REGION_CREATE(pScreen, NULL, 0);
REGION_COPY(pScreen, pCopyClip, pRegion);
(*pGC->funcs->ChangeClip) (pGC, CT_REGION, pCopyClip, 0);
@@ -338,7 +340,10 @@ I830DRI2CopyRegion(DrawablePtr pDraw, RegionPtr pRegion,
}
(*pGC->ops->CopyArea) (src, dst,
- pGC, 0, 0, pDraw->width, pDraw->height, 0, 0);
+ pGC,
+ 0, 0,
+ drawable->width, drawable->height,
+ 0, 0);
FreeScratchGC(pGC);
/* Emit a flush of the rendering cache, or on the 965 and beyond
diff --git a/src/i830_video.c b/src/i830_video.c
index 0ca03e96..7c1890d3 100644
--- a/src/i830_video.c
+++ b/src/i830_video.c
@@ -1588,7 +1588,7 @@ i830_copy_video_data(ScrnInfoPtr scrn, intel_adaptor_private *adaptor_priv,
* (which we always are).
* clipBoxes is the clipping region in screen space.
* data is a pointer to our port private.
- * pDraw is a Drawable, which might not be the screen in the case of
+ * drawable is some Drawable, which might not be the screen in the case of
* compositing. It's a new argument to the function in the 1.1 server.
*/
static int
@@ -1599,12 +1599,13 @@ I830PutImage(ScrnInfoPtr scrn,
short drw_w, short drw_h,
int id, unsigned char *buf,
short width, short height,
- Bool sync, RegionPtr clipBoxes, pointer data, DrawablePtr pDraw)
+ Bool sync, RegionPtr clipBoxes, pointer data,
+ DrawablePtr drawable)
{
intel_screen_private *intel = intel_get_screen_private(scrn);
intel_adaptor_private *adaptor_priv = (intel_adaptor_private *) data;
ScreenPtr pScreen = screenInfo.screens[scrn->scrnIndex];
- PixmapPtr pixmap = get_drawable_pixmap(pDraw);;
+ PixmapPtr pixmap = get_drawable_pixmap(drawable);
INT32 x1, x2, y1, y2;
int dstPitch;
int dstPitch2 = 0;
@@ -1699,7 +1700,7 @@ I830PutImage(ScrnInfoPtr scrn,
pixmap);
}
- DamageDamageRegion(pDraw, clipBoxes);
+ DamageDamageRegion(drawable, clipBoxes);
}
adaptor_priv->videoStatus = CLIENT_VIDEO_ON;