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

Side by Side Diff: services/media/framework_ffmpeg/ffmpeg_io.h

Issue 1686363002: Motown: ffmpeg implementations of framework 'parts' (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Changed the way AVBuffer allocation/deallocation is done in the ffmpeg audio decoder. 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef SERVICES_MEDIA_FRAMEWORK_FFMPEG_FFMPEG_IO_H_
6 #define SERVICES_MEDIA_FRAMEWORK_FFMPEG_FFMPEG_IO_H_
7
8 #include "services/media/framework/parts/reader.h"
9 extern "C" {
10 #include "third_party/ffmpeg/libavformat/avio.h"
11 }
12
13 namespace mojo {
14 namespace media {
15
16 struct AVIOContextDeleter {
17 void operator()(AVIOContext* context) const {
18 av_free(context->buffer);
19 av_free(context);
20 }
21 };
22
23 using AvioContextPtr = std::unique_ptr<AVIOContext, AVIOContextDeleter>;
24
25 // Creates an ffmpeg avio_context for a given reader.
26 AvioContextPtr CreateAvioContext(Reader* reader);
27
28 } // namespace media
29 } // namespace mojo
30
31 #endif // SERVICES_MEDIA_FRAMEWORK_FFMPEG_FFMPEG_IO_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698