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

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

Issue 2697643003: media: Clean up MediaCodecBridge and remove subclasses (Closed)
Patch Set: rebase Created 3 years, 10 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_ANDROID_VIDEO_ENCODE_ACCELERATOR_H_ 5 #ifndef MEDIA_GPU_ANDROID_VIDEO_ENCODE_ACCELERATOR_H_
6 #define MEDIA_GPU_ANDROID_VIDEO_ENCODE_ACCELERATOR_H_ 6 #define MEDIA_GPU_ANDROID_VIDEO_ENCODE_ACCELERATOR_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 void MaybeStartIOTimer(); 71 void MaybeStartIOTimer();
72 void MaybeStopIOTimer(); 72 void MaybeStopIOTimer();
73 73
74 // Used to DCHECK that we are called on the correct thread. 74 // Used to DCHECK that we are called on the correct thread.
75 base::ThreadChecker thread_checker_; 75 base::ThreadChecker thread_checker_;
76 76
77 // VideoDecodeAccelerator::Client callbacks go here. Invalidated once any 77 // VideoDecodeAccelerator::Client callbacks go here. Invalidated once any
78 // error triggers. 78 // error triggers.
79 std::unique_ptr<base::WeakPtrFactory<Client>> client_ptr_factory_; 79 std::unique_ptr<base::WeakPtrFactory<Client>> client_ptr_factory_;
80 80
81 std::unique_ptr<VideoCodecBridge> media_codec_; 81 std::unique_ptr<MediaCodecBridge> media_codec_;
82 82
83 // Bitstream buffers waiting to be populated & returned to the client. 83 // Bitstream buffers waiting to be populated & returned to the client.
84 std::vector<BitstreamBuffer> available_bitstream_buffers_; 84 std::vector<BitstreamBuffer> available_bitstream_buffers_;
85 85
86 // Frames waiting to be passed to the codec, queued until an input buffer is 86 // Frames waiting to be passed to the codec, queued until an input buffer is
87 // available. Each element is a tuple of <Frame, key_frame, enqueue_time>. 87 // available. Each element is a tuple of <Frame, key_frame, enqueue_time>.
88 typedef std::queue<std::tuple<scoped_refptr<VideoFrame>, bool, base::Time>> 88 typedef std::queue<std::tuple<scoped_refptr<VideoFrame>, bool, base::Time>>
89 PendingFrames; 89 PendingFrames;
90 PendingFrames pending_frames_; 90 PendingFrames pending_frames_;
91 91
(...skipping 14 matching lines...) Expand all
106 106
107 // True if there is encoder error. 107 // True if there is encoder error.
108 bool error_occurred_; 108 bool error_occurred_;
109 109
110 DISALLOW_COPY_AND_ASSIGN(AndroidVideoEncodeAccelerator); 110 DISALLOW_COPY_AND_ASSIGN(AndroidVideoEncodeAccelerator);
111 }; 111 };
112 112
113 } // namespace media 113 } // namespace media
114 114
115 #endif // MEDIA_GPU_ANDROID_VIDEO_ENCODE_ACCELERATOR_H_ 115 #endif // MEDIA_GPU_ANDROID_VIDEO_ENCODE_ACCELERATOR_H_
OLDNEW
« no previous file with comments | « media/gpu/android_video_decode_accelerator.cc ('k') | media/gpu/android_video_encode_accelerator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698