News for hackers. Stuff that matters.
Re:Butano: Modern C++ high level GameBoy Advance engine by aliswe on Saturday November 14, 2020 @01:42PM (#25094480)
I remember trying to make a C compiler for SNES almost 15 years ago. The expert on the SNES architecure who I was working with was 14 years old.
Re:Butano: Modern C++ high level GameBoy Advance engine by wk_end on Saturday November 14, 2020 @03:25PM (#25095337)
I'm sure you're just throwing in a personal anecdote of interest and already know this, but for readers unfamiliar with these pieces of hardware:

The SNES (early 90s) and the GBA (early 2000s), despite roughly similar graphical capabilities, are vastly different machines. The SNES uses a 65816-based architecture running at ~3MHz that's extremely hard to compile C down to while still getting acceptable performance/code size - almost all games for it were coded in assembly language.

By comparison, the GBA uses an ARM7-based architecture running at ~33MHz. GCC was available for it literally before it came out. Even though I'd experimented a bit with QBASIC when I was younger, plugging away on the GBA when I was around 14 was how I learned C, how computers really work at a low-level, and roughly speaking, how to "really" code.

So this isn't a GBA C++ compiler - that's existed for ages. This is a "just" game engine. It's super cool that people are still working on stuff like this - the GBA is a very fun platform to develop a game on, at a nice sweet spot between straightforward enough to get started on, powerful enough to make something cool, not so powerful that you need a team of dozens to make something impressive (for the platform).

Re:Butano: Modern C++ high level GameBoy Advance engine by jsmolka on Saturday November 14, 2020 @03:54PM (#25095531)
The GBAs ARM7TDMI runs at ~16MHz.
Re:Butano: Modern C++ high level GameBoy Advance engine by wk_end on Saturday November 14, 2020 @05:35PM (#25096305)
Ah, my bad. I misremembered. Was probably muddling it with either the DS, as the other commenter mentioned, or the MIPS CPU in the Playstation.
Re:Butano: Modern C++ high level GameBoy Advance engine by saagarjha on Saturday November 14, 2020 @04:34PM (#25095849)
(The Nintendo DS featured a 33 MHz ARM7TDMI.)
Re:Butano: Modern C++ high level GameBoy Advance engine by MaxBarraclough on Saturday November 14, 2020 @06:02PM (#25096511)
Any idea what became of them?
Re:Butano: Modern C++ high level GameBoy Advance engine by aliswe on Tuesday November 17, 2020 @06:41PM (#25131385)
Sorry, was confused by "them". Yeah, he is basically the creatpr of all the big programming tutorials on snes programming. But to be such a giant he was mighty uninterested. He wanted to get into making music instead.
Re:Butano: Modern C++ high level GameBoy Advance engine by BearOso on Saturday November 14, 2020 @09:17PM (#25097606)
snesc by lordtech?
Re:Butano: Modern C++ high level GameBoy Advance engine by bArray on Saturday November 14, 2020 @10:17PM (#25097917)
Worth also mentioning smaller game engines for devices like the GameBoy (Color): https://github.com/Zal0/ZGB
Re:Butano: Modern C++ high level GameBoy Advance engine by klavinski on Sunday November 15, 2020 @03:21AM (#25099301)
There are also higher-level tools to create GameBoy games, such as GB Studio: https://www.gbstudio.dev/
Re:Butano: Modern C++ high level GameBoy Advance engine by ArtWomb on Saturday November 14, 2020 @05:10PM (#25096126)
Beautiful! Is sprite rendering the only way to draw pixels to the screen? And is the Audio API of real time synth?
Re:Butano: Modern C++ high level GameBoy Advance engine by deaddodo on Sunday November 15, 2020 @01:47AM (#25098895)
No, you can directly rasterize to the screen buffer:

https://www.coranac.com/tonc/text/bitmaps.htm

However, you’re limited to the CPU’s (relatively) mediocre processing power. This is exactly how some of the raycasted game engines were built, though:

https://m.youtube.com/watch?v=eD1RRESSF6Y

And, if you look at open source raycaster engines, they’ll use either Mode 3 or Mode 4, usually with a background enabled:

https://github.com/jduranmaster/GBA-caster/blob/dd62073a4371...

Re:Butano: Modern C++ high level GameBoy Advance engine by lostgame on Saturday November 14, 2020 @05:14PM (#25096159)
Looks like it supports raster effects, but from what I'm seeing this engine does not e.g. support writing directly to the framebuffer.
Re:Butano: Modern C++ high level GameBoy Advance engine by msk-lywenn on Saturday November 14, 2020 @06:15PM (#25096587)
There is no framebuffer on the GBA, just sprites and tiled backgrounds. Although if it's like on the DS, I don't recall exactly, you can setup a background in such a way that it emulates a framebuffer. Handy for software 3D.
Re:Butano: Modern C++ high level GameBoy Advance engine by bluedino on Saturday November 14, 2020 @07:59PM (#25097098)
There are bitmap modes on the Advance:

https://www.coranac.com/tonc/text/bitmaps.htm

Re:Butano: Modern C++ high level GameBoy Advance engine by harrygeez on Saturday November 14, 2020 @11:53PM (#25098361)
I'm a little confused. So is this better than an emulator?
Re:Butano: Modern C++ high level GameBoy Advance engine by soneil on Sunday November 15, 2020 @12:02AM (#25098395)
Game engine, not emulator. It's for creating games that run on the GBA (.. or on a GBA emulator)