アクティブなアトリビュート変数の名前を列挙する

attribute-check.png
int total = -1;
    glGetProgramiv(mProgram, GL_ACTIVE_ATTRIBUTES, &total);
    for (int i = 0; i<total; ++i) {
        int name_len = -1, num = -1;
        GLenum type = GL_ZERO;
        char name[100];
        glGetActiveAttrib(mProgram, GLuint(i), sizeof(name) - 1, &name_len, &num, &type, name);
        name[name_len] = 0;
        cout <

uniform-check

サポートサイト Wikidot.com uniform-check