From 84d47f7d4c2d1355a6eb914dd091b39683f83c15 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Fri, 4 Dec 2020 07:35:40 -0800 Subject: [PATCH] Move the bsinc tables to core --- CMakeLists.txt | 6 +++--- alc/alu.cpp | 3 +-- alc/mixer/mixer_c.cpp | 4 ++-- alc/mixer/mixer_neon.cpp | 2 +- alc/mixer/mixer_sse.cpp | 2 +- {alc => core}/bsinc_defs.h | 6 +++--- {alc => core}/bsinc_tables.cpp | 1 - {alc => core}/bsinc_tables.h | 6 +++--- 8 files changed, 14 insertions(+), 16 deletions(-) rename {alc => core}/bsinc_defs.h (86%) rename {alc => core}/bsinc_tables.cpp (99%) rename {alc => core}/bsinc_tables.h (74%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7b4c044e..97004962 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -627,6 +627,9 @@ set(OPENAL_OBJS al/state.cpp ) set(ALC_OBJS + core/bsinc_defs.h + core/bsinc_tables.cpp + core/bsinc_tables.h core/bufferline.h core/devformat.cpp core/devformat.h @@ -647,9 +650,6 @@ set(ALC_OBJS alc/bformatdec.h alc/bs2b.cpp alc/bs2b.h - alc/bsinc_defs.h - alc/bsinc_tables.cpp - alc/bsinc_tables.h alc/buffer_storage.cpp alc/buffer_storage.h alc/compat.h diff --git a/alc/alu.cpp b/alc/alu.cpp index 5c532a05..18a26a38 100644 --- a/alc/alu.cpp +++ b/alc/alu.cpp @@ -59,6 +59,7 @@ #include "atomic.h" #include "bformatdec.h" #include "bs2b.h" +#include "core/bsinc_tables.h" #include "core/devformat.h" #include "core/mastering.h" #include "cpu_caps.h" @@ -80,8 +81,6 @@ #include "vecmat.h" #include "voice.h" -#include "bsinc_tables.h" - struct CTag; #ifdef HAVE_SSE struct SSETag; diff --git a/alc/mixer/mixer_c.cpp b/alc/mixer/mixer_c.cpp index c292235a..702401e6 100644 --- a/alc/mixer/mixer_c.cpp +++ b/alc/mixer/mixer_c.cpp @@ -5,8 +5,8 @@ #include #include "alcmain.h" -#include "alu.h" -#include "bsinc_defs.h" +#include "alnumeric.h" +#include "core/bsinc_tables.h" #include "defs.h" #include "hrtfbase.h" diff --git a/alc/mixer/mixer_neon.cpp b/alc/mixer/mixer_neon.cpp index bce2f4f8..631b0371 100644 --- a/alc/mixer/mixer_neon.cpp +++ b/alc/mixer/mixer_neon.cpp @@ -5,7 +5,7 @@ #include #include "alnumeric.h" -#include "bsinc_defs.h" +#include "core/bsinc_defs.h" #include "defs.h" #include "hrtfbase.h" diff --git a/alc/mixer/mixer_sse.cpp b/alc/mixer/mixer_sse.cpp index 858f5bff..c59e8579 100644 --- a/alc/mixer/mixer_sse.cpp +++ b/alc/mixer/mixer_sse.cpp @@ -5,7 +5,7 @@ #include #include "alnumeric.h" -#include "bsinc_defs.h" +#include "core/bsinc_defs.h" #include "defs.h" #include "hrtfbase.h" diff --git a/alc/bsinc_defs.h b/core/bsinc_defs.h similarity index 86% rename from alc/bsinc_defs.h rename to core/bsinc_defs.h index 179e025d..43865289 100644 --- a/alc/bsinc_defs.h +++ b/core/bsinc_defs.h @@ -1,5 +1,5 @@ -#ifndef BSINC_DEFS_H -#define BSINC_DEFS_H +#ifndef CORE_BSINC_DEFS_H +#define CORE_BSINC_DEFS_H /* The number of distinct scale and phase intervals within the filter table. */ constexpr unsigned int BSincScaleBits{4}; @@ -13,4 +13,4 @@ constexpr unsigned int BSincPhaseCount{1 << BSincPhaseBits}; */ constexpr unsigned int BSincPointsMax{48}; -#endif /* BSINC_DEFS_H */ +#endif /* CORE_BSINC_DEFS_H */ diff --git a/alc/bsinc_tables.cpp b/core/bsinc_tables.cpp similarity index 99% rename from alc/bsinc_tables.cpp rename to core/bsinc_tables.cpp index 893e9792..315e1448 100644 --- a/alc/bsinc_tables.cpp +++ b/core/bsinc_tables.cpp @@ -10,7 +10,6 @@ #include #include "math_defs.h" -#include "vector.h" namespace { diff --git a/alc/bsinc_tables.h b/core/bsinc_tables.h similarity index 74% rename from alc/bsinc_tables.h rename to core/bsinc_tables.h index 8e37336d..f52cda66 100644 --- a/alc/bsinc_tables.h +++ b/core/bsinc_tables.h @@ -1,5 +1,5 @@ -#ifndef BSINC_TABLES_H -#define BSINC_TABLES_H +#ifndef CORE_BSINC_TABLES_H +#define CORE_BSINC_TABLES_H #include "bsinc_defs.h" @@ -14,4 +14,4 @@ struct BSincTable { extern const BSincTable bsinc12; extern const BSincTable bsinc24; -#endif /* BSINC_TABLES_H */ +#endif /* CORE_BSINC_TABLES_H */