Here is a slightly modified verion of their code for subencoding >= 130. If someone with more knowledge than me about ZRLE would look at it and see if they can see the problem, I'd appreciate it. (For those who don't know the language, the funny [] is the object message call in Objective-C, but that shouldn't be the problem)
if(subEncoding >= 130) {
for(i=0; i<(subEncoding - 128); i++) {
[frameBuffer fillColor:palette + i fromTightPixel:data];
data += cPixelSize;
}
y = 0;
while(y < (tile.size.width * tile.size.height)) {
unsigned char index = *data++;
if(index & 0x80) {
index &= 0x7f;
i = 1;
do {
b = *data++;
i += b;
} while(b == 0xff);
[frameBuffer putRun:palette + index ofLength:i at:tile pixelOffset:y];
y += i;
}
else
{
[frameBuffer putRun:palette + index ofLength:1 at:tile pixelOffset:y];
y++;
}
}
Thanks for the help, --
Jared McIntyre Deep Fried Software Deep Fried LLC Owner/Engineer http://www.dfsoftware.com [EMAIL PROTECTED] _______________________________________________ VNC-List mailing list [EMAIL PROTECTED] To remove yourself from the list visit: http://www.realvnc.com/mailman/listinfo/vnc-list