   Run for cover! Perlin Noise is here!
  Hello allIve come across a situation where i have a bitmap generated with perlin noise (octaves, seeds, so on), and i need to create another bitmap wich represents a zoom in on the first one. I could simply "copy and paste" the desired portion, stretching it to fit the output size, but i loose too much detail in this way (after all, i am strectching an image).Is there a way to recalculate a portion of a perlin noise based image using the original values and the desired rectangle to zoom in on?schematics: (im an undiscovered ascii artist)(EDIT)I had a box drawn here with a smaller box inside. Guess my ascii art is not that good. Or my browser. (/EDIT)i have all the variables used to generate the first one, but given a rectangle inside the first one, is it possible to recalculate a new image, the size of the first one, but representing a "zoom in"?Most perlin noise information i read about, does not cover this.Thank you all for your time,Joao Correia[edited by - joaocorreia123 on February 9, 2004 3:04:56 PM]
  Do you have the code that generated the first image?  If so then it should be possible (or even easy depending on the implementation) to do what you want.  It will probably involve stretching and offsetting each octave of noise.  I.e. if the original image is 512×512 and you want to zoom a 128×64 portion of that (with origin at 256, 96) to 512×256 then you''ll need to multiply the wavelength of each octave by 4 and adjust the seed value.  If the original seed was (y * something) + x, your new seed would be ((y + 96) * something) + x + 256.Hope that helps,Enigma ;  I understand the general idea behind what you are saying, i just dind''t get the "wavelenght". Could you please elaborate a bit on it? Why 4?Thank you for your time,Joao Correia ;  When you generate each octave of noise you sample a different number of points and interpolate between them.  The distance between your sampled points is the wavelength, i.e. for the noise:   x...x  .. .  ..    .x...x x...xwhere x represents a sampled point and . an interpolated point your wavelength is 4.  if you want to zoom in on this you simply make your wavelength (and amplitude - forgot to mention that before) larger.  If you want to zoom in 4 times (what was 128 pixels will be 512 pixels in zoomed image) then you need to multiply your wavelength and amplitude by 4, so a zoomed version of first bit of the above (zoomed by 2× to save space) is: x.....    .   .  . ..    .x.......xwhere each x is still a sampled point and each . is still an interpolated point and the entire image is still the same width.Enigma ;  Thank you very much for the assistance. That was exactly what i was looking for.(Amazing ascii art btw  - i couldn''t even get a simple box to show up properly)Thank you for your time,Joao Correia ;  Re: ASCII art - try using <pre> tags.Enigma ;  You can also use something like sinc filtering if you have the time for it (instead of just a plain triangle filter like Enigma proposed). 