Commit Graph

15 Commits (master)

Author SHA1 Message Date
Chris Robinson f2ff2bb2f6 Use the difference in HF scale for upsampling ambisonics 2022-09-03 21:06:39 -07:00
Chris Robinson e5c49d019f Revert "Don't apply the HF scaling for "upsampling" ambisonics"
This reverts commit bf3f63fb4c.
2022-09-02 09:41:19 -07:00
Chris Robinson bf3f63fb4c Don't apply the HF scaling for "upsampling" ambisonics
Not sure if this is best, but it fixes the issue of upsampling lower orders to
higher orders multiple times (mixing lower order to higher order, cutting back
to lower order by dropping the extra channels, then upsampling again, applying
the HF scale multiple times and messing up the high frequencies/energy vector),
as well as having too-strong high frequencies of upsampled content in general.

As it is, with the new upsampling method, the lower order signal contributes to
some higher order channels, which helps offset the high frequency scaling
difference (except first- to second-order, which adds nothing).
2022-08-31 09:06:53 -07:00
Chris Robinson b8d73a226a Add a 2D fourth-order upsampler
This will be necessary for 2D fourth-order sources with 3D fourth-order output.
2022-08-27 03:43:33 -07:00
Chris Robinson 0ae6955f1c Fix variable name 2022-08-26 02:01:28 -07:00
Chris Robinson e48c294a69 Create and use 2D upsampling matrices 2022-08-25 23:22:45 -07:00
Chris Robinson 4f75f9258c Avoid duplicate code 2022-08-18 18:44:37 -07:00
Chris Robinson 90f02176dd Inline a function and remove an unnecessary parameter 2022-08-16 13:00:03 -07:00
Chris Robinson 6d5580805e Use a decode-encode method for ambisonic upsampling
This should allow for clearer and less diffuse responses. While a cube is in
the blindspots for second-order, resulting in an identify transform for first-
to-second-order, they do start contributing to third-order channels, which
should make for sharper virtual points. The fixed HF scales should also play
nicer with larger order upmixes.
2022-08-15 09:01:03 -07:00
Chris Robinson b489705b25 Minor UHJ coefficient scaling precision improvement 2021-12-13 01:09:53 -08:00
Chris Robinson d998c03a27 Add a UHJ-specific coefficient scaling array 2021-07-13 06:31:13 -07:00
Chris Robinson 440ce71dce Move GetHFOrderScales to a more appropriate place 2021-04-24 13:46:52 -07:00
Chris Robinson 20f5e7c1fa Avoid global constexpr arrays 2021-01-21 04:03:30 -08:00
Chris Robinson 204f7d8811 Rename From2D to FromACN2D 2020-12-25 06:40:13 -08:00
Chris Robinson 191fe888b4 Move ambidefs.h to core 2020-12-12 10:38:24 -08:00