AlgoSim
Homepage | Screenshots | Gallery of Visualisation | User's Guide | Function Reference | Download | FAQ | Support | Bugs and Solutions | Donate

Reference: pmDistortSpace

pmDistortSpace(pm) applies a small random distortion to the pixels of the pixmap pm, and returns the result. Specifically, each pixel will be moved -1, 0, or 1 pixels to the right and -1, 0, or 1 pixels downwards. (The distortion applies to each pixel position once, from (0, 0), to (width - 1, height - 1) in row-major order.)

pmDistortSpace(pm, r) moves each pixel a maximum of r pixels to the left/right and a maximum of r pixels upwards/downwards. Hence, the default vale of r is 1.