Gui: Rename variable to eliminate macro conflict

Windows.h defines 'near' and 'far' macros, and they are actually used in the Inventor codebase (so we can't just undefine them).
This commit is contained in:
Chris Hennes
2024-12-13 16:07:24 -06:00
parent 02a5538fba
commit afe76db288

View File

@@ -788,7 +788,7 @@ RayPickInfo View3DInventor::getObjInfoRay(Base::Vector3d* startvec, Base::Vector
vdy = dirvec->y;
vdz = dirvec->z;
// near plane clipping is required to avoid false intersections
float near = 0.1;
float nearClippingPlane = 0.1;
RayPickInfo ret = {false,
Base::Vector3d(),
@@ -798,7 +798,7 @@ RayPickInfo View3DInventor::getObjInfoRay(Base::Vector3d* startvec, Base::Vector
std::nullopt,
std::nullopt};
SoRayPickAction action(getViewer()->getSoRenderManager()->getViewportRegion());
action.setRay(SbVec3f(vsx, vsy, vsz), SbVec3f(vdx, vdy, vdz), near);
action.setRay(SbVec3f(vsx, vsy, vsz), SbVec3f(vdx, vdy, vdz), nearClippingPlane);
action.apply(getViewer()->getSoRenderManager()->getSceneGraph());
SoPickedPoint* Point = action.getPickedPoint();