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

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

Issue 2902693002: Use base::Optional<int32_t> in H264POC::ComputePicOrderCnt(...) (Closed)
Patch Set: Created 3 years, 7 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/vt_video_decode_accelerator_mac.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_GPU_VT_VIDEO_DECODE_ACCELERATOR_MAC_H_ 5 #ifndef MEDIA_GPU_VT_VIDEO_DECODE_ACCELERATOR_MAC_H_
6 #define MEDIA_GPU_VT_VIDEO_DECODE_ACCELERATOR_MAC_H_ 6 #define MEDIA_GPU_VT_VIDEO_DECODE_ACCELERATOR_MAC_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 150
151 struct FrameOrder { 151 struct FrameOrder {
152 bool operator()(const linked_ptr<Frame>& lhs, 152 bool operator()(const linked_ptr<Frame>& lhs,
153 const linked_ptr<Frame>& rhs) const; 153 const linked_ptr<Frame>& rhs) const;
154 }; 154 };
155 155
156 // 156 //
157 // Methods for interacting with VideoToolbox. Run on |decoder_thread_|. 157 // Methods for interacting with VideoToolbox. Run on |decoder_thread_|.
158 // 158 //
159 159
160 // Compute the |pic_order_cnt| for a frame. Returns true or calls
161 // NotifyError() before returning false.
162 bool ComputePicOrderCnt(const H264SPS* sps,
163 const H264SliceHeader& slice_hdr,
164 Frame* frame);
165
166 // Set up VideoToolbox using the current SPS and PPS. Returns true or calls 160 // Set up VideoToolbox using the current SPS and PPS. Returns true or calls
167 // NotifyError() before returning false. 161 // NotifyError() before returning false.
168 bool ConfigureDecoder(); 162 bool ConfigureDecoder();
169 163
170 // Wait for VideoToolbox to output all pending frames. Returns true or calls 164 // Wait for VideoToolbox to output all pending frames. Returns true or calls
171 // NotifyError() before returning false. 165 // NotifyError() before returning false.
172 bool FinishDelayedFrames(); 166 bool FinishDelayedFrames();
173 167
174 // |frame| is owned by |pending_frames_|. 168 // |frame| is owned by |pending_frames_|.
175 void DecodeTask(const BitstreamBuffer&, Frame* frame); 169 void DecodeTask(const BitstreamBuffer&, Frame* frame);
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 // Declared last to ensure that all weak pointers are invalidated before 281 // Declared last to ensure that all weak pointers are invalidated before
288 // other destructors run. 282 // other destructors run.
289 base::WeakPtrFactory<VTVideoDecodeAccelerator> weak_this_factory_; 283 base::WeakPtrFactory<VTVideoDecodeAccelerator> weak_this_factory_;
290 284
291 DISALLOW_COPY_AND_ASSIGN(VTVideoDecodeAccelerator); 285 DISALLOW_COPY_AND_ASSIGN(VTVideoDecodeAccelerator);
292 }; 286 };
293 287
294 } // namespace media 288 } // namespace media
295 289
296 #endif // MEDIA_GPU_VT_VIDEO_DECODE_ACCELERATOR_MAC_H_ 290 #endif // MEDIA_GPU_VT_VIDEO_DECODE_ACCELERATOR_MAC_H_
OLDNEW
« no previous file with comments | « no previous file | media/gpu/vt_video_decode_accelerator_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698