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

Side by Side Diff: media/mp4/mp4_stream_parser.h

Issue 10837116: Update EME MediaKeyNeededEvent.initData for ISO BMFF to match current spec. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Overzealous statement terminator is overzealous Created 8 years, 2 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/mp4/box_reader.h ('k') | media/mp4/mp4_stream_parser.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 #ifndef MEDIA_MP4_MP4_STREAM_PARSER_H_ 5 #ifndef MEDIA_MP4_MP4_STREAM_PARSER_H_
6 #define MEDIA_MP4_MP4_STREAM_PARSER_H_ 6 #define MEDIA_MP4_MP4_STREAM_PARSER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 30 matching lines...) Expand all
41 kWaitingForInit, 41 kWaitingForInit,
42 kParsingBoxes, 42 kParsingBoxes,
43 kEmittingSamples, 43 kEmittingSamples,
44 kError 44 kError
45 }; 45 };
46 46
47 bool ParseBox(bool* err); 47 bool ParseBox(bool* err);
48 bool ParseMoov(mp4::BoxReader* reader); 48 bool ParseMoov(mp4::BoxReader* reader);
49 bool ParseMoof(mp4::BoxReader* reader); 49 bool ParseMoof(mp4::BoxReader* reader);
50 50
51 bool EmitKeyNeeded(const TrackEncryption& track_encryption); 51 // Returns 'true' if sent or not required, 'false' if there was an error.
52 bool EmitNeedKeyIfNecessary(
53 const std::vector<ProtectionSystemSpecificHeader>& headers);
52 54
53 // To retain proper framing, each 'mdat' atom must be read; to limit memory 55 // To retain proper framing, each 'mdat' atom must be read; to limit memory
54 // usage, the atom's data needs to be discarded incrementally as frames are 56 // usage, the atom's data needs to be discarded incrementally as frames are
55 // extracted from the stream. This function discards data from the stream up 57 // extracted from the stream. This function discards data from the stream up
56 // to |offset|, updating the |mdat_tail_| value so that framing can be 58 // to |offset|, updating the |mdat_tail_| value so that framing can be
57 // retained after all 'mdat' information has been read. 59 // retained after all 'mdat' information has been read.
58 // Returns 'true' on success, 'false' if there was an error. 60 // Returns 'true' on success, 'false' if there was an error.
59 bool ReadAndDiscardMDATsUntil(const int64 offset); 61 bool ReadAndDiscardMDATsUntil(const int64 offset);
60 62
61 void ChangeState(State new_state); 63 void ChangeState(State new_state);
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 uint32 video_track_id_; 107 uint32 video_track_id_;
106 bool has_sbr_; 108 bool has_sbr_;
107 109
108 DISALLOW_COPY_AND_ASSIGN(MP4StreamParser); 110 DISALLOW_COPY_AND_ASSIGN(MP4StreamParser);
109 }; 111 };
110 112
111 } // namespace mp4 113 } // namespace mp4
112 } // namespace media 114 } // namespace media
113 115
114 #endif // MEDIA_MP4_MP4_STREAM_PARSER_H_ 116 #endif // MEDIA_MP4_MP4_STREAM_PARSER_H_
OLDNEW
« no previous file with comments | « media/mp4/box_reader.h ('k') | media/mp4/mp4_stream_parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698