Project with camera.
This commit is contained in:
parent
80b5c57639
commit
98257dc480
0
macamera/FrameView/FrameHandler.swift
Normal file
0
macamera/FrameView/FrameHandler.swift
Normal file
26
macamera/FrameView/FrameView.swift
Normal file
26
macamera/FrameView/FrameView.swift
Normal file
@ -0,0 +1,26 @@
|
||||
//
|
||||
// FrameView.swift
|
||||
// macamera
|
||||
//
|
||||
// Created by Maxime on 06/05/2025.
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
|
||||
struct FrameView: View {
|
||||
|
||||
var image: CGImage?
|
||||
private let label = Text("frame")
|
||||
|
||||
var body: some View {
|
||||
if let image = image {
|
||||
Image(image, scale: 1.0, orientation: .up, label: label)
|
||||
} else {
|
||||
Color.black
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#Preview {
|
||||
FrameView()
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user