The documentation at https://developer.apple.com/documentation/visionos/designing-realitykit-content-with-reality-composer-pro states:
Reality Composer Pro treats your imported assets as read-only.
This is a huge obstacle for me, as I need to do multiple adjustments to the scene.
I somehow managed to actually import one of my assets into the scene and can manipulate it directly, but now I can't figure out how I did this.
As I have to prepare further assets and would like to do this directly in Reality Composer Pro, I'm looking for a way to actually load them into the scene.
Any idea how this can be done?
Post
Replies
Boosts
Views
Activity
I have a rkasset package, from which I load my scene.
In the scene, I'm using entity.findEntity(named:"..") to find entities to activate/deactivate.
When I have entities deactivated in the *.usda, they are not found with this method. Further inspection shows that the deactivated entities seem not to be compiled into the build.
Is there anything I can set that prevents skipping the build for these deactivated entities?
In Swift UI it should be posssible to load a custom symbol from the asset catalog into an image, similar to Image(systemName:) with SF Symbol.However, with beta3 this does not seem to work for me, or I'm overlooking something…Image("foo") works fine with bitmaps from the asset catalog, but trying to use Image("bar") with an SVG – which was generated with the SF Symbols app, it delivers just an error log "no image bar was found in main bundle: file"Any ideas how to make that work?ThanksKlaus
I have a relatively simple SwiftUI component that is a member of both my iOS App target as well as the corresponding WatchKit Extension.
As long as I select either the App scheme and select only the App target, or
the Watch scheme and select only the WatchKitExtension target
the preview works just fine.
As soon as I include the View in both targets, the preview fails with
The run destination iPhone 12 Pro Max is not valid for Running the scheme 'Trallala WatchKit App'. or
The run destination Apple Watch Series 6 - 44mm is not valid for Running the scheme 'MultiTimer'.
respectively. I get that the creation of the preview depends on the current target, but why does including it in additional targets create this error, and of course more important:
How to address that?
Additional question: Is there a way to create previews for both target platforms side by side?
Thanks a million
Klaus
Right now I have to use the credit card associated with my Apple-ID to pay for the developer program – at least if renewing automatically.
As my developer program is for my business, I would much prefer to use my business credit card to pay for it, instead of mingling private and business expenses.
Short of creating a second Apple-ID for this, which would be a pain in the ****, do I have any other options?
I'm trying to understand the following very simple view hierarchy:
struct BugScreenSpacing: View {
		var body: some View {
				VStack {
						Button("This", action:{})
						Button("takes", action:{})
						Button("a lot", action:{})
						Button("of space", action:{})
				}
		}
}
This is cut off at the top.
If I add a spacer and choose to ignore the bottom safe area, the content is still cut off at the top, and even executes the Spacer!
struct BugScreenSpacing: View {
		var body: some View {
				VStack {
						Button("This", action:{})
						Spacer()
						Button("takes", action:{})
						Button("a lot", action:{})
						Button("of space", action:{})
				}.edgesIgnoringSafeArea(.bottom)
		}
}
As soon as I put that into a scrollview, it behaves as expected – full code including previews below:
import SwiftUI
struct BugScreenSpacing: View {
		var body: some View {
				VStack {
						Button("This", action:{})
						Spacer()
						Button("takes", action:{})
						Button("a lot", action:{})
						Button("of space", action:{})
				}.edgesIgnoringSafeArea(.bottom)
		}
}
struct BugScreenSpacing_Previews: PreviewProvider {
		
		static var previews: some View {
				Group {
						BugScreenSpacing()
								.previewDevice("Apple Watch Series 6 - 40mm")
						ScrollView{
								BugScreenSpacing()
						}
						.previewDevice("Apple Watch Series 6 - 40mm")
						//Does not depend on device size:
						BugScreenSpacing()
								.previewDevice("Apple Watch Series 6 - 44mm")
						ScrollView{
								BugScreenSpacing()
						}
						.previewDevice("Apple Watch Series 6 - 44mm")
				}
		}
}
What is happening here? How to correctly use the full available space, and rather are cut at the bottom than at the top?
PDFViewDelegate.pdfViewWillChangeScaleFactor only exists for MacOS, but how to listen for scale changes (at best before they happen) on iOS?I receive the PDFViewScaleChanged notification after the user changes scale by pinching, yet not if she or he does it by double tap. The same is true when trying to override PDFView.scaleFactor setter, double tap scale changes go unnoticed, although scaleFactor is actually adjusted.I'm trying to tackle the issue that there seem to be no reliable way to listen for scale changes (in the best case before they happen).Any ideas?Thanks a millionKlaus