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

Side by Side Diff: media/video/video_decode_accelerator.h

Issue 7260008: Implement proper synchronization between HW video decode IPC and CommandBuffer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixing compilation errors from bots. Created 9 years, 5 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 MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_ 5 #ifndef MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_
6 #define MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_ 6 #define MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 // 249 //
250 // Returns true when command successfully accepted. Otherwise false. 250 // Returns true when command successfully accepted. Otherwise false.
251 virtual bool Initialize(const std::vector<uint32>& config) = 0; 251 virtual bool Initialize(const std::vector<uint32>& config) = 0;
252 252
253 // Decodes given bitstream buffer. Once decoder is done with processing 253 // Decodes given bitstream buffer. Once decoder is done with processing
254 // |bitstream_buffer| it will call NotifyEndOfBitstreamBuffer() with the 254 // |bitstream_buffer| it will call NotifyEndOfBitstreamBuffer() with the
255 // bitstream buffer id. 255 // bitstream buffer id.
256 // Parameters: 256 // Parameters:
257 // |bitstream_buffer| is the input bitstream that is sent for decoding. 257 // |bitstream_buffer| is the input bitstream that is sent for decoding.
258 // 258 //
259 // Returns true when command successfully accepted. Otherwise false. 259 // Returns true when command successfully accepted. Otherwise false.
scherkus (not reviewing) 2011/06/27 22:54:47 update docs
Ami GONE FROM CHROMIUM 2011/06/28 00:06:35 Done.
260 virtual bool Decode(const BitstreamBuffer& bitstream_buffer) = 0; 260 virtual void Decode(const BitstreamBuffer& bitstream_buffer) = 0;
261 261
262 // Assigns a set of picture buffers to the video decoder. 262 // Assigns a set of picture buffers to the video decoder.
263 // AssignGLESBuffers assigns texture-backed buffers. 263 // AssignGLESBuffers assigns texture-backed buffers.
264 // AssignSysmemBuffers assigns system memory-backed buffers. 264 // AssignSysmemBuffers assigns system memory-backed buffers.
265 // 265 //
266 // Ownership of each picture buffer remains with the client, but the client 266 // Ownership of each picture buffer remains with the client, but the client
267 // is not allowed to deallocate the buffer before the DismissPictureBuffer 267 // is not allowed to deallocate the buffer before the DismissPictureBuffer
268 // callback has been initiated for a given buffer. 268 // callback has been initiated for a given buffer.
269 // 269 //
270 // Parameters: 270 // Parameters:
271 // |buffers| contains the allocated picture buffers for the output. 271 // |buffers| contains the allocated picture buffers for the output.
272 virtual void AssignGLESBuffers(const std::vector<GLESBuffer>& buffers) = 0; 272 virtual void AssignGLESBuffers(const std::vector<GLESBuffer>& buffers) = 0;
273 virtual void AssignSysmemBuffers( 273 virtual void AssignSysmemBuffers(
274 const std::vector<SysmemBuffer>& buffers) = 0; 274 const std::vector<SysmemBuffer>& buffers) = 0;
275 275
276 // Sends picture buffers to be reused by the decoder. This needs to be called 276 // Sends picture buffers to be reused by the decoder. This needs to be called
277 // for each buffer that has been processed so that decoder may know onto which 277 // for each buffer that has been processed so that decoder may know onto which
278 // picture buffers it can write the output to. 278 // picture buffers it can write the output to.
279 // 279 //
280 // Parameters: 280 // Parameters:
281 // |picture_buffer_id| id of the picture buffer that is to be reused. 281 // |picture_buffer_id| id of the picture buffer that is to be reused.
282 virtual void ReusePictureBuffer(int32 picture_buffer_id) = 0; 282 virtual void ReusePictureBuffer(int32 picture_buffer_id) = 0;
283 283
284 // Flushes the decoder. Flushing will result in output of the 284 // Flushes the decoder. Flushing will result in output of the
285 // pictures and buffers held inside the decoder and returning of bitstream 285 // pictures and buffers held inside the decoder and returning of bitstream
286 // buffers using the callbacks implemented by the plug-in. Once done with 286 // buffers using the callbacks implemented by the plug-in. Once done with
287 // flushing, the decode will call NotifyFlushDone(). 287 // flushing, the decode will call NotifyFlushDone().
288 // 288 //
289 // Returns true when command successfully accepted. Otherwise false. 289 // Returns true when command successfully accepted. Otherwise false.
scherkus (not reviewing) 2011/06/27 22:54:47 update docs
Ami GONE FROM CHROMIUM 2011/06/28 00:06:35 Done.
290 virtual bool Flush() = 0; 290 virtual void Flush() = 0;
291 291
292 // Aborts the decoder. Decode will abort the decoding as soon as possible and 292 // Aborts the decoder. Decode will abort the decoding as soon as possible and
293 // will not output anything. NotifyAbortDone() is called as soon as abort has 293 // will not output anything. NotifyAbortDone() is called as soon as abort has
294 // been finished. After abort all buffers can be considered dismissed, even 294 // been finished. After abort all buffers can be considered dismissed, even
295 // when there has not been callbacks to dismiss them. 295 // when there has not been callbacks to dismiss them.
296 // 296 //
297 // Returns true when command successfully accepted. Otherwise false. 297 // Returns true when command successfully accepted. Otherwise false.
scherkus (not reviewing) 2011/06/27 22:54:47 update docs
Ami GONE FROM CHROMIUM 2011/06/28 00:06:35 Done.
298 virtual bool Abort() = 0; 298 virtual void Abort() = 0;
299 }; 299 };
300 300
301 } // namespace media 301 } // namespace media
302 302
303 #endif // MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_ 303 #endif // MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698