In this special 125th subscriber episode we're briefly explore how to draw an asymmetrical playfield on an ATARI 2600, with code example provided in our GITHUB. Thanks everyone for your continued support!
Released:
September 13, 2021
Original Link:
https://youtube.com/watch/3SIfWrnCjpQ
Your support is greatly appreciated! https://www.patreon.com/8blit
Welcome everyone to a special episode for this channel. This one is all about acknowledging small milestones and celebrating reaching our 125th Subscriber to the channel! I know that in the grand ecosystem of youtube, that 125 subscribers doesn’t even put me on the map, but to me it’s a sign that I’m on the right track… producing quality educational content for like minded people.
When I first decided to go ahead and create this channel, dedicated to programming for a video game console that’s over 40 years old, I never expected to reach 50 subscribers. I really didn’t even know if there WERE that many people in the world that would be interested in this topic. But here we are… a few videos later, at 125 subscribers.
Thanks for being here, and thanks so much for your support.
In honor of this modest milestone in the history of 8blit, I whipped up a small example demonstrating one way to draw an asymmetrical playfield. If you have been following along with our videos you should already be familiar with the oddity of the playfield. But for those of you who are new, let’s have a quick recap, and I’ll put a link to our previous video covering the playfield in the description below.
The playfield is made up of only 40 pixels… spread across three 8 bit graphics registers. FP0, PF1, and PF2. PF1 and PF2 use all 8 bits, while FP0 only uses 4 high bits. Each bit in these registers represents a single pixel. Obviously, this doesn’t add up to 40 bits. 8 + 8 + 4 is only 20. That’s because these registers only represent half of the screen. The other half is just a copy of the first, either orientated the same way, or reflected. Most games will utilize a reflected playfield because it’s the most versatile.
Normally, you would set the playfield registers at the start of your scanline, while still in horizontal blanking, and then use the rest of your machine cycle for other game logic.
But what if you didn’t want the same pixels on both sides of the screen, what if you wanted an asymmetrical playfield? The good news is that it’s entirely possible,… the bad news is that while you can be a little more creative with your playfield, it does come at the expense of using up the majority of your available machine cycles on each scan line.
The idea is to draw the first half of the screen, and then change the registers before the second half of the screen starts to be drawn…. but that’s easier said than done. The way it works… is you first set the pixels in the three playfield registers at the beginning of horizontal blanking, right after your WSYNC. This can use about 15 machine cycles to load the and store the pixels for each of the registers. That’s most of the almost 23 machine cycles you have before the TIA starts drawing the PF0 register, which itself takes just over 5 machine cycles for the TIA to draw right after horizontal blank. So now we’re at 28 machine cycles, which is the earliest you can update PF0, which again will take 3 more cycles… but you can’t yet update PF1 until cycle 39 and then you….
-record scratch-
This is all a bit too deep to get into for a special episode, but I promise we’ll go more in-depth in a future video. However, the source code for this episode’s example demonstrating one method to achieve an asymmetrical playfield is available right now in our github which is linked below.
Thanks for being here for the channel’s early days, I hope you continue to find the videos educational… and I hope that if you’re interested to learn more about programming for the ATARI VCS, that this channel inspires you to do so.
In our next episode we’ll continue to explore the player, missile, and ball graphics, their modifier registers, as well as adding a bit of colour to our graphics..
Please help get the word out by liking and sharing the videos… and if you’re new to the channel, or have not yet done so, please consider subscribing and remember to click the little bell icon so you’re notified when new episodes are available.
Thanks for watching, and I’ll catch you next time.
Back to top of page