mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-19 13:40:49 +03:00
0030791: Visualization - possibility to display materials by different hatching style for clipping
# move capping style from presentation into drawer # crash in capping by setting projection as # several hatch templates
This commit is contained in:
@@ -293,8 +293,11 @@ namespace
|
||||
const gp_Dir aPlaneUp (aPlaneMat.GetValue (0, 2), aPlaneMat.GetValue (1, 2), aPlaneMat.GetValue (2, 2));
|
||||
const gp_Dir& aCameraUp = aCamera->Up();
|
||||
const gp_Vec aCameraPln = aPlaneSide.Dot (aCameraUp) * aPlaneSide + aPlaneUp.Dot (aCameraUp) * aPlaneUp;
|
||||
const gp_Dir& aCameraDir = aCamera->Direction();
|
||||
aRotateAngle = static_cast<Standard_ShortReal> (aCameraPln.AngleWithRef (aPlaneUp, aCameraDir) / M_PI * 180.0);
|
||||
if (aCameraPln.Magnitude() > Precision::Confusion())
|
||||
{
|
||||
const gp_Dir& aCameraDir = aCamera->Direction();
|
||||
aRotateAngle = static_cast<Standard_ShortReal> (aCameraPln.AngleWithRef (aPlaneUp, aCameraDir) / M_PI * 180.0);
|
||||
}
|
||||
}
|
||||
|
||||
aHatchAngle = aRotateAngle;
|
||||
|
Reference in New Issue
Block a user