|
Shaka Packager SDK
|
Public Member Functions | |
| TrackRunIterator (const Movie *moov) | |
| bool | Init () |
| bool | Init (const MovieFragment &moof) |
| bool | IsRunValid () const |
| bool | IsSampleValid () const |
| void | AdvanceRun () |
| void | AdvanceSample () |
| bool | AuxInfoNeedsToBeCached () |
| bool | CacheAuxInfo (const uint8_t *buf, int size) |
| int64_t | GetMaxClearOffset () |
| const AudioSampleEntry & | audio_description () const |
| Only valid if is_audio() is true. | |
| const VideoSampleEntry & | video_description () const |
| Only valid if is_video() is true. | |
| std::unique_ptr< DecryptConfig > | GetDecryptConfig () |
Properties of the current run. Only valid if IsRunValid(). | |
| uint32_t | track_id () const |
| int64_t | aux_info_offset () const |
| int | aux_info_size () const |
| bool | is_encrypted () const |
| bool | is_audio () const |
| bool | is_video () const |
Properties of the current sample. Only valid if IsSampleValid(). | |
| int64_t | sample_offset () const |
| int | sample_size () const |
| int64_t | dts () const |
| int64_t | cts () const |
| int64_t | duration () const |
| bool | is_keyframe () const |
Definition at line 25 of file track_run_iterator.h.
|
explicit |
Create a new TrackRunIterator from movie box.
| moov | should not be NULL. |
Definition at line 89 of file track_run_iterator.cc.
| shaka::media::mp4::TrackRunIterator::~TrackRunIterator | ( | ) |
Definition at line 94 of file track_run_iterator.cc.
| void shaka::media::mp4::TrackRunIterator::AdvanceRun | ( | ) |
Advance iterator to the next run. Require that the iterator point to a valid run.
Definition at line 442 of file track_run_iterator.cc.
| void shaka::media::mp4::TrackRunIterator::AdvanceSample | ( | ) |
Advance iterator to the next sample. Require that the iterator point to a valid sample.
Definition at line 455 of file track_run_iterator.cc.
| const AudioSampleEntry & shaka::media::mp4::TrackRunIterator::audio_description | ( | ) | const |
Only valid if is_audio() is true.
Definition at line 556 of file track_run_iterator.cc.
| int64_t shaka::media::mp4::TrackRunIterator::aux_info_offset | ( | ) | const |
Definition at line 538 of file track_run_iterator.cc.
| int shaka::media::mp4::TrackRunIterator::aux_info_size | ( | ) | const |
Definition at line 542 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::AuxInfoNeedsToBeCached | ( | ) |
Definition at line 464 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::CacheAuxInfo | ( | const uint8_t * | buf, |
| int | size | ||
| ) |
Caches the CENC data from the given buffer.
| buf | must be a buffer starting at the offset given by cenc_offset(). |
| size | must be at least cenc_size(). |
Definition at line 471 of file track_run_iterator.cc.
| int64_t shaka::media::mp4::TrackRunIterator::cts | ( | ) | const |
Definition at line 583 of file track_run_iterator.cc.
| int64_t shaka::media::mp4::TrackRunIterator::dts | ( | ) | const |
Definition at line 578 of file track_run_iterator.cc.
| int64_t shaka::media::mp4::TrackRunIterator::duration | ( | ) | const |
Definition at line 588 of file track_run_iterator.cc.
| std::unique_ptr< DecryptConfig > shaka::media::mp4::TrackRunIterator::GetDecryptConfig | ( | ) |
Only call when is_encrypted() is true and AuxInfoNeedsToBeCached() is false. Result is owned by caller.
Definition at line 605 of file track_run_iterator.cc.
| int64_t shaka::media::mp4::TrackRunIterator::GetMaxClearOffset | ( | ) |
Definition at line 507 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::Init | ( | ) |
For non-fragmented mp4, moov contains all the chunk information; This function sets up the iterator to access all the chunks. For fragmented mp4, chunk and sample information are generally contained in moof. This function is a no-op in this case. Init(moof) will be called later after parsing moof.
Definition at line 162 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::Init | ( | const MovieFragment & | moof | ) |
Set up the iterator to handle all the runs from the current fragment.
Definition at line 287 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::is_audio | ( | ) | const |
Definition at line 546 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::is_encrypted | ( | ) | const |
Definition at line 533 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::is_keyframe | ( | ) | const |
Definition at line 593 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::is_video | ( | ) | const |
Definition at line 551 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::IsRunValid | ( | ) | const |
Definition at line 495 of file track_run_iterator.cc.
| bool shaka::media::mp4::TrackRunIterator::IsSampleValid | ( | ) | const |
Definition at line 497 of file track_run_iterator.cc.
| int64_t shaka::media::mp4::TrackRunIterator::sample_offset | ( | ) | const |
Definition at line 568 of file track_run_iterator.cc.
| int shaka::media::mp4::TrackRunIterator::sample_size | ( | ) | const |
Definition at line 573 of file track_run_iterator.cc.
| uint32_t shaka::media::mp4::TrackRunIterator::track_id | ( | ) | const |
Definition at line 528 of file track_run_iterator.cc.
| const VideoSampleEntry & shaka::media::mp4::TrackRunIterator::video_description | ( | ) | const |
Only valid if is_video() is true.
Definition at line 562 of file track_run_iterator.cc.