Problem with exaModifyPixmapHeader_classic?
Michel Dänzer
michel at daenzer.net
Tue May 18 07:24:41 PDT 2010
On Die, 2010-05-18 at 17:42 +0800, april wrote:
> Hi all:
> I found problems when using exaGetPixmapOffset to get the offset of
> pixmap in framebuffer when this Pixmap is not within the EXA
> offscreen.
> Because the pExaPixmap->fb_ptr is NULL.
> In function exaModifyPixmapHeader_classic, pExaPixmap->fb_ptr is NULL
> unless pixmap is in EXA Offscreen.
>
> So can it be changed to the follow?
> --------------------------------------------------------------------------------
> /* Classic EXA:
> * - Framebuffer.
> * - Scratch pixmap with offscreen memory.
> */
> if (pExaScr->info->memoryBase && pPixData) {
> - if ((CARD8 *)pPixData >= pExaScr->info->memoryBase &&
> - ((CARD8 *)pPixData - pExaScr->info->memoryBase) <
> - pExaScr->info->memorySize) {
> + if (exaPixmapIsOffscreen(pExaPixmap)) {
> pExaPixmap->fb_ptr = pPixData;
> pExaPixmap->fb_pitch = devKind;
> pExaPixmap->offscreen = TRUE;
> }
> }
I think that would be wrong if fb_ptr != NULL?
It might be helpful if you can provide more details about the problem
you're trying to solve.
--
Earthling Michel Dänzer | http://www.vmware.com
Libre software enthusiast | Debian, X and DRI developer
More information about the xorg-devel
mailing list