Skip to content

Commit 2eb8555

Browse files
committed
Release 1.0.21
* Fixed configuration file serialization. * Code updates that could cause potential problems related to using another decimal point for floating-point number formatting. * Added support of storing current file type selection in file dialogs. * Added support of variable size of filter dots. * Implemented widget overrides by priority on the graph widget. * Updated module versions in dependencies.
2 parents 5676dcf + 2cfd2c4 commit 2eb8555

38 files changed

+745
-196
lines changed

CHANGELOG

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,15 @@
22
* RECENT CHANGES
33
*******************************************************************************
44

5+
=== 1.0.21 ===
6+
* Fixed configuration file serialization.
7+
* Code updates that could cause potential problems related to using another
8+
decimal point for floating-point number formatting.
9+
* Added support of storing current file type selection in file dialogs.
10+
* Added support of variable size of filter dots.
11+
* Implemented widget overrides by priority on the graph widget.
12+
* Updated module versions in dependencies.
13+
514
=== 1.0.20 ===
615
* Updated module versions in dependencies.
716

include/lsp-plug.in/plug-fw/ctl.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@
9797
#include <lsp-plug.in/plug-fw/ctl/3d/Model3D.h>
9898

9999
#include <lsp-plug.in/plug-fw/ctl/specific/AudioSample.h>
100+
#include <lsp-plug.in/plug-fw/ctl/specific/DryWetLink.h>
100101
#include <lsp-plug.in/plug-fw/ctl/specific/FileButton.h>
101102
#include <lsp-plug.in/plug-fw/ctl/specific/Fraction.h>
102103
#include <lsp-plug.in/plug-fw/ctl/specific/LedChannel.h>

include/lsp-plug.in/plug-fw/ctl/PluginWindow.h

Lines changed: 30 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (C) 2021 Linux Studio Plugins Project <https://lsp-plug.in/>
3-
* (C) 2021 Vladimir Sadovnikov <[email protected]>
2+
* Copyright (C) 2023 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2023 Vladimir Sadovnikov <[email protected]>
44
*
55
* This file is part of lsp-plugin-fw
66
* Created on: 13 апр. 2021 г.
@@ -42,10 +42,6 @@ namespace lsp
4242
public:
4343
static const ctl_class_t metadata;
4444

45-
private:
46-
PluginWindow & operator = (const PluginWindow &);
47-
PluginWindow(const PluginWindow &);
48-
4945
private:
5046
static const tk::tether_t top_tether[];
5147
static const tk::tether_t bottom_tether[];
@@ -96,6 +92,14 @@ namespace lsp
9692
ssize_t nMouseY;
9793
} window_scale_t;
9894

95+
typedef struct enum_menu_t
96+
{
97+
PluginWindow *pWnd;
98+
tk::Menu *pMenu;
99+
ui::IPort *pPort;
100+
lltl::parray<tk::MenuItem> vItems;
101+
} enum_menu_t;
102+
99103
class ConfigSink: public tk::TextDataSink
100104
{
101105
private:
@@ -132,10 +136,13 @@ namespace lsp
132136
tk::CheckBox *wRelPaths; // Relative path checkbox
133137
tk::MenuItem *wInvertVScroll; // Global inversion of mouse vertical scroll
134138
tk::MenuItem *wInvertGraphDotVScroll; // Invert mouse vertical scroll for GraphDot widgets
139+
tk::MenuItem *wZoomableSpectrum; // Automatic scaling mode of the frequency graph
140+
tk::Menu *wFilterPointThickness; // Filter point thickness submenu
135141

136142
ui::IPort *pPVersion;
137143
ui::IPort *pPBypass;
138144
ui::IPort *pPath;
145+
ui::IPort *pFileType;
139146
ui::IPort *pR3DBackend;
140147
ui::IPort *pLanguage;
141148
ui::IPort *pRelPaths;
@@ -147,10 +154,12 @@ namespace lsp
147154
ui::IPort *pOverrideHydrogen;
148155
ui::IPort *pInvertVScroll;
149156
ui::IPort *pInvertGraphDotVScroll;
157+
ui::IPort *pZoomableSpectrum;
150158

151159
ConfigSink *pConfigSink; // Configuration sink
152160

153161
window_scale_t sWndScale;
162+
enum_menu_t sFilterPointThickness;
154163

155164
lltl::parray<backend_sel_t> vBackendSel;
156165
lltl::parray<lang_sel_t> vLangSel;
@@ -220,11 +229,15 @@ namespace lsp
220229

221230
static status_t slot_invert_vscroll_changed(tk::Widget *sender, void *ptr, void *data);
222231
static status_t slot_invert_graph_dot_vscroll_changed(tk::Widget *sender, void *ptr, void *data);
232+
static status_t slot_zoomable_spectrum_changed(tk::Widget *sender, void *ptr, void *data);
233+
234+
static status_t slot_submit_enum_menu_item(tk::Widget *sender, void *ptr, void *data);
223235

224236
protected:
225237
static i18n::IDictionary *get_default_dict(tk::Widget *src);
226238
static tk::FileFilters *create_config_filters(tk::FileDialog *dlg);
227239
static ssize_t compare_presets(const resource::resource_t *a, const resource::resource_t *b);
240+
void init_enum_menu(enum_menu_t *menu);
228241

229242
protected:
230243
void do_destroy();
@@ -238,6 +251,7 @@ namespace lsp
238251
tk::Hyperlink *create_hlink(tk::WidgetContainer *dst, const char *url, const char *text, const expr::Parameters *params, const char *style_name);
239252
tk::MenuItem *create_menu_item(tk::Menu *dst);
240253
tk::Menu *create_menu();
254+
tk::Menu *create_enum_menu(enum_menu_t *em, tk::Menu *parent, const char *label);
241255
status_t create_dialog_window(ctl::Window **ctl, tk::Window **dst, const char *path);
242256

243257
status_t init_r3d_support(tk::Menu *menu);
@@ -258,6 +272,9 @@ namespace lsp
258272
void sync_knob_scale_enabled();
259273
void sync_override_hydrogen();
260274
void sync_invert_vscroll(ui::IPort *port);
275+
void sync_zoomable_spectrum();
276+
void sync_filter_point_thickness();
277+
void sync_enum_menu(enum_menu_t *menu, ui::IPort *port);
261278
void apply_user_paths_settings();
262279
void read_path_param(tk::String *value, const char *port_id);
263280
void read_bool_param(tk::Boolean *value, const char *port_id);
@@ -269,8 +286,13 @@ namespace lsp
269286

270287
public:
271288
explicit PluginWindow(ui::IWrapper *src, tk::Window *widget);
289+
PluginWindow(const PluginWindow &) = delete;
290+
PluginWindow(PluginWindow &&) = delete;
272291
virtual ~PluginWindow() override;
273292

293+
PluginWindow & operator = (const PluginWindow &) = delete;
294+
PluginWindow & operator = (PluginWindow &&) = delete;
295+
274296
/** Init widget
275297
*
276298
*/
@@ -288,8 +310,8 @@ namespace lsp
288310
virtual void end(ui::UIContext *ctx) override;
289311
virtual void notify(ui::IPort *port, size_t flags) override;
290312
};
291-
}
292-
}
313+
} /* namespace ctl */
314+
} /* namespace lsp */
293315

294316

295317

include/lsp-plug.in/plug-fw/ctl/graph/Mesh.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ namespace lsp
4747
ctl::Boolean sSmooth;
4848
ctl::Boolean sFill;
4949
ctl::Integer sStrobes;
50+
ctl::Integer sXAxis;
51+
ctl::Integer sYAxis;
5052

5153
ctl::Color sColor;
5254
ctl::Color sFillColor;

include/lsp-plug.in/plug-fw/ctl/specific/AudioSample.h

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (C) 2021 Linux Studio Plugins Project <https://lsp-plug.in/>
3-
* (C) 2021 Vladimir Sadovnikov <[email protected]>
2+
* Copyright (C) 2023 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2023 Vladimir Sadovnikov <[email protected]>
44
*
55
* This file is part of lsp-plugin-fw
66
* Created on: 20 июл. 2021 г.
@@ -87,6 +87,7 @@ namespace lsp
8787
ui::IPort *pPort;
8888
ui::IPort *pMeshPort;
8989
ui::IPort *pPathPort;
90+
ui::IPort *pFileTypePort;
9091
tk::FileDialog *pDialog;
9192
ctl::Widget *pFilePreview;
9293
tk::Menu *pMenu;
@@ -170,8 +171,13 @@ namespace lsp
170171

171172
public:
172173
explicit AudioSample(ui::IWrapper *wrapper, tk::AudioSample *widget);
174+
AudioSample(const AudioSample &) = delete;
175+
AudioSample(AudioSample &&) = delete;
173176
virtual ~AudioSample() override;
174177

178+
AudioSample & operator = (const AudioSample &) = delete;
179+
AudioSample & operator = (AudioSample &&) = delete;
180+
175181
virtual status_t init() override;
176182
virtual void destroy() override;
177183

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
/*
2+
* Copyright (C) 2023 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2023 Vladimir Sadovnikov <[email protected]>
4+
*
5+
* This file is part of lsp-plugin-fw
6+
* Created on: 19 дек. 2023 г.
7+
*
8+
* lsp-plugin-fw is free software: you can redistribute it and/or modify
9+
* it under the terms of the GNU Lesser General Public License as published by
10+
* the Free Software Foundation, either version 3 of the License, or
11+
* any later version.
12+
*
13+
* lsp-plugin-fw is distributed in the hope that it will be useful,
14+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
15+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16+
* GNU Lesser General Public License for more details.
17+
*
18+
* You should have received a copy of the GNU Lesser General Public License
19+
* along with lsp-plugin-fw. If not, see <https://www.gnu.org/licenses/>.
20+
*/
21+
22+
#ifndef LSP_PLUG_IN_PLUG_FW_CTL_SPECIFIC_DRYWETLINK_H_
23+
#define LSP_PLUG_IN_PLUG_FW_CTL_SPECIFIC_DRYWETLINK_H_
24+
25+
#ifndef LSP_PLUG_IN_PLUG_FW_CTL_IMPL_
26+
#error "Use #include <lsp-plug.in/plug-fw/ctl.h>"
27+
#endif /* LSP_PLUG_IN_PLUG_FW_CTL_IMPL_ */
28+
29+
#include <lsp-plug.in/plug-fw/version.h>
30+
#include <lsp-plug.in/tk/tk.h>
31+
32+
namespace lsp
33+
{
34+
namespace ctl
35+
{
36+
/**
37+
* Dry/Wet link controller
38+
*/
39+
class DryWetLink: public Button
40+
{
41+
public:
42+
static const ctl_class_t metadata;
43+
44+
protected:
45+
ui::IPort *pDry;
46+
ui::IPort *pWet;
47+
48+
protected:
49+
void sync_value(ui::IPort *dst, ui::IPort *src);
50+
static float get_gain(ui::IPort *port);
51+
static void set_gain(ui::IPort *port, float gain);
52+
53+
public:
54+
explicit DryWetLink(ui::IWrapper *wrapper, tk::Button *widget);
55+
DryWetLink(const DryWetLink &) = delete;
56+
DryWetLink(DryWetLink &&) = delete;
57+
virtual ~DryWetLink() override;
58+
59+
DryWetLink & operator = (const DryWetLink &) = delete;
60+
DryWetLink & operator = (DryWetLink &&) = delete;
61+
62+
public:
63+
virtual void set(ui::UIContext *ctx, const char *name, const char *value) override;
64+
virtual void notify(ui::IPort *port, size_t flags) override;
65+
};
66+
67+
} /* namespace ctl */
68+
} /* namespace lsp */
69+
70+
71+
72+
73+
#endif /* LSP_PLUG_IN_PLUG_FW_CTL_SPECIFIC_DRYWETLINK_H_ */

include/lsp-plug.in/plug-fw/ctl/specific/FileButton.h

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (C) 2021 Linux Studio Plugins Project <https://lsp-plug.in/>
3-
* (C) 2021 Vladimir Sadovnikov <[email protected]>
2+
* Copyright (C) 2023 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2023 Vladimir Sadovnikov <[email protected]>
44
*
55
* This file is part of lsp-plugin-fw
66
* Created on: 22 сент. 2021 г.
@@ -70,6 +70,7 @@ namespace lsp
7070
ui::IPort *pCommand; // Port that triggers command for save/load operation
7171
ui::IPort *pProgress; // Port that indicates the loading progress
7272
ui::IPort *pPathPort; // Port that contains the current navigation path of file dialog
73+
ui::IPort *pFileTypePort; // Port that contains the current selected file type
7374

7475
DragInSink *pDragInSink;
7576
tk::FileDialog *pDialog;
@@ -104,8 +105,13 @@ namespace lsp
104105

105106
public:
106107
explicit FileButton(ui::IWrapper *wrapper, tk::FileButton *widget, bool save);
108+
FileButton(const FileButton &) = delete;
109+
FileButton(FileButton &&) = delete;
107110
virtual ~FileButton() override;
108111

112+
FileButton & operator = (const FileButton &) = delete;
113+
FileButton & operator = (FileButton &&) = delete;
114+
109115
virtual status_t init() override;
110116

111117
public:

include/lsp-plug.in/plug-fw/meta/ports.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,8 @@
123123
{ id, label, U_GAIN_AMP, R_METER, F_OUT | F_LOG | F_UPPER | F_LOWER | F_PEAK, 0, max, dfl, 0, NULL, NULL }
124124
#define METER_OUT_GAIN(id, label, max) \
125125
{ id, label, U_GAIN_AMP, R_METER, F_OUT | F_LOG | F_UPPER | F_LOWER, 0, max, 0.0f, 0, NULL, NULL }
126+
#define LUFS_METER(id, label, max) \
127+
{ id, label, U_LUFS, R_METER, F_OUT | F_UPPER | F_LOWER, -72.0f, max, 0.0f, 0, NULL, NULL }
126128
#define METER_GAIN10(id, label) METER_GAIN(id, label, 10.0f)
127129
#define METER_GAIN20(id, label) METER_GAIN(id, label, 20.0f)
128130
#define METER_PERCENT(id, label) { id, label, U_PERCENT, R_METER, F_OUT | F_UPPER | F_LOWER, 0.0f, 100.0f, 0.0f, 0.1f, NULL, NULL }

include/lsp-plug.in/plug-fw/meta/types.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -409,6 +409,7 @@ namespace lsp
409409
{
410410
const char *name; // Plugin name
411411
const char *description; // Plugin description
412+
const char *vst2_name; // VST 2.x plugin name
412413
const char *acronym; // Plugin acronym
413414
const person_t *developer; // Developer
414415
const char *uid; // Unique character identifier of plugin

include/lsp-plug.in/plug-fw/ui/IPort.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
#include <lsp-plug.in/plug-fw/version.h>
3030
#include <lsp-plug.in/plug-fw/meta/types.h>
31-
#include <lsp-plug.in/lltl/parray.h>
31+
#include <lsp-plug.in/lltl/ptrset.h>
3232

3333
namespace lsp
3434
{
@@ -43,7 +43,7 @@ namespace lsp
4343
{
4444
protected:
4545
const meta::port_t *pMetadata;
46-
lltl::parray<IPortListener> vListeners;
46+
lltl::ptrset<IPortListener> vListeners;
4747

4848
public:
4949
explicit IPort(const meta::port_t *meta);
@@ -113,7 +113,7 @@ namespace lsp
113113

114114
/** Set single float value
115115
*
116-
* @param flags additional control flags
116+
* @param flags additional control flags @see port_flags_t
117117
*/
118118
virtual void set_value(float value, size_t flags);
119119

0 commit comments

Comments
 (0)