You are not logged in.
Hi.
I'm using the draw tiles function to draw a map over the entire screen. Doing this I noticed some graphic glitches on the screen. Vertically the glitch starts at the center of the TV and continues approx 60 pixels to the right. Horizontal it starts from center and goes down approx 40 pixels. I've taken a screen shot from the memory and uploaded the picture here:
.. any clues why this happens? Have I done something wrong when generationg the tile.png file? I used the GRRLIB.exe tool found on wiibrew.org.
Offline
Try to recheck your code, this kind of stuff should not be...
btw : do you use the cvs version of libogc ?? old version have "voodo bugs" when using GX functions...
Offline
It's hard to believe that is my code, since it is just two for loops that draws the tiles. If something was wrong with the code, I guess I would see the glitch on all tiles, but I'll take an extra look at it again just to be on the safe side.
I have no idea which version I use, think it was installed when I installed devkitPro. I'll try to update libogc and see what happens..
-Update:
I have the lastest version of devkitPro (1.4.7) so I guess I also have the lastest version of libogc.
Last edited by spiffen (2008-11-18 10:12:50)
Offline
To use the latest version you need to take it from devkitPro CVS or hackmii GIT.
Just used those two commands in your CVS app:
cvs -d:pserver:anonymous@devkitpro.cvs.sourceforge.net:/cvsroot/devkitpro login
cvs -z3 -d:pserver:anonymous@devkitpro.cvs.sourceforge.net:/cvsroot/devkitpro co -P libogc
When prompted for a password for anonymous, simply press the Enter key.
libogc with GIT could be downloaded at git://hackmii.com/home/ogcgit/libogc with a tool like msysgit under Windows.
Good luck!
Offline
Hi.
I've managed to get the source now, but I have no idea how to build it. Anyone know how? Or where I might find a "guide" for this?
/E
Offline
If you are under Windows, just type make in a command prompt in the libogc folder, the Makefile will do the rest
Last edited by Crayon (2008-11-18 21:18:58)
Offline
Ahh it was that easy. Compiled it successfully and replace lib and include files in devkitPro, but the problem still remains.
If I minimize the code I'm using for drawing the tiles to a bare minimum, are you intrested in trying to find out why this happens? Could it have to do with my console settings? PAL and 480p on component out?
Offline
I found the problem. The problem was not in GRRLIB but in libogc. Had to use a "correction" value when calculating the s1, s2, t1, t2 parameters in function GRRLIB_DrawTile(). It's not the best solution, but it works well.
I replaced
f32 s1= frame/maxframe; f32 s2= (frame+1)/maxframe; f32 t1=0; f32 t2=1;
with
f32 FRAME_CORR = 0.001f; f32 s1= (frame/maxframe)+(FRAME_CORR/(width*maxframe)); f32 s2= ((frame+1)/maxframe)-(FRAME_CORR/(width*maxframe)); f32 t1= 0+(FRAME_CORR/height); f32 t2= 1-(FRAME_CORR/height);
Offline
post shagkur your fix, he will find a way to correct libogc soon
Offline