2011-10-25 131 views

回答

1

執行gluProject()的邏輯,這只是幾個矩陣相乘。

+0

作爲一個方面說明,鏈接的文檔沒有提到在* v「= P x M xv *步驟之後完成的透視分割步驟* v」/ = v「(3)* –

+0

嘿,我嘗試了gluproject結果是quiyte奇怪...這是我的矩陣和veritces – pritam001

+0

浮子[] MODELVIEW = target.getViewMatrix(); 浮子[]投影= target.getProjectionMatrix(); 浮子[] modelViewprojectionarray = target.getModelViewProjectionMatrix(); int [] view = {0,0,(int)screenWidth,(int)screenHeight}; float x = screenWidth/2,y = screenHeight/2,z = 0.01f; float [] pos = new float [4 ]; GLU.gluProject(x,y,z,modelView,0, projection,0,view,0, pos,0); float xmovedValue = convertPixelsToDp(pos [0],this); float ymovedValue = convertPixelsToDp(pos [1],this); – pritam001

相關問題