CGContextSaveGState:无效的上下文0x0错误

时间:2014-01-23 10:48:14

标签: objective-c

我正在尝试在我的应用中播放来自Youtube的视频 代码:

videoView = [[UIWebView alloc] initWithFrame:self.frame];
videoView.backgroundColor = [UIColor clearColor];
videoView.opaque = NO;
videoView.delegate = self;
videoView.mediaPlaybackRequiresUserAction=NO;
 videoView.scrollView.scrollEnabled=NO;
NSURL *url=[NSURL URLWithString:str];
NSURLRequest *request=[NSURLRequest requestWithURL:url];
[videoView loadRequest:request];
 [self addSubview:videoView];
videoView=nil;

但它显示了一些错误,如:

CGContextSaveGState: invalid context 0x0 error.
CGContextSetBlendMode: invalid context 0x0.
 CGContextSetAlpha: invalid context 0x0
CGContextScaleCTM: invalid context 0x0.
 CGContextClipToRect: invalid context 0x0.
CGContextDrawTiledImage: invalid context 0x0.
CGContextRestoreGState: invalid context 0x0
 CGContextGetCTM: invalid context 0x0.
 CGContextClipToRect: invalid context 0x0.
 CGContextDrawTiledImage: invalid context 0x0.
 CGContextRestoreGState: invalid context 0x0.
CGContextGetCTM: invalid context 0x0.

0 个答案:

没有答案