Re: How to set up my NSViews?
Re: How to set up my NSViews?
- Subject: Re: How to set up my NSViews?
- From: Richard Charles <email@hidden>
- Date: Tue, 06 Sep 2016 12:12:38 -0600
Use AVPlayerLayer which is a subclass of CALayer. Set your parent NSView as a layer backed view or as a layer hosting view. This process can be a little confusing.
Refer to Setting Up Layer Objects.
https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/CoreAnimation_guide/SettingUpLayerObjects/SettingUpLayerObjects.html
--Richard Charles
> On Sep 6, 2016, at 10:41 AM, Andreas Falkenhahn <email@hidden> wrote:
>
> My NSWindow contains an NSView which I use to draw custom graphics to. It doesn't
> contain any widgets like buttons at all, just custom graphics drawn in drawRect().
>
> Now I'd like to have an AVPlayerView NSView on top of this view. Thus, I tried to
> add this AVPlayerView on top of the NSView by doing the following:
>
> [view addSubview:playerview];
>
> However, this didn't work and generated lots of debug output to stderr. What is
> the way to add an AVPlayerView on top of my window's NSView?
>
> --
> Best regards,
> Andreas Falkenhahn mailto:email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden