Offset very strange

I have a CameraPreview which is displaying very strange on the bottom of the screen i have following code
var body: some View {
VStack {
CameraView()
}
...

override public func viewDidLoad() {
super.viewDidLoad()

// Set up the video preview view.
previewView.session = session
previewView.videoPreviewLayer.videoGravity = videoGravity
previewView.videoPreviewLayer.connection?.videoOrientation = AVCaptureVideoOrientation.portrait
previewView.frame = view.frame
...
var body: some View {
VStack {
CameraView()
}
...

override public func viewDidLoad() {
super.viewDidLoad()

// Set up the video preview view.
previewView.session = session
previewView.videoPreviewLayer.videoGravity = videoGravity
previewView.videoPreviewLayer.connection?.videoOrientation = AVCaptureVideoOrientation.portrait
previewView.frame = view.frame
...
` I'm sitting there for 2 hours and cant figure it out
No description
2 Replies
Texilox
TexiloxOP15mo ago
How to get the output displayed on top?
BigWang
BigWang15mo ago
maybe try .ignoressafearea on your view
Want results from more Discord servers?
Add your server