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

Side by Side Diff: content/renderer/media/webmediaplayer_impl.h

Issue 512033002: Remove the lies WebMediaPlayerImpl is telling V8. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 | content/renderer/media/webmediaplayer_impl.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 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 CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_
6 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ 6 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 scoped_ptr<media::Renderer> CreateRenderer(); 192 scoped_ptr<media::Renderer> CreateRenderer();
193 193
194 // Finishes starting the pipeline due to a call to load(). 194 // Finishes starting the pipeline due to a call to load().
195 void StartPipeline(); 195 void StartPipeline();
196 196
197 // Helpers that set the network/ready state and notifies the client if 197 // Helpers that set the network/ready state and notifies the client if
198 // they've changed. 198 // they've changed.
199 void SetNetworkState(blink::WebMediaPlayer::NetworkState state); 199 void SetNetworkState(blink::WebMediaPlayer::NetworkState state);
200 void SetReadyState(blink::WebMediaPlayer::ReadyState state); 200 void SetReadyState(blink::WebMediaPlayer::ReadyState state);
201 201
202 // Lets V8 know that player uses extra resources not managed by V8.
203 void IncrementExternallyAllocatedMemory();
204
205 // Gets the duration value reported by the pipeline. 202 // Gets the duration value reported by the pipeline.
206 double GetPipelineDuration() const; 203 double GetPipelineDuration() const;
207 204
208 // Callbacks from |pipeline_| that are forwarded to |client_|. 205 // Callbacks from |pipeline_| that are forwarded to |client_|.
209 void OnDurationChanged(); 206 void OnDurationChanged();
210 void OnNaturalSizeChanged(gfx::Size size); 207 void OnNaturalSizeChanged(gfx::Size size);
211 void OnOpacityChanged(bool opaque); 208 void OnOpacityChanged(bool opaque);
212 209
213 // Called by VideoRendererImpl on its internal thread with the new frame to be 210 // Called by VideoRendererImpl on its internal thread with the new frame to be
214 // painted. 211 // painted.
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 // Tracks whether to issue time changed notifications during buffering state 272 // Tracks whether to issue time changed notifications during buffering state
276 // changes. 273 // changes.
277 bool should_notify_time_changed_; 274 bool should_notify_time_changed_;
278 275
279 blink::WebMediaPlayerClient* client_; 276 blink::WebMediaPlayerClient* client_;
280 277
281 base::WeakPtr<WebMediaPlayerDelegate> delegate_; 278 base::WeakPtr<WebMediaPlayerDelegate> delegate_;
282 279
283 base::Callback<void(const base::Closure&)> defer_load_cb_; 280 base::Callback<void(const base::Closure&)> defer_load_cb_;
284 281
285 bool incremented_externally_allocated_memory_;
286
287 // Factories for supporting video accelerators. May be null. 282 // Factories for supporting video accelerators. May be null.
288 scoped_refptr<media::GpuVideoAcceleratorFactories> gpu_factories_; 283 scoped_refptr<media::GpuVideoAcceleratorFactories> gpu_factories_;
289 284
290 // Routes audio playback to either AudioRendererSink or WebAudio. 285 // Routes audio playback to either AudioRendererSink or WebAudio.
291 scoped_refptr<WebAudioSourceProviderImpl> audio_source_provider_; 286 scoped_refptr<WebAudioSourceProviderImpl> audio_source_provider_;
292 287
293 bool supports_save_; 288 bool supports_save_;
294 289
295 // These two are mutually exclusive: 290 // These two are mutually exclusive:
296 // |data_source_| is used for regular resource loads. 291 // |data_source_| is used for regular resource loads.
(...skipping 20 matching lines...) Expand all
317 int text_track_index_; 312 int text_track_index_;
318 313
319 scoped_ptr<EncryptedMediaPlayerSupport> encrypted_media_support_; 314 scoped_ptr<EncryptedMediaPlayerSupport> encrypted_media_support_;
320 315
321 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl); 316 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl);
322 }; 317 };
323 318
324 } // namespace content 319 } // namespace content
325 320
326 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ 321 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | content/renderer/media/webmediaplayer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698