Skip to content
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

Setting WAVE_LEN to something bigger than 256 crashes app #6

Open
christoph-hart opened this issue Mar 26, 2018 · 1 comment
Open

Comments

@christoph-hart
Copy link

Awesome project but the exported length of 256 samples per wavetable is a bit unambitious. However setting the WAVE_LEN constant to something bigger crashes the app. Would be great to be able to set this to at least 512 or 1024.

@miczac
Copy link

miczac commented Jan 6, 2019

I just forked the repo and had a very brief look at it: except for util.cpp WAVE_LEN seems to be used consequently, but I have a hunch that some data types might not be appropriate when increasing WAVE_LEN.
E.g. src/db.cpp: int16_t *samples_i16 = new int16_t[BANK_LEN * WAVE_LEN];
Here the product should be < 32768, which is only true for WAVE_LEN = 256, AFAIK.

I didn't browse thoroughly but I suspect it's something of that kind.
I'm not a programmer and alas I can't compile at all since carbon.h of libsndfile has issues (potentially deprecated).
So ... I think it would be fixable and amendable in a way passing a parameter to the program setting WAVE_LEN accordingly. If this is defaulted to 256 it should also behave as initially intended.
Michael.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants