- #1
Artlav
- 162
- 1
There is an article on procedural texture generation by example.
I'm trying to implement it, and got lost in the mathematics.
http://graphics.cs.kuleuven.be/publications/LVLD10PISTE/
The outline of the algorithm is thus:
We start with a noise-like photo.
Do a 2D DFT of it:
Compute the power band coefficients and reconstruct the image with wavelet noise:
Wavelet noise is band limited, which makes it a good base block for such synthesis:
That's the theory.
In practice, i can't figure out the formula for the coefficients.
Formula (E is the input image):
Definition of the power band:
What does it mean?
Should i sum all the magnitudes of the elements in each band?
This gives me nonsense if i divide it by the amount of elements, and randomly unscaled value if i don't (that's the above picture, guesstimately scaled).
If i sum the real parts of the elements, then i get wildly wrong and out of scale figures. Normalising them also gives me something plausible.
And so on, for any way i can think of.
I guess i misunderstand something in the notation.
Does the integral sign means summing here?
Or how should i read it?
That's basically the question - what does it mean?
Bonus question - anyone heard of this method being used somewhere? A working implementation to peek at would be nice.
I'm trying to implement it, and got lost in the mathematics.
http://graphics.cs.kuleuven.be/publications/LVLD10PISTE/
The outline of the algorithm is thus:
We start with a noise-like photo.
Do a 2D DFT of it:
Compute the power band coefficients and reconstruct the image with wavelet noise:
Wavelet noise is band limited, which makes it a good base block for such synthesis:
That's the theory.
In practice, i can't figure out the formula for the coefficients.
Formula (E is the input image):
Definition of the power band:
What does it mean?
Should i sum all the magnitudes of the elements in each band?
This gives me nonsense if i divide it by the amount of elements, and randomly unscaled value if i don't (that's the above picture, guesstimately scaled).
If i sum the real parts of the elements, then i get wildly wrong and out of scale figures. Normalising them also gives me something plausible.
And so on, for any way i can think of.
I guess i misunderstand something in the notation.
Does the integral sign means summing here?
Or how should i read it?
That's basically the question - what does it mean?
Bonus question - anyone heard of this method being used somewhere? A working implementation to peek at would be nice.