Commit Graph

1531 Commits

Author SHA1 Message Date
Rintaro Kuroiwa fe2214b9a0 Add unittest file for XmlNode
Small coverage.

Change-Id: I6053d82a0f9b1d391b4720c419ff7b3cbaa67ca8
2014-01-23 08:48:31 -08:00
Rintaro Kuroiwa bd44c7d7b8 MpdBuilder should handle ContentProtectionXml
Added functions to add MediaInfo::ContentProtectionXml to
RepresentationBaseXmlNode. This allows adding ContentProtection elements
using MediaInfo protobuf.

Change-Id: I46aa97ba8cbf1548388ebbb61ac163786dfa0be8
2014-01-23 08:46:53 -08:00
Kongqun Yang 6957a4ac07 Implement packager driving program packager_main
I am not sure whether it is a good idea to define command line flags
in the actual source. I created several flags definition .h to host
these flags for now.

Change-Id: Ib6ca60d8656e8015a64dafff8e0a98a47676bbd2
2014-01-22 11:51:28 -08:00
Kongqun Yang 8f495e6615 Create doxygen config
Change-Id: I77c28af150d5110cf6067919dc8795cf25cda79d
2014-01-22 19:26:27 +00:00
Rintaro Kuroiwa 90dae2716c Convert info from muxer to MediaInfo and dump to file
A MuxerListener implementation.
MediaInfo protobuf is dumped out to a file as human readable string.

Change-Id: I1b1d52b4d11d969efc07b413ff25cb26fb1aa2b4
2014-01-22 00:38:23 -08:00
Rintaro Kuroiwa 9b3ed17a96 Delegate MediaInfo generation for VOD
Info from muxer is delegated to a function in internal namespace to
create MediaInfo protobuf structure.

Change-Id: I7c00ce02c9ab23f022cf485e582d771ce61107cf
2014-01-22 00:24:05 -08:00
Kongqun Yang 596e59c8be Add RSA signing support in WidevineEncryptorSource
Defines an abstract request signer class and two implementations of the
signer class, AesRequestSigner for AES-CBC signing and RsaRequestSigner
for RSA-PSS signing.

WidevineEncryptorSource now uses Signer for signature generation.

Change-Id: I4528409a9be998535bccde40fdadb412e4bbdaf3
2014-01-21 18:32:08 -08:00
Kongqun Yang 85c91568f2 Add a new packager test for separate av muxer output
Also fix a bug that when Muxer::Finalize is called, the fragmenter
isn't initialized yet.

Change-Id: I826d1ad2519e553de8581ac4a334373cf1eb8067
2014-01-22 02:27:52 +00:00
Kongqun Yang 257b48536a Clean up tools directory.
Remove all files and directories except:
clang  emacs  git  gyp  heapcheck  protoc_wrapper  valgrind  vim
xdisplaycheck

Change-Id: I6326e4edad4b843e0d0c2ef39c20ac90f13c8579
2014-01-21 23:15:57 +00:00
Rintaro Kuroiwa 72deea3493 Fix compilation errors by clang for mpd_builder target
Change-Id: I7c6f09714a4005267469bebf4b9783466883236f
2014-01-21 14:02:19 -08:00
Rintaro Kuroiwa efa270963e Remove disable gold flag and enable clang in build.sh
Change-Id: I497234ed6285785e5b8905d03c44adb9b9eda4ab
2014-01-17 14:28:37 -08:00
Kongqun Yang e6df0ffb21 Fix asan error in aes_encryptor_unittest.
The error was caused by an incorrectly constructed test case.

Change-Id: I86006bd79d85f68d28d623da5c644b9037a12844
2014-01-17 01:42:40 +00:00
Kongqun Yang 8095e21c96 Clean up clang compilation errors.
Clang from Chromium enforces Chromium styles:
http://www.chromium.org/developers/coding-style,
http://www.chromium.org/developers/coding-style/chromium-style-checker-errors.

Change-Id: I8070739489a8109380578d1797801e981d119793
2014-01-17 01:41:45 +00:00
Rintaro Kuroiwa 3da90d8bad Ignore gold directory for pulling in gold linker
Change-Id: I00e4c80c6b14d9173d62b898e8a0cf7603e03ee5
2014-01-16 14:56:41 -08:00
Kongqun Yang 76269c4706 Add static function File::ReadFileToString.
Change-Id: Ib50aea743662376c8c7da82bba4002932da4014c
2014-01-16 22:14:59 +00:00
Rintaro Kuroiwa 014cde57bd Ignore third_party/llvm-build
This only matters if you pull clang for building the packager.
clang binaries gets pulled in to third_party/llvm-build if you run
the script in tools/clang/scripts/update.sh.
clang is useful for ASAN and style (and better compiler error output).

Change-Id: Id615d739f80e92036fe13c3152569e51aed8a7f0
2014-01-16 11:02:10 -08:00
Rintaro Kuroiwa e4d94be0d3 Fire MuxerListener events from MP4Muxer
Implementation only for OnMediaStart and OnMediaEnd.

Change-Id: I58a94c29b7e8cecf29b6202c7018592e5ce620b2
2014-01-14 18:25:07 -08:00
Kongqun Yang 57ca7d2144 Remove EncryptorSource argument from Muxer constructor.
Add a new function Muxer::SetEncryptorSource. Also clean up
packager test.

Change-Id: I5fee46e3d15e0c7a0f138c1d90f980b724887768
2014-01-15 01:48:41 +00:00
Kongqun Yang b6af6ca976 Move encryptor creation out of EncryptorSource::Initialize.
Use EncryptorSource::CreateEncryptor for encryptor creation.
EncryptorSource no longer owns the created encryptor.

Change-Id: I34d1f32262b7692bcb347d3b084fd06cbae7850f
2014-01-15 01:47:47 +00:00
Rintaro Kuroiwa 0154654539 Remove LITE from protobuf for serialization to human readable string
TextFormat class methods that output human readable messsages need
Message instance where LITE uses MessageLite.

Change-Id: I4ff14aa9334acdad608f0b02c81d9cb765e70a60
2014-01-14 16:18:40 -08:00
Rintaro Kuroiwa f4c7807554 Add 'name' field to Element protobuf message
Change-Id: I527433d6cee2c4e0deb2f243f623f40e29ba8c21
2014-01-14 15:18:54 -08:00
Rintaro Kuroiwa a84d6a7d09 Add mimeType to Representation and use float for duration
Work on some TODOs.
Mandatory mimeType field was missing from Representation.
All duration in the MPD is now float.

Change-Id: I85b8511bc1c43759d80f831bee371c398895cf39
2014-01-14 13:58:01 -08:00
Rintaro Kuroiwa 4723ef777d Add container type to MediaInfo proto
Change-Id: Ife22c7d8641af3847be3da9bf6e96146d72749f0
2014-01-14 21:10:28 +00:00
Kongqun Yang e7472c4247 Fix a path conflict due to merging.
Change-Id: Ib84e9628e62d423141fcad5e9763fc87dd666c5e
2014-01-13 18:10:10 +00:00
Rintaro Kuroiwa db5b2a4740 Unit test for MPD builder
Initial checkin, very small coverage.

Change-Id: I60f3fd768d5b8dca7a84f051e57f59a654272e53
2014-01-10 17:40:26 -08:00
Kongqun Yang 1eb5236c90 Rsa Key unittest.
Change-Id: I761db06762e594884f339aee66fec171c92b8108
2014-01-11 01:16:40 +00:00
Kongqun Yang a725f3fd02 Fix mp4 parsing failure if CTTS table is empty.
The original code assumes CompositionOffset is always valid and
has the same number of samples as other table, which is not true
if CTTS table is empty for non-fragmented mp4.

Change-Id: If4ecc1159de33202db4ab36df8e32c2a6900daf8
2014-01-10 16:36:22 -08:00
Rintaro Kuroiwa 0ccae0d0c9 Add namespace info to MPD
Change-Id: Ie12ebb1fef24d60ff7b8644406931a2677d7033e
2014-01-11 00:03:41 +00:00
Kongqun Yang c73bfadd0e Move test utilities in media/base to media/test.
Also clean up test_data_util.cc.

Change-Id: Ic6038e072939d55fad7cc739b53ab9888b4251c1
2014-01-10 15:38:40 -08:00
Rintaro Kuroiwa faab1435ba Merge "A muxer listener implementation for VOD" 2014-01-10 23:35:12 +00:00
Kongqun Yang e4ebc9763c Rename AAC to AACAudioSpecificConfig.
Change-Id: Idda2db1f2cdde6c2c220830c2681bef209ad4ce2
2014-01-10 23:34:50 +00:00
Rintaro Kuroiwa 1a28e0c475 A muxer listener implementation for VOD
Change-Id: I48890799deb7cda66d477392a671bbd8c01a9dbe
2014-01-10 15:32:13 -08:00
Rintaro Kuroiwa 4c01b89625 Merge "Add fields in ContentProtection to match MPD spec" 2014-01-10 22:57:34 +00:00
Rintaro Kuroiwa d34a331ef5 Add fields in ContentProtection to match MPD spec
Because we need to have all meta info in the MediaInfo protobuf, we need
full 'ContentProtection' element.

Change-Id: I714ff5b8d7baa2ae0d169a59005210a63da315b5
2014-01-10 14:53:06 -08:00
Kongqun Yang ffc4a82460 Implement RsaPrivateKey and RsaPublicKey.
Used for message signing, signature verification, encryption and
decryption using RSA algorithm.

Change-Id: Icacd5a994c532a7bd4179c44e98c3ee9db744e83
2014-01-10 22:28:20 +00:00
Kongqun Yang 1e7080dda6 Implement Widevine encryptor source.
Use AES CBC signing for now. Rsa signing is not implemented yet.

Change-Id: Ife52ac098e9a82d4e40bbe0c0156f435a67c1aac
2014-01-10 14:24:15 -08:00
Kongqun Yang 577f899794 Implement AES CBC encryption/decrytion.
Change-Id: I017b02b5e8fc64c280a8245b72be89e1cf047f26
2014-01-10 21:33:09 +00:00
Rintaro Kuroiwa d36091cf65 MpdNotifier and simple MpdNotifier implementation for VOD
This is the MPD side of the bridge between MpdBuilder
and Muxer.

Change-Id: I4ca7436914e008b3c65399cced1f689abd82d085
2014-01-10 11:35:38 -08:00
Kongqun Yang cde567c14c Add gflags for commandline flags processing.
gflags configuration files are fetched from webrtc:
https://code.google.com/p/webrtc/source/browse/trunk/third_party/gflags
gflags source is cloned from https://github.com/schuhschuh/gflags

Change-Id: Ieb544990278b542decd2a25e6c24fc93cc5e3228
2014-01-10 02:38:18 +00:00
Rintaro Kuroiwa 0f3056b551 Use scoped_ptr for box ownership transfer
MP4Muxer passes ownership of ftyp and moov box to MP4Segmenter.

Change-Id: Iae7c7161560c744d8d3e7e5382450e7d056112ec
2014-01-08 12:06:04 -08:00
Kongqun Yang 1b5c3b5316 MP4 Muxer implementation.
Change-Id: I2aeb506e5bf7e2301e855456688273fe5f3988a2
2014-01-07 17:40:37 -08:00
Kongqun Yang 01646837e1 Implement write function for cenc and es_descriptor.
And MP4 code clean ups due to mp4 box changes.

Change-Id: I712b2dceb5038bfefa14097fe2fb2ab1fb913cb5
2014-01-07 16:59:52 -08:00
Kongqun Yang dccb069ffc A simple HTTPFetcher implementation using happyhttp.
Change-Id: I4f64d46ca4873711300ae175c5f5646ca1a7c366
2014-01-06 22:02:36 +00:00
Rintaro Kuroiwa 79bd9eb51d Merge "Ignore pyc files" 2014-01-06 20:11:55 +00:00
Rintaro Kuroiwa 807f21d81a Ignore pyc files
Change-Id: Icf52c911c1fa0a9a601c7c95576485f7f495cfe3
2014-01-06 11:40:13 -08:00
Kongqun Yang 636baf9b21 MP4 Box unittest.
Change-Id: I1ed9b0108f5da4c52a3e33514ac4fd952f6616d0
2014-01-02 17:14:53 -08:00
Kongqun Yang 57474b31d6 Implement mp4 box read/write.
The box may be optimized if necessary during writing.

Change-Id: I7a46e72a0bcbeacb23085a87e1f0df3a826e4da7
2014-01-02 17:12:51 -08:00
Kongqun Yang 0f3bc4b6b4 Implement base mp4 box objects: Box and FullBox.
Change-Id: Ic1acc0f7ec3999d5270609a8836dbbde7f0d1c0f
2014-01-03 00:58:09 +00:00
Rintaro Kuroiwa b6e127416b MuxerListener interface
Muxer event handler interface.

Change-Id: Iee4b43c49ae9a105bbadb61b6ae9ed2e66bfaba2
2014-01-02 10:44:51 -08:00
Rintaro Kuroiwa 65a3a69646 mpd_builder build target fix
This can compile the static library.

Change-Id: Iec108b9b94dbfd5f1de09434403763d59b89b535
2013-12-26 16:03:13 -08:00