Does uu + vv = 1 or uu + vv = t help?
u and v are points on a unit circle on the u and v axes.
Post
Replies
Boosts
Views
Activity
In this case, I found an answer. My C++ is rusty, but this works.
The purpose of the call was to increment a pointer (mTimeBoundsQueuePtr) in a thread-safe manner.
In CARingBuffer.h, at the top of the file, I added
#include <atomic>
and changed the declaration of mTimeBoundsQueuePtr at the bottom from
UInt32 mTimeBoundsQueuePtr;
to
std::atomic<UInt32> mTimeBoundsQueuePtr;
Then in CARingBuffer.cpp, I changed the last line of CARingBuffer::SetTimeBounds
from
CAAtomicCompareAndSwap32Barrier(mTimeBoundsQueuePtr, mTimeBoundsQueuePtr + 1, (SInt32*)&mTimeBoundsQueuePtr);
to
mTimeBoundsQueuePtr++;
I've done additional testing and it appears my conclusions about the sample rate were wrong. When I change the format to 8000 Hz sample rate, while the srcNode render block is still called ever 0.0106 seconds, it is only requesting 85 or 86 samples which corresponds to the lower sample rate. So I think the ringBuffer is working.
Thanks for the reply, but I'm still not clear. The atomic reference shows a function that take 4 parameters and returns a bool. The CAAtomicCompareAndSwap32Barrier takes 3 parameters and doesn't return a value. How do I map the CAAtomic parameters to the atomic parameters?
Can someone explain what the parameters to CAAtomic... are and what the function does to them?
Thanks,
Mark
I recompiled my app with a non-paid developer key set to run locally the other day. Today, when I tried to launch the app, I again got the above error.
Me too, on an existing project, but not a brand new project (just the simple "Hello, World" starter app).
Thanks - I searched all over the Apple Developer site and couldn't find the link. It looks like xcodereleases is a non-apple site that links to the Apple downloads.
Mark
private (set) helps. Thanks.
I think I figured it out. URLSession uses a user agent of the application bundle name / build. Somehow the build setting on my program was cleared so the user agent was / (Unknown version number). That was causing the FCC's server to reject my request. I change the build number in Xcode and I can download my file.
More information:
I copied the download code from this program and created a new program. It is able to download the file (getting an HTTP status code of 200).
So I now think there is something cached in the original program that is causing it to be blocked. If this were a browser, I would clear the caches/cookies/etc. How can I do that with URLSession?
I deleted the CACHES folder under the Library/Containers. I even deleted the entire sandbox under Library/Containers (the program rebuilt it). Still getting the 403 error.
Sorry about the poorly formatted comment. I guess you can't include code blocks in comments, and I can't find a way to delete my comment, so here it is again, in a more readable format.
Thank you for your speedy reply, but I must still be missing something. I created a simple macOS app and modified the ContenView struct.
struct ContentView: View {
var text: String {
if #available(macOS 12, *) {
return "Hello, world! OSX12"
} else {
return "Hello, world! OSX11"
}
}
var body: some View {
Text(text)
.padding()
}
}
`
But no matter how I set the macOS Deployment Target in the project or deployment target in the target, it always displays Hello, world OSX 12 when I run it.
Thanks
Regarding the "copy_read_only:" message. I was able to reproduce the messages on a MacOS app with the "Hello, world" initial view from a new SwiftUI app. I was able to make the message go away by giving the app read/write access to the user selected and pictures folders in the app sandbox, or by removing the sandbox.