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

Side by Side Diff: media/tools/player_x11/player_x11.cc

Issue 10808087: Remove use of PipelineStatus from BufferedDataSource and FileDataSource. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src
Patch Set: status -> success Created 8 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
« no previous file with comments | « media/tools/player_wtl/movie.cc ('k') | media/tools/seek_tester/seek_tester.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 #include <signal.h> 5 #include <signal.h>
6 6
7 #include <iostream> // NOLINT 7 #include <iostream> // NOLINT
8 8
9 #include "base/at_exit.h" 9 #include "base/at_exit.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 static bool g_running = false; 43 static bool g_running = false;
44 44
45 media::AudioManager* g_audio_manager = NULL; 45 media::AudioManager* g_audio_manager = NULL;
46 46
47 media::VideoRendererBase* g_video_renderer = NULL; 47 media::VideoRendererBase* g_video_renderer = NULL;
48 48
49 scoped_refptr<media::FileDataSource> CreateFileDataSource( 49 scoped_refptr<media::FileDataSource> CreateFileDataSource(
50 const std::string& file) { 50 const std::string& file) {
51 scoped_refptr<media::FileDataSource> file_data_source( 51 scoped_refptr<media::FileDataSource> file_data_source(
52 new media::FileDataSource()); 52 new media::FileDataSource());
53 CHECK_EQ(file_data_source->Initialize(file), media::PIPELINE_OK); 53 CHECK(file_data_source->Initialize(file));
54 return file_data_source; 54 return file_data_source;
55 } 55 }
56 56
57 // Initialize X11. Returns true if successful. This method creates the X11 57 // Initialize X11. Returns true if successful. This method creates the X11
58 // window. Further initialization is done in X11VideoRenderer. 58 // window. Further initialization is done in X11VideoRenderer.
59 bool InitX11() { 59 bool InitX11() {
60 g_display = XOpenDisplay(NULL); 60 g_display = XOpenDisplay(NULL);
61 if (!g_display) { 61 if (!g_display) {
62 std::cout << "Error - cannot open display" << std::endl; 62 std::cout << "Error - cannot open display" << std::endl;
63 return false; 63 return false;
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
303 // Release callback which releases video renderer. Do this before cleaning up 303 // Release callback which releases video renderer. Do this before cleaning up
304 // X below since the video renderer has some X cleanup duties as well. 304 // X below since the video renderer has some X cleanup duties as well.
305 paint_cb.Reset(); 305 paint_cb.Reset();
306 306
307 XDestroyWindow(g_display, g_window); 307 XDestroyWindow(g_display, g_window);
308 XCloseDisplay(g_display); 308 XCloseDisplay(g_display);
309 g_audio_manager = NULL; 309 g_audio_manager = NULL;
310 310
311 return 0; 311 return 0;
312 } 312 }
OLDNEW
« no previous file with comments | « media/tools/player_wtl/movie.cc ('k') | media/tools/seek_tester/seek_tester.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698