OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef REMOTING_CODEC_VIDEO_ENCODER_VPX_H_ | 5 #ifndef REMOTING_CODEC_VIDEO_ENCODER_VPX_H_ |
6 #define REMOTING_CODEC_VIDEO_ENCODER_VPX_H_ | 6 #define REMOTING_CODEC_VIDEO_ENCODER_VPX_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
8 #include "base/callback.h" | 10 #include "base/callback.h" |
| 11 #include "base/macros.h" |
9 #include "base/time/time.h" | 12 #include "base/time/time.h" |
10 #include "remoting/codec/scoped_vpx_codec.h" | 13 #include "remoting/codec/scoped_vpx_codec.h" |
11 #include "remoting/codec/video_encoder.h" | 14 #include "remoting/codec/video_encoder.h" |
12 #include "remoting/codec/video_encoder_helper.h" | 15 #include "remoting/codec/video_encoder_helper.h" |
13 | 16 |
14 typedef struct vpx_image vpx_image_t; | 17 typedef struct vpx_image vpx_image_t; |
15 | 18 |
16 namespace webrtc { | 19 namespace webrtc { |
17 class DesktopRegion; | 20 class DesktopRegion; |
18 class DesktopSize; | 21 class DesktopSize; |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 bool lossless_color_ = false; | 65 bool lossless_color_ = false; |
63 | 66 |
64 // Holds the initialized & configured codec. | 67 // Holds the initialized & configured codec. |
65 ScopedVpxCodec codec_; | 68 ScopedVpxCodec codec_; |
66 | 69 |
67 // Used to generate zero-based frame timestamps. | 70 // Used to generate zero-based frame timestamps. |
68 base::TimeTicks timestamp_base_; | 71 base::TimeTicks timestamp_base_; |
69 | 72 |
70 // VPX image and buffer to hold the actual YUV planes. | 73 // VPX image and buffer to hold the actual YUV planes. |
71 scoped_ptr<vpx_image_t> image_; | 74 scoped_ptr<vpx_image_t> image_; |
72 scoped_ptr<uint8[]> image_buffer_; | 75 scoped_ptr<uint8_t[]> image_buffer_; |
73 | 76 |
74 // Active map used to optimize out processing of un-changed macroblocks. | 77 // Active map used to optimize out processing of un-changed macroblocks. |
75 scoped_ptr<uint8[]> active_map_; | 78 scoped_ptr<uint8_t[]> active_map_; |
76 webrtc::DesktopSize active_map_size_; | 79 webrtc::DesktopSize active_map_size_; |
77 | 80 |
78 // True if the codec wants unchanged frames to finish topping-off with. | 81 // True if the codec wants unchanged frames to finish topping-off with. |
79 bool encode_unchanged_frame_; | 82 bool encode_unchanged_frame_; |
80 | 83 |
81 // Used to help initialize VideoPackets from DesktopFrames. | 84 // Used to help initialize VideoPackets from DesktopFrames. |
82 VideoEncoderHelper helper_; | 85 VideoEncoderHelper helper_; |
83 | 86 |
84 DISALLOW_COPY_AND_ASSIGN(VideoEncoderVpx); | 87 DISALLOW_COPY_AND_ASSIGN(VideoEncoderVpx); |
85 }; | 88 }; |
86 | 89 |
87 } // namespace remoting | 90 } // namespace remoting |
88 | 91 |
89 #endif // REMOTING_CODEC_VIDEO_ENCODER_VP8_H_ | 92 #endif // REMOTING_CODEC_VIDEO_ENCODER_VP8_H_ |
OLD | NEW |