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

Side by Side Diff: media/gpu/accelerated_video_decoder.h

Issue 2926593002: V4L2SVDA/VAAPIVDA: use visible size from decoder and pass to client (Closed)
Patch Set: V4L2SVDA/VAAPIVDA: use visible size from decoder and pass to client Created 3 years, 6 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
« no previous file with comments | « no previous file | media/gpu/h264_decoder.h » ('j') | media/gpu/h264_decoder.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_GPU_ACCELERATED_VIDEO_DECODER_H_ 5 #ifndef MEDIA_GPU_ACCELERATED_VIDEO_DECODER_H_
6 #define MEDIA_GPU_ACCELERATED_VIDEO_DECODER_H_ 6 #define MEDIA_GPU_ACCELERATED_VIDEO_DECODER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "media/gpu/media_gpu_export.h" 12 #include "media/gpu/media_gpu_export.h"
13 #include "ui/gfx/geometry/rect.h"
13 #include "ui/gfx/geometry/size.h" 14 #include "ui/gfx/geometry/size.h"
14 15
15 namespace media { 16 namespace media {
16 17
17 // An AcceleratedVideoDecoder is a video decoder that requires support from an 18 // An AcceleratedVideoDecoder is a video decoder that requires support from an
18 // external accelerator (typically a hardware accelerator) to partially offload 19 // external accelerator (typically a hardware accelerator) to partially offload
19 // the decode process after parsing stream headers, and performing reference 20 // the decode process after parsing stream headers, and performing reference
20 // frame and state management. 21 // frame and state management.
21 class MEDIA_GPU_EXPORT AcceleratedVideoDecoder { 22 class MEDIA_GPU_EXPORT AcceleratedVideoDecoder {
22 public: 23 public:
(...skipping 27 matching lines...) Expand all
50 51
51 // Try to decode more of the stream, returning decoded frames asynchronously. 52 // Try to decode more of the stream, returning decoded frames asynchronously.
52 // Return when more stream is needed, when we run out of free surfaces, when 53 // Return when more stream is needed, when we run out of free surfaces, when
53 // we need a new set of them, or when an error occurs. 54 // we need a new set of them, or when an error occurs.
54 virtual DecodeResult Decode() WARN_UNUSED_RESULT = 0; 55 virtual DecodeResult Decode() WARN_UNUSED_RESULT = 0;
55 56
56 // Return dimensions/required number of output surfaces that client should 57 // Return dimensions/required number of output surfaces that client should
57 // be ready to provide for the decoder to function properly. 58 // be ready to provide for the decoder to function properly.
58 // To be used after Decode() returns kAllocateNewSurfaces. 59 // To be used after Decode() returns kAllocateNewSurfaces.
59 virtual gfx::Size GetPicSize() const = 0; 60 virtual gfx::Size GetPicSize() const = 0;
61 virtual gfx::Rect GetVisibleRect() const = 0;
60 virtual size_t GetRequiredNumOfPictures() const = 0; 62 virtual size_t GetRequiredNumOfPictures() const = 0;
61 63
62 private: 64 private:
63 DISALLOW_COPY_AND_ASSIGN(AcceleratedVideoDecoder); 65 DISALLOW_COPY_AND_ASSIGN(AcceleratedVideoDecoder);
64 }; 66 };
65 67
66 } // namespace media 68 } // namespace media
67 69
68 #endif // MEDIA_GPU_ACCELERATED_VIDEO_DECODER_H_ 70 #endif // MEDIA_GPU_ACCELERATED_VIDEO_DECODER_H_
OLDNEW
« no previous file with comments | « no previous file | media/gpu/h264_decoder.h » ('j') | media/gpu/h264_decoder.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698