POV-Ray : Documentation : Pigment Pattern
  POV-Ray 3.6 Documentation Online View Onion Planar Pigment Pattern

Use any pigment as a pattern. Instead of using the pattern directly on the object, a pigment_pattern converts the pigment to gray-scale first. For each point, the gray-value is checked against a list and the corresponding item is then used for the texture at that particular point. For values between listed items, an averaged texture is calculated.
Texture items can be color, pigment, normal or texture and are specified in a color_map, pigment_map, normal_map or texture_map.
It takes a standard pigment specification.


  pigment {
    pigment_pattern { PIGMENT_BODY }
    color_map { COLOR_MAP_BODY } |
    colour_map { COLOR_MAP_BODY } | 
    pigment_map { PIGMENT_MAP_BODY }

  normal {
    pigment_pattern { PIGMENT_BODY } [Bump_Size]
    normal_map { NORMAL_MAP_BODY }

  texture {
    pigment_pattern { PIGMENT_BODY }
    texture_map { TEXTURE_MAP_BODY }


This pattern is also useful when parent and children patterns need to be transformed independently from each other. Transforming the pigment_pattern will not affect the child textures. When any of the child textures should be transformed, apply it to the specific MAP_ENTRY.

This can be used with any pigments, ranging from a simple checker to very complicated nested pigments. For example:

 pigment {
   pigment_pattern {
     checker White, Black
     scale 2
     turbulence .5
   pigment_map {
     [ 0, checker Red, Green scale .5 ]
     [ 1, checker Blue, Yellow scale .2 ]

Note: This pattern uses a pigment to get the gray values from. If you want to get the pattern from an image, you should use the image_pattern. Onion Planar

Copyright 2003-2021 Persistence of Vision Raytracer Pty. Ltd.