Chromium Code Reviews| Index: content/renderer/media/rtc_video_decoder.h |
| =================================================================== |
| --- content/renderer/media/rtc_video_decoder.h (revision 89290) |
| +++ content/renderer/media/rtc_video_decoder.h (working copy) |
| @@ -2,8 +2,8 @@ |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| -#ifndef MEDIA_FILTERS_RTC_VIDEO_DECODER_H_ |
| -#define MEDIA_FILTERS_RTC_VIDEO_DECODER_H_ |
| +#ifndef CONTENT_RENDERER_MEDIA_RTC_VIDEO_DECODER_H_ |
| +#define CONTENT_RENDERER_MEDIA_RTC_VIDEO_DECODER_H_ |
| #include <deque> |
| #include <string> |
| @@ -26,26 +26,24 @@ |
| virtual ~ExternalRenderer() {} |
| }; |
| -namespace media { |
| - |
| -class RTCVideoDecoder : public VideoDecoder, |
| +class RTCVideoDecoder : public media::VideoDecoder, |
|
scherkus (not reviewing)
2011/06/24 21:33:39
nit: use initializer list format
class RTCVideoDe
Ronghua
2011/06/27 22:34:51
Done.
|
| public ExternalRenderer { |
| public: |
| RTCVideoDecoder(MessageLoop* message_loop, const std::string& url); |
| virtual ~RTCVideoDecoder(); |
| // Filter implementation. |
| - virtual void Play(FilterCallback* callback); |
| - virtual void Seek(base::TimeDelta time, const FilterStatusCB& cb); |
| - virtual void Pause(FilterCallback* callback); |
| - virtual void Stop(FilterCallback* callback); |
| + virtual void Play(media::FilterCallback* callback); |
| + virtual void Seek(base::TimeDelta time, const media::FilterStatusCB& cb); |
| + virtual void Pause(media::FilterCallback* callback); |
| + virtual void Stop(media::FilterCallback* callback); |
| // Decoder implementation. |
| - virtual void Initialize(DemuxerStream* demuxer_stream, |
| - FilterCallback* filter_callback, |
| - StatisticsCallback* stat_callback); |
| - virtual const MediaFormat& media_format(); |
| - virtual void ProduceVideoFrame(scoped_refptr<VideoFrame> video_frame); |
| + virtual void Initialize(media::DemuxerStream* demuxer_stream, |
| + media::FilterCallback* filter_callback, |
| + media::StatisticsCallback* stat_callback); |
| + virtual const media::MediaFormat& media_format(); |
| + virtual void ProduceVideoFrame(scoped_refptr<media::VideoFrame> video_frame); |
| virtual bool ProvidesBuffer(); |
| // ExternalRenderer implementation |
| @@ -56,10 +54,6 @@ |
| virtual int DeliverFrame(unsigned char* buffer, |
| int buffer_size); |
| - // TODO(ronghuawu): maybe move this function to a |
| - // base class (RawVideoDecoder) so that the camera preview may share this. |
| - static bool IsUrlSupported(const std::string& url); |
| - |
| private: |
| friend class RTCVideoDecoderTest; |
| FRIEND_TEST_ALL_PREFIXES(RTCVideoDecoderTest, Initialize_Successful); |
| @@ -80,14 +74,13 @@ |
| size_t height_; |
| std::string url_; |
| DecoderState state_; |
| - MediaFormat media_format_; |
| - std::deque<scoped_refptr<VideoFrame> > frame_queue_available_; |
| + media::MediaFormat media_format_; |
| + std::deque<scoped_refptr<media::VideoFrame> > frame_queue_available_; |
| // Used for accessing frame queue from another thread. |
| base::Lock lock_; |
| DISALLOW_COPY_AND_ASSIGN(RTCVideoDecoder); |
| }; |
| -} // namespace media |
| +#endif // CONTENT_RENDERER_MEDIA_RTC_VIDEO_DECODER_H_ |
| -#endif // MEDIA_FILTERS_RTC_VIDEO_DECODER_H_ |