Synthesis of textures and bump maps of tiled surfaces – Part III

Image converted using ifftoany

Making more noise – Of marble and wood

The noise function thus far does an excellent job of creating random patterns that smoothly vary across the tiles. However, the output of Equation (1) a few sections earlier can be further modified to give other natural looking textures like marble or wood. Thus, once the value of noise was calculated using Equation (1), a further modification can be done such that

noiseValue=0.5+cos(noiseX+noiseValue*parameterA)*0.5                   (2)

In essence, Equation (2) ‘corrupts’ a smoothly-varying cosine function with noise, creating wavy patterns. The final noise value will have low frequency noise for low values of parameterA and high frequency for higher values of parameterA. The table below illustrates this

Table 2 Cosine modulated noise

 [table id=2 /]

With a judicious use of color, the above can be translated into texture that resembles marble, as shown in Figure 15, for example a marble-like surface with medium grey veining and a pinkish-white field.

Image converted using ifftoany

Figure 15 Marble-like texture map using a modulated cosine noise

The texture and bump maps used in rendering Figure 15 were as follows, while the input file is included right below the figure.

 figure16

Figure 16 Texture maps for a marble-like appearance

outputFileName /Users/amzs/Desktop/grey_marble_tile_localnoise01.tif
textureWidth 2048
textureHeight 2048
tiledAreaWidth 10.0
tiledAreaLength 10.0
tileWidth 1.0
tileLength 0.6
groutWidth 0.02
tileColorGlobalColorType variable
tileColorGlobalColorNoiseType perlin
tileColorGlobalColor 1.0 1.0 1.0 1.0
tileColorGlobalColorLowSide 1.0 1.0 1.0 1.0
tileColorGlobalColorHighSide 1.0 1.0 1.0 1.0
tileColorGlobalNoiseXMin 0.0 
tileColorGlobalNoiseYMin 0.0 
tileColorGlobalNoiseXMax 10.0 
tileColorGlobalNoiseYMax 10.0
groutColorColorType variable
groutColorColorNoiseType random
groutColorColor 0.8 0.8 0.8 1.0
groutColorColorLowSide 0.6 0.6 0.6 1.0
groutColorColorHighSide 0.9 0.9 0.9 1.0
tileColorLocalColorType variable
tileColorLocalColorNoiseType cosineModulated
tileColorLocalColor 0.9 0.9 0.9 1.0
tileColorLocalColorLowSide 0.68 0.68 0.68 1.0
tileColorLocalColorHighSide 1.0 0.94 0.88 1.0
tileColorLocalNoiseXMin 0.0 
tileColorLocalNoiseYMin 0.0 
tileColorLocalNoiseXMax 50.0 
tileColorLocalNoiseYMax 50.0 
tileColorLocalOctaves 16
tileColorLocalPersistence 0.5
tileColorLocalParameterA 4.0
tileBumpNoiseAlternateColorType variable
tileBumpNoiseAlternateColorNoiseType perlin 
tileBumpNoiseAlternateColor 1.0 1.0 1.0 1.0
tileBumpNoiseAlternateColorLowSide 1.0 1.0 1.0 1.0
tileBumpNoiseAlternateColorHighSide 1.0 1.0 1.0 1.0
tileBumpNoiseAlternateNoiseXMin 0.0
tileBumpNoiseAlternateNoiseYMin 0.0
tileBumpNoiseAlternateNoiseXMax 8.0
tileBumpNoiseAlternateNoiseYMax 8.0
tileBumpNoiseAlternateOctaves 2
tileBumpNoiseAlternatePersistence 0.25
randomTileOrientation false
randomTileNoiseStartPoint true
generateBumpMap true
tileBumpNoiseAlternate true
useTileXOffset
tileXOffset 0.51
blurFinalImage true

If a different function is used to alter the noise value obtained from Perlin noise, we can go from marble to wood, one line difference, I promise. Consider Equation 3, which alters the noise output in a different way

noiseValue = noiseValue *parameterA-(int)( noiseValue *parameterA)     (3)

In essence this statement computes the difference between a scaled noise value (scaled by parameterA) and it’s rounded-down integer value, generating visible bands resembling the grain and figure of certain woods (oak comes to mind).

By further thresholding the noise value, a two-tone wood grain can be achieved, as shown in Table 3.

Table 3 Parameters for wood-like grain

[table id=3 /]

Generating texture and bump maps using the wood-like grain noise can result in relatively convincing tiles like the one shown below in Figure 17, resembling the recently ubiquitously trendy wood-grained porcelain tiles. The texture and bump maps used in the rendering were as shown in Figure 18 and the input file used in generating the texture and bump maps is included below the figures.

Image converted using ifftoany

Figure 17 Wood-grained tiles

figure18

Figure 18 Texture and bump maps for wood-grained tiles

outputFileName /Users/amzs/Desktop/woodtiles01.tif
textureWidth 2048
textureHeight 2048
tiledAreaWidth 10.0
tiledAreaLength 10.0
tileWidth 2.0
tileLength 0.4
groutWidth 0.02
tileXOffset 1.01
tileColorGlobalColorType variable
tileColorGlobalColorNoiseType perlin
tileColorGlobalColor 1.0 1.0 1.0 1.0
tileColorGlobalColorLowSide 1.0 1.0 0.93725490196078 1.0
tileColorGlobalColorHighSide 1.0 0.97254901960784 0.89019607843137 1.0
tileColorGlobalNoiseXMin 0.0 
tileColorGlobalNoiseYMin 0.0 
tileColorGlobalNoiseXMax 10.0 
tileColorGlobalNoiseYMax 10.0 
tileColorLocalColorType variable
tileColorLocalColorNoiseType wood
tileColorLocalColor 0.3359375 0.18359375 0.0546875 1.0
tileColorLocalColorLowSide 0.27734375 0.13671875 0.01953125 1.0
tileColorLocalColorHighSide 0.65625 0.3984375 0.1796875 1.0
tileColorLocalNoiseXMin 0.0 
tileColorLocalNoiseYMin 0.0 
tileColorLocalNoiseXMax 10.0 
tileColorLocalNoiseYMax 50.0 
tileColorLocalOctaves 2 
tileColorLocalPersistence 0.25 
tileColorLocalParameterA 20.0 
tileBumpNoiseAlternateColorType variable
tileBumpNoiseAlternateColorNoiseType perlin 
tileBumpNoiseAlternateColor 1.0 1.0 1.0 1.0
tileBumpNoiseAlternateColorLowSide 1.0 1.0 1.0 1.0
tileBumpNoiseAlternateColorHighSide 1.0 1.0 1.0 1.0
tileBumpNoiseAlternateNoiseXMin 0.0
tileBumpNoiseAlternateNoiseYMin 0.0
tileBumpNoiseAlternateNoiseXMax 2.0
tileBumpNoiseAlternateNoiseYMax 2.0
tileBumpNoiseAlternateOctaves 2
tileBumpNoiseAlternatePersistence 0.25
tileDiscolorationMapColorType variable
tileDiscolorationMapColorNoiseType perlin
tileDiscolorationMapColor 1.0 1.0 1.0 1.0
tileDiscolorationMapColorLowSide 1.0 1.0 1.0 1.0
tileDiscolorationMapColorHighSide 1.0 1.0 1.0 1.0
tileDiscolorationMapNoiseXMin 1.0
tileDiscolorationMapNoiseYMin 1.0 
tileDiscolorationMapNoiseXMax 1.5
tileDiscolorationMapNoiseYMax 1.5
tileDiscolorationMapOctaves 16
tileDiscolorationMapPersistence 1.0
tileDiscolorationMapThresholdLower 0.5
tileDiscolorationMapThresholdUpper 1.0
tileDiscolorationMapThresholdPercentReduction 20.0
tileDiscolorationMapGenerate true
groutColorColorType variable
groutColorColorNoiseType random
groutColorColor 0.5 0.5 0.5 1.0
groutColorColorLowSide 0.4 0.4 0.4 1.0
groutColorColorHighSide 0.6 0.6 0.6 1.0
randomTileOrientation false
randomTileNoiseStartPoint true
useTileXOffset
generateBumpMap true
tileBumpNoiseAlternate true
blurFinalImage false

These few examples are only scratching the surface what can be done with noise. Particularly, if noise at various scales is layered over each other or used to alter some other aspects of texture and bump map image synthesis. So, go ahead and experiment, the wonderful world of noise awaits you!