-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
review partial work on issue 70 #79
Conversation
Thanks for this, @nwolek . In performance-sensitive code we cannot use exceptions. So your intuition that something is amiss using the try-catches here is correct. Actually, speaking of performance-sensitive audio code there is, IMO, a really good video @ https://www.youtube.com/watch?v=boPEO2auJj4 (YMMV) ( @lossius may also appreciate the video talk ) A couple of other observations: h3. Arg Order
I would suggest reversing the arguments so that
I also I changed the name here because we aren't passing the whole channel, but the index number of the channel. h3. Template specification As I'm sure you are already thinking, it's bummer to have to write code like this:
instead of
As I think about it though, it would be less desirable to make the interpolation a part of the state of the SampleBundle. So I guess that means we should experiment with just making this line of code a bit less long. Finding some shorthand for it can be an issue assigned to me. As long as this is functional though we can keep moving forward even if it is a lot of typing to make those statements. |
VideoThat was a good one! I think he did a good job surveying the issues I knew, and helped me better understand the issues I am less familiar with. Arg orderGood idea putting channel last. I was thinking that we might eventually have other versions that provide you with all channels in a single SampleBundle. I would also like something where we pass in a vector of interpolation indices and get back a SampleBundle. Something like:
Template specsAgreed. Part of my reason for writing it out was to show just how ugly it was. |
… print function by default. issue #70
@tap - Good call removing the try-catch statements. Timing the interpolation of about 500 samples was about 75% faster when replaced by good old if statements. |
@tap - please give this another look and let me know if you think this is ready to merge into master. |
I believe I have implemented all that @tap outlined 9 days ago, so I am moving forward with merge. |
review partial work on issue 70
I would not consider this done (hence the 70a branch name), but I would like @tap to give this a look and comment on the direction it is going. Not sure I like the use of so many try-catch statements to keep things in bounds. If you have any other ideas, I would appreciate them!