| OLD | NEW |
| 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 // This file contains an implementation of an H.264 Decoded Picture Buffer | 5 // This file contains an implementation of an H.264 Decoded Picture Buffer |
| 6 // used in H264 decoders. | 6 // used in H264 decoders. |
| 7 | 7 |
| 8 #ifndef MEDIA_GPU_H264_DPB_H_ | 8 #ifndef MEDIA_GPU_H264_DPB_H_ |
| 9 #define MEDIA_GPU_H264_DPB_H_ | 9 #define MEDIA_GPU_H264_DPB_H_ |
| 10 | 10 |
| 11 #include <stddef.h> | 11 #include <stddef.h> |
| 12 | 12 |
| 13 #include <vector> | 13 #include <vector> |
| 14 | 14 |
| 15 #include "base/macros.h" | 15 #include "base/macros.h" |
| 16 #include "base/memory/ref_counted.h" | 16 #include "base/memory/ref_counted.h" |
| 17 #include "media/filters/h264_parser.h" | 17 #include "media/filters/h264_parser.h" |
| 18 #include "media/gpu/media_gpu_export.h" | |
| 19 #include "ui/gfx/geometry/rect.h" | 18 #include "ui/gfx/geometry/rect.h" |
| 20 | 19 |
| 21 namespace media { | 20 namespace media { |
| 22 | 21 |
| 23 class V4L2H264Picture; | 22 class V4L2H264Picture; |
| 24 class VaapiH264Picture; | 23 class VaapiH264Picture; |
| 25 | 24 |
| 26 // A picture (a frame or a field) in the H.264 spec sense. | 25 // A picture (a frame or a field) in the H.264 spec sense. |
| 27 // See spec at http://www.itu.int/rec/T-REC-H.264 | 26 // See spec at http://www.itu.int/rec/T-REC-H.264 |
| 28 class MEDIA_GPU_EXPORT H264Picture : public base::RefCounted<H264Picture> { | 27 class H264Picture : public base::RefCounted<H264Picture> { |
| 29 public: | 28 public: |
| 30 using Vector = std::vector<scoped_refptr<H264Picture>>; | 29 using Vector = std::vector<scoped_refptr<H264Picture>>; |
| 31 | 30 |
| 32 enum Field { | 31 enum Field { |
| 33 FIELD_NONE, | 32 FIELD_NONE, |
| 34 FIELD_TOP, | 33 FIELD_TOP, |
| 35 FIELD_BOTTOM, | 34 FIELD_BOTTOM, |
| 36 }; | 35 }; |
| 37 | 36 |
| 38 H264Picture(); | 37 H264Picture(); |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 | 173 |
| 175 H264Picture::Vector pics_; | 174 H264Picture::Vector pics_; |
| 176 size_t max_num_pics_; | 175 size_t max_num_pics_; |
| 177 | 176 |
| 178 DISALLOW_COPY_AND_ASSIGN(H264DPB); | 177 DISALLOW_COPY_AND_ASSIGN(H264DPB); |
| 179 }; | 178 }; |
| 180 | 179 |
| 181 } // namespace media | 180 } // namespace media |
| 182 | 181 |
| 183 #endif // MEDIA_GPU_H264_DPB_H_ | 182 #endif // MEDIA_GPU_H264_DPB_H_ |
| OLD | NEW |