Procedural texturing: Difference between revisions

Jump to navigation Jump to search
No edit summary
Line 310: Line 310:
[[File:Southwest04.jpg|400px|Procedural rock Grand Canyon]]
[[File:Southwest04.jpg|400px|Procedural rock Grand Canyon]]
[[File:Southwest09.jpg|400px|Procedural rock Zion National Park]]
[[File:Southwest09.jpg|400px|Procedural rock Zion National Park]]
=== The agriculture effect ===
The basic texture scheme based on Perlin noise is of limited value for e.g. agricultural terrain which rarely shows the organic shapes generated by Perlin noise. For such terrain, the agriculture effect should be used instead which is based on Perlin noise.
The effect needs to be declared for the landclass as
  <effect>Effects/agriculture</effect>
(note that since the default rendering scheme has typically the crop effect associated with agriculture, this declaration inherits crop.eff).
By default, large patches of agriculture usually show strong tiling:
[[File:Domains_agro01.jpg|400px|center|Tiling in agriculture]]
It is implemented in two modes, overlay and rotation. Since the agriculture effect is optional, its overlay texture is declared separately from the normal declaration above as follows:
  <texture-set>
    <texture>base_texture.png</texture>
    <texture n="16">overlay_texture.png</texture>
  <texture-set>
If the overlay texture is declared void.png (to which the effect defaults), it is not used. The effect takes a number of parameters. For the overlay, the fraction taken by the overlay texture and the scale at which the patches are drawn can be specified as:
  <overlay_fraction>0.5</overlay_fraction>
  <overlay_scale>1000.0</overlay_scale>
  <rotation_flag>0</rotation_flag>
  <rotation_scale>1000.0</rotation_scale>
  <distortion_factor>0.0</distortion_factor>
  <uv_xoffset>0.0</uv_xoffset>
  <uv_yoffset>0.0</uv_yoffset>


=== Pixel color postprocessing ===
=== Pixel color postprocessing ===
Line 370: Line 402:


[[File:procedural11.jpg|500px|center|Base scenery near Grenoble]]
[[File:procedural11.jpg|500px|center|Base scenery near Grenoble]]


== Limitations of procedural texturing ==
== Limitations of procedural texturing ==
1,360

edits

Navigation menu