mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-07 18:30:55 +03:00
0025331: Visualization - method V3d_View::ConvertWithProj returns incorrect value
This commit is contained in:
parent
4716247158
commit
3910bc6501
@ -1896,9 +1896,15 @@ void V3d_View::ConvertWithProj(const Standard_Integer Xp,
|
|||||||
|
|
||||||
aResult = myCamera->UnProject (gp_Pnt (anX, anY, aZ - 10.0));
|
aResult = myCamera->UnProject (gp_Pnt (anX, anY, aZ - 10.0));
|
||||||
|
|
||||||
Dx = X - aResult.X();
|
Graphic3d_Vec3d aNormDir;
|
||||||
Dy = Y - aResult.Y();
|
aNormDir.x() = X - aResult.X();
|
||||||
Dz = Z - aResult.Z();
|
aNormDir.y() = Y - aResult.Y();
|
||||||
|
aNormDir.z() = Z - aResult.Z();
|
||||||
|
aNormDir.Normalize();
|
||||||
|
|
||||||
|
Dx = aNormDir.x();
|
||||||
|
Dy = aNormDir.y();
|
||||||
|
Dz = aNormDir.z();
|
||||||
|
|
||||||
if( MyViewer->Grid()->IsActive() ) {
|
if( MyViewer->Grid()->IsActive() ) {
|
||||||
Graphic3d_Vertex aNewVrp = Compute (aVrp) ;
|
Graphic3d_Vertex aNewVrp = Compute (aVrp) ;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user