我正在查看 OpenGL 示例,在创建对象之前,这两个示例遵循不同的方式。这两个例子有什么区别?
1)
glActiveTexture(GL_TEXTURE0);
glBindTexture(GL_TEXTURE_2D,myImg);
glActiveTexture(GL_TEXTURE1);
glBindTexture(GL_TEXTURE_2D,myImg2);
2)
glEnable(GL_TEXTURE_2D);
glBindTexture(GL_TEXTURE_2D, _textureId[0]);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);