Commit Graph

374 Commits

Author SHA1 Message Date
Rintaro Kuroiwa e9437068cf Add packager/buildtools to gitginore
Change-Id: I9d832c9ce7172eeef9f7abdef673e217d40ed48f
2015-10-19 12:49:03 -07:00
KongQun Yang c4fc05ef62 Add doxygen API link in README.md and DESIGN.md
Change-Id: I7212102d3117a69d65b0f096e0968278b63cd0b0
2015-10-19 12:11:23 -07:00
KongQun Yang afbab86399 Additional clean ups on comments and TODOs
Also rename WebMStreamParser to WebMMediaParser.

Change-Id: I0defca481f9d7774dd84810a5abd52902d5f47b6
2015-10-19 17:23:46 +00:00
KongQun Yang 845766f69a Make webm parser compile and unittest pass
Change-Id: Ib93fbb3eba6f0638f3aa57a9a47e73e8738792d1
2015-10-16 15:51:56 -07:00
KongQun Yang 5a4234f4da Update webm_cluster_parser to emit samples
Change-Id: I02436cfcb53b96210d6f683227cdabb994f4c01f
2015-10-16 15:46:36 -07:00
KongQun Yang 732e06fde0 Adjust webm code for packager
- Adding namespace edash_packager
- Fix includes
- (u)int(8|16|32|64) to (u)int(8|16|32|64)_t
- Remove MEDIA_EXPORT
- Remove MediaLog

Change-Id: Ifa116d966ab70ae1b3c299ae1f6f7044d7ae0cc6
2015-10-16 15:46:36 -07:00
KongQun Yang 87993c5dc7 Add WebM parser code from Chromium
Also includes its dependencies, like media/base/text_track_config.*
and media/filters/webvtt_util.h

Change-Id: I5b26245daf004da19b912b7c5b2c21ce4ba85688
2015-10-16 15:46:36 -07:00
KongQun Yang b6db8b9867 Get rid of svn dependencies
- Generate local copies of libevent, libxml and protobuf.

Change-Id: Ibb29f604191519267f0e6a3ee810cad0c1f80b27
2015-10-16 20:11:20 +00:00
Kongqun Yang 571d713fec Boringssl gyp and patches from Chromium
Bug: 22463853

Change-Id: Ib108016160d2c6ecdd56e369b585ab3c3ae82601
2015-10-16 20:11:04 +00:00
Kongqun Yang 9c0ae378bc Switch to boringssl. Also update curl accordingly.
Boringssl and yasm gyp and patches will follow in a separate cl.

Bug: 22463853

Change-Id: I87b91ac089866db58ac433def006fe9ac4744bd6
2015-10-16 20:10:38 +00:00
Kongqun Yang 73924e56c3 Replace gflags with git repo
Change-Id: I3819ce117e05ee86cef9abad4ca56bcb1d2860a6
2015-10-16 20:10:17 +00:00
Kongqun Yang 47c79d08ce Update code to resolve problems due to base updates.
Notably deprecate of OVERRIDE, to be replaced with C++11 override.

Bug: 22463130
Bug: 22664127

Change-Id: I12c82e092e9e8eb0870da4363307c3563a3531b7
2015-10-16 20:09:56 +00:00
Kongqun Yang 8cd33d8b21 Update DEPS to use git as much as possible.
Will retire remaining svn repositories in subsequent CLs.

Bug: 22463130

Change-Id: Iebe5d53b8a4424413836c5b8351b349e8da3ce70
2015-10-16 20:09:19 +00:00
Thomas Inskip a9b6fcedd7 Added fallback to computed AVCDecoderConfigurationRecord if the one
stored in the WVM metadata is invalid.

Change-Id: I9e3c7ba4677f1ac7c19ec4d51f600d28bb427acb
2015-10-14 09:46:14 -07:00
Thomas Inskip cb7173d280 Added support for multiple audio & video configurations in WVM parser.
BUG=24614172

Change-Id: I197a0ebdfa6df90abc27358762cae041e4f8fd45
2015-10-13 10:42:49 -07:00
KongQun Yang 93e6c4fc92 Reduce test file sizes and remove unused test files
Change-Id: I7e3b24e92b2a16de857e0424c85232cc31444182
2015-10-12 20:16:03 +00:00
Thomas Inskip d0fb8ced4b Use default audio and video PES stream IDs (0xc0 and 0xe0 respectively)
if not specified in the WVM metadata.

BUG=24753064

Change-Id: I4c4cd0b30f0e153d46639382682da13b127dd305
2015-10-08 13:16:00 -07:00
Kongqun Yang 25cac4aa12 Added CHANGELOG.md and bump version to v1.2.0
Change-Id: Iab4a6085ad97fa04a319013ff70c3450511ebc52
2015-10-02 00:13:36 +00:00
KongQun Yang 7bc1b6323b Update README.md
- Added instructions on how to sync to a particular revision
- Added a paragraph on DASH-IF IOP compliance
- Some minor edits on docker instructions

Change-Id: I4ebe1d471f1593aa1a88e604ed6e8c4261b044a5
2015-10-01 23:30:41 +00:00
KongQun Yang 3677042a7c Cleanup producer_consumer_queue_unittest
Uses EXPECT_NEAR for comparison with an acceptable error bound. Also
increases error bound to 50ms.

Change-Id: I8fc61b3b915a50f8fe33b9ea72e123aefee25a80
2015-10-01 10:31:27 -07:00
KongQun Yang 2080973f17 Fix an xml include in xml_compare.cc
Change-Id: I06867c8405b0b7ff55f17622e409a42d3eceacc0
2015-09-30 17:45:46 -07:00
Kongqun Yang 5782ffdc81 Merge pull request #32 from leandromoreira/master
introduces docker for testing/development fixes #31
2015-09-30 15:21:44 -07:00
Rintaro Kuroiwa 76e5be3756 More fix for live
- Neither live with or without key rotation did not output the right
  result.
- No key rotation: did not produce any ContentProtection element.
- With key rotation: did not have DRM specific ContentProtection.
- To get key rotation working with shaka player, <cenc:pssh> elements
  are removed.

Change-Id: I1f34d303ae1f3ea81820e3368ab66b8420498372
2015-09-29 15:12:46 -07:00
KongQun Yang 8a850af9cd Add end to end tests for edash-packager
Test files can be updated with --test_update_golden_files if needed.

Change-Id: I5aa904634450f8963f55c46ab5fe0b63f67fef46
2015-09-29 20:38:22 +00:00
KongQun Yang 8c202047fb Make edash-packager outputs predictable for testing
- Added --iv to inject iv for fixed key encryption.
- Added support for key rotation in fixed key encryption.
- Added --use_fake_clock_for_muxer to set timestamp to 0 in the output.

Also updates stream info dump message:
- Modified pixel_width: %d\n pixel_height: %d to pixel aspect ratio: %d:%d
- Removed language from video stream info.

These flags should only be used for testing.

Change-Id: Iedf8d6d6492226219f49fe44d932645f557010e4
2015-09-29 17:19:59 +00:00
Kongqun Yang 7ac31f2111 Move design to DESIGN.md
Change-Id: Ibc09946970fac89faf151de2ef3e19de1cecb171
2015-09-24 17:46:05 +00:00
KongQun Yang 5c788c2dd5 Use StrEq for string comparison in mpd notifier unittests
Change-Id: I9960908764aea29adbe8feae2a71359f9ff4ecee
2015-09-22 16:17:28 -07:00
Rintaro Kuroiwa 6a7b32641a Get MpdWriter working again
- ContentProtection elements were missing when using MpdWriter,
  therefore mpd_generator also did not generate ContentProtection.
- MpdWriter uses MpdNotifier now, instead of directly using MpdBuiler.
- Add mock_mpd_notifier.{h,cc} to be shared by several tests.

Change-Id: Id0f6213aa0c80e50294cd4193962054b0b5c2492
2015-09-22 15:00:03 -07:00
Kongqun Yang 3a5fdd2d9c Fix incorrect width/height in VisualSampleEntry for mp2t stream with cropping
Cropping is necessary if width/height are not exactly disivible by 16 due
to 16x16 macroblock size.

The width and height fields in VisualSampleEntry must correctly document
the cropped frame dimentions (visual presentation size) of the AVC stream
that is described by that entry.

Also fixes width/height in input mp4 and wvm streams if the values in
VisualSampleEntry / metadata do not match with the values in
AVCDecoderConfigurationRecord (SPS).

Issue: 39

Change-Id: Id55c5acf245bee3f4e66302b2042eb7d9c488c19
2015-09-18 17:42:52 +00:00
Rintaro Kuroiwa c75d319985 Live profile MPD did not have ContentProtection
- Because MpdBuilder no longer sets ContentProtection, live was broken.
- For key-rotation, <cenc:pssh> element is updated.

Change-Id: I45bb80a12faff39ccf5deb82439c0732ed9cea59
2015-09-16 15:50:00 -07:00
Rintaro Kuroiwa fa4a172b04 Add MpdNofitier::Flush() for explicit flushing
- Without the Flush() method the implementation had to do writes in
  almost all methods. Usually the user of the notifier knows when to
  write out the MPD.

Change-Id: Ic165d4594f01357a8ac7e8501eefa0f85c08d32f
2015-09-10 16:24:19 -07:00
Rintaro Kuroiwa d6fea8a8e6 Explicitly specify that availabilityStartTime is UTC
- Adding a 'Z' at the end means it is in UTC time.

Change-Id: I2e876c81449adcf3878e6d0d2b3c74f34edc8963
2015-09-10 11:55:12 -07:00
Rintaro Kuroiwa 0687b544b1 Fix SimpleMpdNotifier logic
- SimpleMpdNotifier didn't register the container ID to its map for VOD.
- AddContentProtection() was not implemented.

Change-Id: I5f1412c785ee5ad3d00910755ff283c404dd895c
2015-09-08 14:31:59 -07:00
Kongqun Yang 6e4460a245 Fix par_num / par_den not initialized problem in previous CL
Change-Id: I843d4e5ed60b05f9f68c298e11af1bdf3361ddf0
2015-08-28 21:28:36 +00:00
Kongqun Yang d71a37656a Find @par with smallest error with par_y in [1, 19]
Quotient reduction to minimal form does not work well in practice due to
rounding of the inputs.

Bug: 23432995

Change-Id: If333ab48accb7f6a3fac6ba4eb48ca7b9cee9826
2015-08-26 00:34:58 +00:00
Kongqun Yang 6cc81137a8 Add filters dependency to mp4 target
This fixes the build.

Change-Id: Iae0f6599d66ddcba82a3a826c22baf075e2bb560
2015-08-25 17:47:27 +00:00
Kongqun Yang 2a95367dd4 Move SAR extraction out of video_stream_info.cc
This fixes a circular dependency of media_base depends on filter and
filter depends on media_base.

Also added code to extract sar in WvmMediaParser if it is not yet
extracted when setting extra_data.

Change-Id: I1b5aef2444e4134c9b6663911ac5e5c4c220404a
2015-08-24 23:16:49 +00:00
Rintaro Kuroiwa 5a38dc9c12 Put Role element before Representation
- Follwing the MPD schema.

Change-Id: I2aadf43be224c7fb565592b1814e4bec74ac4800
2015-08-24 12:44:37 -07:00
Kongqun Yang 0614caed83 Fix a memory leak in mpd compare code
This only affects unittests.

Change-Id: I5deba5ce08c08970ec8b2de9ff5f6f7a7a5a436a
2015-08-20 19:24:52 +00:00
Kongqun Yang 368e94941b Add mailing list to README
Change-Id: I4d7b299391be5aa156a29b20932ee7fbd4e0c38d
2015-08-19 23:57:02 +00:00
Rintaro Kuroiwa 869d7f4620 Add generate_dash_if_iop_compliant_mpd flag for the driver
Change-Id: I0ad320848ad6eb36dfe358fe858a3d5f1f42dbcf
2015-08-18 13:13:41 -07:00
Rintaro Kuroiwa bb8cf87617 Add logic to correctly set subSegmentAlignment for VOD
- subSegmentAlignment logic assumed that all Representations were
  added before calling Representations::AddNewSegment() on any
  Representation in an AdaptationSet. It is not a valid assumption
  for VOD and is removed.

Change-Id: Ifb7e34ee103ee30027e45a804427baf281f3137c
2015-08-18 13:09:38 -07:00
Kongqun Yang e5b6096857 Generate tkhd and pasp boxes properly with non-square pixels
- Width/Height in tkhd box should be display resolution instead of
  coded resolution.
- pasp was not generated earlier.
- Assuming SAR as 1:1 if it failed to be extracted successfully.
- Also update test files for mp4_media_parser_unittest.

This fixes Issue #35.

Change-Id: Iedbe6a44465aac6723b6ea2de30aed180821eccd
2015-08-07 21:46:08 +00:00
Rintaro Kuroiwa 4f60bfc6c3 Call AddRole in DashIopCompliantMpdNotifier for video AdaptationSets
- All video AdaptationSets gets Role=main.

Change-Id: I476af6fd4b75491daf260640db88bfcc33dadb9c
2015-08-07 11:55:27 -07:00
Kongqun Yang 0ac14327c2 Handle large composition offset greater than (1<<31) properly
This fixes Issue #34: Sample composition offset greater than (1<<31)
is not supported.

Change-Id: I76b7bf7ceeaa9d9a7555f61842d4972a80ee48ca
2015-08-07 18:51:49 +00:00
Rintaro Kuroiwa 3d4872ec77 Add test that adds Role and ContentProtection elements
- ContentProtection elements must appear before Role elements.

Change-Id: If517a91c977487c1bd42cfe0b973aa0cfb8223f7
2015-08-06 16:46:13 -07:00
Rintaro Kuroiwa 48ff2fbe6a Call MpdNotifier::NotifyNewSegment for VOD
- Call NotifyNewSegment() in MpdNotifyMuxerListener::OnMediaEnd() to
  notify subsegments.
- This is necessary for MpdBuilder to calculate subsegmentAlignment.

Change-Id: I9359c408da4f616e543a6d9e568b010a90c90185
2015-08-05 11:49:15 -07:00
Rintaro Kuroiwa ab8f64ea2c Wire up Representation::SetSampleDuration() to update AdaptationSet frame rate
- Representation::SetSampleDuration() calls
  AdaptatoinSet::OnSetFrameRateForRepresentation() via
  RepresentationStateChangeListener.

Change-Id: I4a76c57798c9b6dc1e84ba47336ed1c78fbabfd6
2015-08-04 22:08:58 +00:00
Kongqun Yang 336435fcca Address one sample fragment issue #33
The segment duration was not reset after segment was finalized. It
was reset after adding one sample. This new sample was added to the
new fragment but was not recorded in the new segment, which resulted
in off-by-one error in the segment generation.

Change-Id: I1f9e00591be6b897773bf6caf94409b4bcd2277f
2015-08-04 14:19:00 -07:00
Rintaro Kuroiwa fca2bb1e44 Handle MpdNotifyMuxerListener::OnSampleDurationReady() for VOD
- Saves sample_duration in the media_info protobuf.
- When MpdNotifyMuxerListener::OnMediaEnd() is called, media_info passed
  to MpdNotifier::NotifyNewContainer() should contain the sample
  duration.
- Add tests for MpdNotifyMuxerListener.
- Moved common code from vod_media_info_dump_muxer_listener_unittest.cc
  and mpd_notify_muxer_listener_unittest.cc to
  muxer_listener_test_helper.cc.

Change-Id: Ibf2340076d45828d26f1af54a1ed8e95e5884c23
2015-08-03 13:07:18 -07:00