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

Side by Side Diff: media/filters/ffmpeg_demuxer.h

Issue 2305923002: Ensure FFmpegDemuxer WeakPtrs are created on the right thread. (Closed)
Patch Set: Fix. Created 4 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 | media/filters/ffmpeg_demuxer.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Implements the Demuxer interface using FFmpeg's libavformat. At this time 5 // Implements the Demuxer interface using FFmpeg's libavformat. At this time
6 // will support demuxing any audio/video format thrown at it. The streams 6 // will support demuxing any audio/video format thrown at it. The streams
7 // output mime types audio/x-ffmpeg and video/x-ffmpeg and include an integer 7 // output mime types audio/x-ffmpeg and video/x-ffmpeg and include an integer
8 // key FFmpegCodecID which contains the CodecID enumeration value. The CodecIDs 8 // key FFmpegCodecID which contains the CodecID enumeration value. The CodecIDs
9 // can be used to create and initialize the corresponding FFmpeg decoder. 9 // can be used to create and initialize the corresponding FFmpeg decoder.
10 // 10 //
(...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after
347 std::unique_ptr<BlockingUrlProtocol> url_protocol_; 347 std::unique_ptr<BlockingUrlProtocol> url_protocol_;
348 std::unique_ptr<FFmpegGlue> glue_; 348 std::unique_ptr<FFmpegGlue> glue_;
349 349
350 const EncryptedMediaInitDataCB encrypted_media_init_data_cb_; 350 const EncryptedMediaInitDataCB encrypted_media_init_data_cb_;
351 351
352 const MediaTracksUpdatedCB media_tracks_updated_cb_; 352 const MediaTracksUpdatedCB media_tracks_updated_cb_;
353 353
354 std::map<MediaTrack::Id, const DemuxerStream*> track_id_to_demux_stream_map_; 354 std::map<MediaTrack::Id, const DemuxerStream*> track_id_to_demux_stream_map_;
355 355
356 // NOTE: Weak pointers must be invalidated before all other member variables. 356 // NOTE: Weak pointers must be invalidated before all other member variables.
357 base::WeakPtr<FFmpegDemuxer> weak_this_;
358 base::WeakPtrFactory<FFmpegDemuxer> cancel_pending_seek_factory_;
357 base::WeakPtrFactory<FFmpegDemuxer> weak_factory_; 359 base::WeakPtrFactory<FFmpegDemuxer> weak_factory_;
358 360
359 DISALLOW_COPY_AND_ASSIGN(FFmpegDemuxer); 361 DISALLOW_COPY_AND_ASSIGN(FFmpegDemuxer);
360 }; 362 };
361 363
362 } // namespace media 364 } // namespace media
363 365
364 #endif // MEDIA_FILTERS_FFMPEG_DEMUXER_H_ 366 #endif // MEDIA_FILTERS_FFMPEG_DEMUXER_H_
OLDNEW
« no previous file with comments | « no previous file | media/filters/ffmpeg_demuxer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698