gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

Coding > the circle effect

#82842 - ProblemBaby - Wed May 10, 2006 6:56 pm

Hello

I want to know how the effect in super mario world when you finished a level is done, you know like a window but it is a circle, hope you understand what I mean, it doesnt use a rot/scale bg, its smooth all the time, but how is it done, I cant see something in the hardware that can do it, any ideas how I can achive the effect?

thanks

#82845 - Ultima2876 - Wed May 10, 2006 7:16 pm

Use windowing a HDMA.

Basiclaly, you use HDMA to set the windowing extents on each scanline, with values for a circle calculated in the last Vblank.

At least that's how I would do it :P

#82850 - ProblemBaby - Wed May 10, 2006 8:01 pm

Oh how stupid Iam, thanks

#82882 - tepples - Thu May 11, 2006 12:41 am

I wonder if Nintendo got permission from Lucasfilm to use a sped-up version of the THX theme for that effect.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.

#84937 - nrx - Thu May 25, 2006 10:35 pm

If you want an example, you can have a look to the source code of GOD: I implemented such a "circle effect" long ago; it is used when you quit the game (i.e. when leaving the maze to go back to the title screen).

The source code is still available here; what you're looking for is inside "World.c" (functions named "WorldCircleInterrupt" and "WorldClose").