Jump to content
StephenHorn

A collection of retro game programming techniques

Recommended Posts

I want to plug a new Youtube channel called Coding Secrets, done by Jon Burton of the Traveller's Tales videogame studio. He's worked on quite a few games over a career that dates back to the Sega Genesis, and has put together several videos discussing how various effects were created within the very finite and unforgiving limitations of the consoles he was working on.

Coding Secrets started as a series of videos on his original Youtube channel, Gamehut, itself a fascinating collection of videogame history from his career. Anyways, if you're potentially interested in retro games programming and haven't yet discovered his videos, give his channels a shot. Now's a great time, too, because he's re-exporting his Coding Secrets videos in higher-def and a higher framerate, so be sure to check back as he catches up with his back-catalog of content.

Speaking for myself, this is one of my favorite videos from what's brought over to the new channel:

 

  • Like 5

Share this post


Link to post
Share on other sites
Posted (edited)

I had originally planned to leave this topic alone if there wasn't much interest, but now I want to plug just one more video from this channel, because the exact parallax technique Sega used in Sonic the Hedgehog is something that I've discussed a couple of times in the Facebook group, as a viable technique on the VERA. And, in fact, this video shows just how similar the VERA's capabilities are to the Genesis' video processing, right down to the limitation on how many sprites can be drawn on a single line. (However, line IRQs are broken in r37, but the github repo has the fix so you can either grab and compile from there, or wait until r38.)

 

Edited by StephenHorn
  • Like 3
  • Thanks 1

Share this post


Link to post
Share on other sites

Oh, I have seen some of these! They are really fascinating.  My favorite was the one where he talks about mixing four channels of sampled audio on hardware that was only designed to allow one.  Truly genius.  (Alas, all the technical wizardry was done in the service of a rather forgettable piece of music.  Technically impressive regardless!)

 

Share this post


Link to post
Share on other sites
28 minutes ago, John Chow Seymour said:

Oh, I have seen some of these! They are really fascinating.  My favorite was the one where he talks about mixing four channels of sampled audio on hardware that was only designed to allow one.  Truly genius.  (Alas, all the technical wizardry was done in the service of a rather forgettable piece of music.  Technically impressive regardless!)

 

I believe multi-channel samples would be possible on the CX16, using the VERA's PCM channel. However, the VERA uses a 4KiB buffer for sample storage (similar to modern sound cards), instead of direct register-writes that the Genesis' YM2612 uses.

The method from back when the X16 had 2×AY in it used the chips' GPIO pins to drive two 8-bit DAC channels (I'm not quite sure if it was true, but I watched The 8-Bit Guy's video and he showed the AY chips). But the VERA PCM adds popping at AFLOW intervals as the new samples are computed by the CPU.

Perhaps one could work around this by setting a VERA PSG channel to its max frequency ($FFFF) and its waveform to 50% duty square ($3F). The square wave is pitched above our max-frequency cap of 20KHz, so we hear the low and high phases "blend" together to form an amplitude above zero-level. This allows 6-bit logarithmic-scaled PCM to be pushed by manipulating the channel's volume register. There are perhaps other PCM exploits for the YM2151 and SAA1099 (which are in the X16), but I'll not look into them.

  • Like 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

Please review our Terms of Use