@brecht I have a question regarding hash_float_to_float
hash_float_to_float(cellPosition + cellOffset) * randomness; |
@mod_moder I'd figured you'll say that, but I honestly don't see how splitting this up into multiple pull requests would reduce the work for the reviewers in any way. Apart from that as all the…
@mod_moder Well, looks like I did end up having to change a lot of the pre-exisitng code, so you did kind of get your general code cleanup after all ;-)
Right, I completely forgot about noise.cc
, in that case I think I'll put the switch statement in the for loop, as it would probably still be faster than a function call and the performance…
I meant something like this:
const VArray<float> &randomness = get_randomness(param++); ... for (int64_t i : mask) { VoronoiParams params; params.randomness =…
As for GLSL I'll just #define
a macro (something like INITIALIZE_VORONOIPARAMS
) which would take care of the initialization of VoronoiParams
.
The voronoi evaluation still runs on one element at a time, and I think it's fine to keep it like that. And so that would mean VoronoiParams does not need to contain a VArray. Rather you can…
@brecht I've made some final changes to voronoi.h
. I would then copy the voronoi.h
implementation to the other versions as closely as reasonable, so is there still anything you would like to…
For
VArray
, I guess it's best to keep the implementation innoise.cc
scalar for now, includingVoronoiParams
? To avoid making that much more complicated and keep it similar to the other…
Also regarding the GLSL implementation, as far as I know the GLSL voronoi implementation starts in this file: https://projects.blender.org/blender/blender/src/commit/557a245dd5ce30f9e802e5b11a986f8…
Apart from that I have a question regarding the const VArray<> &
s in 5a6db19da4/source/blender/nodes/shader/n
…
@brecht It generally looks pretty great to me, though I noticed that after your refactor all 4D outputs of F1, Smooth F1 and F2 have been somehow distorted when using the Minkowski
metric:
Ref…
@mod_moder "As I once told you, it would be much better to do a more general code cleanup first."
I have already altered and cleaned up the code wherever it was necessary.
Apart from that the…
@brecht I was able to eliminate all duplicate functions in voronoi.h
by moving both the switch
statements and the normalization functions into the fractalization functions.
voronoi.h
in my…
I'll make the requested changes to the implementation in voronoi.h
.
Just 2 questions before I do so: What exactly do you mean by `"Add utility function to accumulate octaves into VoronoiOutp…