Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.acorn.programmer > #5908
| From | Andrew Conroy <a.m.conroy@owlart.co.uk> |
|---|---|
| Subject | PlayIt loop problem |
| Newsgroups | comp.sys.acorn.programmer |
| Date | 2019-11-29 22:53 +0000 |
| Message-ID | <581abc755fa.m.conroy@owlart.co.uk> (permalink) |
| Organization | Owl-Art Un-Ltd. |
I have PlayIt v1.73 and I'm trying to get it to play a sound sample in a
loop, so it plays the sample twice. The code I have is:
DIM playitblock% 23
SYS "PlayIt_LoadDriver", "PlayIt:SSound"
SYS "PlayIt_Open", "Sample"
SYS "PlayIt_FileInfo", 0, 0, playitblock%
length% = playitblock%!20
SYS "PlayIt_SetLoop", 1, length%, 2
SYS "PlayIt_Play"
but for some reason I don't understand it always plays one more loop than
the value for R2 in PlayIt_SetLoop, unless the value in R2 is 1, when it
does only play the sample once (as per the manual). In the code above,
where I have R2 set to 2, it plays the sample three times.
Does anyone have any experience of using PlayIt and can see what I'm
doing wrong? This seems to happen on RISC OS 3.7, 4.02 and 5.24 that I've
tried so far.
Thanks,
Andrew
--
+----------------------------------------+---------------------------------+
| Andrew Conroy, Owl-Art Un-Ltd. | email: a.m.conroy@argonet.co.uk |
| Coming to you on an Acorn RiscPC SA110 | |
+----------------------------------------+---------------------------------+
The impossible I can do at once, miracles take a little longer!!
Back to comp.sys.acorn.programmer | Previous | Next | Find similar | Unroll thread
PlayIt loop problem Andrew Conroy <a.m.conroy@owlart.co.uk> - 2019-11-29 22:53 +0000
csiph-web