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

Side by Side Diff: media/cast/video_sender/video_sender.h

Issue 193303002: WeakPtr destruction order cleanup: media edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 6 years, 9 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
« no previous file with comments | « media/cast/video_sender/external_video_encoder.h ('k') | media/filters/audio_renderer_impl.h » ('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 MEDIA_CAST_VIDEO_SENDER_VIDEO_SENDER_H_ 5 #ifndef MEDIA_CAST_VIDEO_SENDER_VIDEO_SENDER_H_
6 #define MEDIA_CAST_VIDEO_SENDER_VIDEO_SENDER_H_ 6 #define MEDIA_CAST_VIDEO_SENDER_VIDEO_SENDER_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 // with a video frame. The key is the lowest 8 bits of frame id (which is 134 // with a video frame. The key is the lowest 8 bits of frame id (which is
135 // what is sent via RTCP). This map is used for logging purposes. The only 135 // what is sent via RTCP). This map is used for logging purposes. The only
136 // time when this mapping will be incorrect is when it receives an ACK for a 136 // time when this mapping will be incorrect is when it receives an ACK for a
137 // old enough frame such that 8-bit wrap around has already occurred, which 137 // old enough frame such that 8-bit wrap around has already occurred, which
138 // should be pretty rare. 138 // should be pretty rare.
139 RtpTimestamp frame_id_to_rtp_timestamp_[256]; 139 RtpTimestamp frame_id_to_rtp_timestamp_[256];
140 140
141 bool initialized_; 141 bool initialized_;
142 // Indicator for receiver acknowledgments. 142 // Indicator for receiver acknowledgments.
143 bool active_session_; 143 bool active_session_;
144
145 // NOTE: Weak pointers must be invalidated before all other member variables.
144 base::WeakPtrFactory<VideoSender> weak_factory_; 146 base::WeakPtrFactory<VideoSender> weak_factory_;
145 147
146 DISALLOW_COPY_AND_ASSIGN(VideoSender); 148 DISALLOW_COPY_AND_ASSIGN(VideoSender);
147 }; 149 };
148 150
149 } // namespace cast 151 } // namespace cast
150 } // namespace media 152 } // namespace media
151 153
152 #endif // MEDIA_CAST_VIDEO_SENDER_VIDEO_SENDER_H_ 154 #endif // MEDIA_CAST_VIDEO_SENDER_VIDEO_SENDER_H_
OLDNEW
« no previous file with comments | « media/cast/video_sender/external_video_encoder.h ('k') | media/filters/audio_renderer_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698