A.D.A. Amiga Demoscene Archive

        Welcome guest!

  

  

  

log in with SceneID

  

Demos Amiga Demoscene Archive Forum / Coding / The Player - how to get it play packed samples?

 

Author Message
Corial
Member
#1 - Posted: 19 Oct 2011 11:46
Reply Quote
Hi

I am in urgent need of help regarding The Player. I need to have i play packed samples, but for some reason, when I exit my intro the screen turns black. This does not happen when playing "normal".

In my main function I specify:

ifd music
lea p61_module,a0
lea $dff000,a6
sub.l a1,a1
moveq #0,d0
bsr.w p61_motuuli+p61_initoffset
endc


When I then exit the intro, I specify

ifd music
bra.w p61_motuuli+p61_endoffset


Anybody with any experence? I have not changed any settings. I have just converted my .mod with Delta and Pack Samples set, and then I want to replay it. The music starts and stops fine, but leaves me with a black screen. And this only occurs when playing with the above settings. Modules that are not converted with Pack Samples work fine, and everything exits correctly.
Corial
Member
#2 - Posted: 19 Oct 2011 11:48
Reply Quote
Fuck missed something:


ifd music
bra.w p61_motuuli+p61_endoffset
else
rts
endc
Corial
Member
#3 - Posted: 19 Oct 2011 12:27
Reply Quote
The version is use seems to be 610.6. That is at least the version listed for the .asm file in the Source folder
ZEROblue
Member
#4 - Posted: 19 Oct 2011 18:36
Reply Quote
You just need to point A2 to the buffer to decompress the samples into before you call P61_Init.
Corial
Member
#5 - Posted: 19 Oct 2011 20:42
Reply Quote
Thanks for the hint.I will try it tomorrow morning.Could you also give me a clue regarding the buffersize?Forgive my lameness,but I don't have knowledge regarding such music stuff.
Corial
Member
#6 - Posted: 20 Oct 2011 09:19
Reply Quote
Ok, tried it and things are working with packed samples now! Thanks for leading me in the right direction, ZeroBlue! I still need to figure out a way to determine the size of the samplebuffer. I have set it very high now, but it should be possible to calculate it somehow. I had to use some trial and error. Buffersize too small = blinking yellow box in Asmone :-)

I only have 1 sample, which clicks a little bit, but I'll just try to skip it. But it seems that I can find the 9k's which I am missing currently.

You need to put your samplebuffer in a bss_c area like:

section soundbuffer, bss_c
buffer:ds.b somesuitablesize


And to use the player with packed samples, type:

lea p61_module,a0
lea buffer,a2
lea $dff000,a6
sub.l a1,a1
moveq #0,d0
bsr.w p61_motuuli+p61_initoffset
Corial
Member
#7 - Posted: 20 Oct 2011 09:33
Reply Quote
Ah, Blueberry had some simple solutions to determining the buffersize.
dalton
Member
#8 - Posted: 20 Oct 2011 12:57
Reply Quote
doesn't p61con write that kind of info (along with usecode) in the file comment?

 

  Please log in to comment

  

  

  

 

A.D.A. Amiga Demoscene Archive, Version 3.0