Re: Stroking "on the inside" with NSBezierPath
The default stroke seems to be one that assumes the path you make is the center of the stroke. How can I make the stroke be on one of the *side* of the path? Depending on how you look at it it could be to the "right", "left", "outside" or "inside". Any way to modify that? Thanks,U Just set the clip path to your path before stroking it. Matthew ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: Optimized image drawing (currently using CGImageCreate -> CGContextDrawImage)
As far as I remember, you can get something like 1000 512x512 image draw per sec on a mac pro (not a very good card, but not bad also). If you use OpenGL instead of CoreGraphics, this is more like 7000 1024x768 image per sec. Did you have QuartzGL turned on when you tested this? Matthew ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: custom view binding to NSTreeController
On Dec 5, 2008, at 8:23 AM, Rob Keniger wrote: On 05/12/2008, at 1:29 AM, Matthew Johnson wrote: I agree it's a shame. There are plenty of examples for simpler binding scenarios, but none I have found for custom views binding to NSTreeController. I really appreciate your sample will do something similar if I don't find a better way. You're right that it will be fast for smaller data sets. The problem is that it should be a constant time operation and your code is much more expensive than that. Depending on the implementation of removeItemsInArray your code is at least O(n) and it is likely to be O(n2). That will not scale to large data sets very well. I agree. I had a look at a class-dump of AppKit and it doesn't look like there's much in there that would help in this. There really needs to be a way for NSTreeController's arrangedObjects KVO notifications to include the NSTreeNodes that are being added/ removed. There seems no reason why they couldn't be included in the change dictionary. I think I'll file a bug against it. Sounds good. Let me know what the radar number is and I'll file one also and mention your radar. Thanks, Matthew ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: custom view binding to NSTreeController
As far as I know it's the only way, all the examples I've ever seen use a similar method. Array iteration is pretty fast and I can only imagine it being slow for a very large data set. I've definitely never had performance issues with it, but I am not creating large trees. I also would love to hear from Apple if there's a better way. It's certainly a shame there is not more example code out there. I agree it's a shame. There are plenty of examples for simpler binding scenarios, but none I have found for custom views binding to NSTreeController. I really appreciate your sample will do something similar if I don't find a better way. You're right that it will be fast for smaller data sets. The problem is that it should be a constant time operation and your code is much more expensive than that. Depending on the implementation of removeItemsInArray your code is at least O(n) and it is likely to be O (n2). That will not scale to large data sets very well. Matthew ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
custom view binding to NSTreeController
I am creating a custom view which I would like to bind to NSTreeController. I have tried observing both [treeController arrangedObjects] and [[treeController arrangedObjects] childNodes]. Both seem to only notify that a change has occurred and do not provide any details about the change (insertion, removal, etc). If this is the case, you would have to walk the entire tree every time a change happens in order to detect changes. This seems like a pretty bad idea. There must be a better way to do this. I am hoping somebody can share an example of how to implement the observation necessary to create a custom view that binds to NSTreeController. Does anybody have sample code? Is anyone able to provide a high level idea of how NSOutlineView and NSBrowser do this? Is it even possible to do this efficiently with public API? Thanks, Matthew ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
subclassing CAAnimation
I would like to subclass CAAnimation to implement an animation with custom rendering. I can't find any details about how animations work with the render tree to render each frame. There doesn't appear to be public API for this yet. This is an experimental project so I don't mind using unsupported APIs if anyone knows how to do this. Any help is much appreciated. Thanks, Matthew ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]