Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SSMF features undocumented as of Spring 88.0
- skyReflectModTex (RGBA, A-channel unused)
- should be the same size as specularTex
- modifies the DIFFUSE color as follows
- diffuseColor.r = diffuseColor.r * (1 - skyReflectModTex.r) + reflectionColor.r * skyReflectModTex.r
- diffuseColor.g = diffuseColor.g * (1 - skyReflectModTex.g) + reflectionColor.g * skyReflectModTex.g
- diffuseColor.b = diffuseColor.b * (1 - skyReflectModTex.b) + reflectionColor.b * skyReflectModTex.b
- (before any other shading calculations use diffuseColor)
- can be used to suggest a surface composed of eg. ice or crystals
- lightEmissionTex (RGBA)
- should be the same size as specularTex
- modifies the FRAGMENT color as follows
- fragmentColor.rgb = fragmentColor.rgb * (1 - lightEmissionTex.a) + lightEmissionTex.rgb
- (after the diffuse + detail texturing stages and shadows,
- but before specular/dynamic lighting and fog are applied)
- can be used to accentuate eg. metal spots in shadowed regions
- detailNormalTex (RGBA)
- should be the same size as specularTex
- modifies the SHADING normal as follows
- shadingNormal.xyz = NORMALIZE(terrainNormal.xyz * (1 - detailNormalTex.a) + detailNormalTex.rgb)
- (normals are assumed to be given in tangent-space
- and with the usual XYZ2RGB encoding scheme, where
- texture.rgb = normal.xyz * 0.5 + 0.5)
- can be used to suggest surface details while keeping terrain flat
- parallaxHeightTex (RGBA)
- should be the same size as specularTex
- modifies the diffuse, normal, and specular
- TEXTURE COORDINATES before sampling is done
- height, scale, and bias parameters are packed
- as follows to produce a texel offset-factor f
- h = (parallaxHeightTex.r * 65280 + parallaxHeightTex.g * 256) / 65536
- s = (parallaxHeightTex.b)
- b = (parallaxHeightTex.a - 0.5)
- f = h * s + b
- the mathematics probably won't make much sense,
- so it's better to just experiment with this one
- (tip: you want to end up with small values for s
- and b, eg. s=0.04 and b=-0.02, so for now set the
- blue channel pixels to 10 and alpha channel pixels
- to 75 in your editing tool -- remember that from a
- graphics card's perspective the pixels have values
- between 0 and 1)
- can be used to suggest surface details while keeping terrain flat
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement