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

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

Issue 1016773002: MJPEG acceleration for video capture using VAAPI (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rename GpuJpegDecodeAcceleratorAdapter to GpuJpegDecoder Created 5 years, 8 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_JPEG_DECODE_ACCELERATOR_H_ 5 #ifndef MEDIA_VIDEO_JPEG_DECODE_ACCELERATOR_H_
6 #define MEDIA_VIDEO_JPEG_DECODE_ACCELERATOR_H_ 6 #define MEDIA_VIDEO_JPEG_DECODE_ACCELERATOR_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "media/base/bitstream_buffer.h" 9 #include "media/base/bitstream_buffer.h"
10 #include "media/base/media_export.h" 10 #include "media/base/media_export.h"
11 #include "media/base/video_frame.h" 11 #include "media/base/video_frame.h"
12 12
13 namespace media { 13 namespace media {
14 14
15 // JPEG decoder interface. 15 // JPEG decoder interface.
16 // The input are JPEG images including headers (Huffman tables may be omitted). 16 // The input are JPEG images including headers (Huffman tables may be omitted).
17 // The output color format is I420. The decoder will convert the color format 17 // The output color format is I420. The decoder will convert the color format
18 // to I420 if the color space or subsampling does not match that and if it is 18 // to I420 if the color space or subsampling does not match that and if it is
19 // capable of doing so. The client is responsible for allocating buffers and 19 // capable of doing so. The client is responsible for allocating buffers and
20 // keeps the ownership of them. All methods must be called on the same thread. 20 // keeps the ownership of them.
wuchengli 2015/04/23 09:35:19 Document "Initialize and Destroy must be called on
kcwu 2015/05/08 14:42:42 Done.
21 // The intended use case of this interface is decoding MJPEG images coming 21 // The intended use case of this interface is decoding MJPEG images coming
22 // from camera capture. It can also be used for normal still JPEG image 22 // from camera capture. It can also be used for normal still JPEG image
23 // decoding, but normal JPEG images may use more JPEG features that may not be 23 // decoding, but normal JPEG images may use more JPEG features that may not be
24 // supported by a particular accelerator implementation and/or platform. 24 // supported by a particular accelerator implementation and/or platform.
25 class MEDIA_EXPORT JpegDecodeAccelerator { 25 class MEDIA_EXPORT JpegDecodeAccelerator {
26 public: 26 public:
27 static const int32_t kInvalidBitstreamBufferId = -1; 27 static const int32_t kInvalidBitstreamBufferId = -1;
28 28
29 // Enumeration of decode errors generated by NotifyError callback. 29 // Enumeration of decode errors generated by NotifyError callback.
30 enum Error { 30 enum Error {
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // uses "Destroy()" instead of trying to use the destructor. 125 // uses "Destroy()" instead of trying to use the destructor.
126 template <> 126 template <>
127 struct MEDIA_EXPORT DefaultDeleter<media::JpegDecodeAccelerator> { 127 struct MEDIA_EXPORT DefaultDeleter<media::JpegDecodeAccelerator> {
128 public: 128 public:
129 void operator()(void* jpeg_decode_accelerator) const; 129 void operator()(void* jpeg_decode_accelerator) const;
130 }; 130 };
131 131
132 } // namespace base 132 } // namespace base
133 133
134 #endif // MEDIA_VIDEO_JPEG_DECODE_ACCELERATOR_H_ 134 #endif // MEDIA_VIDEO_JPEG_DECODE_ACCELERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698