| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_FILTERS_GPU_VIDEO_DECODER_H_ | 5 #ifndef MEDIA_FILTERS_GPU_VIDEO_DECODER_H_ |
| 6 #define MEDIA_FILTERS_GPU_VIDEO_DECODER_H_ | 6 #define MEDIA_FILTERS_GPU_VIDEO_DECODER_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <list> | 9 #include <list> |
| 10 #include <map> | 10 #include <map> |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 // Allocate & delete native textures. | 43 // Allocate & delete native textures. |
| 44 virtual bool CreateTextures(int32 count, const gfx::Size& size, | 44 virtual bool CreateTextures(int32 count, const gfx::Size& size, |
| 45 std::vector<uint32>* texture_ids) = 0; | 45 std::vector<uint32>* texture_ids) = 0; |
| 46 virtual bool DeleteTexture(uint32 texture_id) = 0; | 46 virtual bool DeleteTexture(uint32 texture_id) = 0; |
| 47 | 47 |
| 48 // Allocate & return a shared memory segment. Caller is responsible for | 48 // Allocate & return a shared memory segment. Caller is responsible for |
| 49 // Close()ing the returned pointer. | 49 // Close()ing the returned pointer. |
| 50 virtual base::SharedMemory* CreateSharedMemory(size_t size) = 0; | 50 virtual base::SharedMemory* CreateSharedMemory(size_t size) = 0; |
| 51 }; | 51 }; |
| 52 | 52 |
| 53 // Takes ownership of |factories| but not |message_loop|. | 53 GpuVideoDecoder(MessageLoop* message_loop, scoped_ptr<Factories> factories); |
| 54 GpuVideoDecoder(MessageLoop* message_loop, Factories* factories); | |
| 55 virtual ~GpuVideoDecoder(); | 54 virtual ~GpuVideoDecoder(); |
| 56 | 55 |
| 57 // Filter implementation. | 56 // Filter implementation. |
| 58 virtual void Stop(const base::Closure& callback) OVERRIDE; | 57 virtual void Stop(const base::Closure& callback) OVERRIDE; |
| 59 virtual void Seek(base::TimeDelta time, const FilterStatusCB& cb) OVERRIDE; | 58 virtual void Seek(base::TimeDelta time, const FilterStatusCB& cb) OVERRIDE; |
| 60 virtual void Pause(const base::Closure& callback) OVERRIDE; | 59 virtual void Pause(const base::Closure& callback) OVERRIDE; |
| 61 virtual void Flush(const base::Closure& callback) OVERRIDE; | 60 virtual void Flush(const base::Closure& callback) OVERRIDE; |
| 62 | 61 |
| 63 // VideoDecoder implementation. | 62 // VideoDecoder implementation. |
| 64 virtual void Initialize(DemuxerStream* demuxer_stream, | 63 virtual void Initialize(DemuxerStream* demuxer_stream, |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 178 std::list<scoped_refptr<VideoFrame> > ready_video_frames_; | 177 std::list<scoped_refptr<VideoFrame> > ready_video_frames_; |
| 179 int64 next_picture_buffer_id_; | 178 int64 next_picture_buffer_id_; |
| 180 int64 next_bitstream_buffer_id_; | 179 int64 next_bitstream_buffer_id_; |
| 181 | 180 |
| 182 DISALLOW_COPY_AND_ASSIGN(GpuVideoDecoder); | 181 DISALLOW_COPY_AND_ASSIGN(GpuVideoDecoder); |
| 183 }; | 182 }; |
| 184 | 183 |
| 185 } // namespace media | 184 } // namespace media |
| 186 | 185 |
| 187 #endif // MEDIA_FILTERS_GPU_VIDEO_DECODER_H_ | 186 #endif // MEDIA_FILTERS_GPU_VIDEO_DECODER_H_ |
| OLD | NEW |