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

Side by Side Diff: media/base/stream_parser.h

Issue 195973006: Allow StreamParsers to request automatic timestampOffset updates. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comments. 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 | « no previous file | media/filters/chunk_demuxer.cc » ('j') | media/filters/chunk_demuxer.cc » ('J')
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 #ifndef MEDIA_BASE_STREAM_PARSER_H_ 5 #ifndef MEDIA_BASE_STREAM_PARSER_H_
6 #define MEDIA_BASE_STREAM_PARSER_H_ 6 #define MEDIA_BASE_STREAM_PARSER_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 // Map of text track ID to decode-timestamp-ordered buffers for the track. 46 // Map of text track ID to decode-timestamp-ordered buffers for the track.
47 typedef std::map<TrackId, const BufferQueue> TextBufferQueueMap; 47 typedef std::map<TrackId, const BufferQueue> TextBufferQueueMap;
48 48
49 StreamParser(); 49 StreamParser();
50 virtual ~StreamParser(); 50 virtual ~StreamParser();
51 51
52 // Indicates completion of parser initialization. 52 // Indicates completion of parser initialization.
53 // First parameter - Indicates initialization success. Set to true if 53 // First parameter - Indicates initialization success. Set to true if
54 // initialization was successful. False if an error 54 // initialization was successful. False if an error
55 // occurred. 55 // occurred.
56 // Second parameter - Indicates the stream duration. Only contains a valid 56 // Second parameter - Indicates the stream duration. Only contains a valid
57 // value if the first parameter is true. 57 // value if the first parameter is true.
58 typedef base::Callback<void(bool, base::TimeDelta)> InitCB; 58 // Third parameters - Indicates that timestampOffset should be updated based
59 // on the earliest end timestamp (audio or video) provided
60 // during each NewBuffersCB.
61 typedef base::Callback<void(bool, base::TimeDelta, bool)> InitCB;
59 62
60 // Indicates when new stream configurations have been parsed. 63 // Indicates when new stream configurations have been parsed.
61 // First parameter - The new audio configuration. If the config is not valid 64 // First parameter - The new audio configuration. If the config is not valid
62 // then it means that there isn't an audio stream. 65 // then it means that there isn't an audio stream.
63 // Second parameter - The new video configuration. If the config is not valid 66 // Second parameter - The new video configuration. If the config is not valid
64 // then it means that there isn't an audio stream. 67 // then it means that there isn't an audio stream.
65 // Third parameter - The new text tracks configuration. If the map is empty, 68 // Third parameter - The new text tracks configuration. If the map is empty,
66 // then no text tracks were parsed from the stream. 69 // then no text tracks were parsed from the stream.
67 // Return value - True if the new configurations are accepted. 70 // Return value - True if the new configurations are accepted.
68 // False if the new configurations are not supported 71 // False if the new configurations are not supported
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 // subtle issues with tie-breaking. See http://crbug.com/338484. 139 // subtle issues with tie-breaking. See http://crbug.com/338484.
137 MEDIA_EXPORT bool MergeBufferQueues( 140 MEDIA_EXPORT bool MergeBufferQueues(
138 const StreamParser::BufferQueue& audio_buffers, 141 const StreamParser::BufferQueue& audio_buffers,
139 const StreamParser::BufferQueue& video_buffers, 142 const StreamParser::BufferQueue& video_buffers,
140 const StreamParser::TextBufferQueueMap& text_buffers, 143 const StreamParser::TextBufferQueueMap& text_buffers,
141 StreamParser::BufferQueue* merged_buffers); 144 StreamParser::BufferQueue* merged_buffers);
142 145
143 } // namespace media 146 } // namespace media
144 147
145 #endif // MEDIA_BASE_STREAM_PARSER_H_ 148 #endif // MEDIA_BASE_STREAM_PARSER_H_
OLDNEW
« no previous file with comments | « no previous file | media/filters/chunk_demuxer.cc » ('j') | media/filters/chunk_demuxer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698