[MacGLQuake] Mac gl quakeworld bug (I'm sure this has been brought up)

Brad Oliver bradman@pobox.com
Tue, 05 Dec 2000 15:07:08 -0600


On 12/5/00 1:51 PM, "macglquake-admin@indigita.com"
<macglquake-admin@indigita.com> wrote:

> I have the same problems your a talking about. I'm not sure if pOx knows of
> these and is correcting them or not.

I fixed them in the 0.8.1 source in Hexen 2. There's 2 bugs at play, one in
the core (the malloc for the screenshot buffer is not checked for failure)
and another in the Mac code. Use this new code in gl_vidmac.c:

void GL_BeginRendering (int *x, int *y, int *width, int *height)
{
    extern cvar_t gl_clear;

    *x = *y = 0;
    *width = gWindowRect.right - gWindowRect.left;
    *height = gWindowRect.bottom - gWindowRect.top;
    
    if (is3dfx) return;
    
    // Another ATi workaround - the window we created in
_aglSetDrawableMonitor
    // is one pixel too small to avoid the flickering issue. To tell OpenGL
the
    // proper dimensions, we add one to the resolution here.
    *width ++;
    *height ++;
}

That should take care of it. Note that it's still busted on Voodoo5's -
you'll just get a buffer full of crap. There's no way to work around that as
it's a 3dfx problem.

--
Brad Oliver
bradman@pobox.com