 Wrapping is used in 3D computer graphics to repeat a texture over a polygon, eliminating the need for large textures or multiple polygons.To wrap a position "x" to an area of width "w", calculate the value formula_1.For computational purposes the wrapped value "x"' of "x" can be expressed as

where formula_3 is the highest value in the range, and formula_4 is the lowest value in the range.