src/third_party/angle/src/libANGLE/VaryingPacking.cpp
// true if varying x has a higher priority in packing than y
true if varying x has a higher priority in packing than y
true if varying x has a higher priority in packing than y
bool ComparePackedVarying(const PackedVarying &x, const PackedVarying &y)
{
    sh::ShaderVariable vx, vy;
    const sh::ShaderVariable *px, *py;
    px = &x.varying();
    py = &y.varying();
    if (x.isArrayElement())
    {
        vx = *px;
        vx.arraySizes.clear();
        px = &vx;
    }
    if (y.isArrayElement())
    {
        vy = *py;
        vy.arraySizes.clear();
        py = &vy;
    }
    return gl::CompareShaderVar(*px, *py);
}
bool ComparePackedVarying ( const PackedVarying & x , const PackedVarying & y ) { sh :: ShaderVariable vx , vy ; const sh :: ShaderVariable * px , * py ; px = & x . varying ( ) ; py = & y . varying ( ) ; if ( x . isArrayElement ( ) ) { vx = * px ; vx . arraySizes . clear ( ) ; px = & vx ; } if ( y . isArrayElement ( ) ) { vy = * py ; vy . arraySizes . clear ( ) ; py = & vy ; } return gl :: CompareShaderVar ( * px , * py ) ; }
true if varying x has a higher priority in packing than y
true if varying x has a higher priority in packing than y
// If the PackedVarying 'x' or 'y' to be compared is an array element, this clones an equivalent // non-array shader variable 'vx' or 'vy' for actual comparison instead.