Skip to content

Commit 8341136

Browse files
committed
Release 1.0.33
* Added listen button that allows to feed audio sample preview to direct outputs. * Offline tasks are optimized for better floating-point computing. * Updated build scripts and dependencies.
2 parents 458ed4f + 66c95fb commit 8341136

11 files changed

Lines changed: 86 additions & 50 deletions

File tree

CHANGELOG

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

5+
=== 1.0.33 ===
6+
* Added listen button that allows to feed audio sample preview to direct outputs.
7+
* Offline tasks are optimized for better floating-point computing.
8+
* Updated build scripts and dependencies.
9+
510
=== 1.0.32 ===
611
* Updated build scripts and dependencies.
712

include/private/plugins/sampler.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,8 @@ namespace lsp
4747
enum dm_mode_t
4848
{
4949
DM_APPLY_GAIN = 1 << 0,
50-
DM_APPLY_PAN = 1 << 1
50+
DM_APPLY_PAN = 1 << 1,
51+
DM_APPLY_LISTEN = 1 << 2
5152
};
5253

5354
typedef struct sampler_channel_t
@@ -129,6 +130,7 @@ namespace lsp
129130
plug::IPort *pInstSel; // Instrument selector
130131
plug::IPort *pDOGain; // Direct output gain flag
131132
plug::IPort *pDOPan; // Direct output panning flag
133+
plug::IPort *pDOListen; // Direct output listen flag
132134

133135
protected:
134136
void process_trigger_events();

modules.mk

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -19,62 +19,62 @@
1919
#
2020

2121
# Variables that describe dependencies
22-
LSP_3RD_PARTY_VERSION := 1.0.24
22+
LSP_3RD_PARTY_VERSION := 1.0.25
2323
LSP_3RD_PARTY_NAME := lsp-3rd-party
2424
LSP_3RD_PARTY_TYPE := hdr
2525
LSP_3RD_PARTY_INC_OPT := -idirafter
2626
LSP_3RD_PARTY_URL_RO := https://github.com/lsp-plugins/$(LSP_3RD_PARTY_NAME).git
2727
LSP_3RD_PARTY_URL_RW := git@github.com:lsp-plugins/$(LSP_3RD_PARTY_NAME).git
2828

29-
LSP_COMMON_LIB_VERSION := 1.0.43
29+
LSP_COMMON_LIB_VERSION := 1.0.44
3030
LSP_COMMON_LIB_NAME := lsp-common-lib
3131
LSP_COMMON_LIB_TYPE := src
3232
LSP_COMMON_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_COMMON_LIB_NAME).git
3333
LSP_COMMON_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_COMMON_LIB_NAME).git
3434

35-
LSP_DSP_LIB_VERSION := 1.0.32
35+
LSP_DSP_LIB_VERSION := 1.0.33
3636
LSP_DSP_LIB_NAME := lsp-dsp-lib
3737
LSP_DSP_LIB_TYPE := src
3838
LSP_DSP_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_DSP_LIB_NAME).git
3939
LSP_DSP_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_DSP_LIB_NAME).git
4040

41-
LSP_DSP_UNITS_VERSION := 1.0.32
41+
LSP_DSP_UNITS_VERSION := 1.0.33
4242
LSP_DSP_UNITS_NAME := lsp-dsp-units
4343
LSP_DSP_UNITS_TYPE := src
4444
LSP_DSP_UNITS_URL_RO := https://github.com/lsp-plugins/$(LSP_DSP_UNITS_NAME).git
4545
LSP_DSP_UNITS_URL_RW := git@github.com:lsp-plugins/$(LSP_DSP_UNITS_NAME).git
4646

47-
LSP_LLTL_LIB_VERSION := 1.0.27
47+
LSP_LLTL_LIB_VERSION := 1.0.28
4848
LSP_LLTL_LIB_NAME := lsp-lltl-lib
4949
LSP_LLTL_LIB_TYPE := src
5050
LSP_LLTL_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_LLTL_LIB_NAME).git
5151
LSP_LLTL_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_LLTL_LIB_NAME).git
5252

53-
LSP_R3D_BASE_LIB_VERSION := 1.0.25
53+
LSP_R3D_BASE_LIB_VERSION := 1.0.26
5454
LSP_R3D_BASE_LIB_NAME := lsp-r3d-base-lib
5555
LSP_R3D_BASE_LIB_TYPE := src
5656
LSP_R3D_BASE_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_BASE_LIB_NAME).git
5757
LSP_R3D_BASE_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_R3D_BASE_LIB_NAME).git
5858

59-
LSP_R3D_IFACE_VERSION := 1.0.25
59+
LSP_R3D_IFACE_VERSION := 1.0.26
6060
LSP_R3D_IFACE_NAME := lsp-r3d-iface
6161
LSP_R3D_IFACE_TYPE := src
6262
LSP_R3D_IFACE_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_IFACE_NAME).git
6363
LSP_R3D_IFACE_URL_RW := git@github.com:lsp-plugins/$(LSP_R3D_IFACE_NAME).git
6464

65-
LSP_R3D_GLX_LIB_VERSION := 1.0.25
65+
LSP_R3D_GLX_LIB_VERSION := 1.0.26
6666
LSP_R3D_GLX_LIB_NAME := lsp-r3d-glx-lib
6767
LSP_R3D_GLX_LIB_TYPE := bin
6868
LSP_R3D_GLX_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_GLX_LIB_NAME).git
6969
LSP_R3D_GLX_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_R3D_GLX_LIB_NAME).git
7070

71-
LSP_R3D_WGL_LIB_VERSION := 1.0.20
71+
LSP_R3D_WGL_LIB_VERSION := 1.0.21
7272
LSP_R3D_WGL_LIB_NAME := lsp-r3d-wgl-lib
7373
LSP_R3D_WGL_LIB_TYPE := bin
7474
LSP_R3D_WGL_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_WGL_LIB_NAME).git
7575
LSP_R3D_WGL_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_R3D_WGL_LIB_NAME).git
7676

77-
LSP_RUNTIME_LIB_VERSION := 1.0.30
77+
LSP_RUNTIME_LIB_VERSION := 1.0.31
7878
LSP_RUNTIME_LIB_NAME := lsp-runtime-lib
7979
LSP_RUNTIME_LIB_TYPE := src
8080
LSP_RUNTIME_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_RUNTIME_LIB_NAME).git
@@ -86,26 +86,26 @@ LSP_TEST_FW_TYPE := src
8686
LSP_TEST_FW_URL_RO := https://github.com/lsp-plugins/$(LSP_TEST_FW_NAME).git
8787
LSP_TEST_FW_URL_RW := git@github.com:lsp-plugins/$(LSP_TEST_FW_NAME).git
8888

89-
LSP_TK_LIB_VERSION := 1.0.30
89+
LSP_TK_LIB_VERSION := 1.0.31
9090
LSP_TK_LIB_NAME := lsp-tk-lib
9191
LSP_TK_LIB_TYPE := src
9292
LSP_TK_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_TK_LIB_NAME).git
9393
LSP_TK_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_TK_LIB_NAME).git
9494

95-
LSP_WS_LIB_VERSION := 1.0.30
95+
LSP_WS_LIB_VERSION := 1.0.31
9696
LSP_WS_LIB_NAME := lsp-ws-lib
9797
LSP_WS_LIB_TYPE := src
9898
LSP_WS_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_WS_LIB_NAME).git
9999
LSP_WS_LIB_URL_RW := git@github.com:lsp-plugins/$(LSP_WS_LIB_NAME).git
100100

101101
# Plugin-related module dependencies
102-
LSP_PLUGIN_FW_VERSION := 1.0.33
102+
LSP_PLUGIN_FW_VERSION := 1.0.34
103103
LSP_PLUGIN_FW_NAME := lsp-plugin-fw
104104
LSP_PLUGIN_FW_TYPE := src
105105
LSP_PLUGIN_FW_URL_RO := https://github.com/lsp-plugins/$(LSP_PLUGIN_FW_NAME).git
106106
LSP_PLUGIN_FW_URL_RW := git@github.com:lsp-plugins/$(LSP_PLUGIN_FW_NAME).git
107107

108-
LSP_PLUGINS_SHARED_VERSION := 1.0.32
108+
LSP_PLUGINS_SHARED_VERSION := 1.0.33
109109
LSP_PLUGINS_SHARED_NAME := lsp-plugins-shared
110110
LSP_PLUGINS_SHARED_TYPE := src
111111
LSP_PLUGINS_SHARED_URL_RO := https://github.com/lsp-plugins/$(LSP_PLUGINS_SHARED_NAME).git

project.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ARTIFACT_TYPE = plug
2525
ARTIFACT_DESC = LSP Sampler Plugin Series
2626
ARTIFACT_HEADERS = lsp-plug.in
2727
ARTIFACT_EXPORT_HEADERS = 0
28-
ARTIFACT_VERSION = 1.0.32
28+
ARTIFACT_VERSION = 1.0.33
2929

3030

3131

res/main/ui/sampling/multiple.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
<label text="labels.direct_output_" pad.l="12"/>
1616
<button text="labels.gain" id="do_gain" ui:inject="Button_magenta"/>
1717
<button text="labels.panning" id="do_pan" ui:inject="Button_yellow"/>
18+
<button text="labels.listen" id="do_lstn" ui:inject="Button_green"/>
1819
</ui:if>
1920
<void hexpand="true"/>
2021
</hbox>

src/doc/manuals/plugins/multisampler.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,14 @@
9797
<ul>
9898
<li><b>Bypass</b> - hot bypass switch, when turned on (led indicator is shining), the plugin does not affect the input signal.</li>
9999
<li><b>Workspace</b> - combo box that allows to switch between instrument setup and instrument mixer.</li>
100+
<?php if ($do) { ?>
101+
<li><b>Direct output</b> - set of buttons that allow to control the behaviour of all direct outputs:</li>
102+
<ul>
103+
<li><b>Gain</b> - the loudness of the instrument is also applied to direct output signal.</li>
104+
<li><b>Panning</b> - the panning of the instrument is also applied to direct output signal.</li>
105+
<li><b>Listen</b> - the sound of sample preview is also fed to direct output.</li>
106+
</ul>
107+
<?php } ?>
100108
</ul>
101109

102110
<p><b>'Instrument mixer' section:</b></p>

src/main/meta/sampler.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626

2727
#define LSP_PLUGINS_SAMPLER_VERSION_MAJOR 1
2828
#define LSP_PLUGINS_SAMPLER_VERSION_MINOR 0
29-
#define LSP_PLUGINS_SAMPLER_VERSION_MICRO 32
29+
#define LSP_PLUGINS_SAMPLER_VERSION_MICRO 33
3030

3131
#define LSP_PLUGINS_SAMPLER_VERSION \
3232
LSP_MODULE_VERSION( \
@@ -39,6 +39,10 @@ namespace lsp
3939
{
4040
namespace meta
4141
{
42+
// Lisf of different revisions for adding controls
43+
#define REV_0 0
44+
#define REV_1 1
45+
4246
//-------------------------------------------------------------------------
4347
// Sampler
4448
static const port_item_t sampler_sample_selectors[] =
@@ -238,7 +242,8 @@ namespace lsp
238242

239243
#define S_DO_CONTROL \
240244
SWITCH("do_gain", "Apply gain to direct-out", "DOut gain on", 1.0f), \
241-
SWITCH("do_pan", "Apply panning to direct-out", "DOut pan on", 1.0f)
245+
SWITCH("do_pan", "Apply panning to direct-out", "DOut pan on", 1.0f), \
246+
ADDON_SWITCH(REV_1, "do_lstn", "Pass listen events to direct-out", "DOut listen on", 0.0f)
242247

243248
#define S_SAMPLE_FILE(gain) \
244249
PATH("sf", "Sample file"), \

src/main/plug/sampler.cpp

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ namespace lsp
122122
pInstSel = NULL;
123123
pDOGain = NULL;
124124
pDOPan = NULL;
125+
pDOListen = NULL;
125126
}
126127

127128
sampler::~sampler()
@@ -243,6 +244,7 @@ namespace lsp
243244
{
244245
BIND_PORT(pDOGain);
245246
BIND_PORT(pDOPan);
247+
BIND_PORT(pDOListen);
246248
}
247249

248250
// If number of samplers <= 2 - skip area selector
@@ -421,6 +423,8 @@ namespace lsp
421423
nDOMode |= DM_APPLY_GAIN;
422424
if ((pDOPan != NULL) && (pDOPan->value() >= 0.5f))
423425
nDOMode |= DM_APPLY_PAN;
426+
if ((pDOListen != NULL) && (pDOListen->value() >= 0.5f))
427+
nDOMode |= DM_APPLY_LISTEN;
424428

425429
lsp_trace("muting=%s", (bMuting) ? "true" : "false");
426430
lsp_trace("note_off=%s", (note_off) ? "true" : "false");
@@ -697,27 +701,33 @@ namespace lsp
697701
// Now post-process all channels for sampler
698702
for (size_t j=0; j<nChannels; ++j)
699703
{
700-
sampler_channel_t *c = &s->vChannels[j];
704+
sampler_channel_t * const c1 = &s->vChannels[j];
705+
sampler_channel_t * const c2 = &s->vChannels[j ^ 1];
701706

702707
// Copy data to direct output buffer if present
703708
float gain = (nDOMode & DM_APPLY_GAIN) ? s->fGain : 1.0f;
704-
float pan = (nDOMode & DM_APPLY_PAN) ? c->fPan : 1.0f;
705-
if (s->vChannels[j].vDry != NULL)
706-
dsp::fmadd_k3(s->vChannels[j].vDry, tmp_outs[j], pan * gain, count);
707-
if (s->vChannels[j^1].vDry != NULL)
708-
dsp::fmadd_k3(s->vChannels[j^1].vDry, tmp_outs[j], (1.0f - pan) * gain, count);
709+
float pan = (nDOMode & DM_APPLY_PAN) ? c1->fPan : 1.0f;
710+
711+
if (c1->vDry != NULL)
712+
{
713+
dsp::fmadd_k3(c1->vDry, tmp_outs[j], pan * gain, count);
714+
if (nDOMode & DM_APPLY_LISTEN)
715+
dsp::add2(c1->vDry, tmp_listen[j], count);
716+
}
717+
if (c2->vDry != NULL)
718+
dsp::fmadd_k3(c2->vDry, tmp_outs[j], (1.0f - pan) * gain, count);
709719

710720
// Process output
711-
c->sBypass.process(tmp_outs[j], NULL, tmp_outs[j], count);
721+
c1->sBypass.process(tmp_outs[j], NULL, tmp_outs[j], count);
712722
dsp::add2(tmp_outs[j], tmp_listen[j], count);
713723

714724
// Mix output to common sampler's bus
715725
if (vChannels[j].vOut != NULL)
716-
dsp::fmadd_k3(vChannels[j].vOut, tmp_outs[j], c->fPan * s->fGain, count);
726+
dsp::fmadd_k3(vChannels[j].vOut, tmp_outs[j], c1->fPan * s->fGain, count);
717727

718728
// Apply pan to the other stereo channel (if present)
719729
if (vChannels[j^1].vOut != NULL)
720-
dsp::fmadd_k3(vChannels[j^1].vOut, tmp_outs[j], (1.0f - c->fPan) * s->fGain, count);
730+
dsp::fmadd_k3(vChannels[j^1].vOut, tmp_outs[j], (1.0f - c1->fPan) * s->fGain, count);
721731
}
722732

723733
// Post-process dry channels

src/main/plug/sampler_kernel.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,10 @@ namespace lsp
5050

5151
status_t sampler_kernel::AFLoader::run()
5252
{
53+
dsp::context_t ctx;
54+
dsp::start(&ctx);
55+
lsp_finally { dsp::finish(&ctx); };
56+
5357
return pCore->load_file(pFile);
5458
};
5559

@@ -74,6 +78,10 @@ namespace lsp
7478

7579
status_t sampler_kernel::AFRenderer::run()
7680
{
81+
dsp::context_t ctx;
82+
dsp::start(&ctx);
83+
lsp_finally { dsp::finish(&ctx); };
84+
7785
return pCore->render_sample(pFile);
7886
};
7987

src/main/ui/sampler.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1648,7 +1648,10 @@ namespace lsp
16481648

16491649
// Obtain the parent directory
16501650
io::Path basedir;
1651-
io::Path *base = (path->get_parent(&basedir) == STATUS_OK) ? &basedir : NULL;
1651+
size_t flags = ui::EXPORT_FLAG_USER_FRIENDLY;
1652+
io::Path *base = (path->get_parent(&basedir) == STATUS_OK) ? &basedir : NULL;
1653+
if (base != NULL)
1654+
flags |= ui::EXPORT_FLAG_RELATIVE_PATHS;
16521655

16531656
// Create LSPC file
16541657
lspc::File fd;
@@ -1674,7 +1677,7 @@ namespace lsp
16741677
}
16751678

16761679
// Call wrapper to serialize
1677-
if ((res = pWrapper->export_settings(&s, base)) != STATUS_OK)
1680+
if ((res = pWrapper->export_settings(&s, flags, base)) != STATUS_OK)
16781681
{
16791682
s.close();
16801683
fd.close();

0 commit comments

Comments
 (0)