sannies / mp4parser

A Java API to read, write and create MP4 files
Apache License 2.0
2.76k stars 566 forks source link

Can i use this lib to save media stream data in webrtc? #88

Closed hoang89yenthe closed 9 years ago

sannies commented 9 years ago

I don't know. Please describe what you are trying to accomplish.

hoang89yenthe commented 9 years ago

I want to streamming media data throught 2 android devices. I used this example : https://github.com/pchab/AndroidRTC and i did it. In this example, they used 2 lib android: libjingle_peerconnection and socket.io_client. My problem is when media data is streamming, i can not save it as mp4. Please check my question in here :http://stackoverflow.com/questions/30685276/how-do-record-media-stream-data-as-h-264mp4-in-webrtc-android Sorry for my english

sannies commented 9 years ago

Ok. Mp4 is a container format . Mp4parser can package supported formats/codecs in MP4 containers . What kind of codec is used for webrtc?

hoang89yenthe commented 9 years ago

VP8 for video and Opus for Audio

sannies commented 9 years ago

Ok, now we are getting closer! Afaik there is no specification that allows you package VP8 and/or Opus in MP4 containers. Therefore the mp4parser library won't be able to help you.

mlaggner commented 5 years ago

according to http://opus-codec.org/docs/ - http://opus-codec.org/docs/opus_in_isobmff.html it should be possible to package opus in mp4