273 Commits

Author SHA1 Message Date
Chris Robinson
01f76f2b67 Allow intrusive_ptr::reset to take a new pointer 2020-08-24 14:09:26 -07:00
Chris Robinson
34b29a48a4 Ensure enough space is allocated for structs with a FlexArray 2020-08-15 23:53:43 -07:00
Chris Robinson
23259b48dd Avoid a zero-length array for the FlexArray definition
Newer GCCs are warning about FlexArray being used at the end of another struct.
Though not the most ideal to always allocate space for at least 1 element,
actual 0-sized uses are rare and for smaller element types.
2020-08-15 23:22:10 -07:00
Chris Robinson
8e7199cbb6 Avoid a cmake check for determining the size of long 2020-08-13 14:04:29 -07:00
Chris Robinson
fd52c828a9 Improve handling main() with UTF-8 args on Windows 2020-08-12 17:40:00 -07:00
Chris Robinson
c549797af0 Make osme things constexpr 2020-08-10 15:11:52 -07:00
Chris Robinson
02f8419663 Fix DIAGNOSTIC_POP for GCC and Clang 2020-08-06 23:20:20 -07:00
Chris Robinson
ac1fc1b60a Don't include headers in a namespace definition 2020-07-23 09:03:47 -07:00
Chris Robinson
f81558c948 Avoid including windows.h in threads.h 2020-06-28 12:55:55 -07:00
Chris Robinson
31791c9997 Workaround a MinGW quirk
Sometimes MinGW defines strncasecmp to _strnicmp in string.h, which can cause
problems with al::strncasecmp if it's not consistently replaced.
2020-06-26 05:39:26 -07:00
Chris Robinson
b7b52ec28b Simplify the aligned over-allocation strategy 2020-06-07 15:40:04 -07:00
Chris Robinson
9322c86e2f Avoid explicit checks for _BitScanForward[64] 2020-06-07 14:15:48 -07:00
Chris Robinson
c5e90ed6c7 Use an enum for FamCount 2020-05-19 12:15:57 -07:00
Chris Robinson
463591663c Check that aligned_alloc is available with cmake
Some compilers support C++17 even on targets that lack required functions.
Projects that want to force C++17 will then run into a problem with
std::aligned_alloc not existing on those targets, so it needs to be explicitly
checked for. The alternative is to simply never use it even when it would be
available.
2020-05-19 08:13:13 -07:00
Chris Robinson
0f81fafc62 Fix some standard calls 2020-05-16 01:21:09 -07:00
Chris Robinson
2574b98f8a Move the bsinc tables out of common 2020-05-11 02:24:08 -07:00
Chris Robinson
2fb4ac1621 Revert "Fix the FFT half point for the shifter effects"
This reverts commit 12bb5a47cda0ef6ec1ced73ccf5d267a71f9e710.
2020-05-09 16:44:29 -07:00
Chris Robinson
12bb5a47cd Fix the FFT half point for the shifter effects 2020-05-08 01:39:48 -07:00
Chris Robinson
047f1666d5 Fix subspan extent calculation 2020-04-28 19:58:17 -07:00
Chris Robinson
78e789bf7b Silence a type conversion warning with GCC 2020-04-14 12:05:54 -07:00
Chris Robinson
6ac5816354 Avoid inlining some potentially costly calls 2020-04-14 11:50:59 -07:00
Chris Robinson
f7380a44d4 Use a common base for a couple exceptions 2020-04-10 15:12:57 -07:00
Chris Robinson
e123fa0ec3 Apply some alloc and alignment attributes 2020-04-10 11:05:25 -07:00
Chris Robinson
97c11577cd Make a default/empty constructor noexcept 2020-04-09 19:32:02 -07:00
Chris Robinson
efed431237 Use a unique_ptr for constructing the bsinc table coefficients 2020-04-07 08:30:37 -07:00
Chris Robinson
2fcc3f3887 Dynamically allocate the temporary bsinc filter table 2020-04-06 17:12:39 -07:00
Chris Robinson
baf14aad2a Pass the BSincHeader by reference instead of value 2020-04-05 23:08:02 -07:00
Chris Robinson
25464b2210 Avoid storing the bsinc coefficient deltas before output
This cuts the majority of stack use when generating the coefficients.
2020-04-04 22:04:59 -07:00
Chris Robinson
ee89ca1bdd Fix bsinc filter alignment and offsets 2020-04-02 02:13:18 -07:00
Chris Robinson
57109902cd Avoid std::abs in a constexpr function 2020-04-02 01:52:07 -07:00
Chris Robinson
8853519d89 Generate the bsinc tables using constexpr methods
All the methods used should be compliant with C++14 constexpr rules. However,
the number of scales and phases cause GenerateBSincCoeffs to reach the allowed
step limit, preventing full compile-time generation. It's not a terribly big
deal, it'll generate them very quickly when loading, but it does prevent using
shared read-only memory pages.
2020-04-02 00:49:19 -07:00
Chris Robinson
6fb59f1182 Avoid using M_PI 2020-04-01 22:22:50 -07:00
Chris Robinson
c24d127229 Avoid non-namespace template specialization 2020-03-24 12:03:07 -07:00
Chris Robinson
eed8407599 Remove some unused functions 2020-03-23 17:18:11 -07:00
Chris Robinson
6a3b3b180b Add a macro to disable class-specific new/delete 2020-03-23 16:00:50 -07:00
Chris Robinson
5d0f90fed0 Avoid ## in a macro
Cppcheck thinks it's an invalid use of it
2020-03-23 14:26:00 -07:00
Chris Robinson
132a69c03d Use more appropriate types for bitfields 2020-03-22 21:34:50 -07:00
Chris Robinson
46234171d1 Clean up some C++11-isms 2020-03-22 21:15:12 -07:00
Chris Robinson
49b2d703e7 Properly define the new[] and delete[] operators 2020-03-22 13:28:45 -07:00
Chris Robinson
9ce182228d Avoid some pre-C++14 workarounds 2020-03-22 08:51:06 -07:00
Chris Robinson
819763a6c2 Fix some 'ambiguous' calls for newer MSVC 2020-01-06 01:40:21 -08:00
Chris Robinson
e9ee6dd239 Ensure a pointer is provided for a templated iterator type 2020-01-05 23:17:26 -08:00
Chris Robinson
06b7c63cef Fix reverse iterators for spans 2019-12-25 21:48:40 -08:00
Chris Robinson
7b3f88c430 Avoid extraneous looping 2019-11-29 05:52:33 -08:00
Chris Robinson
c093728ced Move the polyphase resampler to the common lib 2019-11-28 10:54:47 -08:00
Chris Robinson
697da8724f Avoid an extraneous macro and use a simplified type alias 2019-10-27 00:47:33 -07:00
Chris Robinson
0cba99ed1b Avoid static constexpr for arrays iterated over at run-time 2019-10-25 01:43:23 -07:00
Chris Robinson
f8ff4e269b Put the pragma defines in a separate header 2019-10-07 15:26:35 -07:00
Chris Robinson
4620912f0f Don't inline the utf8 converters 2019-10-01 23:33:00 -07:00
Chris Robinson
0063f4bfac Add some allocator fields GCC 6.3 seems to want 2019-10-01 01:49:21 -07:00