Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(102)

Side by Side Diff: webrtc/sdk/objc/Framework/Classes/metal/RTCMTLVideoView.m

Issue 2651743007: Add metal view, shaders and renderer. (Closed)
Patch Set: Address comments Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 /*
2 * Copyright 2017 The WebRTC project authors. All Rights Reserved.
3 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
11 #import "WebRTC/RTCMTLVideoView.h"
12
13 #import <Metal/Metal.h>
14
15 #import "RTCNV12Renderer.h"
16
17 @interface RTCMTLVideoView ()
18 @property(nonatomic) id<RTCMTLRenderer> renderer;
19 @end
20
21 @implementation RTCMTLVideoView {
22 id<RTCMTLRenderer> _renderer;
23 }
24
25 @synthesize renderer = _renderer;
26
27 - (instancetype)initWithFrame:(CGRect)frameRect device:(nullable id<MTLDevice>)d evice {
28 self = [super initWithFrame:frameRect device:device];
29 if (self) {
30 _renderer = [[RTCNV12Renderer alloc] initWithView:self];
31 }
32 return self;
33 }
34
35 - (BOOL)setupRenderer {
36 return [_renderer setup];
37 }
38
39 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698