[Coco] Help with speeding up sprite rendering

Arthur Flexser flexser at fiu.edu
Fri Mar 17 02:21:56 EDT 2017


You're undoing the effect of your ANDCC #$00 instruction as soon as you
pull a new CC value off the stack.  I think you'd need to disable IRQ and
FIRQ at their sources--in the PIAs and (on the CoCo 3) in the GIME
registers, so that no servicing is performed even if the CC has interrupts
enabled.

Art

On Fri, Mar 17, 2017 at 2:03 AM, Glen Hewlett <glen.hewlett at sympatico.ca>
wrote:

> Hi All,
>
> I’m working on some routines to draw sprites on the screen faster and I
> have a lot of it working fine.
> If I use PULS and PSHU commands I can really improve the speed of my
> sprite rendering.
>
> For example instead of using a bunch of
> LDD             ,X++
> STD             ,U++
> ...
> I’m using
> PULS    A,B,X,Y,DP
> PSHU    A,B,X,Y,DP
>>
> That’s all great for sprites that are 7 bytes wide, but I also need to
> move sprites that are 8 bytes wide.  I’ve read on the net about using the
> condition code (CC) in the same way I described above but it breaks my
> program.  I couldn’t find some example code, just some talk about doing it.
>
> I’ve tried:
> ANDCC   #$00
> PULS    A,B,X,Y,DP,CC
> PSHU    A,B,X,Y,DP,CC
>> ANDCC   #$EF    - re-enable the IRQ
>
> I’m not sure what this is doing, as the computer is still running and the
> IRQ is triggering but it’s not generating the sprites when I do this.  In
> fact the computer seems to be stuck in the IRQ loop.
>
> Normally my program is moving the sprites around while in the IRQ routine,
> is this the part of the problem when using the CC register?  Or am I just
> handling the CC register improperly?
>
> If anyone has some sample code or can offer some advice I sure would
> appreciate it.
>
> Cheers,
> Glen.
>
> --
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco
>


More information about the Coco mailing list