Skip to content

Instantly share code, notes, and snippets.

View Markyparky56's full-sized avatar
💭
Hello, World!

Mark A. Ropper Markyparky56

💭
Hello, World!
View GitHub Profile
// https://www.shadertoy.com/view/dlfXDN
// 2023 myth0genesis
// 4D Simplex Noise Gradient
// I saw that Stefan Gustavson didn't seem to have published any shader
// with an analytic solution for the gradients of his variant
// of 4D simplex noise, so I thought I'd try solving it myself
// and publish it here for anyone who finds it useful.
// Compares the analytic solution to the numerically approximated one (for a sanity check)
// and shows the results of all four derivatives with respect to each dimension.
// Top : Analytic gradient | Bottom: Forward differences approximated gradient