Skip to content

Commit 111106e

Browse files
committed
Release 0.5.12
* Submitted x86/x86_64 SSE2-optimized linear interpolation functions. * Submitted x86/x86_64 AVX2-optimized linear interpolation functions. * Submitted ARMv7 NEON-optimized linear interpolation functions. * Submitted AArch64 ASIMD-optimized linear interpolation functions. * Updated build system.
2 parents d22937c + 715b87f commit 111106e

File tree

32 files changed

+5766
-409
lines changed

32 files changed

+5766
-409
lines changed

CHANGELOG

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

5+
=== 0.5.12 ===
6+
* Submitted x86/x86_64 SSE2-optimized linear interpolation functions.
7+
* Submitted x86/x86_64 AVX2-optimized linear interpolation functions.
8+
* Submitted ARMv7 NEON-optimized linear interpolation functions.
9+
* Submitted AArch64 ASIMD-optimized linear interpolation functions.
10+
* Updated build system.
11+
512
=== 0.5.11 ===
613
* Improved build: fixed many GCC warnings.
714
* DSP library can now be compiled with Clang C++ compiler.

Makefile

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -57,18 +57,18 @@ clean:
5757
fetch:
5858
@$(CHK_CONFIG)
5959
@echo "Fetching desired source code dependencies"
60-
@$(MAKE) -s -f "make/modules.mk" $(@) BASEDIR="$(BASEDIR)" CONFIG="$(CONFIG)"
60+
@$(MAKE) -s -f "$(BASEDIR)/make/modules.mk" $(@) BASEDIR="$(BASEDIR)" CONFIG="$(CONFIG)"
6161
@echo "Fetch OK"
6262

6363
tree:
6464
@echo "Fetching all possible source code dependencies"
65-
@$(MAKE) -s -f "make/modules.mk" $(@) BASEDIR="$(BASEDIR)" TREE="1"
65+
@$(MAKE) -s -f "$(BASEDIR)/make/modules.mk" $(@) BASEDIR="$(BASEDIR)" TREE="1"
6666
@echo "Fetch OK"
6767

6868
prune: clean
6969
@echo "Pruning the whole project tree"
70-
@$(MAKE) -s -f "make/modules.mk" prune BASEDIR="$(BASEDIR)" CONFIG="$(CONFIG)"
71-
@$(MAKE) -s -f "make/modules.mk" prune BASEDIR="$(BASEDIR)" TREE="1"
70+
@$(MAKE) -s -f "$(BASEDIR)/make/modules.mk" prune BASEDIR="$(BASEDIR)" CONFIG="$(CONFIG)"
71+
@$(MAKE) -s -f "$(BASEDIR)/make/modules.mk" prune BASEDIR="$(BASEDIR)" TREE="1"
7272
@-rm -rf "$(CONFIG)"
7373
@echo "Prune OK"
7474

@@ -86,7 +86,7 @@ config:
8686
distsrc:
8787
@echo "Building source code archive"
8888
@mkdir -p "$(DISTSRC)/modules"
89-
@$(MAKE) -s -f "make/modules.mk" tree BASEDIR="$(BASEDIR)" MODULES="$(DISTSRC)/modules" TREE="1"
89+
@$(MAKE) -s -f "$(BASEDIR)/make/modules.mk" tree BASEDIR="$(BASEDIR)" MODULES="$(DISTSRC)/modules" TREE="1"
9090
@cp -R $(BASEDIR)/include $(BASEDIR)/make $(BASEDIR)/src "$(DISTSRC)/"
9191
@cp $(BASEDIR)/CHANGELOG $(BASEDIR)/COPYING* $(BASEDIR)/Makefile $(BASEDIR)/*.mk "$(DISTSRC)/"
9292
@find "$(DISTSRC)" -iname '.git' | xargs -exec rm -rf {}

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ Current set of functions provided:
2929
* Mid/Side matrix functions for converting Stereo channel to Mid/Side and back;
3030
* Functions for searching minimums and maximums;
3131
* Resampling functions based on Lanczos filter;
32+
* Interpolation functions;
3233
* Some set of function to work with 3D mathematics.
3334

3435
Supported platforms

dependencies.mk

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

2121
# Variables that describe dependencies
22-
LSP_COMMON_LIB_VERSION := 1.0.11
22+
LSP_COMMON_LIB_VERSION := 1.0.12
2323
LSP_COMMON_LIB_NAME := lsp-common-lib
2424
LSP_COMMON_LIB_TYPE := src
2525
LSP_COMMON_LIB_URL := https://github.com/sadko4u/$(LSP_COMMON_LIB_NAME).git
2626

27-
LSP_TEST_FW_VERSION := 1.0.6
27+
LSP_TEST_FW_VERSION := 1.0.7
2828
LSP_TEST_FW_NAME := lsp-test-fw
2929
LSP_TEST_FW_TYPE := src
3030
LSP_TEST_FW_URL := https://github.com/sadko4u/$(LSP_TEST_FW_NAME).git
3131

32-
STDLIB_VERSION := system
33-
STDLIB_TYPE := opt
34-
STDLIB_LDFLAGS := -lpthread
32+
LIBPTHREAD_VERSION := system
33+
LIBPTHREAD_NAME := libpthread
34+
LIBPTHREAD_TYPE := opt
35+
LIBPTHREAD_LDFLAGS := -lpthread
3536

36-
ifeq ($(PLATFORM),Windows)
37-
TEST_STDLIB_VERSION := system
38-
TEST_STDLIB_TYPE := opt
39-
TEST_STDLIB_LDFLAGS := -lshlwapi
40-
else
41-
TEST_STDLIB_VERSION := system
42-
TEST_STDLIB_TYPE := opt
43-
TEST_STDLIB_LDFLAGS :=
44-
endif
37+
LIBSHLWAPI_VERSION := system
38+
LIBSHLWAPI_NAME := libshlwapi
39+
LIBSHLWAPI_TYPE := opt
40+
LIBSHLWAPI_LDFLAGS := -lshlwapi
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/*
2+
* Copyright (C) 2020 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2020 Vladimir Sadovnikov <[email protected]>
4+
*
5+
* This file is part of lsp-dsp-lib
6+
* Created on: 13 дек. 2020 г.
7+
*
8+
* lsp-dsp-lib 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-dsp-lib 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-dsp-lib. If not, see <https://www.gnu.org/licenses/>.
20+
*/
21+
22+
#ifndef LSP_PLUG_IN_DSP_COMMON_INTERPOLATION_H_
23+
#define LSP_PLUG_IN_DSP_COMMON_INTERPOLATION_H_
24+
25+
#include <lsp-plug.in/dsp/common/interpolation/linear.h>
26+
27+
#endif /* INCLUDE_LSP_PLUG_IN_DSP_COMMON_INTERPOLATION_H_ */
Lines changed: 136 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,136 @@
1+
/*
2+
* Copyright (C) 2020 Linux Studio Plugins Project <https://lsp-plug.in/>
3+
* (C) 2020 Vladimir Sadovnikov <[email protected]>
4+
*
5+
* This file is part of lsp-dsp-lib
6+
* Created on: 13 дек. 2020 г.
7+
*
8+
* lsp-dsp-lib 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-dsp-lib 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-dsp-lib. If not, see <https://www.gnu.org/licenses/>.
20+
*/
21+
22+
#ifndef LSP_PLUG_IN_DSP_COMMON_INTERPOLATION_LINEAR_H_
23+
#define LSP_PLUG_IN_DSP_COMMON_INTERPOLATION_LINEAR_H_
24+
25+
/**
26+
* Perform linear interpolation of x values defined by initial points:
27+
*
28+
* dst[i] = interp[i]
29+
* interp[i] = y0 + ((x[i] - x0) * (y1 - y0)) / (x1 - x0)
30+
*
31+
* @param dst destination buffer to store interpolated values
32+
* @param x0 the x coordinate of first initial point
33+
* @param y0 the y coordinate of first initial point
34+
* @param x1 the x coordinate of second initial point
35+
* @param y1 the y coordinate of second initial point
36+
* @param x the initial coordinate of X point
37+
* @param n number of x'es to process
38+
*/
39+
LSP_DSP_LIB_SYMBOL(void, lin_inter_set, float *dst, int32_t x0, float y0, int32_t x1, float y1, int32_t x, uint32_t n);
40+
41+
/**
42+
* Perform linear interpolation of x values defined by initial points and multiply
43+
* them by the samples stored in destination buffer
44+
*
45+
* dst[i] = src[i] * interp[i]
46+
* interp[i] = y0 + ((x[i] - x0) * (y1 - y0)) / (x1 - x0)
47+
*
48+
* @param dst destination buffer to apply multiplication by interpolated values
49+
* @param x0 the x coordinate of first initial point
50+
* @param y0 the y coordinate of first initial point
51+
* @param x1 the x coordinate of second initial point
52+
* @param y1 the y coordinate of second initial point
53+
* @param x the initial coordinate of X point
54+
* @param n number of x'es to process
55+
*/
56+
LSP_DSP_LIB_SYMBOL(void, lin_inter_mul2, float *dst, int32_t x0, float y0, int32_t x1, float y1, int32_t x, uint32_t n);
57+
58+
/**
59+
* Perform linear interpolation of x values defined by initial points, multiply
60+
* them by the samples stored in source buffer and store values to destination buffer
61+
*
62+
* dst[i] = src[i] * interp[i]
63+
* interp[i] = y0 + ((x[i] - x0) * (y1 - y0)) / (x1 - x0)
64+
*
65+
* @param dst destination buffer to store the result
66+
* @param src source buffer to apply multiplication by interpolated values
67+
* @param x0 the x coordinate of first initial point
68+
* @param y0 the y coordinate of first initial point
69+
* @param x1 the x coordinate of second initial point
70+
* @param y1 the y coordinate of second initial point
71+
* @param x the initial coordinate of X point
72+
* @param n number of x'es to process
73+
*/
74+
LSP_DSP_LIB_SYMBOL(void, lin_inter_mul3, float *dst, const float *src, int32_t x0, float y0, int32_t x1, float y1, int32_t x, uint32_t n);
75+
76+
/**
77+
* Perform linear interpolation of x values defined by initial points, multiply
78+
* them by the samples stored in first source buffer and add values to values
79+
* stored in the destination buffer:
80+
*
81+
* dst[i] = src[i] * interp[i] + dst[i]
82+
* interp[i] = y0 + ((x[i] - x0) * (y1 - y0)) / (x1 - x0)
83+
*
84+
* @param dst destination buffer to add the result
85+
* @param src source buffer to apply multiplication by interpolated values
86+
* @param x0 the x coordinate of first initial point
87+
* @param y0 the y coordinate of first initial point
88+
* @param x1 the x coordinate of second initial point
89+
* @param y1 the y coordinate of second initial point
90+
* @param x the initial coordinate of X point
91+
* @param n number of x'es to process
92+
*/
93+
LSP_DSP_LIB_SYMBOL(void, lin_inter_fmadd2, float *dst, const float *src, int32_t x0, float y0, int32_t x1, float y1, int32_t x, uint32_t n);
94+
95+
/**
96+
* Perform linear interpolation of x values defined by initial points, multiply
97+
* them by the samples stored in destination source buffer, add values stored in
98+
* source buffer and store result in destination buffer
99+
*
100+
* dst[i] = dst[i] * interp[i] + src[i]
101+
* interp[i] = y0 + ((x[i] - x0) * (y1 - y0)) / (x1 - x0)
102+
*
103+
* @param dst destination buffer to add the result
104+
* @param src source buffer to apply multiplication by interpolated values
105+
* @param x0 the x coordinate of first initial point
106+
* @param y0 the y coordinate of first initial point
107+
* @param x1 the x coordinate of second initial point
108+
* @param y1 the y coordinate of second initial point
109+
* @param x the initial coordinate of X point
110+
* @param n number of x'es to process
111+
*/
112+
LSP_DSP_LIB_SYMBOL(void, lin_inter_frmadd2, float *dst, const float *src, int32_t x0, float y0, int32_t x1, float y1, int32_t x, uint32_t n);
113+
114+
/**
115+
* Perform linear interpolation of x values defined by initial points, multiply
116+
* them by the samples stored in first source buffer, add values from second source
117+
* buffer and store values to destination buffer
118+
*
119+
* dst[i] = src1[i] * interp[i] + src2[i]
120+
* interp[i] = y0 + ((x[i] - x0) * (y1 - y0)) / (x1 - x0)
121+
*
122+
* @param dst destination buffer to store the result
123+
* @param src1 source buffer to apply multiplication by interpolated values
124+
* @param src2 source buffer to use for addition
125+
* @param x0 the x coordinate of first initial point
126+
* @param y0 the y coordinate of first initial point
127+
* @param x1 the x coordinate of second initial point
128+
* @param y1 the y coordinate of second initial point
129+
* @param x the initial coordinate of X point
130+
* @param n number of x'es to process
131+
*/
132+
LSP_DSP_LIB_SYMBOL(void, lin_inter_fmadd3, float *dst, const float *src1, const float *src2, int32_t x0, float y0, int32_t x1, float y1, int32_t x, uint32_t n);
133+
134+
135+
136+
#endif /* LSP_PLUG_IN_DSP_COMMON_INTERPOLATION_LINEAR_H_ */

include/lsp-plug.in/dsp/dsp.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@
6060
#include <lsp-plug.in/dsp/common/resampling.h>
6161
#include <lsp-plug.in/dsp/common/search.h>
6262
#include <lsp-plug.in/dsp/common/smath.h>
63+
#include <lsp-plug.in/dsp/common/interpolation.h>
6364

6465
#undef LSP_DSP_LIB_CXX_IFACE
6566

include/lsp-plug.in/dsp/version.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
// Define version of headers
2626
#define LSP_DSP_LIB_MAJOR 0
2727
#define LSP_DSP_LIB_MINOR 5
28-
#define LSP_DSP_LIB_MICRO 11
28+
#define LSP_DSP_LIB_MICRO 12
2929

3030
#ifdef LSP_DSP_LIB_BUILTIN
3131
#define LSP_DSP_LIB_CPPEXPORT

0 commit comments

Comments
 (0)