@Generated(value={"Immutables.generator","R2SurfaceShaderBasicReflectiveParametersType"}) public final class R2SurfaceShaderBasicReflectiveParameters extends Object implements R2SurfaceShaderBasicReflectiveParametersType
| Modifier and Type | Class and Description |
|---|---|
static class |
R2SurfaceShaderBasicReflectiveParameters.Builder
Builds instances of type
R2SurfaceShaderBasicReflectiveParameters. |
| Modifier and Type | Method and Description |
|---|---|
com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType> |
albedoColor()
The base albedo color for the surface.
|
float |
albedoMix()
A specification of the mix value between the albedo color and texture.
|
R2Texture2DUsableType |
albedoTexture()
An albedo map which is used to modulate the value of
R2SurfaceShaderBasicParametersValuesType.albedoColor(). |
float |
alphaDiscardThreshold()
The alpha discard threshold specifies a lower bound on the opacity of
surface pixels.
|
static R2SurfaceShaderBasicReflectiveParameters.Builder |
builder()
Creates a builder for
R2SurfaceShaderBasicReflectiveParameters. |
static R2SurfaceShaderBasicReflectiveParameters |
copyOf(R2SurfaceShaderBasicReflectiveParametersType instance)
Creates an immutable copy of a
R2SurfaceShaderBasicReflectiveParametersType value. |
float |
emission()
The emission value for the surface, in the range
[0.0, 1.0]. |
R2Texture2DUsableType |
emissionTexture()
An emission map which is used to modulate the value of
R2SurfaceShaderBasicParametersValuesType.emission(). |
float |
environmentMix()
The linear mix between the surface's albedo and calculated
reflection values.
|
R2TextureCubeUsableType |
environmentTexture()
An environment map used to simulate reflections on the rendered surface.
|
boolean |
equals(Object another)
This instance is equal to all instances of
R2SurfaceShaderBasicReflectiveParameters that have equal attribute values. |
int |
hashCode()
Computes a hash code from attributes:
textureDefaults, albedoColor, specularColor, emission, emissionTexture, albedoTexture, albedoMix, specularTexture, specularExponent, normalTexture, alphaDiscardThreshold, environmentTexture, environmentMix. |
R2Texture2DUsableType |
normalTexture()
A normal map used to peturb normal vectors for the surface.
|
static R2SurfaceShaderBasicReflectiveParameters |
of(R2TextureDefaultsType textureDefaults,
com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType> albedoColor,
com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType> specularColor,
float emission,
R2Texture2DUsableType emissionTexture,
R2Texture2DUsableType albedoTexture,
float albedoMix,
R2Texture2DUsableType specularTexture,
float specularExponent,
R2Texture2DUsableType normalTexture,
float alphaDiscardThreshold)
Construct a new immutable
R2SurfaceShaderBasicReflectiveParameters instance. |
com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType> |
specularColor()
The base specular color for the surface.
|
float |
specularExponent()
The specular exponent.
|
R2Texture2DUsableType |
specularTexture()
A specular map which is used to modulate the value of
R2SurfaceShaderBasicParametersValuesType.specularColor(). |
R2TextureDefaultsType |
textureDefaults() |
String |
toString()
Prints the immutable value
R2SurfaceShaderBasicReflectiveParameters with attribute values. |
R2SurfaceShaderBasicReflectiveParameters |
withAlbedoColor(com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType> value)
Copy the current immutable object by setting a value for the
albedoColor attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withAlbedoMix(float value)
Copy the current immutable object by setting a value for the
albedoMix attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withAlbedoTexture(R2Texture2DUsableType value)
Copy the current immutable object by setting a value for the
albedoTexture attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withAlphaDiscardThreshold(float value)
Copy the current immutable object by setting a value for the
alphaDiscardThreshold attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withEmission(float value)
Copy the current immutable object by setting a value for the
emission attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withEmissionTexture(R2Texture2DUsableType value)
Copy the current immutable object by setting a value for the
emissionTexture attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withEnvironmentMix(float value)
Copy the current immutable object by setting a value for the
environmentMix attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withEnvironmentTexture(R2TextureCubeUsableType value)
Copy the current immutable object by setting a value for the
environmentTexture attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withNormalTexture(R2Texture2DUsableType value)
Copy the current immutable object by setting a value for the
normalTexture attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withSpecularColor(com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType> value)
Copy the current immutable object by setting a value for the
specularColor attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withSpecularExponent(float value)
Copy the current immutable object by setting a value for the
specularExponent attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withSpecularTexture(R2Texture2DUsableType value)
Copy the current immutable object by setting a value for the
specularTexture attribute. |
R2SurfaceShaderBasicReflectiveParameters |
withTextureDefaults(R2TextureDefaultsType value)
Copy the current immutable object by setting a value for the
textureDefaults attribute. |
public R2TextureDefaultsType textureDefaults()
textureDefaults in interface R2SurfaceShaderBasicParametersValuesTypetextureDefaults in interface R2SurfaceShaderBasicReflectiveParametersTypetextureDefaults attributepublic com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType> albedoColor()
R2SurfaceShaderBasicParametersValuesTypeThe base albedo color for the surface. This value is mixed with values
sampled from R2SurfaceShaderBasicParametersValuesType.albedoTexture() based on R2SurfaceShaderBasicParametersValuesType.albedoMix().
albedoColor in interface R2SurfaceShaderBasicParametersValuesTypealbedoColor in interface R2SurfaceShaderBasicReflectiveParametersTypealbedoColor attributeR2SurfaceShaderBasicParametersValuesType.albedoTexture(),
R2SurfaceShaderBasicParametersValuesType.albedoMix()public com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType> specularColor()
R2SurfaceShaderBasicParametersValuesTypeThe base specular color for the surface. This essentially encodes both the intensity and color of specular highlights for the surface.
specularColor in interface R2SurfaceShaderBasicParametersValuesTypespecularColor in interface R2SurfaceShaderBasicReflectiveParametersTypespecularColor attributepublic float emission()
R2SurfaceShaderBasicParametersValuesTypeThe 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.
emission in interface R2SurfaceShaderBasicParametersValuesTypeemission in interface R2SurfaceShaderBasicReflectiveParametersTypeemission attributepublic R2Texture2DUsableType emissionTexture()
R2SurfaceShaderBasicParametersValuesTypeAn 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.
emissionTexture in interface R2SurfaceShaderBasicParametersValuesTypeemissionTexture in interface R2SurfaceShaderBasicReflectiveParametersTypeemissionTexture attributepublic R2Texture2DUsableType albedoTexture()
R2SurfaceShaderBasicParametersValuesTypeAn 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).
albedoTexture in interface R2SurfaceShaderBasicParametersValuesTypealbedoTexture in interface R2SurfaceShaderBasicReflectiveParametersTypealbedoTexture attributepublic float albedoMix()
R2SurfaceShaderBasicParametersValuesTypeA 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.
albedoMix in interface R2SurfaceShaderBasicParametersValuesTypealbedoMix in interface R2SurfaceShaderBasicReflectiveParametersTypealbedoMix attributepublic R2Texture2DUsableType specularTexture()
R2SurfaceShaderBasicParametersValuesTypeA 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.
specularTexture in interface R2SurfaceShaderBasicParametersValuesTypespecularTexture in interface R2SurfaceShaderBasicReflectiveParametersTypespecularTexture attributepublic float specularExponent()
R2SurfaceShaderBasicParametersValuesTypeThe specular exponent. This is a value in the range [0.0, 256.0]
and is used directly as the exponent term.
specularExponent in interface R2SurfaceShaderBasicParametersValuesTypespecularExponent in interface R2SurfaceShaderBasicReflectiveParametersTypespecularExponent attributepublic R2Texture2DUsableType normalTexture()
R2SurfaceShaderBasicParametersValuesTypeA 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.
normalTexture in interface R2SurfaceShaderBasicParametersValuesTypenormalTexture in interface R2SurfaceShaderBasicReflectiveParametersTypenormalTexture attributepublic float alphaDiscardThreshold()
R2SurfaceShaderBasicParametersValuesTypeThe 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.
alphaDiscardThreshold in interface R2SurfaceShaderBasicParametersValuesTypealphaDiscardThreshold in interface R2SurfaceShaderBasicReflectiveParametersTypealphaDiscardThreshold attributepublic R2TextureCubeUsableType environmentTexture()
An environment map used to simulate reflections on the rendered surface.
The resulting surface appearance is a linear mix between the albedo
and the reflection values sampled from the environment map, based on environmentMix().
environmentTexture in interface R2SurfaceShaderBasicReflectiveParametersTypealbedoMix()public float environmentMix()
0.0 specifies that the appearance
of the surface will be entirely defined by the albedo. A value of
1.0 specifies that the appearance of the surface will be entirely
defined by the environment reflection.environmentMix in interface R2SurfaceShaderBasicReflectiveParametersType[0.0, 1.0]environmentTexture()public final R2SurfaceShaderBasicReflectiveParameters withTextureDefaults(R2TextureDefaultsType value)
textureDefaults attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for textureDefaultsthis objectpublic final R2SurfaceShaderBasicReflectiveParameters withAlbedoColor(com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType> value)
albedoColor attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for albedoColorthis objectpublic final R2SurfaceShaderBasicReflectiveParameters withSpecularColor(com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType> value)
specularColor attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for specularColorthis objectpublic final R2SurfaceShaderBasicReflectiveParameters withEmission(float value)
emission attribute.
A value strict bits equality used to prevent copying of the same value by returning this.value - A new value for emissionthis objectpublic final R2SurfaceShaderBasicReflectiveParameters withEmissionTexture(R2Texture2DUsableType value)
emissionTexture attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for emissionTexturethis objectpublic final R2SurfaceShaderBasicReflectiveParameters withAlbedoTexture(R2Texture2DUsableType value)
albedoTexture attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for albedoTexturethis objectpublic final R2SurfaceShaderBasicReflectiveParameters withAlbedoMix(float value)
albedoMix attribute.
A value strict bits equality used to prevent copying of the same value by returning this.value - A new value for albedoMixthis objectpublic final R2SurfaceShaderBasicReflectiveParameters withSpecularTexture(R2Texture2DUsableType value)
specularTexture attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for specularTexturethis objectpublic final R2SurfaceShaderBasicReflectiveParameters withSpecularExponent(float value)
specularExponent attribute.
A value strict bits equality used to prevent copying of the same value by returning this.value - A new value for specularExponentthis objectpublic final R2SurfaceShaderBasicReflectiveParameters withNormalTexture(R2Texture2DUsableType value)
normalTexture attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for normalTexturethis objectpublic final R2SurfaceShaderBasicReflectiveParameters withAlphaDiscardThreshold(float value)
alphaDiscardThreshold attribute.
A value strict bits equality used to prevent copying of the same value by returning this.value - A new value for alphaDiscardThresholdthis objectpublic final R2SurfaceShaderBasicReflectiveParameters withEnvironmentTexture(R2TextureCubeUsableType value)
environmentTexture attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for environmentTexturethis objectpublic final R2SurfaceShaderBasicReflectiveParameters withEnvironmentMix(float value)
environmentMix attribute.
A value strict bits equality used to prevent copying of the same value by returning this.value - A new value for environmentMixthis objectpublic boolean equals(Object another)
R2SurfaceShaderBasicReflectiveParameters that have equal attribute values.public int hashCode()
textureDefaults, albedoColor, specularColor, emission, emissionTexture, albedoTexture, albedoMix, specularTexture, specularExponent, normalTexture, alphaDiscardThreshold, environmentTexture, environmentMix.public String toString()
R2SurfaceShaderBasicReflectiveParameters with attribute values.public static R2SurfaceShaderBasicReflectiveParameters of(R2TextureDefaultsType textureDefaults, com.io7m.jtensors.parameterized.PVectorI4F<R2SpaceRGBAType> albedoColor, com.io7m.jtensors.parameterized.PVectorI3F<R2SpaceRGBType> specularColor, float emission, R2Texture2DUsableType emissionTexture, R2Texture2DUsableType albedoTexture, float albedoMix, R2Texture2DUsableType specularTexture, float specularExponent, R2Texture2DUsableType normalTexture, float alphaDiscardThreshold)
R2SurfaceShaderBasicReflectiveParameters instance.textureDefaults - The value for the textureDefaults attributealbedoColor - The value for the albedoColor attributespecularColor - The value for the specularColor attributeemission - The value for the emission attributeemissionTexture - The value for the emissionTexture attributealbedoTexture - The value for the albedoTexture attributealbedoMix - The value for the albedoMix attributespecularTexture - The value for the specularTexture attributespecularExponent - The value for the specularExponent attributenormalTexture - The value for the normalTexture attributealphaDiscardThreshold - The value for the alphaDiscardThreshold attributepublic static R2SurfaceShaderBasicReflectiveParameters copyOf(R2SurfaceShaderBasicReflectiveParametersType instance)
R2SurfaceShaderBasicReflectiveParametersType value.
Uses accessors to get values to initialize the new immutable instance.
If an instance is already immutable, it is returned as is.instance - The instance to copypublic static R2SurfaceShaderBasicReflectiveParameters.Builder builder()
R2SurfaceShaderBasicReflectiveParameters.Copyright © 2016 <code@io7m.com> http://io7m.com