I am exploring ARKit and SceneKit, but I am not sure if what I want to do is possible. In App1: Run an ARKit session using configuration.sceneReconstruction = .mesh I am rending the mesh in func renderer(_ renderer: SCNSceneRenderer, didAdd node: SCNNode, for anchor: ARAnchor) and func renderer(_ renderer: SCNSceneRenderer, didUpdate node: SCNNode, for anchor: ARAnchor) and the mesh appears correct I have set up a button that does the following: Capture the mesh to an .obj file (based off the excellent answer in here) Capture a snapshot (SCNView snapshot) Store the AR Camera Transform Store the AR SCN View Point Of View Projection Transform Storing the transforms in a CSV, and taking care to ensure I restore them in column major order. In App2: Load the geometry from the .obj file into SCNNode, do not apply any transform to it, apply a wireframe to it so I can visualise it Add a camera and apply the 2 saved transforms (AR Camera Transform and then AR SCN View Point Of View Projection Transform Set th
Search results for
column
2,061 results found
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
Hi, I'm trying to change the behaviour of Command-click on Code under Xcode > Settings > Navigation to display the Action menu to use features such as Add Column Breakpoint. But unfortunately the option Selects Code Structure is not visible when unfolding for different options, the only choices are Jumps To Definition and Multi Cursor. I have seen other users having Selects Code Structure instead of Multi Cursor, I really wonder how Multi Cursor got there 😅 . Is there a way to make Selects Code Structure visible and selectable? Any help would be appreciated. I'm running Xcode 15 on macOS Sonoma.
When using the column based split view controller, it presumes that clients want a navigation controller in each of its non-compact columns and will wrap a view controller in one of not provided. This is primarily so that collapsing (when it moves from multiple to single column) behaves deterministically and automatically. So what is happening is you're getting a tab bar controller wrapped in a navigation controller with additional navigation controllers inside – and thus double navigation bars. Realistically this may be a case where you want to create your own custom view controller container instead of using UISplitViewController, as I'm not sure how many of the edge cases you would hit might be resolved.
Topic:
UI Frameworks
SubTopic:
UIKit
Tags:
I had the exact same problem. On the first startup everything is ok, then on the second one it crashes. It seems SwiftData doesn't see the already existing column for one-to-many relationship. This, in turn, crashes the application because of the duplicated column. The solution that I found is to explicitly create the inverse relationship in the second model. So, in your case, changing your DeskPosition model to this: @Model final class DeskPosition { let id: UUID var title: String var desk: Desk? private var heightInCm: Double @Transient var height: DeskHeight { get { DeskHeight(value: heightInCm, unit: .centimeters).localized } set { heightInCm = newValue.converted(to: .centimeters).value } } init(id: UUID, height: DeskHeight, title: String) { self.id = id self.heightInCm = height.converted(to: .centimeters).value self.title = title self.height = height } }
Topic:
App & System Services
SubTopic:
iCloud & Data
Tags:
I recently switched from Windows to a macbook air m2 with 16gbs ram. It was all great in the beginning and now after a week it when using devtools in Chrome, Brave, Firefox.. the helper (renderer) process goes up to 150% in the cpu (%) column and there's 2 of these at 100%+ each. I tried running the same thing on my Windows machine and it runs normally. On the mac it doesnt even load the autofill for css properties, it lags way too much, makes the whole system unusable and hot. My windows machine is not even close to match the performance of the m2. I am not sure what's wrong, any suggestions? I disabled hardware acceleration, I have no extensions (even disabled the google docs offline extension), system is up to date, chrome is up to date, cleared storage and cache. I feel like I am out of options.
AFAIK, not directly in Table. When there are multiple columns, would you have section for a specific column or for all ? It is possible in List. Cen you adapt your code to use List instead ?
Topic:
UI Frameworks
SubTopic:
SwiftUI
Tags:
Using a Dispatch semaphore to turn an asynchronous call into a synchronous call is generally considered bad form. That’s because the semaphore can’t propagate priority. That’s why we have -synchronousRemoteObjectProxyWithErrorHandler:. In the code serverProxy for synchronousRemoteObjectProxyWithErrorHandler access object The use of dispatch_async is to implement an asynchronous operation, and implement the corresponding timeout operation, to be precise, I should be required here to drop a serial column, the reason is because I found the line of sight NSXPC interface call timeout mode is like this. On the server side does not trigger the callback, the awareness is that the client side calls callbackWithInfo:info reply:^(bool action) and waits for the server side to call the action to implement the callback, but if the server side does not call the action all the time, That leads to more and more fds. I'm sure that if the NSXPC server side does not call the action callback function, the number of ports
Topic:
App & System Services
SubTopic:
Processes & Concurrency
Tags:
I'm trying to use the new (announced at WWDC 2023 and available in iOS 17 and macOS 14) API to observe scroll position of SwiftUI ScrollView. I have the following view, but I can't make it work correctly. That is, using the scrollPosition(id:anchor) view modifier makes the scroll view go nuts. At some point, and in some cases even at the very beginning, the scroll view just starts jumping and is stuttering when trying to scroll. See the screen recording here: https://mastodon.social/@tomkraina/111249340792812592 The code: struct ContentView: View { private var itemSize: CGSize = .init(width: 50.0, height: 50.0) // Annotated as @State to create the sections only once @State private var sectionData = makeSections() // Tracking scroll position @State private var currentItemID: MyIdentifier? var currentItemDescription: String { self.currentItemID?.stringId ?? nil } var body: some View { VStack { // 1. Scroll View ScrollView(.vertical) { LazyVGrid( columns: [.init(.adaptive(minimum: self.itemSize.width),
All datasets are doubles with around 20-50 columns and around 1000 rows. I have noticed the significant slowdown across the board, whether training with just 50 rows or up to 1000. All exhibit the same degree of slowdown. The slowdown scales linearly with the number of iterations performed.
Topic:
Machine Learning & AI
SubTopic:
General
Tags:
This may be trivial to some but I just would like to know if you can copy an array to a new array and change the type of the data for each column of elements? I have loaded a file into an array as String data as I can't seem to do it any other way (i.e. as another type) I now want to convert some of the columns to a different type in possibly a new array. I have an array full of string data and I would like to convert it to Double, or some Int, data so that I can easily do my calculations. I would appreciate as much info as possible as I am relatively new to SwiftUI and Xcode. Many thanks, D Norris
Hello everyone, I am experiencing a very weird issue. I have a simple relationship between 2 models, that occasionally starts crashing the app, with the following error: error: : Attempting recovery from error encountered during addPersistentStore: 0x282523c60 Error Domain=NSCocoaErrorDomain Code=134110 An error occurred during persistent store migration. UserInfo={sourceURL=file:///private/var/mobile/Containers/Shared/AppGroup/F8286D67-AC8C-4441-A151-13B5AAA509F3/Library/Application%20Support/default.store, reason=Cannot migrate store in-place: I/O error for database at /private/var/mobile/Containers/Shared/AppGroup/F8286D67-AC8C-4441-A151-13B5AAA509F3/Library/Application Support/default.store. SQLite error code:1, 'duplicate column name: Z1POSITIONS', destinationURL=file:///private/var/mobile/Containers/Shared/AppGroup/F8286D67-AC8C-4441-A151-13B5AAA509F3/Library/Application%20Support/default.store, NSUnderlyingError=0x2825c6700 {Error Domain=NSCocoaErrorDomain Code=134110 An error occurred during
I am using public struct ShareLink : View where Data : RandomAccessCollection, PreviewImage : Transferable, PreviewIcon : Transferable, Label : View, Data.Element : Transferable {} And it is generating entitlement errors and not working reliably ( will transfer 1-3 items, but not 4+ ; will not work a second time) Error is: Error acquiring assertion: Received port for identifier response: <> with error:Error Domain=RBSServiceErrorDomain Code=1 Client not entitled UserInfo={RBSEntitlement=com.apple.runningboard.process-state, NSLocalizedFailureReason=Client not entitled, RBSPermanent=false} elapsedCPUTimeForFrontBoard couldn't generate a task port Received port for identifier response: <> with error:Error Domain=RBSServiceErrorDomain Code=1 Client not entitled UserInfo={RBSEntitlement=com.apple.runningboard.process-state, NSLocalizedFailureReason=Client not entitled, RBSPermanent=false} elapsedCPUTimeForFrontBoard couldn't generate a task port Received port for identifier response: <> with er
I'm confused by the stats on the TestFlight builds screen. See below. There are more crashes than sessions. So the definition of session can't quite be what I thought. Does a session have to last more than a certain amount of time to be included? Do sessions that end in a crash not count as sessions? Do multiple invocations within a short period of time count as a single session? The number of sessions falls over time. I.e. once I have released a new version, the reported Sessions numbers for older versions slowly fall. Maybe as soon as a user has used version N+1, all their sessions for version N are removed from the stats? The invites column is clearly the same for every version, while it should have been slowly increasing. Is there any value in these numbers?
I have a two column LazyVGrid inside a ScrollView and want to animate the removal of an item when the user taps on it. This seems to work fine when either the top or the bottom of the grid is visible (i.e. scrolled all the way up or down) and when removing an item doesn't change the number of rows. But when you scroll down a bit and remove an item when it results in the number of rows changing, it flashes as it's rendering. Minimally Reproducible Example import SwiftUI extension Color { static var random: Color { let red = Double.random(in: 0...1) let green = Double.random(in: 0...1) let blue = Double.random(in: 0...1) return Color(red: red, green: green, blue: blue) } } struct ContentView: View { @State private var items: [Int] = Array(1...50) let columns = [GridItem(.flexible(), spacing: 2), GridItem(.flexible(), spacing: 2)] var colorDictionary: [Int: Color] = [:] init() { for i in 1...50 { colorDictionary[i] = Color.random } } var body: some View { ScrollView { LazyVGrid(columns
Found the fix! Choose your Target, select Build Phases. Expand Link Binary With Libraries, press the + button Add your Framework (in this case, VisionKit)... and then choose 'Optional' in the status column. Not quite sure why this fixes it, but it does.
Topic:
Programming Languages
SubTopic:
Swift
Tags: