Hi,
Thank you for this great product.
Any chance to convert txt EQ from REW (Room EQ Wizard) to EQE?
Example of REW txt preset:
Filter 1: ON PK Fc 50.50 Hz Gain -4.40 dB Q 3.619
Filter 2: ON PK Fc 88.10 Hz Gain -5.00 dB Q 2.385
Filter 3: ON PK Fc 116.5 Hz Gain -4.80 dB Q 2.001
Filter 4: ON PK Fc 255.0 Hz Gain -4.60 dB Q 2.523
Filter 5: ON PK Fc 360.0 Hz Gain -10.20 dB Q 1.148
Filter 6: ON PK Fc 518.0 Hz Gain 18.00 dB Q 1.017
Filter 7: ON PK Fc 791.0 Hz Gain -6.10 dB Q 1.539
Filter 8: ON PK Fc 1142 Hz Gain 14.20 dB Q 1.858
Filter 9: ON PK Fc 1300 Hz Gain -18.10 dB Q 1.012
Filter 10: ON PK Fc 1989 Hz Gain 8.50 dB Q 1.000
Filter 11: ON PK Fc 2338 Hz Gain -2.10 dB Q 4.722
Filter 12: ON PK Fc 4489 Hz Gain -7.40 dB Q 1.391
Filter 13: ON PK Fc 6621 Hz Gain -4.70 dB Q 2.040
Filter 14: ON PK Fc 11783 Hz Gain -3.00 dB Q 2.527
Filter 15: ON PK Fc 13781 Hz Gain -1.80 dB Q 2.341
Check out this script: https://github.com/rweichler/AutoEQE/blob/master/convert_autoeq.lua
That's for AutoEq which uses the same format, you will have to edit it slightly to make it read the right files.
But you're right this should just be a automatic feature where you copy/paste it into a box. Thx for the feedback
Check out this script: https://github.com/rweichler/AutoEQE/blob/master/convert_autoeq.lua
That's for AutoEq which uses the same format, you will have to edit it slightly to make it read the right files.
But you're right this should just be a automatic feature where you copy/paste it into a box. Thx for the feedback
how to run this script?
lua convert_autoeq.lua greenharman.txt
greenharman.txt
nil
lua: convert_autoeq.lua:38: attempt to concatenate a nil value (field '?')
stack traceback:
convert_autoeq.lua:38: in main chunk
[C]: in ?
use this instead
local path = string.gsub(string.gsub(arg[1], '%.txt', '.lua'), '\n', '')
local f = io.open(path, 'w')
function p(s)
f:write(s)
f:write('\n')
end
p('return {')
for line in io.open(arg[1], 'r'):lines() do
local k, fr, g, q = line:match('Filter %d+%: ON (.+) Fc (%-?%d+%.?%d*) Hz Gain (%-?%d+%.?%d*) dB Q (%-?%d+%.?%d*)')
p(' {')
p(' name = "eq",')
p(' gain = '..g..',')
p(' frequency = '..fr..',')
p(' Q = '..q..',')
p(' },')
end
p('}')
f:close()
use this instead
error:
lua convert_autoeq.lua greenharman.txt
lua: convert_autoeq.lua:15: attempt to concatenate a nil value (local 'g')
stack traceback:
convert_autoeq.lua:15: in main chunk
[C]: in ?
result file:
{
{
name = "eq",
it was very hard for me to debug LUA and i did it on C :)
#include <stdio.h>
int main (int argc, char *argv []) {
printf ("return {\n");
printf (" {\n");
printf (" name = \"preamp\",\n");
printf (" gain = %lf,\n", 0.0);
printf (" },\n");
char tmp [128];
while (NULL != fgets (tmp, sizeof (tmp), stdin)) {
int filter_num;
double fc, gain, q;
int ret = sscanf (tmp,
"Filter %d: ON %*[A-Za-z0-9] Fc %lf Hz Gain %lf dB Q %lf\n",
&filter_num, &fc, &gain, &q);
if (ret == 4) {
// line was recognized
printf (" {\n");
printf (" name = \"eq\",\n");
printf (" gain = %lf,\n", gain);
printf (" frequency = %lf,\n", fc);
printf (" Q = %lf,\n", q);
printf (" },\n");
} else {
// line was not recognized
//printf ("ERROR: %d, %s\n", ret, tmp);
}
}
printf ("}\n");
}
for run use:
gcc -o convert convert_autoeq.c
./convert < REWpreset.txt > EQEpreset.lua
i.... incredible....