RTCEAGLVideoView.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * Copyright 2015 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. #import <Foundation/Foundation.h>
  11. #import <UIKit/UIKit.h>
  12. #import <WebRTC/RTCMacros.h>
  13. #import <WebRTC/RTCVideoRenderer.h>
  14. #import <WebRTC/RTCVideoViewShading.h>
  15. NS_ASSUME_NONNULL_BEGIN
  16. @class RTC_OBJC_TYPE(RTCEAGLVideoView);
  17. /**
  18. * RTCEAGLVideoView is an RTCVideoRenderer which renders video frames
  19. * in its bounds using OpenGLES 2.0 or OpenGLES 3.0.
  20. */
  21. RTC_OBJC_EXPORT
  22. NS_EXTENSION_UNAVAILABLE_IOS("Rendering not available in app extensions.")
  23. @interface RTC_OBJC_TYPE (RTCEAGLVideoView) : UIView <RTC_OBJC_TYPE(RTCVideoRenderer)>
  24. @property(nonatomic, weak) id<RTC_OBJC_TYPE(RTCVideoViewDelegate)> delegate;
  25. - (instancetype)initWithFrame:(CGRect)frame
  26. shader:(id<RTC_OBJC_TYPE(RTCVideoViewShading)>)shader
  27. NS_DESIGNATED_INITIALIZER;
  28. - (instancetype)initWithCoder:(NSCoder *)aDecoder
  29. shader:(id<RTC_OBJC_TYPE(RTCVideoViewShading)>)shader
  30. NS_DESIGNATED_INITIALIZER;
  31. /** @abstract Wrapped RTCVideoRotation, or nil.
  32. */
  33. @property(nonatomic, nullable) NSValue *rotationOverride;
  34. @end
  35. NS_ASSUME_NONNULL_END