Amiga.org

Operating System Specific Discussions => Amiga OS => Amiga OS -- Development => Topic started by: bbond007 on March 24, 2012, 02:33:10 AM

Title: Sprites and vSprites priority over background?
Post by: bbond007 on March 24, 2012, 02:33:10 AM
I just started messing with vSprites and i can't seem to find any way to set the priority over the background so that the sprites only appear behind bitmap data. I know there was a way to do it on the C= 64 but maybe this is a hardware limitation on the Amiga. I can't figure out how to do it on regular sprites either. Maybe i'm just not searching using the right terminology...

I was going to make a starfield(how original, i know) but its going to be awfully strange to have the stars appear over objects...

thanks for the help.

nate
Title: Re: Sprites and vSprites priority over background?
Post by: Lando on March 24, 2012, 02:39:02 AM
I do not know what are vSprites but you can set priority of the Amiga's hardware sprites using bits 0-5 of BPLCON2 ($DFF104), as shown in this document

http://amigadev.elowar.com/read/ADCD_2.1/Hardware_Manual_guide/node0159.html
Title: Re: Sprites and vSprites priority over background?
Post by: bbond007 on March 24, 2012, 03:26:42 AM
Quote from: Lando;685019
I do not know what are vSprites but you can set priority of the Amiga's hardware sprites using bits 0-5 of BPLCON2 ($DFF104), as shown in this document

http://amigadev.elowar.com/read/ADCD_2.1/Hardware_Manual_guide/node0159.html


Yes, i think thats what i'm looking for. I'll see is there is a OS friendly way to set that but it gets me on the right track.

vSprites are just the normal hardware sprites just the OS will masquerade them around using the copper for you so you can have more than 8.

thanks!
Title: Re: Sprites and vSprites priority over background?
Post by: bbond007 on March 25, 2012, 05:35:02 AM
Quote from: Lando;685019
I do not know what are vSprites but you can set priority of the Amiga's hardware sprites using bits 0-5 of BPLCON2 ($DFF104), as shown in this document

http://amigadev.elowar.com/read/ADCD_2.1/Hardware_Manual_guide/node0159.html


yes that did the trick....

I ended up needing to use a copper list to set it.
Title: Re: Sprites and vSprites priority over background?
Post by: SamuraiCrow on March 27, 2012, 08:10:43 AM
Quote from: bbond007;685023
vSprites are just the normal hardware sprites just the OS will masquerade them around using the copper for you so you can have more than 8.


Actually, the copper is not used for making more sprites.  The sprite DMA itself does the job.
Title: Re: Sprites and vSprites priority over background?
Post by: bbond007 on March 27, 2012, 03:29:09 PM
Quote from: SamuraiCrow;685590
Actually, the copper is not used for making more sprites.  The sprite DMA itself does the job.


Yes, I discovered i did not need to use the copper, after i actually got it to work :)