@AndyGuo
For a quick sanity check, I printed the values of modelMatrix
out to the terminal before and after the line
Cesium.Matrix4.multiply(modelMatrix, hpr, modelMatrix);
Clearly, the value of modelMatrix
is being updated.
Old values:
(0.9685679805246331, -0.16002090567426402, 0.19044520694840888, 1216389.3637977627)
(0.24874900422400484, 0.6230823955824613, -0.741547207676482, -4736323.641980423)
(0, 0.7656119369905421, 0.6433026985312517, 4081321.7428341154)
(0, 0, 0, 1)
New values:
(-0.7598734968458267, 0.6215487848444989, 0.19044520694840888, 1216388.9829073488)
(-0.5262429747133412, -0.4161442903033351, -0.741547207676482, -4736322.158886007)
(-0.38165508034893125, -0.6637025219978154, 0.6433026985312517, 4081320.456228718)
(0, 0, 0, 1)
Do the new matrix values look appropriate to you? I am wondering if they are somehow an invalid input to modelMatrix
. Looking forward to learning more!
-Sam