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

Side by Side Diff: content/renderer/media/renderer_gpu_video_decoder_factories.h

Issue 10855051: Use enum instead of string in MessageLoopFactory::GetMessageLoop* (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 4 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 | Annotate | Revision Log
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_RENDERER_MEDIA_RENDERER_GPU_VIDEO_DECODER_FACTORIES_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_RENDERER_GPU_VIDEO_DECODER_FACTORIES_H_
6 #define CONTENT_RENDERER_MEDIA_RENDERER_GPU_VIDEO_DECODER_FACTORIES_H_ 6 #define CONTENT_RENDERER_MEDIA_RENDERER_GPU_VIDEO_DECODER_FACTORIES_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 18 matching lines...) Expand all
29 // the constructor-argument loop (mostly that's the compositor thread, or the 29 // the constructor-argument loop (mostly that's the compositor thread, or the
30 // renderer thread if threaded compositing is disabled), and shmem-related calls 30 // renderer thread if threaded compositing is disabled), and shmem-related calls
31 // go to the render thread. 31 // go to the render thread.
32 class CONTENT_EXPORT RendererGpuVideoDecoderFactories 32 class CONTENT_EXPORT RendererGpuVideoDecoderFactories
33 : public media::GpuVideoDecoder::Factories { 33 : public media::GpuVideoDecoder::Factories {
34 public: 34 public:
35 // Takes a ref on |gpu_channel_host| and tests |context| for NULL before each 35 // Takes a ref on |gpu_channel_host| and tests |context| for NULL before each
36 // use. 36 // use.
37 RendererGpuVideoDecoderFactories( 37 RendererGpuVideoDecoderFactories(
38 GpuChannelHost* gpu_channel_host, 38 GpuChannelHost* gpu_channel_host,
39 MessageLoop* message_loop, 39 const scoped_refptr<base::MessageLoopProxy>& message_loop,
40 const base::WeakPtr<WebGraphicsContext3DCommandBufferImpl>& wgc3dcbi); 40 const base::WeakPtr<WebGraphicsContext3DCommandBufferImpl>& wgc3dcbi);
41 41
42 virtual media::VideoDecodeAccelerator* CreateVideoDecodeAccelerator( 42 virtual media::VideoDecodeAccelerator* CreateVideoDecodeAccelerator(
43 media::VideoCodecProfile profile, 43 media::VideoCodecProfile profile,
44 media::VideoDecodeAccelerator::Client* client) OVERRIDE; 44 media::VideoDecodeAccelerator::Client* client) OVERRIDE;
45 45
46 virtual bool CreateTextures(int32 count, const gfx::Size& size, 46 virtual bool CreateTextures(int32 count, const gfx::Size& size,
47 std::vector<uint32>* texture_ids, 47 std::vector<uint32>* texture_ids,
48 uint32 texture_target) OVERRIDE; 48 uint32 texture_target) OVERRIDE;
49 49
(...skipping 20 matching lines...) Expand all
70 media::VideoDecodeAccelerator::Client* client, 70 media::VideoDecodeAccelerator::Client* client,
71 media::VideoDecodeAccelerator** vda, 71 media::VideoDecodeAccelerator** vda,
72 base::WaitableEvent* waiter); 72 base::WaitableEvent* waiter);
73 void AsyncCreateTextures( 73 void AsyncCreateTextures(
74 int32 count, const gfx::Size& size, std::vector<uint32>* texture_ids, 74 int32 count, const gfx::Size& size, std::vector<uint32>* texture_ids,
75 uint32 texture_target, bool* success, base::WaitableEvent* waiter); 75 uint32 texture_target, bool* success, base::WaitableEvent* waiter);
76 void AsyncDeleteTexture(uint32 texture_id); 76 void AsyncDeleteTexture(uint32 texture_id);
77 void AsyncCreateSharedMemory( 77 void AsyncCreateSharedMemory(
78 size_t size, base::SharedMemory** shm, base::WaitableEvent* waiter); 78 size_t size, base::SharedMemory** shm, base::WaitableEvent* waiter);
79 79
80 MessageLoop* message_loop_; 80 scoped_refptr<base::MessageLoopProxy> message_loop_;
81 scoped_refptr<GpuChannelHost> gpu_channel_host_; 81 scoped_refptr<GpuChannelHost> gpu_channel_host_;
82 base::WeakPtr<WebGraphicsContext3DCommandBufferImpl> context_; 82 base::WeakPtr<WebGraphicsContext3DCommandBufferImpl> context_;
83 DISALLOW_IMPLICIT_CONSTRUCTORS(RendererGpuVideoDecoderFactories); 83 DISALLOW_IMPLICIT_CONSTRUCTORS(RendererGpuVideoDecoderFactories);
84 }; 84 };
85 85
86 #endif // CONTENT_RENDERER_MEDIA_RENDERER_GPU_VIDEO_DECODER_FACTORIES_H_ 86 #endif // CONTENT_RENDERER_MEDIA_RENDERER_GPU_VIDEO_DECODER_FACTORIES_H_
OLDNEW
« no previous file with comments | « content/renderer/media/media_stream_impl.cc ('k') | content/renderer/media/renderer_gpu_video_decoder_factories.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698