English Amiga Board

English Amiga Board (http://eab.abime.net/index.php)
-   Coders. Asm / Hardware (http://eab.abime.net/forumdisplay.php?f=112)
-   -   Restore system sprite (http://eab.abime.net/showthread.php?t=82130)

phx 03 April 2016 11:34

Quote:

Originally Posted by Photon (Post 1081537)
Any sprite DMA should be changed only when bitplanes have been off until end of line, such as after $12c for a normal display window or at vblank/"EOF". Then there's no need for null sprites.

Really? I didn't know that. You're saying that when I switch off sprite DMA at an hpos after $12c the sprite will be automatically disarmed and forgets its last data in SPRxDAT? What does it have to do with bitplane DMA?

Quote:

I've stopped caring about the floppy drive light :) It's not that big a deal. Look at the screen instead cos something awesome just loaded!! :)
Sure. :)
But the motor is running, producing this scratching noise which tortures your floppy disks... ;)

Photon 03 April 2016 19:06

Just less offended today, that's all. :) And hopefully floppy drives are manufactured to not harm disks by turning on the motor, else we have a slight design flaw ;)

The key to avoid the infamous running crap sprites is to do the one-off pointer writes (change pointer, not DMA as I incorrectly wrote above!) when sprite DMA is not running.

How do you know it's not running? A simple way is to only change sprite pointers during vertical blanking of the screen. If you change them while bitplanes, coppers, and interrupts are running, you will not be 100% sure it won't cause crap. If you WaitTOF(), you are usually somewhere below line $0, but if you move the mouse as WaitTOF() executes, you could be well down on the screen, perhaps in the middle of the mouse pointer sprite. Likewise, the OS screen could be overscan, so that waiting for line $12c is not low enough. Turning off interrupts and waiting for $138 is the lowest you can go without wasting a whole extra frame before your program starts.

If bitplanes are off, sprite DMA will also be turned off. Some latch. From memory this happens just before DIWSTOP(?), I'm sure Toni can give the details of the behavior.

phx 03 April 2016 21:30

Quote:

Originally Posted by Photon (Post 1081821)
The key to avoid the infamous running crap sprites is to do the one-off pointer writes (change pointer, not DMA as I incorrectly wrote above!) when sprite DMA is not running.

Ahh, yes, that's correct of course. :)

jarre 30 October 2017 17:27

i have a mouse pointer onscreen, when the program starts it's gone, till i exit then it is back, what in the program can cause this.....which adress is responsible for visability of the mouse pointer..??? what to move in and out to disable / enable the mousepointer???

StingRay 30 October 2017 17:59

You need to enable sprite DMA.

jarre 30 October 2017 19:22

Quote:

Originally Posted by StingRay (Post 1195771)
You need to enable sprite DMA.

Example please....adress and what ro put in..?

Photon 01 November 2017 21:45

move.w #$8020,DMACON

But you must set it while sprite DMA is off (raster wait until offscreen, or put in vertical blank interrupt) or else risk rolling sprites. :)

A better way is to add an instruction at the top of your copper list, this ensures that the DMA channel state is changed at the correct time.

dc.w $96,$8020

jarre 01 November 2017 23:06

thanks, go look at it..


All times are GMT +2. The time now is 00:40.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.

Page generated in 0.04292 seconds with 11 queries