TexturedMaterialAppearanceVS.glsl 514 B

1234567891011121314151617181920
  1. attribute vec3 position3DHigh;
  2. attribute vec3 position3DLow;
  3. attribute vec3 normal;
  4. attribute vec2 st;
  5. attribute float batchId;
  6. varying vec3 v_positionEC;
  7. varying vec3 v_normalEC;
  8. varying vec2 v_st;
  9. void main()
  10. {
  11. vec4 p = czm_computePosition();
  12. v_positionEC = (czm_modelViewRelativeToEye * p).xyz; // position in eye coordinates
  13. v_normalEC = czm_normal * normal; // normal in eye coordinates
  14. v_st = st;
  15. gl_Position = czm_modelViewProjectionRelativeToEye * p;
  16. }