Post

Replies

Boosts

Views

Activity

Reply to Sampling 3D Metal Textures on M1
All right, so this is what happened: After setting the texture in the compute encoder and ending the encoding, but before committing the command buffer, I was flagging the texture as purgeable. For some reason Intel did not purge the texture before rendering, while M1 did.
Apr ’21
Reply to Sampling 3D Metal Textures on M1
Thanks. I'll see about feedback assistant tomorrow, but I'm not sure if I will be able to create a concise project that reproduces that. What I am utterly confused about is that this code works perfectly fine on Intel and fails on M1. I tried adding Blit synchronize for the texture, thinking that maybe this was the cause, but it didn't do anything. Interestingly, I found out that only for the green channel I get the 0.0f values, for everything else I seem to be getting "nothing" (meaning that when I add or multiply the sample result for r, b or a, it also always comes back as black, while green behaves as if it actually is 0.0f). And the result is always the same, no matter which coordinates I sample. I'd rather not go to 2D array texture unless there's no other solution. Like you said, it would require changes not only in the shader, but also upstream, that I'd rather avoid.
Apr ’21
Reply to MTLTexture -> CIImage -> CGImage crash on options not nil
Thanks. It probably was it, but I've found an even neater solution: swift public var cgImage: CGImage? { guard let image = CIImage(mtlTexture: self, options: nil) else { print("CIImage not created") return nil } let flipped = image.transformed(by: CGAffineTransform(scaleX: 1, y: -1)) return CIContext().createCGImage(flipped, from: flipped.extent, format: CIFormat.RGBA8, colorSpace: CGColorSpace(name: CGColorSpace.linearSRGB)!) }
Apr ’21
Reply to Installing Launch Daemon?
Thank you. Is there an example of how to do it that I could look at? I've examined the Distribution XML reference and guidelines on creating Agents and Daemons, but I could not find how I should approach the installation. I have no experience creating installers on OS X.
Nov ’20