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

Side by Side Diff: content/renderer/video_decode_accelerator_host.h

Issue 6901036: Update VideoDecode PPAPI structs to be consistent with media structures, part 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing a few parameter types Created 9 years, 7 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_VIDEO_DECODE_ACCELERATOR_HOST_H_ 5 #ifndef CONTENT_RENDERER_VIDEO_DECODE_ACCELERATOR_HOST_H_
6 #define CONTENT_RENDERER_VIDEO_DECODE_ACCELERATOR_HOST_H_ 6 #define CONTENT_RENDERER_VIDEO_DECODE_ACCELERATOR_HOST_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 15 matching lines...) Expand all
26 IPC::Message::Sender* ipc_sender, 26 IPC::Message::Sender* ipc_sender,
27 int32 decoder_host_id); 27 int32 decoder_host_id);
28 virtual ~VideoDecodeAcceleratorHost(); 28 virtual ~VideoDecodeAcceleratorHost();
29 29
30 // IPC::Channel::Listener implementation. 30 // IPC::Channel::Listener implementation.
31 virtual void OnChannelConnected(int32 peer_pid); 31 virtual void OnChannelConnected(int32 peer_pid);
32 virtual void OnChannelError(); 32 virtual void OnChannelError();
33 virtual bool OnMessageReceived(const IPC::Message& message); 33 virtual bool OnMessageReceived(const IPC::Message& message);
34 34
35 // media::VideoDecodeAccelerator implementation. 35 // media::VideoDecodeAccelerator implementation.
36 virtual const std::vector<uint32>& GetConfig( 36 virtual const std::vector<uint32> GetConfigs(
37 const std::vector<uint32>& prototype_config); 37 const std::vector<uint32>& prototype_config);
38 virtual bool Initialize(const std::vector<uint32>& config); 38 virtual bool Initialize(const std::vector<uint32>& config);
39 virtual bool Decode(media::BitstreamBuffer* bitstream_buffer, 39 virtual bool Decode(const media::BitstreamBuffer& bitstream_buffer,
40 media::VideoDecodeAcceleratorCallback* callback); 40 media::VideoDecodeAcceleratorCallback* callback);
41 virtual void AssignPictureBuffer( 41 virtual void AssignPictureBuffer(
42 std::vector<PictureBuffer*> picture_buffers); 42 const std::vector<media::PictureBuffer>& picture_buffers);
43 virtual void ReusePictureBuffer(PictureBuffer* picture_buffer); 43 virtual void ReusePictureBuffer(uint32 picture_buffer_id);
44 virtual bool Flush(media::VideoDecodeAcceleratorCallback* callback); 44 virtual bool Flush(media::VideoDecodeAcceleratorCallback* callback);
45 virtual bool Abort(media::VideoDecodeAcceleratorCallback* callback); 45 virtual bool Abort(media::VideoDecodeAcceleratorCallback* callback);
46 46
47 private: 47 private:
48 // Message loop that this object runs on. 48 // Message loop that this object runs on.
49 MessageLoop* message_loop_; 49 MessageLoop* message_loop_;
50 50
51 // A router used to send us IPC messages. 51 // A router used to send us IPC messages.
52 MessageRouter* router_; 52 MessageRouter* router_;
53 53
54 // Sends IPC messages to the GPU process. 54 // Sends IPC messages to the GPU process.
55 IPC::Message::Sender* ipc_sender_; 55 IPC::Message::Sender* ipc_sender_;
56 56
57 // Route ID of the GLES2 context in the GPU process. 57 // Route ID of the GLES2 context in the GPU process.
58 int context_route_id_; 58 int context_route_id_;
59 59
60 // ID of this VideoDecodeAcceleratorHost. 60 // ID of this VideoDecodeAcceleratorHost.
61 int32 decoder_host_id_; 61 int32 decoder_host_id_;
62 62
63 // ID of VideoDecodeAccelerator in the GPU process. 63 // ID of VideoDecodeAccelerator in the GPU process.
64 int32 decoder_id_; 64 int32 decoder_id_;
65 65
66 // Transfer buffers for both input and output. 66 // Transfer buffers for both input and output.
67 // TODO(vmr): move into plugin provided IPC buffers. 67 // TODO(vmr): move into plugin provided IPC buffers.
68 scoped_ptr<base::SharedMemory> input_transfer_buffer_; 68 scoped_ptr<base::SharedMemory> input_transfer_buffer_;
69 69
70 std::vector<uint32> configs_;
71
72 DISALLOW_COPY_AND_ASSIGN(VideoDecodeAcceleratorHost); 70 DISALLOW_COPY_AND_ASSIGN(VideoDecodeAcceleratorHost);
73 }; 71 };
74 72
75 #endif // CONTENT_RENDERER_VIDEO_DECODE_ACCELERATOR_HOST_H_ 73 #endif // CONTENT_RENDERER_VIDEO_DECODE_ACCELERATOR_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698