Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /storage/content/49/145849/famitracker.com/public_html/forum/classes/dbHandler.php on line 29 FamiTracker
Login:
Menu:
Post: Author:
FamiTracker > General > FamiTracker Talk > Echo effects and distortion Owner: Ryudo New post
Page 1 of 1 Sort:  
Echo effects and distortion Posted: 2011-02-01 21:53  (Last Edited: 2011-02-01 21:54) Reply | Quote
Ryudo

Avatar

Member for: 4157 days
Status: Offline

#12908
Hello Famitracker community,

Let me start of with saying that I am new to using any form of tracker, or even making (or in this case "copying") music. This thread will contain a beginner level (2 days experience) question. I've decided to cover a relatively easy song to get a feel for the program. The song can be listened to here: http://www.youtube.com/watch?v=9ydkV4M4dCw .

The song makes use of 3 channels (No noise / DPCM). Square 2 is used in 2 ways:
1. Echoing Square 1. (In the youtube link above this happens at 0:00-0:36)
2. Playing simultaneously with Square 1. (In the youtube link above this happens at 0:37-0:52)

The entire Square 2 is giving me troubles (so both the echo and the simultaneous parts). I've been playing the original song in audacity to get a feel for the timing relative to each other and this is what it looked like: http://img171.imageshack.us/img171/6223/audacityecho.jpg . As you can see the echo starts in the middle of the original note. I've copied this in Famitracker by making a note last 2 rows for square 1, where the echo would start while square 1 is already on the 2nd row. (See the attached FTM file)

The simultaneous part I tried to get done by having Square 2 run parallel with Square 1 but with a Noise/Duty of 1 instead of 2.

The issue on both parts is that it sounds poor and very inaccurate when compared to the original. (To an extend that the song sounds better if i disable square 2 completely) Playing both channels together causes quite some distortion and I am not quite sure why. I've tried to get the echo working by doing the following:
1. Change the volume sequence property of several instruments
2. Change the volume difference of square 2 relative to square 1.
3. Added different kind of pitches to square 1, square 2 and both.
4. In the original piece I can hear a little bit of a vibrato effect. I get a slightly better result when I add the effect "411" to the echo, but it's still far from what it should be. (aside from that 1 speed or 1 depth feels like it still has too much vibrato. But this is probably a different issue that I'll attempt to fix once the echo is working properly)
5. Change the notes of both Square 1 and Square 2.

My question would be: Why is this distortion happening and how can I fix it? (Or rather, how can i produce the echo effect that's used in the original piece, and does this type of effect have a specific name? How would I best go about these types of problems in the future?)

A very clear example of the distortion I speak about can be found at frame 04.

Thanks in advance,

Ryudo / Celfic

Attached: My FTM file thus far.



_______________________
[url=http://www.youtube.com/user/ReclusiveLemming]Chiptune channel
Posted: 2011-02-02 02:06 Reply | Quote
furrykef

Avatar

Member for: 5189 days
Status: Offline

#12917
In pattern 4 you have both of the notes set to instrument 1 instead of Square 2 to instrument 4. Aside from that, making both of your squares a bit quieter will probably solve any remaining distortion issues.

By the way, you don't have to keep setting the volume to F over and over. It'll just make it harder to change it to something else later on.

Posted: 2011-02-02 02:34  (Last Edited: 2011-02-02 02:35) Reply | Quote
tadpole

Avatar

Member for: 5712 days
Location: Renton, WA, USA
Status: Offline

#12919
You have the right idea here. It's pretty close.
A specific name for the effect? We usually just call it 2 channel echo.


Furrykef is right. The distortion is due to having your squares too loud. But there's one more thing to remember - Detune (the Pxx command).

If you want to take a closer look at what's going on in an NSF, use NSF2MIDI to convert it to a MIDI, and then use Anvil Studio and look at the event list for each channel for all the notes, timings, and volume envelopes.

Also, you can use NSFplug, open up the keyboard, and slow it down.

From these methods, I made a more accurate version (still not perfect). Then I modified your file to make it more accurate.

By the way, thanks for introducing me to such an awesome song!


Attachments:
fixed_your_version.ftm (7 Kb)
my_version.ftm (3 Kb)
Posted: 2011-02-02 03:38  (Last Edited: 2011-02-02 03:56) Reply | Quote
Ryudo

Avatar

Member for: 4157 days
Status: Offline

#12920
@furrykef: Ah thanks for noticing that, I'm not quite sure how I overlooked that one. Regarding the F's, I'm not completely sure what you mean. I put the F's in combination with a A00 in the file after every A01 so the sound gets "reset". If you don't mean that but the ones I put in triangle, I put those there as some sort of markings to indicate where certain parts of the song start only. (I don't think you can set volume for the triangle channel anyway right? That's why I thought this would be a decent choice at least) But I'll definately keep that in mind and i removed them from this one as well.

@tadpole: Thanks a lot for the applications. I'll certainly check them out. The version you made sounds a lot better indeed, although I have a couple of questions about it:

1. I see you modified the flute instrument in a way that the "fade" that i did with the A01 effect is now part of the instrument. I tried that as well at some point because that's how it will be the whole song, but I ran into the issue of the sequence editor only allowing 128 values. Somehow you managed to increase that value up to 176. Even in your FTM I cannot increase it any further, or when i decrease it I cannot increase it again. How exactly can I tell Famitracker to use more than 128 slots?

2. I see you also added a pitch to the instrument (-edit- Ah, not as replacement for the P effect, those are added in the tracker as well (P7F for the echo channel). Guess the same question would go for those). I was wondering how you came up with this? Did this just go by ear/trial-and-error or is this the result of analizing the song using the tools you mentioned?

3. You replaced the Arpeggio instruments I made by a version where you enter the nodes seperately. In a lot of the cases (like the fade for the flute as well for example) you can do it either in the instrument, or as an effect. I assume you did it with an effect because it's more customizable? (Could go faster than the quickest arpeggio) For the flute you choose the opposite approach though, is this because the fade isn't linear and it would get too messy?

Thanks a lot for the help, much appreciated!

_______________________
[url=http://www.youtube.com/user/ReclusiveLemming]Chiptune channel
Posted: 2011-02-02 03:44  (Last Edited: 2011-02-02 03:44) Reply | Quote
jrlepage
Moderator

Avatar

Member for: 4982 days
Location: Canada
Status: Offline

#12921
[quote=Ryudo]I ran into the issue of the sequence editor only allowing 128 values. Somehow you managed to increase that value up to 176.[/quote]
This could have to do with your version of FamiTracker. Which one are you using? The latest version is 0.3.6 stable.

_______________________
Follow me on [url=https://twitter.com/jrlepage2a03]Twitter.
I record (some) NSFs on hardware. Feel free to [url=http://www.famitracker.com/forum/posts.php?id=3633]request a hardware render.
Posted: 2011-02-02 03:52 Reply | Quote
Ryudo

Avatar

Member for: 4157 days
Status: Offline

#12922
Ah yes, that was indeed the cause of the issue. I was using version 0.3.5. Thanks again!

_______________________
[url=http://www.youtube.com/user/ReclusiveLemming]Chiptune channel
Posted: 2011-02-02 04:15  (Last Edited: 2011-02-02 04:16) Reply | Quote
tadpole

Avatar

Member for: 5712 days
Location: Renton, WA, USA
Status: Offline

#12923
[quote=Ryudo]
2. I see you also added a pitch to the instrument (-edit- Ah, not as replacement for the P effect, those are added in the tracker as well (P7F for the echo channel). Guess the same question would go for those). I was wondering how you came up with this? Did this just go by ear/trial-and-error or is this the result of analizing the song using the tools you mentioned?[/quote]

I used NSFplug, opened up the keyboard, and slowed it down to the maximum. I noticed that the FREQ was going from 70 to 6F on the lead and 6F to 70 on the echo. I don't think it's possible to use the 4xx command to do that kind of vibrato, so added the vibrato into the instruments.


[quote=Ryudo]
3. You replaced the Arpeggio instruments I made by a version where you enter the nodes seperately. In a lot of the cases (like the fade for the flute as well for example) you can do it either in the instrument, or as an effect. I assume you did it with an effect because it's more customizable? (Could go faster than the quickest arpeggio) For the flute you choose the opposite approach though, is this because the fade isn't linear and it would get too messy?
[/quote]

Yep, it could have been done in the instrument settings. I did it in the note data window instead because I wanted to show that the volume was retriggered with each note (and yes, it would be pretty messy in the instrument settings).

Posted: 2011-02-02 05:31 Reply | Quote
jrlepage
Moderator

Avatar

Member for: 4982 days
Location: Canada
Status: Offline

#12925
[quote=tadpole]Yep, it could have been done in the instrument settings. I did it in the note data window instead because I wanted to show that the volume was retriggered with each note (and yes, it would be pretty messy in the instrument settings).[/quote]

Here's an FTM to demonstrate that whole sequences of notes with envelopes and everything CAN be done in the instrument window, and also that it generally IS a pain in the neck to do so.

Also proof that I am an idiot with too much time on his hands~~ x.x

_______________________
Follow me on [url=https://twitter.com/jrlepage2a03]Twitter.
I record (some) NSFs on hardware. Feel free to [url=http://www.famitracker.com/forum/posts.php?id=3633]request a hardware render.
Attachments:
l00p.ftm (2 Kb)
Posted: 2011-02-03 11:17 Reply | Quote
furrykef

Avatar

Member for: 5189 days
Status: Offline

#12930
[quote=Ryudo]@furrykef: Ah thanks for noticing that, I'm not quite sure how I overlooked that one. Regarding the F's, I'm not completely sure what you mean. I put the F's in combination with a A00 in the file after every A01 so the sound gets "reset".[/quote]
Ah, right. I rarely use the Axx command exactly because I find it annoying to use for that reason. ^^;


Posted: 2011-02-09 08:45 Reply | Quote
rainwarrior

Avatar

Member for: 4150 days
Location: Canada
Status: Offline

#13018
I am thinking that when you say "distortion" you're not referring to clipping/overflow from numbers that are too large. When I play your example I hear a strong beating effect when two notes of the same pitch are played in both square wave channels loudly enough.

It's a strange effect; it kind of reminds me of cross-modulation, like in a device where two oscillators that are supposed to be independent have some sort of leak and end up affecting each other.

What I'm hearing is not a phasing effect, like you'd get if they were detuned. It's more like amplitude modulation. Another thing that's really weird about it is that if you mute either channel, and output a WAV file of them individually, you won't have this problem when you mix them back together. The two square channels seem to be affecting each others' volumes somehow.

Anyhow, I think that this is something weird about Famitracker itself. If you export as NSF and use a different player (my favourite is NSFPlug) you might find that this problem goes away.

example of two channels interacting Posted: 2011-02-09 16:43 Reply | Quote
nicetas_c



Member for: 4582 days
Location: AB, CA
Status: Offline

#13024
so I was messing around with the latest stable version when this happened

try to mute one channel and unmute it, and then you can never return to the original state where the two channels cancel each other

!!!


Attachments:
036_stable_funfun.ftm (1 Kb)
Posted: 2011-02-09 22:55 Reply | Quote
rainwarrior

Avatar

Member for: 4150 days
Location: Canada
Status: Offline

#13028
nicetas_c, I think that is actually intended/expected behaviour. The square wave units aren't guaranteed to be in synch phase-wise, they just inherit whatever the previous state is. Famitracker happens to reset their phase when you start playback, so if you keep the channels identical they would be synchronized, but when you mute it you halt the phase for one of the channels, so you'll have a hard time getting them to realign.

I don't know if the NES had a way to force a phase reset, but there doesn't seem to be a way to do it in Famitracker. I've always just assumed you can't guarantee it.

The problem I was talking about, which I hear clearly in Ryudo's example, is different though, not a phasing issue.

Posted: 2011-02-10 00:51 Reply | Quote
TechEmporium

Avatar

Member for: 4485 days
Status: Offline

#13032
The NES did have a way to force a phase reset through the TV's frequency as well as a game's internal interrupts.

_______________________
Technology: the one thing that's hated & cursed at by all engineers, technologists, scientists & technicians!

(Lousy modern technology! )
Posted: 2011-02-10 09:56  (Last Edited: 2011-02-10 09:56) Reply | Quote
Dave
Moderator

Avatar

Member for: 5682 days
Location: UK
Status: Offline

#13043
[quote=rainwarrior]I don't know if the NES had a way to force a phase reset, but there doesn't seem to be a way to do it in Famitracker. [/quote]

you know, if that is possible to do, that would be an awesome addition.

_______________________
[url=http://www.iridescentaudio.co.uk]iridescent audio
Posted: 2011-02-11 01:54 Reply | Quote
jsr
Administrator

Avatar

Member for: 5924 days
Location: Sweden
Status: Offline

#13058
[quote=rainwarrior]The two square channels seem to be affecting each others' volumes somehow.[/quote]That's actually what's happening, the two square channels affects each other in the same way as triangle, noise and DPCM. If the (normalized) output from one channel is 1.0, then both channels added together will result in about 1.73 (and not 2.0).

This is slightly related to Ryudo's question, and that kind of sound should not appear. First I didn't know what was going on, but I checked it and it turned out that the sound emulation was too "coarse grained" and resulted in an amplitude modulation due to the non-linear mixing. This was simple to fix, though it was unexpected to find this kind of obvious problem, it must have been there for a long time without me noticing it.
I've made a number of small fixes already so maybe I can do a new release soon with this fix included.

[quote=furrykef]Ah, right. I rarely use the Axx command exactly because I find it annoying to use for that reason.[/quote]I'm aware of this and have been thinking about adding a default volume command to the instrument settings as an option, or maybe an option to remember volume column values on new notes.

[quote=rainwarrior]I don't know if the NES had a way to force a phase reset, but there doesn't seem to be a way to do it in Famitracker.[/quote]There is a way to reset the phase on the square channels, it happens every time when the high part of the period register is written. It can be heard sometimes when doing note slides or vibrato. There is no way (to my knowledge) to reset the phase of triangle and noise.

_______________________
Programmer and developer
Page 1 of 1 Sort: