thetwom / Tuner

Tuner app
GNU General Public License v3.0
170 stars 16 forks source link

Feature request: custom temperaments (no need for GUI) #33

Open wolftune opened 1 year ago

wolftune commented 1 year ago

It would be great to support custom temperaments. It can be something not in the GUI, like the way https://billthefarmer.github.io/ctuner/ supports custom temperaments by the creation of a custom .txt file (incidentally, the most significant problem with that tuner itself for temperaments is that the software is limited to only 12 pitches per octave)

So, just a documented way for users to add their own temperaments would be big, even if they have to mess with text files and file directories rather than have a nice GUI for it.

P.S. calling these "temperaments" is technically imprecise because a tuning could be strictly Just Intonation, which is not a temperament, temperaments temper the pitches away from JI. So, "custom tuning" is the proper term, but I understand the confusion between instrument-tuning (like open strings) vs tuning as in pitch choices in a tuning system.

thetwom commented 1 year ago

Yes, I guess circumventing the GUI by providing a text file would be an option. Still it is somewhat complex as soon as one allows more than 12 notes, since then the user must also give the note names. And one would need debugging capabilities, if one got the syntax wrong. However, I am not saying, it is not possible :-).

I wonder, if this is something people actually need or if this is more something exotic for 2-3 people. In the second case, it might actually be simpler to ask the people to compile their own version and do a bit of documentation how to add temperaments. You don't need to be an android programmer to do this.

I guess you are right about the naming. As you say it is a bit unfortunate that it's the same name as instrument tunings. So maybe it is best to keep it ...

wolftune commented 1 year ago

On naming, nobody who wants to use JI will care that it is called "temperament", they'll be fine.

As far as users, once people realize that playing with different tunings is a thing, it is reasonably common enough for people to explore their own tunings. They get a lap harp or are moving around movable frets or whatever and exploring tuning options. The people who do that are hackers who are willing to go out of their way with some no-UI method (and perhaps they could contribute their custom files to a directory in the repo here?). The better the UI, the more it encourages and shows people about understanding the flexibility, but one step at a time.

I promoted the tuner to the xenharmonic alliance group and one of the first replies was asking about custom temperaments.

We're almost talking about just documentation for the FLO aspects. Like, the current status is that anyone can fork the whole project and adjust the temperaments and build a new apk. What steps can reduce that hassle easily enough? The very first step (which I should have thought of before) is that there can be a simple answer "it's FLO, you can fork the whole project". We don't need to jump from there to perfection.

thetwom commented 1 year ago

I guess I am just not in right communities to realize that people are really exploring own tunings/temperaments :-D.

Unfortunately, the more I think about custom temperament integration, the more difficult it seems. There is quite a bit of logic behind the note names, which one could of course try to translate to a custom file syntax, but if it is too complex, it will not be worth much since the feature will be restricted to people with high affinity to software. So, to make it a useful feature, we would need a UI.

Note, that this is really different to the Bill Farmer tuners, since by having only 12-tone scales, it is enough to drop in 12 numbers. The note names are clearly defined.

So, at the moment it appears more like a UI would be needed. But there are quite a few of other things, I want to do first :-) ... so I have to keep this open ...

wolftune commented 1 year ago

It's not crazy to have this be a sort of "help welcome" issue where anyone else who cares is invited to work on this issue. I don't know how many people in the end will care or use it.

thetwom commented 1 year ago

It might be worth, to adapt some code, making the introduction of new temperaments easier. Lets see, if people express their interest of trying to introduce temperaments in their private forks ...

squidpickles commented 1 year ago

This is somewhere between a +1 and a tangential request, but as a violin player, I often tune to just intonation (especially playing solo). While I tend to tune by ear in most cases, a tuner that could support just intonation would be most welcome

thetwom commented 1 year ago

Thanks for the interest in the app.

There is already a just tuning. Maybe you can check whether this fits your needs or alternatively help me with the reason why it doesn't. To change the tuning, either press on the bottom center (default is EDO12 and set it to "Just tuning") or in the settings menu find the "Temperament" setting. You can also change the reference tone (if you don't want to base the tuning on C). The just tuning currently uses 5-limit asymmetric scale.

squidpickles commented 1 year ago

@thetwom ah, indeed, that's exactly what I'm looking for. So, maybe not quite what this person is requesting.

tristanbay commented 1 year ago

As of now, I currently don't see a way to add my own tuning to use in the app. Since this is an Android app, and editing text files isn't a feature that's provided out of the box, I suggest the following:

I have a kalimba that I want to tune to TE Mavila[9] and your app appears to be more accurate than any web application I tried. Unfortunately, I have to eyeball where the tuning line is, relative to the lines of the preset tuning. It would even be nice to add the number of cents off of the target as text, and not just a line, if that isn't already a feature (and I just haven't noticed it).

Please let me know what you think!

thetwom commented 1 year ago

Hi, thanks for the interest in the app. Glad that it seems to work accurately for you.

Regarding your request, you are right that currently it is not possible to define own tunings. At the moment, the amount of work to implement such a feature seems not to be reflected by the expected frequency of usage. As you are already describing, a lot of aspects have to be taken into account to make it work nicely. So, at least for now, I don't plan to implement this.

If it is more or less common tuning, we could think about integrating it directly in the app. Unfortunately, your reference TE Mavila[9] is not known to me. Maybe you can give more specific info.

Regarding showing the cent deviation, there is also no such feature at the moment. At the moment, the use case for this is not fully clear to me. Is it, since you know the cent deviation from some reference scale?

There is at least one additional option, which might be interesting to you. If you go to scientific mode, you will see the current frequency at the top. But of course, this is not really convenient.

wolftune commented 1 year ago

FWIW, I don't think anything like Mavila is worth including in a list. There are zillions of various tunings people have identified and play with that are not commonly used by any particular community or common instruments. This is a case for either custom temperaments or just not doing.

I do think that having an option to show cents deviation from the current tuning might be more widely useful, and I think the UI would put that where the scientific mode puts current frequency.

thetwom commented 11 months ago

At least the cent deviation from the current tuning is shown v6.3.0.