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

Side by Side Diff: content/renderer/media/android/webmediaplayer_android.h

Issue 405663002: Support basic authentication for html5 media (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updating crbug Created 6 years, 5 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 | Annotate | Revision Log
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_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_
6 #define CONTENT_RENDERER_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ 6 #define CONTENT_RENDERER_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 void DoCreateStreamTexture(); 242 void DoCreateStreamTexture();
243 243
244 // Helper method to reestablish the surface texture peer for android 244 // Helper method to reestablish the surface texture peer for android
245 // media player. 245 // media player.
246 void EstablishSurfaceTexturePeer(); 246 void EstablishSurfaceTexturePeer();
247 247
248 // Requesting whether the surface texture peer needs to be reestablished. 248 // Requesting whether the surface texture peer needs to be reestablished.
249 void SetNeedsEstablishPeer(bool needs_establish_peer); 249 void SetNeedsEstablishPeer(bool needs_establish_peer);
250 250
251 private: 251 private:
252 void InitializePlayer(int demuxer_client_id);
252 void Pause(bool is_media_related_action); 253 void Pause(bool is_media_related_action);
253 void DrawRemotePlaybackText(const std::string& remote_playback_message); 254 void DrawRemotePlaybackText(const std::string& remote_playback_message);
254 void ReallocateVideoFrame(); 255 void ReallocateVideoFrame();
255 void SetCurrentFrameInternal(scoped_refptr<media::VideoFrame>& frame); 256 void SetCurrentFrameInternal(scoped_refptr<media::VideoFrame>& frame);
256 void DidLoadMediaInfo(MediaInfoLoader::Status status); 257 void DidLoadMediaInfo(MediaInfoLoader::Status status);
257 bool IsKeySystemSupported(const std::string& key_system); 258 bool IsKeySystemSupported(const std::string& key_system);
258 259
259 // Actually do the work for generateKeyRequest/addKey so they can easily 260 // Actually do the work for generateKeyRequest/addKey so they can easily
260 // report results to UMA. 261 // report results to UMA.
261 MediaKeyException GenerateKeyRequestInternal(const std::string& key_system, 262 MediaKeyException GenerateKeyRequestInternal(const std::string& key_system,
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 // GL texture mailbox for texture_id_ to provide in the VideoFrame, and sync 351 // GL texture mailbox for texture_id_ to provide in the VideoFrame, and sync
351 // point for when the mailbox was produced. 352 // point for when the mailbox was produced.
352 gpu::Mailbox texture_mailbox_; 353 gpu::Mailbox texture_mailbox_;
353 354
354 // Stream texture ID allocated to the video. 355 // Stream texture ID allocated to the video.
355 unsigned int stream_id_; 356 unsigned int stream_id_;
356 357
357 // Whether the mediaplayer is playing. 358 // Whether the mediaplayer is playing.
358 bool is_playing_; 359 bool is_playing_;
359 360
360 // Whether the mediaplayer has already started playing.
361 bool playing_started_;
362
363 // Whether media player needs to re-establish the surface texture peer. 361 // Whether media player needs to re-establish the surface texture peer.
364 bool needs_establish_peer_; 362 bool needs_establish_peer_;
365 363
366 // Whether |stream_texture_proxy_| is initialized. 364 // Whether |stream_texture_proxy_| is initialized.
367 bool stream_texture_proxy_initialized_; 365 bool stream_texture_proxy_initialized_;
368 366
369 // Whether the video size info is available. 367 // Whether the video size info is available.
370 bool has_size_info_; 368 bool has_size_info_;
371 369
372 // Whether the video metadata and info are available.
373 bool has_media_metadata_;
374 bool has_media_info_;
375
376 // Object for allocating stream textures. 370 // Object for allocating stream textures.
377 scoped_refptr<StreamTextureFactory> stream_texture_factory_; 371 scoped_refptr<StreamTextureFactory> stream_texture_factory_;
378 372
379 // Object for calling back the compositor thread to repaint the video when a 373 // Object for calling back the compositor thread to repaint the video when a
380 // frame available. It should be initialized on the compositor thread. 374 // frame available. It should be initialized on the compositor thread.
381 ScopedStreamTextureProxy stream_texture_proxy_; 375 ScopedStreamTextureProxy stream_texture_proxy_;
382 376
383 // Whether media player needs external surface. 377 // Whether media player needs external surface.
384 // Only used for the VIDEO_HOLE logic. 378 // Only used for the VIDEO_HOLE logic.
385 bool needs_external_surface_; 379 bool needs_external_surface_;
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 438
445 // NOTE: Weak pointers must be invalidated before all other member variables. 439 // NOTE: Weak pointers must be invalidated before all other member variables.
446 base::WeakPtrFactory<WebMediaPlayerAndroid> weak_factory_; 440 base::WeakPtrFactory<WebMediaPlayerAndroid> weak_factory_;
447 441
448 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerAndroid); 442 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerAndroid);
449 }; 443 };
450 444
451 } // namespace content 445 } // namespace content
452 446
453 #endif // CONTENT_RENDERER_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ 447 #endif // CONTENT_RENDERER_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_
OLDNEW
« no previous file with comments | « content/browser/media/android/media_resource_getter_impl.cc ('k') | content/renderer/media/android/webmediaplayer_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698