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

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

Issue 1490333005: Don't require VDAs to return all PictureBuffers at once. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: moved flags into VDA::Capabilities. Created 5 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
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 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 <memory> 8 #include <memory>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 16 matching lines...) Expand all
27 // |max_resolution| and |min_resolution| are inclusive. 27 // |max_resolution| and |min_resolution| are inclusive.
28 struct MEDIA_EXPORT SupportedProfile { 28 struct MEDIA_EXPORT SupportedProfile {
29 SupportedProfile(); 29 SupportedProfile();
30 ~SupportedProfile(); 30 ~SupportedProfile();
31 VideoCodecProfile profile; 31 VideoCodecProfile profile;
32 gfx::Size max_resolution; 32 gfx::Size max_resolution;
33 gfx::Size min_resolution; 33 gfx::Size min_resolution;
34 }; 34 };
35 using SupportedProfiles = std::vector<SupportedProfile>; 35 using SupportedProfiles = std::vector<SupportedProfile>;
36 36
37 struct MEDIA_EXPORT Capabilities {
38 Capabilities();
39 // Flags that can be associated with a VDA.
40 enum Flags {
41 kNoFlags = 0,
42
43 // If set, then the VDA makes no guarantees that it won't stall before
44 // sending all the picture buffers to the client via PictureReady.
45 kCanStallAnytime = 1 << 0,
46 };
47
48 SupportedProfiles supported_profiles;
49 Flags flags;
50 };
51
37 // Enumeration of potential errors generated by the API. 52 // Enumeration of potential errors generated by the API.
38 // Note: Keep these in sync with PP_VideoDecodeError_Dev. Also do not 53 // Note: Keep these in sync with PP_VideoDecodeError_Dev. Also do not
39 // rearrange, reuse or remove values as they are used for gathering UMA 54 // rearrange, reuse or remove values as they are used for gathering UMA
40 // statistics. 55 // statistics.
41 enum Error { 56 enum Error {
42 // An operation was attempted during an incompatible decoder state. 57 // An operation was attempted during an incompatible decoder state.
43 ILLEGAL_STATE = 1, 58 ILLEGAL_STATE = 1,
44 // Invalid argument was passed to an API method. 59 // Invalid argument was passed to an API method.
45 INVALID_ARGUMENT, 60 INVALID_ARGUMENT,
46 // Encoded input is unreadable. 61 // Encoded input is unreadable.
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 // Specialize std::default_delete so that scoped_ptr<VideoDecodeAccelerator> 211 // Specialize std::default_delete so that scoped_ptr<VideoDecodeAccelerator>
197 // uses "Destroy()" instead of trying to use the destructor. 212 // uses "Destroy()" instead of trying to use the destructor.
198 template <> 213 template <>
199 struct MEDIA_EXPORT default_delete<media::VideoDecodeAccelerator> { 214 struct MEDIA_EXPORT default_delete<media::VideoDecodeAccelerator> {
200 void operator()(media::VideoDecodeAccelerator* vda) const; 215 void operator()(media::VideoDecodeAccelerator* vda) const;
201 }; 216 };
202 217
203 } // namespace std 218 } // namespace std
204 219
205 #endif // MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_ 220 #endif // MEDIA_VIDEO_VIDEO_DECODE_ACCELERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698