Allegro.cc - Online Community

Allegro.cc Forums » Allegro Development » Some test program modifications

This thread is locked; no one can reply to it. rss feed Print
Some test program modifications
Ron Novy
Member #6,982
March 2006
avatar

Sorry. These patches won't work seperate because of the timing patch. I'm still getting used to one change (one diff) at a time. It's kind of big too which is why Id rather post it here. I attached the dif to this thread that combines the three changes to test.c listed here.

This first part of the patch changes the sprite used in the rotate sprite test. It uses a sprite with an odd width and height so that the rotation doesn't appear to wobble. Not really an error just a simple cosmetic thing. Note that this patch could easily be edited out of the dif.

The second part of the patch changes the method used to display the timing information by allowing it to update once every second instead of just getting stuck with the first results.

The third part changes the blit to self test. The old blit to self test didn't allow for a full visual test so I changed it to a colored rectangle that now bounces around the screen a few times (you can skip it at any moment with the mouse or keyboard). You now also have the option to switch to and from a 'frame mode' (with the 'f' key) where any key press will advance to the next frame in the test. It allows you to do a more detailed analysis of the blit and has already revealed an error in the FreeBE/AF mach64 driver where the top line doesn't blit in some cases. I don't know if anyone is still updating the FreeBE/AF code or if anyone even still uses it, but my experience is that it will not compile on newer versions of DJGPP. I was once able to get it to compile but when using one of the newly compiled drivers it simply crashes. Any way, just try the patch and see it for yourself.

----
Oh... Bieber! I thought everyone was chanting Beaver... Now it doesn't make any sense at all. :-/

Milan Mimica
Member #3,877
September 2003
avatar

The patch fails to apply to the latest SVN version, sorry.

Ron Novy
Member #6,982
March 2006
avatar

Doh!

[EDIT]

Here is an updated version. I updated the patch using the most recent SVN so it should work if you would like to try again. [Edit] sorry here it is.

[EDIT]
Not to annoy anyone here but I was wondering if anyone has checked out this patch.
It's not really a big deal but some of it might be interesting to look at. Or should I send it to the ML? Oh! I also had a question about the 'realscreen' pointer. Should it be locked since its accessed inside the timer callback? or is it locked already? any way I added a LOCK_VARIABLE(realscreen) just in case at the bottom of the patch

----
Oh... Bieber! I thought everyone was chanting Beaver... Now it doesn't make any sense at all. :-/

Milan Mimica
Member #3,877
September 2003
avatar

Everything looks fine to me.
Trying hard but can't really notice any difference in the rotate sprite test.
I added two rest calls: one inside blit_pause_proc() while waiting for next frame and one in blit_proc() while waiting for the test to start. Attached the updated version.

I'm not sure about applying the patch though. The SVN is in a kind a feature freeze stage, waiting for 4.2.1 to come out. Personally, I'd apply it. Timing information display now looks decent.

About FreeBE/AF, I have no idea. Drivers that nobody is willing to maintain will probably be removed in 4.3. I doubt anyone can confirm this bug you are seeing.

Ron Novy
Member #6,982
March 2006
avatar

Cool. Thanks. The rotate sprite test was only occasionally off by 1 while rotating so it probably isn't that noticeable either way. The blit to self test might help in some cases as well, but as for the FreeBE/AF driver... I'm not really worried as I'll soon be upgrading my PC so I can use OpenGL just like everybody else.

----
Oh... Bieber! I thought everyone was chanting Beaver... Now it doesn't make any sense at all. :-/

Milan Mimica
Member #3,877
September 2003
avatar

The patch has been committed to the SVN.

Ron Novy
Member #6,982
March 2006
avatar

Sweat... Thanks

----
Oh... Bieber! I thought everyone was chanting Beaver... Now it doesn't make any sense at all. :-/

Go to: