I've downloaded AVCam app sample from Apple. I added a custom view "GridView" on top of PreviewView, but i would like to size my GridView in order draw my grid on top of the captured image.
How can i get the bound of the capture image?
thanks
I've downloaded AVCam app sample from Apple. I added a custom view "GridView" on top of PreviewView, but i would like to size my GridView in order draw my grid on top of the captured image.
How can i get the bound of the capture image?
thanks
Copyright © 2021 Jogjafile Inc.

You can do something like this:
1- Create a gird
2- In ViewController
define a grid var:
Add call addGrid in viewdidLoad or anywhere that suits you.
Then we need to update the frame of the gridView based on the displayed camera live view.
You call call updateGrid wherever best suits in your case. In here I called it in viewWillAppear after the session starts running:
Output