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

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

Issue 2802673002: Revert of Enforce MaxFrameDelayCount in VTVideoEncodeAccelerator and cleanups (Closed)
Patch Set: Created 3 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
« no previous file with comments | « no previous file | media/gpu/vt_video_encode_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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_ENCODE_ACCELERATOR_MAC_H_ 5 #ifndef MEDIA_GPU_VT_VIDEO_ENCODE_ACCELERATOR_MAC_H_
6 #define MEDIA_GPU_VT_VIDEO_ENCODE_ACCELERATOR_MAC_H_ 6 #define MEDIA_GPU_VT_VIDEO_ENCODE_ACCELERATOR_MAC_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <memory> 9 #include <memory>
10 10
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 // Copy CMSampleBuffer into a BitstreamBuffer and return it to the |client_|. 80 // Copy CMSampleBuffer into a BitstreamBuffer and return it to the |client_|.
81 void ReturnBitstreamBuffer( 81 void ReturnBitstreamBuffer(
82 std::unique_ptr<EncodeOutput> encode_output, 82 std::unique_ptr<EncodeOutput> encode_output,
83 std::unique_ptr<VTVideoEncodeAccelerator::BitstreamBufferRef> buffer_ref); 83 std::unique_ptr<VTVideoEncodeAccelerator::BitstreamBufferRef> buffer_ref);
84 84
85 // Reset the encoder's compression session by destroying the existing one 85 // Reset the encoder's compression session by destroying the existing one
86 // using DestroyCompressionSession() and creating a new one. The new session 86 // using DestroyCompressionSession() and creating a new one. The new session
87 // is configured using ConfigureCompressionSession(). 87 // is configured using ConfigureCompressionSession().
88 bool ResetCompressionSession(); 88 bool ResetCompressionSession();
89 89
90 // Create a compression session. 90 // Create a compression session, with HW encoder enforced if
91 bool CreateCompressionSession(const gfx::Size& input_size); 91 // |require_hw_encoding| is set.
92 bool CreateCompressionSession(
93 base::ScopedCFTypeRef<CFDictionaryRef> attributes,
94 const gfx::Size& input_size,
95 bool require_hw_encoding);
92 96
93 // Configure the current compression session using current encoder settings. 97 // Configure the current compression session using current encoder settings.
94 bool ConfigureCompressionSession(); 98 bool ConfigureCompressionSession();
95 99
96 // Destroy the current compression session if any. Blocks until all pending 100 // Destroy the current compression session if any. Blocks until all pending
97 // frames have been flushed out (similar to EmitFrames without doing any 101 // frames have been flushed out (similar to EmitFrames without doing any
98 // encoding work). 102 // encoding work).
99 void DestroyCompressionSession(); 103 void DestroyCompressionSession();
100 104
101 base::ScopedCFTypeRef<VTCompressionSessionRef> compression_session_; 105 base::ScopedCFTypeRef<VTCompressionSessionRef> compression_session_;
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 // other destructors run. 142 // other destructors run.
139 base::WeakPtr<VTVideoEncodeAccelerator> encoder_weak_ptr_; 143 base::WeakPtr<VTVideoEncodeAccelerator> encoder_weak_ptr_;
140 base::WeakPtrFactory<VTVideoEncodeAccelerator> encoder_task_weak_factory_; 144 base::WeakPtrFactory<VTVideoEncodeAccelerator> encoder_task_weak_factory_;
141 145
142 DISALLOW_COPY_AND_ASSIGN(VTVideoEncodeAccelerator); 146 DISALLOW_COPY_AND_ASSIGN(VTVideoEncodeAccelerator);
143 }; 147 };
144 148
145 } // namespace media 149 } // namespace media
146 150
147 #endif // MEDIA_GPU_VT_VIDEO_ENCODE_ACCELERATOR_MAC_H_ 151 #endif // MEDIA_GPU_VT_VIDEO_ENCODE_ACCELERATOR_MAC_H_
OLDNEW
« no previous file with comments | « no previous file | media/gpu/vt_video_encode_accelerator_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698