微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

如何使用Eyeshot的功能创建螺丝形状

如何解决如何使用Eyeshot的功能创建螺丝形状

我需要使用.NET应用程序中的Eyeshot库创建螺丝形状。

在SolidWorks中,只需创建需要进行扫掠/拉伸的形状/轮廓以及用作轨道或方向的螺旋曲线即可轻松实现。

在SolidWorks中,将螺旋起点定位到​​轮廓直径的某个点,并使用“扫掠”命令结果将要围绕该螺旋驱动/旋转的点并创建所需的形状。

SolidWorks example

在Eyeshot中,我将个人资料创建为LinearPath实体并使用

SweepAsSolid(ICurve rail,double tol,sweepMethodType sweepMethod = sweepMethodType.RotationMinimizingFrames)

功能,但结果不同。似乎SweepAsSolid函数位置螺旋起始点位于轮廓中心且形状不同。

是否可以使用与SolidWorks中相同的步骤通过Eyeshot的库获取所需形状?

解决方法

我认为您正在寻找方法ExtrudeWithTwist():

 func detectScreenShot(action: @escaping () -> ()) {
       UIScreen.main.addObserver(self,forKeyPath: "captured",options: .new,context: nil)
        
        let mainQueue = OperationQueue.main
        NotificationCenter.default.addObserver(forName: UIApplication.userDidTakeScreenshotNotification,object: nil,queue: mainQueue) { notification in
            // executes after screenshot
            print(notification)
            action()
        }
    }



override func observeValue(forKeyPath keyPath: String?,of object: Any?,change: [NSKeyValueChangeKey: Any]?,context: UnsafeMutableRawPointer?) {
        if (keyPath == "captured") {
            let isCaptured = UIScreen.main.isCaptured
          
            print(isCaptured)
        }
    }

the result

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。