Commit cecb6681 authored by David Reveman's avatar David Reveman

Add xglPixmapToRegion

parent 343f9657
......@@ -129,6 +129,7 @@ typedef struct _xglScreen {
CreateGCProcPtr CreateGC;
CloseScreenProcPtr CloseScreen;
SetWindowPixmapProcPtr SetWindowPixmap;
BitmapToRegionProcPtr BitmapToRegion;
#ifdef RENDER
CompositeProcPtr Composite;
......@@ -615,6 +616,9 @@ xglModifyPixmapHeader (PixmapPtr pPixmap,
int devKind,
pointer pPixData);
RegionPtr
xglPixmapToRegion (PixmapPtr pPixmap);
Bool
xglCreatePixmapSurface (PixmapPtr pPixmap);
......
......@@ -356,6 +356,24 @@ xglModifyPixmapHeader (PixmapPtr pPixmap,
return TRUE;
}
RegionPtr
xglPixmapToRegion (PixmapPtr pPixmap)
{
ScreenPtr pScreen = pPixmap->drawable.pScreen;
RegionPtr pRegion;
XGL_SCREEN_PRIV (pScreen);
if (!xglSyncBits (&pPixmap->drawable, NullBox))
FatalError (XGL_SW_FAILURE_STRING);
XGL_SCREEN_UNWRAP (BitmapToRegion);
pRegion = (*pScreen->BitmapToRegion) (pPixmap);
XGL_SCREEN_WRAP (BitmapToRegion, xglPixmapToRegion);
return pRegion;
}
Bool
xglCreatePixmapSurface (PixmapPtr pPixmap)
{
......
......@@ -56,7 +56,6 @@ int xglWinPrivateIndex;
#define xglListInstalledColormaps (void *) NoopDDA
#define xglStoreColors (void *) NoopDDA
#define xglResolveColor (void *) NoopDDA
#define xglBitmapToRegion (void *) NoopDDA
static PixmapPtr
xglGetWindowPixmap (WindowPtr pWin)
......@@ -226,11 +225,9 @@ xglScreenInit (ScreenPtr pScreen,
pScreen->ResolveColor = miResolveColor;
*/
/*
pScreen->BitmapToRegion = xglBitmapToRegion;
*/
pScreen->ModifyPixmapHeader = xglModifyPixmapHeader;
XGL_SCREEN_WRAP (BitmapToRegion, xglPixmapToRegion);
pScreen->GetWindowPixmap = xglGetWindowPixmap;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment