yzt
2023-05-26 2f70f6727314edd84d8ec2bfe3ce832803f1ea77
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
precision highp float;
 
void main() 
{
    // Initialize the attributes struct with all
    // attributes except quantized ones.
    ProcessedAttributes attributes;
    initializeAttributes(attributes);
 
    // Dequantize the quantized ones and add them to the
    // attributes struct.
    #ifdef USE_DEQUANTIZATION
    dequantizationStage(attributes);
    #endif
 
    // Update the position for this instance in place
    #ifdef HAS_INSTANCING
    instancingStage(attributes.positionMC);
        #ifdef USE_PICKING
        v_pickColor = a_pickColor;
        #endif
    #endif
 
    #if defined(HAS_FEATURES) && defined(FEATURE_ID_ATTRIBUTE)
    Feature feature;
    featureStage(feature);
    cpuStylingStage(attributes.positionMC, feature);
    updateFeatureStruct(feature);
    #endif
    
    #ifdef HAS_CUSTOM_VERTEX_SHADER
    customShaderStage(attributes);
    #endif
 
    // Compute the final position in each coordinate system needed.
    // This also sets gl_Position.
    geometryStage(attributes);    
 
    #ifdef PRIMITIVE_TYPE_POINTS
    pointStage();
    #endif
}