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 MEDIA_CAST_VIDEO_SENDER_CODECS_VP8_VP8_ENCODER_H_ | 5 #ifndef MEDIA_CAST_VIDEO_SENDER_CODECS_VP8_VP8_ENCODER_H_ |
6 #define MEDIA_CAST_VIDEO_SENDER_CODECS_VP8_VP8_ENCODER_H_ | 6 #define MEDIA_CAST_VIDEO_SENDER_CODECS_VP8_VP8_ENCODER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/threading/thread_checker.h" | 10 #include "base/threading/thread_checker.h" |
(...skipping 19 matching lines...) Expand all Loading... |
30 Vp8Encoder(const VideoSenderConfig& video_config, uint8 max_unacked_frames); | 30 Vp8Encoder(const VideoSenderConfig& video_config, uint8 max_unacked_frames); |
31 | 31 |
32 virtual ~Vp8Encoder(); | 32 virtual ~Vp8Encoder(); |
33 | 33 |
34 // Initialize the encoder before Encode() can be called. This method | 34 // Initialize the encoder before Encode() can be called. This method |
35 // must be called on the thread that Encode() is called. | 35 // must be called on the thread that Encode() is called. |
36 virtual void Initialize() OVERRIDE; | 36 virtual void Initialize() OVERRIDE; |
37 | 37 |
38 // Encode a raw image (as a part of a video stream). | 38 // Encode a raw image (as a part of a video stream). |
39 virtual bool Encode(const scoped_refptr<media::VideoFrame>& video_frame, | 39 virtual bool Encode(const scoped_refptr<media::VideoFrame>& video_frame, |
40 transport::EncodedVideoFrame* encoded_image) OVERRIDE; | 40 transport::EncodedFrame* encoded_image) OVERRIDE; |
41 | 41 |
42 // Update the encoder with a new target bit rate. | 42 // Update the encoder with a new target bit rate. |
43 virtual void UpdateRates(uint32 new_bitrate) OVERRIDE; | 43 virtual void UpdateRates(uint32 new_bitrate) OVERRIDE; |
44 | 44 |
45 // Set the next frame to be a key frame. | 45 // Set the next frame to be a key frame. |
46 virtual void GenerateKeyFrame() OVERRIDE; | 46 virtual void GenerateKeyFrame() OVERRIDE; |
47 | 47 |
48 virtual void LatestFrameIdToReference(uint32 frame_id) OVERRIDE; | 48 virtual void LatestFrameIdToReference(uint32 frame_id) OVERRIDE; |
49 | 49 |
50 private: | 50 private: |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 // This is bound to the thread where Initialize() is called. | 94 // This is bound to the thread where Initialize() is called. |
95 base::ThreadChecker thread_checker_; | 95 base::ThreadChecker thread_checker_; |
96 | 96 |
97 DISALLOW_COPY_AND_ASSIGN(Vp8Encoder); | 97 DISALLOW_COPY_AND_ASSIGN(Vp8Encoder); |
98 }; | 98 }; |
99 | 99 |
100 } // namespace cast | 100 } // namespace cast |
101 } // namespace media | 101 } // namespace media |
102 | 102 |
103 #endif // MEDIA_CAST_VIDEO_SENDER_CODECS_VP8_VP8_ENCODER_H_ | 103 #endif // MEDIA_CAST_VIDEO_SENDER_CODECS_VP8_VP8_ENCODER_H_ |
OLD | NEW |