Code: Select all
263 corners[3].x = i+255;
(gdb) print surf
$26 = (SDL_Surface *) 0x8a6b860
(gdb) until
264 for(j = dst->y; j <= dst->y+dst->h; j += 256) {
(gdb) print surf
$27 = (SDL_Surface *) 0x50d080c
(gdb) print &surf
$28 = (SDL_Surface **) 0x9f3fdb8
(gdb) print corners
$29 = {{u = 0, v = 0, x = 0, y = 35666192, z = 5.32682648e-38}, {u = 0,
v = 0, x = -nan(0x7fffff), y = 0, z = -nan(0x7fffff)}, {u = 0, v = 0,
x = 0, y = 0, z = 0}, {u = 255, v = 0, x = 255, y = 6.50189876e-33,
z = 1.62241341e-36}}
(gdb) print &corners
$30 = (vertexel16 (*)[4]) 0x9f3fd78
(gdb) print &corners[3]
$31 = (vertexel16 *) 0x9f3fda8
(gdb) print &corners[3].x
$32 = (float *) 0x9f3fdac
Also, corners is supposed to be:
{{u = 0, v = 0, x = 0.0f, y = 0.0f, z = 0.0f}, {u = 0, v = 255, x = 0.0f, y= 255.0f, z = 0.0f}, {u = 255, v = 255, x = 255.0f, y = 255.0f, z = 0.0f}, {u = 0, v = 255, x = 0.0f, y = 255.0f, z = 0.0f}}, which, as you can see, is completely changed. Is this some bug in PSPLink that's corrupting the stack? Or something else entirely?