OpenGL ES 2.0 an Android: What dimensions should the normalMatrix have?
问题 I am learning OpenGL ES 2.0, without ever having learned OpenGL or OpenGL ES 1.x. I'm applying non-uniform scaling to my modelViewMatrix, so the tutorials tell me that I need to take special steps to compute a normalMatrix. In my application the modelViewMatrix has dimension 4x4. Some tutorials say that for the normalMatrix I need to simply calculate transpose(inverse(modelViewMatrix)). Other instructions say that I need to first take the upper left 3x3 sub-matrix of my modelViewMatrix and