Subject: Re: [stella] Confused newbie...|
From: Christopher Tumber <christophertumber@xxxxxxxxxx>
Date: Fri, 08 Oct 2004 23:16:29 -0400
>Finally I understand what they do! So I'd do horizontal positioning in >the VBlank or Overscan and skipDraw in the actual kernel? Bingo! In some cases you'll be doing sprite positioning while the screen is being drawn, but for the simplest of cases you're just as well to do it during vblank/overscan to keep things simple. For example, lets say you use sprites to draw the score, ships left, etc at the top of the screen. You then want to re-use those sprites in the game screen. So you position the sprites in the vblank into the places you need them to draw the score. You later reposition the sprites after drawing the score/lives left scanlines and before you get to the actual game scanlines. Or, if you want to re-use sprites throughout the game screen in order to give you more objects on screen at once. >So skipDraw needs to be on every scanline, basically? Yes. You don't HAVE to use skipDraw, you could use something simpler and maybe easier to understand (some more straightforeward compares maybe). However, since you only have 76 cycles per scanline and you often want to be changing other registers during a scanline (ie: the playfield, various colour registers) eventually you're going to want to do this as efficiently as possible. And skipDraw is the best there is so far... Chris...