OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 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 | 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 | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 * | 9 * |
10 */ | 10 */ |
11 | 11 |
12 #ifndef WEBRTC_MODULES_VIDEO_CODING_CODECS_H264_H264_ENCODER_IMPL_H_ | 12 #ifndef WEBRTC_MODULES_VIDEO_CODING_CODECS_H264_H264_ENCODER_IMPL_H_ |
13 #define WEBRTC_MODULES_VIDEO_CODING_CODECS_H264_H264_ENCODER_IMPL_H_ | 13 #define WEBRTC_MODULES_VIDEO_CODING_CODECS_H264_H264_ENCODER_IMPL_H_ |
14 | 14 |
15 #include "webrtc/modules/video_coding/codecs/h264/include/h264.h" | 15 #include "webrtc/modules/video_coding/codecs/h264/include/h264.h" |
16 | 16 |
| 17 #include <memory> |
17 #include <vector> | 18 #include <vector> |
18 | 19 |
19 #include "webrtc/base/scoped_ptr.h" | |
20 | 20 |
21 class ISVCEncoder; | 21 class ISVCEncoder; |
22 | 22 |
23 namespace webrtc { | 23 namespace webrtc { |
24 | 24 |
25 class H264EncoderImpl : public H264Encoder { | 25 class H264EncoderImpl : public H264Encoder { |
26 public: | 26 public: |
27 H264EncoderImpl(); | 27 H264EncoderImpl(); |
28 ~H264EncoderImpl() override; | 28 ~H264EncoderImpl() override; |
29 | 29 |
(...skipping 24 matching lines...) Expand all Loading... |
54 int32_t SetPeriodicKeyFrames(bool enable) override; | 54 int32_t SetPeriodicKeyFrames(bool enable) override; |
55 void OnDroppedFrame() override; | 55 void OnDroppedFrame() override; |
56 | 56 |
57 private: | 57 private: |
58 bool IsInitialized() const; | 58 bool IsInitialized() const; |
59 | 59 |
60 ISVCEncoder* openh264_encoder_; | 60 ISVCEncoder* openh264_encoder_; |
61 VideoCodec codec_settings_; | 61 VideoCodec codec_settings_; |
62 | 62 |
63 EncodedImage encoded_image_; | 63 EncodedImage encoded_image_; |
64 rtc::scoped_ptr<uint8_t[]> encoded_image_buffer_; | 64 std::unique_ptr<uint8_t[]> encoded_image_buffer_; |
65 EncodedImageCallback* encoded_image_callback_; | 65 EncodedImageCallback* encoded_image_callback_; |
66 }; | 66 }; |
67 | 67 |
68 } // namespace webrtc | 68 } // namespace webrtc |
69 | 69 |
70 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_H264_H264_ENCODER_IMPL_H_ | 70 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_H264_H264_ENCODER_IMPL_H_ |
OLD | NEW |