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

Side by Side Diff: services/media/framework_ffmpeg/ffmpeg_init.cc

Issue 1822333002: Motown: wholesale clang-format (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: dalesat Created 4 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "base/synchronization/lock.h" 5 #include "base/synchronization/lock.h"
6 #include "services/media/framework_ffmpeg/ffmpeg_init.h" 6 #include "services/media/framework_ffmpeg/ffmpeg_init.h"
7 7
8 extern "C" { 8 extern "C" {
9 #include "third_party/ffmpeg/libavformat/avformat.h" 9 #include "third_party/ffmpeg/libavformat/avformat.h"
10 } 10 }
11 11
12 namespace mojo { 12 namespace mojo {
13 namespace media { 13 namespace media {
14 14
15 void InitFfmpeg() { 15 void InitFfmpeg() {
16 static base::Lock lock_; 16 static base::Lock lock_;
17 static bool initialized_ = false; 17 static bool initialized_ = false;
18 18
19 base::AutoLock lock(lock_); 19 base::AutoLock lock(lock_);
20 if (!initialized_) { 20 if (!initialized_) {
21 initialized_ = true; 21 initialized_ = true;
22 av_register_all(); 22 av_register_all();
23 } 23 }
24 } 24 }
25 25
26 } // namespace media 26 } // namespace media
27 } // namespace mojo 27 } // namespace mojo
OLDNEW
« no previous file with comments | « services/media/framework_ffmpeg/ffmpeg_init.h ('k') | services/media/framework_ffmpeg/ffmpeg_video_decoder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698