1/* 2 * Copyright (c) 2013 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#ifndef WEBRTC_MODULES_VIDEO_RENDER_IOS_VIDEO_RENDER_IOS_CHANNEL_H_ 12#define WEBRTC_MODULES_VIDEO_RENDER_IOS_VIDEO_RENDER_IOS_CHANNEL_H_ 13 14#include "webrtc/modules/video_render/video_render_defines.h" 15#include "webrtc/modules/video_render/ios/video_render_ios_view.h" 16 17namespace webrtc { 18 19class VideoRenderIosGles20; 20 21class VideoRenderIosChannel : public VideoRenderCallback { 22 public: 23 explicit VideoRenderIosChannel(VideoRenderIosView* view); 24 virtual ~VideoRenderIosChannel(); 25 26 // Implementation of VideoRenderCallback. 27 int32_t RenderFrame(const uint32_t stream_id, 28 const VideoFrame& video_frame) override; 29 30 int SetStreamSettings(const float z_order, 31 const float left, 32 const float top, 33 const float right, 34 const float bottom); 35 bool IsUpdated(); 36 bool RenderOffScreenBuffer(); 37 38 private: 39 VideoRenderIosView* view_; 40 VideoFrame* current_frame_; 41 bool buffer_is_updated_; 42}; 43 44} // namespace webrtc 45#endif // WEBRTC_MODULES_VIDEO_RENDER_IOS_VIDEO_RENDER_IOS_CHANNEL_H_ 46