SynthMaker

Turn this function into code?

Archive · 2010 26 old posts

From the original SynthMaker forum (2004–2014), with its members’ names and dates.

aliasant ·

MegaHurtz ·

what does it do?

snh (F *2)

aliasant ·

MegaHurtz wrote: what does it do?

snh (F *2)

Il tell you if you turn it to code 🙂

MegaHurtz ·

Here you go Dr zoidberg.

Limmited edition so be quick 😀

aliasant ·

MegaHurtz wrote: Here you go Dr zoidberg.

Limmited edition so be quick 😀

Lol. It didnt work as it works with floats...

I have to figure out how to messure it.

MegaHurtz ·

What would be the result? This only does a in+2 when in changes.

aliasant ·

Here. Test this one and youll see the problem.

aliasant ·

MegaHurtz wrote: What would be the result? This only does a in+2 when in changes.

It should add the current sample to the previous and output that.

MegaHurtz ·

If you press the trigger it`s the same 😀

MegaHurtz ·

slight hack..

MegaHurtz ·

aliasant ·

MegaHurtz wrote:

That works nicely 🙂

PM me yuour mail and Ill send you the complete thing when I have put it all together. Got a meeting now so probably later on tonight.

MegaHurtz ·

Will do, Happy patching!

aliasant ·

MegaHurtz wrote: Will do, Happy patching!

Back and looking at this realizing I need the jz ( change thing ) in normal code and not asm cause Im about to loop this if possible.

So can we even write the jz in normal code?

MegaHurtz ·

not that I know off.. Ill see if i can do it.

oddson ·

MegaHurtz wrote:

This file name breaks the link in my browser.

aliasant ·

MegaHurtz wrote: not that I know off.. Ill see if i can do it.

Wait,'

Ill send you my float vesion instead. I dont think there should be a jnz at all. It might need to calculate every sample.

MegaHurtz ·

Nice work, in asm with the jnz it was easy becouse it yust stops doing it`s thing. I was pretty shure this similar thing would do the same but it seems it doesnt.

Edit: W8 it does, Yust looked narly becouse of the speed I rotated.

aliasant ·

MegaHurtz wrote: Nice work, in asm with the jnz it was easy becouse it yust stops doing it`s thing. I was pretty shure this similar thing would do the same but it seems it doesnt.

Edit: W8 it does, Yust looked narly becouse of the speed I rotated.

YEs. That worked exactly like the the other. NICE !

Looking at it now its simply a lowpass filter at half nyquist? At least that is what it looks like in a freq spectrum.

Compared it to other lopass filters I had ( some of them) and it doesnt act like any of them. Closest was a butterworth with a res at -1 ( Dozius version ) and Freq at about 17kHz

aliasant ·

Correction.

Note. First half the output from the code. Then Dozius Lopass filter at nywuist with res at a staggering -10 Funny stuff.

MegaHurtz ·

Is it liniar phase? (ansered itself) That makes me wonder..

out=in+late; late=in;

Wich loses it`s average at 1 sample but is a similar filter.

aliasant ·

MegaHurtz wrote: Is it liniar phase? (ansered itself) That makes me wonder..

out=in+late; late=in;

Wich loses it`s average at 1 sample but is a similar filter.

I fed the code with a feedback function and now it looks a bit like ..well. Interesting. Loudness maybe? Trying to fix the output so it stays at, at least similar gain. My bet here is that this is a "Re-inventing the wheel" kind of deal. When there is something useful from all this someone will pop in saying: Oh. But thats just a "kachingkabing" function that can easily be written like this; followed by some rediciously simple code using only 3 cycles.....+ a weekend girlfriend at no extra cost.

MyCo ·

streamin in; streamout out;

float last;

out = out + (last!=in) & (last+in-out); last = in;

aliasant ·

MyCo wrote: streamin in; streamout out;

float last;

out = out + (last!=in) & (last+in-out); last = in;

Nice. Actually twice as fast 🙂

Still not sure what the heck this is.

What I have used my float thing for is to connect a bunch in series with the "gain" compensation at the end and it has worked a bit like RMS smoothing of a float without the need of an external ticker.

MegaHurtz ·

it`s an average baked into a sample and hold on change. Mike did a nice yob on reducing the lines, this is simplicitywise similar to the asm version. Except the jnz on change. Funny thing these constructions start behaving like filters. This one thakes into account the previous value, wich can be defined as uncorrelated adding. My favourite number for an uncorrelated add is ((a+b)*0.666). Wich in this case will allow you to get a slightly higher number than the 1 that goes in. So ((a+b)* 0.5) will be your target number to be on the safe side. If the rising edge is harder this will fiter more, mabe a nice experiment to get this into the smaller number of a moving average.

McBarGig ·

Yeah I have not had the chance to look into moving average filters yet, but this may be a good start..

Wrote something here? To have a post removed or your name hidden, write to [email protected].

Before your first post

A few rules keep this a friendly place. You agree to them once.

Shown next to what you post, here and in the app. It doesn’t have to be your real name: 3–24 lower-case letters, digits or _ (capitals become lower case, spaces become _).

    Then your post goes up straight away.

    Delete this reply?

    Open it in SynthMaker?

    It goes on the track you’re editing there, in place of that track’s sound, and into My sounds. Your other tracks stay as they are.

    Want to keep that track’s sound? Start a new song in SynthMaker first (Song › New song), then open this.

    Report this reply?

    Only the developer reads reports. The person isn’t told who reported them.

    What’s wrong with it?

    Block this person?

    You won’t see their posts and replies here any more. They aren’t told, and you can unblock them at any time.

    People you’ve blocked

    Their posts and replies are hidden from you. Unblock someone to see them again.

    The community rules

    A few rules keep this a friendly place. Everyone agrees to them once, before their first post.