Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Side by Side Diff: content/common/gpu/client/gpu_video_decode_accelerator_host.h

Issue 671663002: Standardize usage of virtual/override/final in content/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 CONTENT_COMMON_GPU_CLIENT_GPU_VIDEO_DECODE_ACCELERATOR_HOST_H_ 5 #ifndef CONTENT_COMMON_GPU_CLIENT_GPU_VIDEO_DECODE_ACCELERATOR_HOST_H_
6 #define CONTENT_COMMON_GPU_CLIENT_GPU_VIDEO_DECODE_ACCELERATOR_HOST_H_ 6 #define CONTENT_COMMON_GPU_CLIENT_GPU_VIDEO_DECODE_ACCELERATOR_HOST_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 13 matching lines...) Expand all
24 public media::VideoDecodeAccelerator, 24 public media::VideoDecodeAccelerator,
25 public CommandBufferProxyImpl::DeletionObserver, 25 public CommandBufferProxyImpl::DeletionObserver,
26 public base::NonThreadSafe { 26 public base::NonThreadSafe {
27 public: 27 public:
28 // |this| is guaranteed not to outlive |channel| and |impl|. (See comments 28 // |this| is guaranteed not to outlive |channel| and |impl|. (See comments
29 // for |channel_| and |impl_|.) 29 // for |channel_| and |impl_|.)
30 GpuVideoDecodeAcceleratorHost(GpuChannelHost* channel, 30 GpuVideoDecodeAcceleratorHost(GpuChannelHost* channel,
31 CommandBufferProxyImpl* impl); 31 CommandBufferProxyImpl* impl);
32 32
33 // IPC::Listener implementation. 33 // IPC::Listener implementation.
34 virtual void OnChannelError() override; 34 void OnChannelError() override;
35 virtual bool OnMessageReceived(const IPC::Message& message) override; 35 bool OnMessageReceived(const IPC::Message& message) override;
36 36
37 // media::VideoDecodeAccelerator implementation. 37 // media::VideoDecodeAccelerator implementation.
38 virtual bool Initialize(media::VideoCodecProfile profile, 38 bool Initialize(media::VideoCodecProfile profile, Client* client) override;
39 Client* client) override; 39 void Decode(const media::BitstreamBuffer& bitstream_buffer) override;
40 virtual void Decode(const media::BitstreamBuffer& bitstream_buffer) override; 40 void AssignPictureBuffers(
41 virtual void AssignPictureBuffers(
42 const std::vector<media::PictureBuffer>& buffers) override; 41 const std::vector<media::PictureBuffer>& buffers) override;
43 virtual void ReusePictureBuffer(int32 picture_buffer_id) override; 42 void ReusePictureBuffer(int32 picture_buffer_id) override;
44 virtual void Flush() override; 43 void Flush() override;
45 virtual void Reset() override; 44 void Reset() override;
46 virtual void Destroy() override; 45 void Destroy() override;
47 46
48 // CommandBufferProxyImpl::DeletionObserver implemetnation. 47 // CommandBufferProxyImpl::DeletionObserver implemetnation.
49 virtual void OnWillDeleteImpl() override; 48 void OnWillDeleteImpl() override;
50 49
51 private: 50 private:
52 // Only Destroy() should be deleting |this|. 51 // Only Destroy() should be deleting |this|.
53 virtual ~GpuVideoDecodeAcceleratorHost(); 52 ~GpuVideoDecodeAcceleratorHost() override;
54 53
55 // Notify |client_| of an error. Posts a task to avoid re-entrancy. 54 // Notify |client_| of an error. Posts a task to avoid re-entrancy.
56 void PostNotifyError(Error); 55 void PostNotifyError(Error);
57 56
58 void Send(IPC::Message* message); 57 void Send(IPC::Message* message);
59 58
60 // IPC handlers, proxying media::VideoDecodeAccelerator::Client for the GPU 59 // IPC handlers, proxying media::VideoDecodeAccelerator::Client for the GPU
61 // process. Should not be called directly. 60 // process. Should not be called directly.
62 void OnBitstreamBufferProcessed(int32 bitstream_buffer_id); 61 void OnBitstreamBufferProcessed(int32 bitstream_buffer_id);
63 void OnProvidePictureBuffer(uint32 num_requested_buffers, 62 void OnProvidePictureBuffer(uint32 num_requested_buffers,
(...skipping 28 matching lines...) Expand all
92 91
93 // WeakPtr factory for posting tasks back to itself. 92 // WeakPtr factory for posting tasks back to itself.
94 base::WeakPtrFactory<GpuVideoDecodeAcceleratorHost> weak_this_factory_; 93 base::WeakPtrFactory<GpuVideoDecodeAcceleratorHost> weak_this_factory_;
95 94
96 DISALLOW_COPY_AND_ASSIGN(GpuVideoDecodeAcceleratorHost); 95 DISALLOW_COPY_AND_ASSIGN(GpuVideoDecodeAcceleratorHost);
97 }; 96 };
98 97
99 } // namespace content 98 } // namespace content
100 99
101 #endif // CONTENT_COMMON_GPU_CLIENT_GPU_VIDEO_DECODE_ACCELERATOR_HOST_H_ 100 #endif // CONTENT_COMMON_GPU_CLIENT_GPU_VIDEO_DECODE_ACCELERATOR_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698