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

Strange crash with Fatal error: Array index is out of range #3

Open
wilg opened this issue Feb 4, 2022 · 0 comments
Open

Strange crash with Fatal error: Array index is out of range #3

wilg opened this issue Feb 4, 2022 · 0 comments

Comments

@wilg
Copy link

wilg commented Feb 4, 2022

I get a crash somewhat randomly when generating in a loop of tens of thousands of pixels.

Here's an example of some of the settings when it crashed. It doesn't seem to crash particularly reproducibly.

let noise = GradientNoise2D(amplitude: 1, frequency: 0.5, seed: 332)
noise.evaluate(-25.3217883662071, 43.793)

I (amazingly) cannot figure out how to copy the stack trace out of Xcode but it crashes on this line:

https://github.com/kelvin13/noise/blob/965fc23d7e95fb21a9065ef1566ee2bbd2b86e4b/sources/noise/gradient.swift#L540

with

2022-02-04 12:49:07.312857-0800 Run[53616:517701] Swift/Array.swift:405: Fatal error: Array index is out of range
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

1 participant