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

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

Issue 8686010: <video> decode in hardware! (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add missing OVERRIDEs Created 9 years 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"
11 #include "base/callback_old.h" 11 #include "base/callback_old.h"
12 #include "media/base/bitstream_buffer.h" 12 #include "media/base/bitstream_buffer.h"
13 #include "media/base/video_decoder_config.h"
13 #include "media/video/picture.h" 14 #include "media/video/picture.h"
14 #include "ui/gfx/size.h" 15 #include "ui/gfx/size.h"
15 16
16 namespace media { 17 namespace media {
17 18
18 // Video decoder interface. 19 // Video decoder interface.
19 // This interface is extended by the various components that ultimately 20 // This interface is extended by the various components that ultimately
20 // implement the backend of PPB_VideoDecode_Dev. 21 // implement the backend of PPB_VideoDecode_Dev.
21 // 22 //
22 // No thread-safety guarantees are implied by the use of RefCountedThreadSafe 23 // No thread-safety guarantees are implied by the use of RefCountedThreadSafe
23 // below. 24 // below.
24 class MEDIA_EXPORT VideoDecodeAccelerator 25 class MEDIA_EXPORT VideoDecodeAccelerator
25 : public base::RefCountedThreadSafe<VideoDecodeAccelerator> { 26 : public base::RefCountedThreadSafe<VideoDecodeAccelerator> {
26 public: 27 public:
27 // Video stream profile. This *must* match PP_VideoDecoder_Profile. 28 typedef VideoCodecProfile Profile;
scherkus (not reviewing) 2011/12/06 00:27:44 why not use VCP?
Ami GONE FROM CHROMIUM 2011/12/07 00:03:04 A bunch of places already refer to the inner type
28 enum Profile {
29 // Keep the values in this enum unique, as they imply format (h.264 vs. VP8,
30 // for example), and keep the values for a particular format grouped
31 // together for clarity.
32 H264PROFILE_MIN = 0,
33 H264PROFILE_BASELINE = H264PROFILE_MIN,
34 H264PROFILE_MAIN,
35 H264PROFILE_EXTENDED,
36 H264PROFILE_HIGH,
37 H264PROFILE_HIGH10PROFILE,
38 H264PROFILE_HIGH422PROFILE,
39 H264PROFILE_HIGH444PREDICTIVEPROFILE,
40 H264PROFILE_SCALABLEBASELINE,
41 H264PROFILE_SCALABLEHIGH,
42 H264PROFILE_STEREOHIGH,
43 H264PROFILE_MULTIVIEWHIGH,
44 H264PROFILE_MAX = H264PROFILE_MULTIVIEWHIGH,
45 };
46 29
47 // Enumeration of potential errors generated by the API. 30 // Enumeration of potential errors generated by the API.
48 // Note: Keep these in sync with PP_VideoDecodeError_Dev. 31 // Note: Keep these in sync with PP_VideoDecodeError_Dev.
49 enum Error { 32 enum Error {
50 // An operation was attempted during an incompatible decoder state. 33 // An operation was attempted during an incompatible decoder state.
51 ILLEGAL_STATE = 1, 34 ILLEGAL_STATE = 1,
52 // Invalid argument was passed to an API method. 35 // Invalid argument was passed to an API method.
53 INVALID_ARGUMENT, 36 INVALID_ARGUMENT,
54 // Encoded input is unreadable. 37 // Encoded input is unreadable.
55 UNREADABLE_INPUT, 38 UNREADABLE_INPUT,
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 virtual void Destroy() = 0; 135 virtual void Destroy() = 0;
153 136
154 protected: 137 protected:
155 friend class base::RefCountedThreadSafe<VideoDecodeAccelerator>; 138 friend class base::RefCountedThreadSafe<VideoDecodeAccelerator>;
156 virtual ~VideoDecodeAccelerator(); 139 virtual ~VideoDecodeAccelerator();
157 }; 140 };
158 141
159 } // namespace media 142 } // namespace media
160 143
161 #endif // MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_ 144 #endif // MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698