Newer
Older
casic-smartcity-well-front / static / Cesium / Shaders / Materials / SlopeRampMaterial.glsl
[wangxitong] on 8 Jul 2021 385 bytes mars3d总览
uniform sampler2D image;

czm_material czm_getMaterial(czm_materialInput materialInput)
{
    czm_material material = czm_getDefaultMaterial(materialInput);
    vec4 rampColor = texture2D(image, vec2(materialInput.slope / (czm_pi / 2.0), 0.5));
    rampColor = czm_gammaCorrect(rampColor);
    material.diffuse = rampColor.rgb;
    material.alpha = rampColor.a;
    return material;
}