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

Side by Side Diff: media/tools/player_wtl/view.h

Issue 7795027: One-liner fix for player_wtl. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_TOOLS_PLAYER_WTL_VIEW_H_ 5 #ifndef MEDIA_TOOLS_PLAYER_WTL_VIEW_H_
6 #define MEDIA_TOOLS_PLAYER_WTL_VIEW_H_ 6 #define MEDIA_TOOLS_PLAYER_WTL_VIEW_H_
7 7
8 #include <stdio.h> 8 #include <stdio.h>
9 #include <process.h> 9 #include <process.h>
10 #include <string.h> 10 #include <string.h>
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 if (!bmp_.IsNull()) { 228 if (!bmp_.IsNull()) {
229 scoped_refptr<media::VideoFrame> frame; 229 scoped_refptr<media::VideoFrame> frame;
230 renderer_->GetCurrentFrame(&frame); 230 renderer_->GetCurrentFrame(&frame);
231 if (frame.get()) { 231 if (frame.get()) {
232 base::TimeDelta frame_timestamp = frame->GetTimestamp(); 232 base::TimeDelta frame_timestamp = frame->GetTimestamp();
233 if (frame != last_frame_ || frame_timestamp != last_timestamp_) { 233 if (frame != last_frame_ || frame_timestamp != last_timestamp_) {
234 last_frame_ = frame; 234 last_frame_ = frame;
235 last_timestamp_ = frame_timestamp; 235 last_timestamp_ = frame_timestamp;
236 ConvertFrame(frame); 236 ConvertFrame(frame);
237 } 237 }
238 frame = NULL;
239 } 238 }
240 renderer_->PutCurrentFrame(frame); 239 renderer_->PutCurrentFrame(frame);
241 240
242 #ifdef TESTING 241 #ifdef TESTING
243 double paint_time_start = GetTime(); 242 double paint_time_start = GetTime();
244 static double paint_time_previous = 0; 243 static double paint_time_previous = 0;
245 if (!paint_time_previous) 244 if (!paint_time_previous)
246 paint_time_previous = paint_time_start; 245 paint_time_previous = paint_time_start;
247 #endif 246 #endif
248 CDC dcMem; 247 CDC dcMem;
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
445 } 444 }
446 } 445 }
447 446
448 media::VideoFrame* last_frame_; 447 media::VideoFrame* last_frame_;
449 base::TimeDelta last_timestamp_; 448 base::TimeDelta last_timestamp_;
450 449
451 DISALLOW_COPY_AND_ASSIGN(WtlVideoWindow); 450 DISALLOW_COPY_AND_ASSIGN(WtlVideoWindow);
452 }; 451 };
453 452
454 #endif // MEDIA_TOOLS_PLAYER_WTL_VIEW_H_ 453 #endif // MEDIA_TOOLS_PLAYER_WTL_VIEW_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698