Post

Replies

Boosts

Views

Activity

Reply to Show image in vision pro app
Drag and drop an image into Assets.xcassets in your project. I used "SoccerBall.png". Then call it in ContentView like this: (Note that you should not include the file extension in Image. Maybe that's why yours isn't working. Try using Image("IMG_3984")) import SwiftUI import RealityKit import RealityKitContent struct ContentView: View { var body: some View { VStack { //Model3D(named: "Scene", bundle: realityKitContentBundle) // .padding(.bottom, 50) Text("Hello, world!") Image("SoccerBall").resizable().scaledToFit() } .padding() } } #Preview(windowStyle: .automatic) { ContentView() }
Topic: App & System Services SubTopic: Core OS Tags:
Feb ’24
Reply to How to revert to non beta iOS 17?
I can't remember but when I did this, I had to go to software update and reinstall the non-beta version of iOS. Once you remove the beta profile, go to Software update and it should let you 'update' to the non-beta version. Sorry, it's been a while since I did this. I can't remember exact steps.
Topic: App & System Services SubTopic: Core OS Tags:
Feb ’24
Reply to Unable to scan barcode from an Image using vision
I would start by modifying an existing sample app: https://developer.apple.com/documentation/vision/detecting_objects_in_still_images
Topic: Machine Learning & AI SubTopic: General Tags:
Replies
Boosts
Views
Activity
Mar ’24
Reply to Scanner issue on Sonoma
Hello, This is the developer forum. For non-developer issues, you need to post here: https://discussions.apple.com/welcome
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Mar ’24
Reply to Show image in vision pro app
Drag and drop an image into Assets.xcassets in your project. I used "SoccerBall.png". Then call it in ContentView like this: (Note that you should not include the file extension in Image. Maybe that's why yours isn't working. Try using Image("IMG_3984")) import SwiftUI import RealityKit import RealityKitContent struct ContentView: View { var body: some View { VStack { //Model3D(named: "Scene", bundle: realityKitContentBundle) // .padding(.bottom, 50) Text("Hello, world!") Image("SoccerBall").resizable().scaledToFit() } .padding() } } #Preview(windowStyle: .automatic) { ContentView() }
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Feb ’24
Reply to How to revert to non beta iOS 17?
I can't remember but when I did this, I had to go to software update and reinstall the non-beta version of iOS. Once you remove the beta profile, go to Software update and it should let you 'update' to the non-beta version. Sorry, it's been a while since I did this. I can't remember exact steps.
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Feb ’24
Reply to Using camera on app playground submission
I don't know much about the Swift Student Challenge but what happens if you run your app in the Simulator? Does it present a message saying that the app requires a device with a camera in order to function?
Replies
Boosts
Views
Activity
Feb ’24
Reply to How to revert to non beta iOS 17?
Google says: https://support.apple.com/en-us/108763
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Feb ’24
Reply to Lost connection to the debugger IDEDebugSessionErrorDomain Code: 22
If you create a simple test app and run it, does it work on the same device?
Replies
Boosts
Views
Activity
Feb ’24
Reply to Swift if statement with multiple conditions
Seems like they are: https://forums.swift.org/t/is-equal-to/31121 I prefer to use the latter and I also prefer to use parentheses when in doubt.
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Feb ’24
Reply to Cant add files to ios simulator
If drag and drop doesn't work for some reason, you can always host a file online and navigate to it using Safari on the Simulator. Safari should allow you to download the file and save it to the Files app.
Replies
Boosts
Views
Activity
Feb ’24
Reply to Cant add files to ios simulator
I was able to drag and drop a pdf file from Finder onto the Simulator. Once I did that, it launched the Files app and allowed me to save it to "On my iPhone" in the Files app. I'm using Xcode 15.2 but on Ventura.
Replies
Boosts
Views
Activity
Feb ’24
Reply to File name globbing in Swift
I believe you're looking for RegEx: https://developer.apple.com/documentation/swift/regex
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Feb ’24
Reply to Plain Segmented Control
You can set the background color to something but I don't know if you can remove it: UISegmentedControl.appearance().backgroundColor = .red
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Feb ’24