Closed
Conversation
A cleaned up, minimal push of the spherical harmonic calculator designed for ChucK's math library.
This change implements a ulib_math entry which allows for the function to actually be called by users. Includes documentation of the function.
Previously, memory was allocated by SH() which would return a pointer for the ulib function to access. This meant one function allocated memory and the other deleted it. Now ulib will allocate memory and provide a pointer to SH() for it to use, meaning SH() is not responsible for management of memory.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds examples for Math.sh(), including a general explanation of usage in math/ and an example using Gain[] to achieve ambisonic encoding in spatial/
I know spherical harmonic projections have applications in ML, perhaps Math.sh() could be used for something. There could be some fun experiments in ambisonic soundfield analysis with ChAI. Let me know how these examples look, happy to reduce or increase detail, and mockup more stuff related to ambisonics.