diff options
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/Image.c')
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Image.c | 36 |
1 files changed, 19 insertions, 17 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.c b/nx-X11/programs/Xserver/hw/nxagent/Image.c index c022ebde7..a5e19724b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.c @@ -428,7 +428,7 @@ FIXME: Here the split trap is always set and so the caching of resource, nxagentSplitTrap); #endif - if (nxagentSplitTrap || nxagentUnpackAlpha[resource] == NULL || + if (nxagentSplitTrap == 1 || nxagentUnpackAlpha[resource] == NULL || nxagentUnpackAlpha[resource] -> size != size || memcmp(nxagentUnpackAlpha[resource] -> data, data, size) != 0) { @@ -584,8 +584,8 @@ FIXME: Should use these. int framebuffer = 1; int realize = 1; */ - if (nxagentGCTrap && !nxagentReconnectTrap && - !nxagentFBTrap && !nxagentShmTrap) + if (nxagentGCTrap == 1 && nxagentReconnectTrap == 0 && + nxagentFBTrap == 0 && nxagentShmTrap == 0) { if (pDrawable -> type == DRAWABLE_PIXMAP) { @@ -601,10 +601,11 @@ FIXME: Should use these. goto nxagentPutImageEnd; } - if (!nxagentReconnectTrap && !nxagentSplitTrap) + if (nxagentReconnectTrap == 0 && + nxagentSplitTrap == 0) { if (pDrawable -> type == DRAWABLE_PIXMAP && - !nxagentFBTrap && !nxagentShmTrap) + nxagentFBTrap == 0 && nxagentShmTrap == 0) { fbPutImage(nxagentVirtualDrawable(pDrawable), pGC, depth, dstX, dstY, dstWidth, dstHeight, leftPad, format, data); @@ -692,11 +693,11 @@ FIXME: Should use these. /* FIXME: Should we disable the split with link LAN? - split = (nxagentOption(Streaming) && + split = (nxagentOption(Streaming) == 1 && nxagentOption(LinkType) != LINK_TYPE_NONE && nxagentOption(LinkType) != LINK_TYPE_LAN */ - split = (nxagentOption(Streaming) && + split = (nxagentOption(Streaming) == 1 && nxagentOption(LinkType) != LINK_TYPE_NONE /* FIXME: Do we stream the images from GLX or Xv? If we do that, @@ -709,8 +710,8 @@ FIXME: Do we stream the images from GLX or Xv? If we do that, /* FIXME: Temporarily stream the GLX data. - && !nxagentGlxTrap - && !nxagentXvTrap + && nxagentGlxTrap == 0 + && nxagentXvTrap == 0 */ ); @@ -719,11 +720,12 @@ FIXME: Temporarily stream the GLX data. * is less than 15. */ - if (split == 1 && (nxagentSplitTrap || depth < 15)) + if (split == 1 && (nxagentSplitTrap == 1 || depth < 15)) { #ifdef TEST - if (nxagentSplitTrap || nxagentReconnectTrap) + if (nxagentSplitTrap == 1 || + nxagentReconnectTrap == 1) { fprintf(stderr, "nxagentPutImage: Not splitting with reconnection [%d] trap [%d] " "depth [%d].\n", nxagentSplitTrap, nxagentReconnectTrap, depth); @@ -765,7 +767,7 @@ FIXME: Temporarily stream the GLX data. */ if (nxagentOption(LinkType) != LINK_TYPE_NONE && - (nxagentGlxTrap || nxagentXvTrap)) + (nxagentGlxTrap == 1 || nxagentXvTrap == 1)) { #ifdef TEST fprintf(stderr, "nxagentPutImage: Disabling the use of the cache with GLX or Xvideo.\n"); @@ -972,7 +974,7 @@ void nxagentRealizeImage(DrawablePtr pDrawable, GCPtr pGC, int depth, bytesPerLine = nxagentImagePad(w, format, leftPad, depth); - if (nxagentOption(Shadow) && format == ZPixmap && + if (nxagentOption(Shadow) == 1 && format == ZPixmap && (nxagentOption(XRatio) != DONT_SCALE || nxagentOption(YRatio) != DONT_SCALE) && pDrawable == (DrawablePtr) nxagentShadowPixmapPtr) @@ -1195,7 +1197,7 @@ FIXME: Should use an unpack resource here. if (w <= IMAGE_PACK_WIDTH || h <= IMAGE_PACK_HEIGHT || nxagentImageLength(w, h, format, leftPad, depth) <= - IMAGE_PACK_LENGTH || nxagentLosslessTrap) + IMAGE_PACK_LENGTH || nxagentLosslessTrap == 1) { if (nxagentPackLossless == PACK_NONE) { @@ -1271,8 +1273,8 @@ FIXME: Should try to locate the image anyway, if the lossless again using the preferred method. */ if (nxagentNeedCache(plainImage, packMethod) && - !nxagentGlxTrap && !nxagentXvTrap && - !nxagentLosslessTrap && NXImageCacheSize > 0) + nxagentGlxTrap == 0 && nxagentXvTrap == 0 && + nxagentLosslessTrap == 0 && NXImageCacheSize > 0) { /* * Be sure that the padding bits are @@ -1339,7 +1341,7 @@ FIXME: There should be a callback registered by the agent that * compress better. */ - if (lossless == 0 && nxagentOption(Adaptive)) + if (lossless == 0 && nxagentOption(Adaptive) == 1) { int ratio = nxagentUniquePixels(plainImage); |