Post

Replies

Boosts

Views

Activity

Reply to SceneKit / renderNode override/ Metal / Instancing
thank you for your reply! I did try to conform pixelformat like that : (0..<8).forEach{ pipelineDescriptor.colorAttachments[$0].pixelFormat = wd.currentRenderPassDescriptor.colorAttachments[$0].texture?.pixelFormat ?? MTLPixelFormat.invalid pipelineDescriptor.colorAttachments[$0].isBlendingEnabled = true } where wd is the scenerenderer but to no avail do you have by chance link towards your particle instancing example ?
Jun ’23
Reply to SWIFTUI view not completely refreshed!
Answer in this thread actually https://stackoverflow.com/questions/68042687/how-to-make-a-non-observableobject-observable -> one user smartly proposed this @dynamicMemberLookup class Observable<M: AnyObject>: ObservableObject { var model: M init(_ model: M) { self.model = model } subscript<T>(dynamicMember kp: WritableKeyPath<M, T>) -> T { get { model[keyPath: kp] } set { self.objectWillChange.send() // signal change on property update model[keyPath: kp] = newValue } } } -> virtually turning any non observable class into one :-)
Feb ’24