Language…
10 users online: ageVerrly,  Anorakun, Dominicentek, DoodleMyNoodle, Faro, GrenCarret, Hwailaluta, monkey03297, playagmes169, Zavok - Guests: 70 - Bots: 293
Users: 55,706 (2,321 active)
Latest user: Princesspeach89

AddmusicK questions - pitch bend, proper ending, and channel modulation

Link Thread Closed
Hi all. I'm a new member here.I sort of have an obsession with cheesy sampled sound, so for me, the SPC700 and admusicK are fun to have just to try to make music with. I'm nowhere ready for finishing music ports, but I am working on it. As I played around, I've observed some things which aren't really related, but I thought I'd put them all down in one post for people to comment on and help me work with if they are able.
First, I'm using AddMusicK 1.0.4 and the Winamp Alpha SPC input plug-in 3.3.4. I really should make sure those are up to date, but I downloaded them within the last 6 months.
First thing I am going to ask about is so-called proper endings. When making a track with AddmusicK that does not loop, some silence seems to be added to the end of an SPC, even with one channel with a constant stream of notes. Even the default SMW ported tracks seem to do this. I've not seen mention of this often, so don't know quite what to do about it. Trying the tags in the txt file to restrict the length only do so much, as it just tells the player how long to play the song for, regardless if there is anything after the specified length. The silence at the end is faded out, not removed from the data. There is also about a half second of silence at the beginning of files. However, in SPC rips, there are no such silences anywhere, not even in the SMW SPC set.
Is this silence at the ends of the track something which I can get rid of? I wouldn't try to get rid of it if I was doing an SMW port, but some people use AddmusicK just to make SPC covers and don't care about how SMW will handle the data. I've been thinking of trying projects like that, and for this purpose I would prefer to do anything I can to optimize it.
Second point: pitch bending and legato. From my understanding, if I want to do fancy slides and slurs, I would have to use the pitch bending commands (& or $dd) to bend between notes, along with the legato toggle command ($f4 $01) so that notes won't be rekeyed. If I want to rekey a note, for example in between measures just to introduce some variety into the articulation, I would first have to turn legato off in the middle of the last note to disable it properly. So a simple penta scale might look like this.
Without legato:
l8 c d e f g f e d c4.
With legato and some articulation:
l8 $f4 $01 c d e f16 $f4 $01 ^16 $f4 $01 g f e d16 $f4 $01 ^16 c4.
It sounds like a lot of work to rekey one note. If that's just how it is, I'm not complaining, just making sure I'm not missing something.
Also, in regards to pitch bend, I haven't yet figured out a way to pitch bend in between notes, for exampel in guitars. The closest you can get is to slowly slide between notes. Is this correct?
Last question, for now anyway. I know it's not popular, but pitch modulation among channels seems to be supported, and while it often sounds gritty and or unpleasant, I've heard it used in ways which intrigue me, for example in Waterworld. I am unable to find much info on it though. I assume one channel would contain a source sound and the other would contain the waveform that would modulate the source's pitch. At present I imagine this as crude FM synthesis or something with a modulator and carrier. I'd like to experiment with it, but don't know anything about details of its operation, and am only guessing. All the AddMusicK readme says is that when using this command, the hex parameters specify which channels to enable pitch modulation on, bitwise (7654321-). Channel 0 cannot have pitch modulation. I'm not nearly as inclined in the techy side of this as I'd like to be, and so am not sure what is meant by bitwise. Does it literally mean numbers like 1, 2, 3, and so on for the 7 channels? What would be a typical setup for this effect?
Thanks for reading and helping out! No need to respond to everything at once, I just wanted to put everything together in one post. Have a great day!
Make more of less, that way you won't make less of more!
Firstly, I recommend you download SPC700 player which loads faster and has more info/settings than winamp/SNESAMP.

Seondly, about bitwise.
Bitwise is a T/F system where one bit represents each channel, so if you want to modulate, say channel 3 and 6 it needs to be like:

channel #
bits

7654321-
01001000

And then you neeed to convert that to hex, so it's $48.

Pitch bending. That is the point of the pitch bending command: to smoothly connect 2 notes. I don't see what else you want, maybe you could shorten the duration. The other 2 bending commands are $EB $XX $YY $ZZ and $EC $XX $YY $ZZ, which let you bend to and from notes respectively. This is all I know about pitch bending.

About the silence at the end/beginning of songs. I have three theories.

a) loading time. I remember AM4 needing something like an r8 length of silence at the beginning of your songs, so the game might just be loading the samples.
b) ADSR/GAIN. I don't remer where, but there was a discussion about whether it's better to use $ED $7F $E0 ADSR or $7F GAIN; which of them play more instly. So I guess it might also be sample playment settings.
c) THere isn't any. I seriously can't find any silence at either the beginning or the loop point of vanilla or custom sampled music. Or even that most basic penta scale. At least not the half second you were talking about. I listened both in game (ZMZ) and at 33% with SPC700. Or if there is it's probably only a few ms and I'm not that much into music to hear/care about it.

also
Originally posted by musicalman
some people use AddmusicK just to make SPC covers and don't care about how SMW will handle the data.

AFAIK AMK won't compile your song if it doesn't work in game. Unless you make an infinite loop with commands or something.Or screw up converting old sampled music. but I haven't heard of many other cases.

Apologies for any grammatical/spelling errors made, I'm a bit tired while writing this.
Sorry for bumping the thread, I was away for a while and recently started getting back into AddmusicK.

Originally posted by Mirrordrill

Firstly, I recommend you download SPC700 player which loads faster and has more info/settings than winamp/SNESAMP.

I do use that sometimes, it does sound a little warmer to my ears. I haven't checked the URL you provided, mine has Japanese setting names. I'll have to see if the one you linked to is any different.

Quote
Secondly, about bitwise.
Bitwise is a T/F system where one bit represents each channel, so if you want to modulate, say channel 3 and 6 it needs to be like:

channel #
bits

7654321-
01001000

And then you need to convert that to hex, so it's $48.

Thanks for your explanation, it makes sense. It took me a while to get it, as I'm not used to binary and hex and stuff, but I'm getting a better grasp of how they work. Pitch modulation is interesting now that I can set it up. May come in handy if I am looking for an unusual bite.

Quote

Pitch bending. That is the point of the pitch bending command: to smoothly connect 2 notes. I don't see what else you want, maybe you could shorten the duration. The other 2 bending commands are $EB $XX $YY $ZZ and $EC $XX $YY $ZZ, which let you bend to and from notes respectively. This is all I know about pitch bending.

The main question I had about pitch bend was this:
If I wanted to emulate a guitar or something which doesn't always bend from one semitone to another, but instead sort of hangs around between notes for a bit. A really obvious example of instruments that do this is harmonicas in bluesy music... not suggesting a blues port for the spc! But it's the most obvious I can think of. In PPMCK or similar you can make pitch envelopes to direct the pitch in interesting ways, as it was just adding and subtracting whatever values you gave it from the pitch registers I think. Not saying that is better though, as proper portamento is lacking. Portamento is really only supported on the 2A03 chip which is only a fraction of the channels PPMCK can use, so the fact that AddmusicK can indiscriminately do it is a big plus for me. I don't think AddmusicK can really go between semitones.. though. There's a hex command, can't remember which right now, to alter the pitch offset but I don't think it would be practical to use it for that. In any case, that was my main question, how much control I had over a pitch bend or if it was more or less a portamento slide between chromatic notes.
My legato question concerns the best way to define when I wanted a sound to retrigger, or when I wouldn't. I was curious if usage of the legato commands as I illustrated above is the best way to go about it. If it is, I'll probably just redefine that legato toggel with something that's easier to type with the replace command.

Quote
About the silence at the end/beginning of songs. I have three theories.

a) loading time. I remember AM4 needing something like an r8 length of silence at the beginning of your songs, so the game might just be loading the samples.
b) ADSR/GAIN. I don't remer where, but there was a discussion about whether it's better to use $ED $7F $E0 ADSR or $7F GAIN; which of them play more instly. So I guess it might also be sample playment settings.
c) THere isn't any. I seriously can't find any silence at either the beginning or the loop point of vanilla or custom sampled music. Or even that most basic penta scale. At least not the half second you were talking about. I listened both in game (ZMZ) and at 33% with SPC700. Or if there is it's probably only a few ms and I'm not that much into music to hear/care about it.

What struck me about other SPC files is that there is virtually no silence. In Winamp when I would put an SPC on repeat, there wouldn't be nearly as much gap at the track boundaries as I get with addmusicK. In the case of the default SMW sample set and the default SMW mml tracks, there is indeed no silence at the beginning of the songs. And if you stick to that sample set, the beginnings are normally tight. When I would load samples though, is when the delay at the start would kick in. And, regardless of what I do, I still get at least 10 seconds of silence at the end of my songs, as seen by Winamp and the SPC700 player you mentioned. Even the SPC files that I generated from the default AddmusicK local songs have at least 10 seconds of silence at the end, and I have no clue why. It is bothering me because I know if I render a song I created and share it as an audio file, I'll always have to trim that silence off, where as if I want to share a ripped SPC from a game, that silence will not exist. I suppose? if I really wanted to kill the few hundred MS of silence I get at the beginning when I load custom samples, I could go into the ASM files and edit them. But I'm not that techy as much as I'd like to be, and I'll break things before I get them working. Besides the silences at the end are more severe so I'd like to have an idea of whether this is an aDdmusicK problem or not. As I think I said in my earlier post, adding a length command to the txt doesn't completely fix it. On Winamp at least it causes a fade-out to occur after the end point, so if I set the length to 30 seconds, at 30 seconds it will start to fade out whether there is data there or not. I'd be interested if anyone has an idea what's going on. How do you guys make songs without a loop? Do you have silences at the end of even simple songs like I do?

Quote
AFAIK AMK won't compile your song if it doesn't work in game. Unless you make an infinite loop with commands or something.Or screw up converting old sampled music. but I haven't heard of many other cases.

True enough. I am not very familiar with how AddmusicK works with SMW, because I am visually impaired and find it difficult to play video games. Instead I love the music and old sound chips. I've heard a few ports of FF7 and SMG music on Youtube which claimed to use AMK and push the SPC700 to its limits with the usage of custom samples and echo buffers and whatnot. The ports were certainly well-done.
I think, though I'm not certain, that if I had an interest or ability to play the game, I'd have to be much more mindful of what I do in my eventual ports than I do if I am just interested in using the SPC700 and AddmusicK as an interesting composition tool. I would, however, like to read up on porting for SMW so that I can follow guidelines and try to make music that'll work without messing something up. I do know that channels 6, 7 and 4 are to be used sparingly if at all, as SMW plays sounds on those channels. Also the sound effects seem to mess with the instruments unless you define your instrument on every note of the sound effect channels. What I'm most worried about is my usage of echo buffers and custom samples and whatnot, since I admit I find the SMW set too bland and overused for music, and there may be times I either don't use it at all or only use a few things from it. So then the question comes... Am I to assume that so long as the song sounds passable without channels 4, 6 and 7, and so long as the default AMK configuration compiles the SPC, that my work is done and it can safely be inserted into a rom without issue?

Quote
Apologies for any grammatical/spelling errors made, I'm a bit tired while writing this.

No worries.
Make more of less, that way you won't make less of more!
ooh boy, lotsa text.

Originally posted by musicalman
The main question I had about pitch bend was this:
If I wanted to emulate a guitar or something which doesn't always bend from one semitone to another, but instead sort of hangs around between notes for a bit. A really obvious example of instruments that do this is harmonicas in bluesy music... not suggesting a blues port for the spc! But it's the most obvious I can think of. In PPMCK or similar you can make pitch envelopes to direct the pitch in interesting ways, as it was just adding and subtracting whatever values you gave it from the pitch registers I think. Not saying that is better though, as proper portamento is lacking. Portamento is really only supported on the 2A03 chip which is only a fraction of the channels PPMCK can use, so the fact that AddmusicK can indiscriminately do it is a big plus for me. I don't think AddmusicK can really go between semitones.. though. There's a hex command, can't remember which right now, to alter the pitch offset but I don't think it would be practical to use it for that. In any case, that was my main question, how much control I had over a pitch bend or if it was more or less a portamento slide between chromatic notes.
My legato question concerns the best way to define when I wanted a sound to retrigger, or when I wouldn't. I was curious if usage of the legato commands as I illustrated above is the best way to go about it. If it is, I'll probably just redefine that legato toggel with something that's easier to type with the replace command.

Pitch bending is limited in SNES in the sense that, as you correctly assumed, you can only bend in semitone intervals. There's a third command for pitch bending by the way, which is $DD $XX $YY $ZZ that works similarly to $EB and $EC, except you don't have to turn the command off afterwards and $ZZ can be replaced with the note itself (instead of having to read a hex table to find the value of an individual note).
For the example you gave (going in between semitones aka quarter steps), probably the best solution is using legato as you said, by joining very short notes using that command, each of them differing slightly through the use of the $EE command (fine-tuning).

Originally posted by musicalman
What struck me about other SPC files is that there is virtually no silence.
In Winamp when I would put an SPC on repeat, there wouldn't be nearly as much gap at the track boundaries as I get with addmusicK. In the case of the default SMW sample set and the default SMW mml tracks, there is indeed no silence at the beginning of the songs. And if you stick to that sample set, the beginnings are normally tight. When I would load samples though, is when the delay at the start would kick in. And, regardless of what I do, I still get at least 10 seconds of silence at the end of my songs, as seen by Winamp and the SPC700 player you mentioned. Even the SPC files that I generated from the default AddmusicK local songs have at least 10 seconds of silence at the end, and I have no clue why. It is bothering me because I know if I render a song I created and share it as an audio file, I'll always have to trim that silence off, where as if I want to share a ripped SPC from a game, that silence will not exist. I suppose? if I really wanted to kill the few hundred MS of silence I get at the beginning when I load custom samples, I could go into the ASM files and edit them. But I'm not that techy as much as I'd like to be, and I'll break things before I get them working. Besides the silences at the end are more severe so I'd like to have an idea of whether this is an aDdmusicK problem or not. As I think I said in my earlier post, adding a length command to the txt doesn't completely fix it. On Winamp at least it causes a fade-out to occur after the end point, so if I set the length to 30 seconds, at 30 seconds it will start to fade out whether there is data there or not. I'd be interested if anyone has an idea what's going on. How do you guys make songs without a loop? Do you have silences at the end of even simple songs like I do?

Sadly, I can't really help you here. In pretty much every non-looping SPC I've heard, including SPCs from original games, I always get that 10 second long silence, and I don't know if there's a way around it or if it's just SPC700 Player that does it.
I don't have the problem of silence at the beginning either. Even when I load many samples, AMK has never exported an SPC with over half a second of silence for me. I could be misunderstanding your post tho? but I really can't provide much help here.

Originally posted by musicalman
True enough. I am not very familiar with how AddmusicK works with SMW, because I am visually impaired and find it difficult to play video games.
Instead I love the music and old sound chips. I've heard a few ports of FF7 and SMG music on Youtube which claimed to use AMK and push the SPC700 to its limits with the usage of custom samples and echo buffers and whatnot. The ports were certainly well-done.
I think, though I'm not certain, that if I had an interest or ability to play the game, I'd have to be much more mindful of what I do in my eventual ports than I do if I am just interested in using the SPC700 and AddmusicK as an interesting composition tool. I would, however, like to read up on porting for SMW so that I can follow guidelines and try to make music that'll work without messing something up. I do know that channels 6, 7 and 4 are to be used sparingly if at all, as SMW plays sounds on those channels. Also the sound effects seem to mess with the instruments unless you define your instrument on every note of the sound effect channels. What I'm most worried about is my usage of echo buffers and custom samples and whatnot, since I admit I find the SMW set too bland and overused for music, and there may be times I either don't use it at all or only use a few things from it. So then the question comes... Am I to assume that so long as the song sounds passable without channels 4, 6 and 7, and so long as the default AMK configuration compiles the SPC, that my work is done and it can safely be inserted into a rom without issue?

For future reference, AMK changes the way SMW handles SFX and now channel 4 is completely available and free to use without any sound affecting it. Also, SFX do not mess up instrument data at all unless you're doing something really hacky on those channels, and it especially won't happen if you're using remote commands that redefine the instrument at the beginning of every note.
You can also simply not load SMW's samples at all if you're not interested in using them for your song. However if you're worried about your port messing with SFXs (since they obviously use SMW's samples), even if you're not intending for it to be used in a hack, you could simply load the essential ones only and load an empty sample in place for the other original samples. No one will notice :P
So for your last question: yes, you're pretty much done there. Don't be afraid to use channels 6 and 7 anyways; you should simply put the least important channels there (like a hi-hat or an echo channel for example) as opposed to not using them at all.
LINKS Twitter | YouTube | SoundCloud | Fortaleza Reznor
to hear birds and see none.
To the SPC silence question: I think you have hex edit the SPC but for that, I will see, where the address is you have to change...
Edit: Found it! It's address 0xAC, a five byte address. Be aware that the value has to be entered in ASCII format as so use the right field (with the characters) to enter the time instead of the left/ center one.

To the SFX question: Most games does this. This is mostly unnoticable on SMW because channels 4, 6 and 7 (and 5 because of the Yoshi drums) aren't often used or at least most of the time only for chorus and fake echos but some games are much worse: These games puts noticable/ important tracks on SFX channels. And I talk about SNES games, not the NES ones for obvious reason.

Originally posted by MaxodeX
Pitch bending is limited in SNES[...]

*N-SPC music engine. If you take a look at some other enginges like Rare's, they are much more flexible (but less dynamic) than Nintendo and AMK's (which is based on the N-SPC) engine.
I'm pretty new to AddMusicK. In my Midi file I had a portamento effect (constant 20%) between 2 notes (from o6 f+24 to o4 d+32). I tried to reconstruct this with $DD $XX $YY $ZZ. Unfortunately it doesn't sound the way I want it to sound and I can't find an explanation for $DD. Can someone help me here and tell me how to use it and what the different hex values mean? Something like start note, end note, speed etc.?

This is how it looks at the moment:
Code
f+24 $DD $00 $20 $90 << d+32 r96
Your question don't pertain too much to the Original post. Please check post dates before posting as this thread is 4 years old.
In the future just make a new thread to ask your question instead of bumping really old threads.
Link Thread Closed