site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com hi, I'm wondering if this is a good idea: My application has 3 threads: 1. Reading 2. Image Composing 3. Display so I had the idea to play with thread priority. When 15 frame buffers or free for rendering I give thread priority 80 When 14 frame buffers or free for rendering I give thread priority 73 ... When 1 frame buffers or free for rendering I give thread priority 20 0 frames the thread sleeps. Would this be a good idea? Or is it better that the thread has a constant priority? Should I also use the FixedPriority option: regards, mvo _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... The image composing thread (2) has a buffer of 15 frames, so 15 frames in advance can be generated. When ever a buffer comes available the thread wakes up and generates another one. The questions I have now is that I want to make sure that other threads have more time available to increase responsiveness or even in the future have more displays busy> Another question related, to make sure that my 2nd thread generates enough frames in advance. if (mFixedPriority) { thread_extended_policy_data_t theFixedPolicy; theFixedPolicy.timeshare = false; // set to true for a non-fixed thread BAIL_MSG_OSERROR(thread_policy_set(aMachPort, THREAD_EXTENDED_POLICY, (thread_policy_t)&theFixedPolicy, THREAD_EXTENDED_POLICY_COUNT), "cOS_Thread::SetPriority: failed to set the fixed-priority policy"); } I don't care about user responsive I want my application to run smooth so sending the frames out at correct timing for smooth animation. This email sent to site_archiver@lists.apple.com