迅速在UIimage上创建一个点

时间:2019-04-18 20:07:10

标签: swift xcode uiimageview

我需要您的帮助来解决此问题。 我的UIImage允许使用 PanGesture 在屏幕上移动,并且还具有 TapGesture 可以随着trasform旋转

.transform.rotated(by: CGFloat(M_PI_4))

在用户完成定位和旋转后,他单击UI按钮以在图像的角上显示四个点

//dotcode
    let dotSize = 20
        let firstDotView = UIView()

        firstDotView.frame = CGRect(x: 0, y: 0, width: dotSize, height: dotSize)
        firstDotView.backgroundColor = UIColor.black
        firstDotView.layer.cornerRadius = 10

        view.addSubview(firstDotView)

1dots like that, don't have any connection with green space

始终显示在角落

0 个答案:

没有答案