diff options
author | Robin Gareus <robin@gareus.org> | 2016-07-12 04:01:56 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2016-07-12 04:01:56 +0200 |
commit | 157564947b1707fea0c31462a2b479cc67a6d554 (patch) | |
tree | 3b717198a169c9e9833ff69dde05f9f01aedb6d7 /libs/plugins/a-eq.lv2 | |
parent | 30240b33e903a6a0ee098cc5c787f74e9f69f6c3 (diff) |
a-eq tweaks:
* shorten e-eq Hz display (no decimals)
* use 16:9 aspect inline display
* fix a compiler warning
Diffstat (limited to 'libs/plugins/a-eq.lv2')
-rw-r--r-- | libs/plugins/a-eq.lv2/a-eq.c | 5 | ||||
-rw-r--r-- | libs/plugins/a-eq.lv2/a-eq.ttl.in | 22 |
2 files changed, 18 insertions, 9 deletions
diff --git a/libs/plugins/a-eq.lv2/a-eq.c b/libs/plugins/a-eq.lv2/a-eq.c index 21a69c0671..30265d7955 100644 --- a/libs/plugins/a-eq.lv2/a-eq.c +++ b/libs/plugins/a-eq.lv2/a-eq.c @@ -128,7 +128,6 @@ instantiate(const LV2_Descriptor* descriptor, const char* bundle_path, const LV2_Feature* const* features) { - int i; Aeq* aeq = (Aeq*)malloc(sizeof(Aeq)); aeq->srate = rate; @@ -140,7 +139,7 @@ instantiate(const LV2_Descriptor* descriptor, } #endif - for (i = 0; i < BANDS; i++) + for (int i = 0; i < BANDS; i++) linear_svf_reset(&aeq->v_filter[i]); aeq->need_expose = true; @@ -547,7 +546,7 @@ static LV2_Inline_Display_Image_Surface * render_inline (LV2_Handle instance, uint32_t w, uint32_t max_h) { Aeq* self = (Aeq*)instance; - uint32_t h = MIN (w, max_h); + uint32_t h = MIN (w * 9 / 16, max_h); if (!self->display || self->w != w || self->h != h) { if (self->display) cairo_surface_destroy(self->display); diff --git a/libs/plugins/a-eq.lv2/a-eq.ttl.in b/libs/plugins/a-eq.lv2/a-eq.ttl.in index b751a96c90..27325560f2 100644 --- a/libs/plugins/a-eq.lv2/a-eq.ttl.in +++ b/libs/plugins/a-eq.lv2/a-eq.ttl.in @@ -11,6 +11,16 @@ foaf:name "Ardour Team" ; foaf:homepage <http://ardour.org/> . +unit:hz0 + a unit:Unit ; + rdfs:label "hertz" ; + unit:prefixConversion [ + unit:factor 0.001 ; + unit:to units:khz + ] ; + unit:render "%.0f Hz" ; + unit:symbol "Hz" . + <urn:ardour:a-eq> a lv2:Plugin, doap:Project, lv2:FilterPlugin ; @@ -37,7 +47,7 @@ lv2:default 160.000000 ; lv2:minimum 20.000000 ; lv2:maximum 20000.000000 ; - unit:unit unit:hz ; + unit:unit unit:hz0 ; lv2:portProperty <http://lv2plug.in/ns/ext/port-props#logarithmic> ; ], [ @@ -58,7 +68,7 @@ lv2:default 300.000000 ; lv2:minimum 20.000000 ; lv2:maximum 20000.000000 ; - unit:unit unit:hz ; + unit:unit unit:hz0 ; lv2:portProperty <http://lv2plug.in/ns/ext/port-props#logarithmic> ; ], [ @@ -88,7 +98,7 @@ lv2:default 1000.000000 ; lv2:minimum 20.000000 ; lv2:maximum 20000.000000 ; - unit:unit unit:hz ; + unit:unit unit:hz0 ; lv2:portProperty <http://lv2plug.in/ns/ext/port-props#logarithmic> ; ], [ @@ -118,7 +128,7 @@ lv2:default 2500.000000 ; lv2:minimum 20.000000 ; lv2:maximum 20000.000000 ; - unit:unit unit:hz ; + unit:unit unit:hz0 ; lv2:portProperty <http://lv2plug.in/ns/ext/port-props#logarithmic> ; ], [ @@ -148,7 +158,7 @@ lv2:default 6000.000000 ; lv2:minimum 20.000000 ; lv2:maximum 20000.000000 ; - unit:unit unit:hz ; + unit:unit unit:hz0 ; lv2:portProperty <http://lv2plug.in/ns/ext/port-props#logarithmic> ; ], [ @@ -188,7 +198,7 @@ lv2:default 9000.000000 ; lv2:minimum 20.000000 ; lv2:maximum 20000.000000 ; - unit:unit unit:hz ; + unit:unit unit:hz0 ; lv2:portProperty <http://lv2plug.in/ns/ext/port-props#logarithmic> ; ], [ |