| |
Higgie
Registered: Apr 2002 Posts: 127 |
How to deal with multispeed tunes?
hello you coders!
i'm currently doing my first (except for some bullshit from back in the late 80s/early 90s) steps in coding and while checking out some tunes from HVSC as background music i stumbled across some 'multispeed' tunes. some questions came up my mind...
1. am i right saying that multispeed means calling the playroutine multiple times per frame?
2. is it just calling the routine at any time, just calling it often enough in every frame?
3. or does replaying multispeed tunes require a special timing?
4. would loose $d012 polling be sufficient? (no stable interrupt)
i have to admit that i haven't tried out yet and wanted to get the theoretical background before i started off into the (possibly) wrong direction.
thanx in advance! |
|
... 31 posts hidden. Click here to view all posts.... |
| |
SIDWAVE Account closed
Registered: Apr 2002 Posts: 2238 |
Not all CIA timed sids are multispeed. Some simply have a fixed speed, or are 60 hz.
To check if a tune is multispeed, go read the code at the start of the play address. If it is switching values for dc04/dc05, then it is multispeed.
The values for dc04/dc05 are:
1x - $4CC7
2x - $2663
3x - $1997
4x - $1331
5x - $0F5A
6x - $0CCB
8x - $0998
10x - $07AC
12x - $0665
16x - $04CB
So when you want to use a 4x tune with d012, you take 312 rasterlines / 4, and place the jsr to music at even spaced interval. Remember the first call is to the music player, then next 3 calls are to the speed routine.
Players usually have 1003(play) 1006 or 1009 (speedplay).
So
d012=0 jsr 1003
d012+4e jsr 1006
d012+4e+4e jst 1006
d012+4e+4e+4e jsr 1006
Or something like that
|
| |
Stryyker
Registered: Dec 2001 Posts: 468 |
Just use the tune and see if it sounds like it should. You will notice a difference especially if you listen for drum sounds or arpeggios.
It really only matters that the music sounds good for your use. |
| |
Higgie
Registered: Apr 2002 Posts: 127 |
hey jan!
many thanx for your detailed explanation. now there is some hope again for me to use the tune i want with my code. :)
is there always a speed routine involved that i have to call or could it also be repetitive calls of the play routine?
if there is a rule of thumb it would be great to have such info added to the sid files in HVSC. would that be possible?
btw: i'm still open for exclusive tunes! hint!!! ;)
|
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
also not all multispeed tunes are originally played in even spaced intervals :) |
| |
SIDWAVE Account closed
Registered: Apr 2002 Posts: 2238 |
Correct.
Anyhow, wilfred bos looked at that sidtune, and:
It plays at 115Hz while the demo plays it at 100Hz.
sid is now fixed. |
| |
Steppe
Registered: Jan 2002 Posts: 1510 |
For the majority of tunes the timing is not critical, I'd say. I know that GRG and DJB made some very timing dependent tunes, but if it's just a 2x or 4x tune it mostly doesn't matter really.
Also, not every player has a specific speedcall. For example Goattracker uses only $1003 for play. |
| |
SIDWAVE Account closed
Registered: Apr 2002 Posts: 2238 |
Quote: hey jan!
many thanx for your detailed explanation. now there is some hope again for me to use the tune i want with my code. :)
is there always a speed routine involved that i have to call or could it also be repetitive calls of the play routine?
if there is a rule of thumb it would be great to have such info added to the sid files in HVSC. would that be possible?
btw: i'm still open for exclusive tunes! hint!!! ;)
Only tune i know that does repetitive call is rainbow dragon (jsr exxx, jsr exxx, same address) - thats not real multispeed.
In 99.8% cases, there is a speed routine you must call on 2nd and the rest of calls. |
| |
HCL
Registered: Feb 2003 Posts: 728 |
@Rambones: Multispeed is multispeed, no matter where your jsr goes :).
Btw. i also experienced that some multispeed .sid-tunes sound different when i ran them in Vice, so i believe there is some difference to sidplay anyways. ..and yes, i know how to play a multispeed tune in Vice :). |
| |
Dane
Registered: May 2002 Posts: 423 |
And some multispeed tunes do not even have a second JSR for playback. Instead some idiot came up with the idea to just transfer zeropage values into D400. Totally lame. |
| |
assiduous Account closed
Registered: Jun 2007 Posts: 343 |
HCL: the Resid tab in Sid settings in Vice will tell you what sampling method is in use. if its set to fast there`s no difference to Sidplay2. using cycle based sampling (interpolation or higher) makes some difference to sound reproduction quality but you wont get any new sounds as in Higgie's example;) |
Previous - 1 | 2 | 3 | 4 | 5 - Next |