com.io7m.r2.core.shaders.provided

## Interface R2SurfaceShaderBasicStippledParametersType

- All Superinterfaces:
    R2SurfaceShaderBasicParametersValuesType
  All Known Implementing Classes:
    R2SurfaceShaderBasicStippledParameters

      public interface R2SurfaceShaderBasicStippledParametersType
      extends R2SurfaceShaderBasicParametersValuesType

  Parameters for the basic stippled surface shader.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `default com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType>` | `albedoColor()` The base albedo color for the surface.
    `default float` | `albedoMix()` A specification of the mix value between the albedo color and texture.
    `default R2Texture2DUsableType` | `albedoTexture()` An albedo map which is used to modulate the value of `R2SurfaceShaderBasicParametersValuesType.albedoColor()`.
    `default float` | `alphaDiscardThreshold()` The alpha discard threshold specifies a lower bound on the opacity of surface pixels.
    `default float` | `emission()` The emission value for the surface, in the range `[0.0, 1.0]`.
    `default R2Texture2DUsableType` | `emissionTexture()` An emission map which is used to modulate the value of `R2SurfaceShaderBasicParametersValuesType.emission()`.
    `default R2Texture2DUsableType` | `normalTexture()` A normal map used to peturb normal vectors for the surface.
    `default com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType>` | `specularColor()` The base specular color for the surface.
    `default float` | `specularExponent()` The specular exponent.
    `default R2Texture2DUsableType` | `specularTexture()` A specular map which is used to modulate the value of `R2SurfaceShaderBasicParametersValuesType.specularColor()`.
    `R2Texture2DUsableType` | `stippleNoiseTexture()` The noise texture used to implement stippling.
    `default float` | `stippleThreshold()` The stipple threshold value.
    `R2TextureDefaultsType` | `textureDefaults()`

- - ### Method Detail

    - #### textureDefaults

          R2TextureDefaultsType textureDefaults()

      Specified by:
        `textureDefaults` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        A reference to the default textures

    - #### albedoColor

          default com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType> albedoColor()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      The base albedo color for the surface. This value is mixed with values sampled from `R2SurfaceShaderBasicParametersValuesType.albedoTexture()` based on `R2SurfaceShaderBasicParametersValuesType.albedoMix()`.

      Specified by:
        `albedoColor` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The base albedo color of the surface
      See Also:
        `R2SurfaceShaderBasicParametersValuesType.albedoTexture()`, `R2SurfaceShaderBasicParametersValuesType.albedoMix()`

    - #### specularColor

          default com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType> specularColor()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      The base specular color for the surface. This essentially encodes both the intensity and color of specular highlights for the surface.

      Specified by:
        `specularColor` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The base specular color of the surface

    - #### emission

          default float emission()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      The emission value for the surface, in the range `[0.0, 1.0]`. The value is typically processed by filters to give surfaces the appearance of emitting light.

      Specified by:
        `emission` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The emission value of the surface

    - #### emissionTexture

          default R2Texture2DUsableType emissionTexture()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      An emission map which is used to modulate the value of `R2SurfaceShaderBasicParametersValuesType.emission()`. Specifically, values sampled from the map are multiplied by `R2SurfaceShaderBasicParametersValuesType.emission()` to give per-pixel control of the emission value.

      Specified by:
        `emissionTexture` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The emission map for the surface

    - #### albedoTexture

          default R2Texture2DUsableType albedoTexture()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      An albedo map which is used to modulate the value of `R2SurfaceShaderBasicParametersValuesType.albedoColor()`. Specifically, values sampled from the map are linearly mixed with `R2SurfaceShaderBasicParametersValuesType.albedoColor()` based on `R2SurfaceShaderBasicParametersValuesType.albedoMix()`. The alpha channel of the map is also used so that a texture with transparent sections will show the underlying `R2SurfaceShaderBasicParametersValuesType.albedoColor()` even when the texture is fully mixed (i.e. `R2SurfaceShaderBasicParametersValuesType.albedoMix()` == `1.0`).

      Specified by:
        `albedoTexture` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The albedo map for the surface

    - #### albedoMix

          default float albedoMix()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      A specification of the mix value between the albedo color and texture. If `0.0`, the albedo of the surface will be `R2SurfaceShaderBasicParametersValuesType.albedoColor()`. If `1.0`, the albedo of the surface will be a value sampled from `R2SurfaceShaderBasicParametersValuesType.albedoTexture()`. Other values in the range `[0.0, 1.0]` will linearly mix between the two extremes.

      Specified by:
        `albedoMix` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The mix between the albedo color and texture

    - #### specularTexture

          default R2Texture2DUsableType specularTexture()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      A specular map which is used to modulate the value of `R2SurfaceShaderBasicParametersValuesType.specularColor()`. Specifically, values sampled from the map are multiplied by `R2SurfaceShaderBasicParametersValuesType.specularColor()` to give per-pixel control of specular intensity and color.

      Specified by:
        `specularTexture` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The specular map for the surface

    - #### specularExponent

          default float specularExponent()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      The specular exponent. This is a value in the range `[0.0, 256.0]` and is used directly as the exponent term.

      Specified by:
        `specularExponent` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The specular exponent

    - #### normalTexture

          default R2Texture2DUsableType normalTexture()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      A normal map used to peturb normal vectors for the surface. The texture is expected to contain RGB-encoded vectors such that `[0.5, 0.5, 1.0]` represents the "neutral" tangent-space `[0.0, 0.0, 1.0]` vector.

      A map containing entirely `[0.5, 0.5, 1.0]` values will have no visible effect on the surface.

      Specified by:
        `normalTexture` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        The normal map

    - #### alphaDiscardThreshold

          default float alphaDiscardThreshold()

      Description copied from interface: `R2SurfaceShaderBasicParametersValuesType`

      The alpha discard threshold specifies a lower bound on the opacity of surface pixels. For any given surface pixel, if the opacity of the calculated albedo is less than the `R2SurfaceShaderBasicParametersValuesType.alphaDiscardThreshold()`, then the pixel is simply discarded; the pixel is not written to the current geometry buffer. This allows for otherwise opaque surfaces to have fully transparent sections.

      Specified by:
        `alphaDiscardThreshold` in interface `R2SurfaceShaderBasicParametersValuesType`
      Returns:
        A discard threshold in the range `[0.0, 1.0]`

    - #### stippleNoiseTexture

          R2Texture2DUsableType stippleNoiseTexture()

      The noise texture used to implement stippling. This is a random noise texture that is tiled across the screen, and values in the red channel are sampled for stippling.
      Returns:
        A noise texture
      See Also:
        `stippleThreshold()`

    - #### stippleThreshold

          default float stippleThreshold()

      The stipple threshold value. For each pixel in the surface, the stipple threshold determine whether or not that pixel will be discarded. Essentially, the `stippleNoiseTexture()` is sampled at each pixel, and if the sampled value is less than the threshold value, the pixel is discarded. Consequently, a stipple threshold of `0.0` never discards pixels.
      Returns:
        The threshold value

Copyright © 2017 <code@io7m.com> http://io7m.com