fyhertz / libstreaming

A solution for streaming H.264, H.263, AMR, AAC using RTP on Android
Apache License 2.0
3.49k stars 1.08k forks source link

Save mediaStream as mp4(h.264) #111

Closed hoang89yenthe closed 9 years ago

hoang89yenthe commented 9 years ago

I want to streamming data through 2 android devices with node.js server. On the remote device, I want to save data as mp4. I did it in this example : https://github.com/pchab/AndroidRTC but I don't know how to save media stream as mp4 Your lib can do that?

tungds commented 9 years ago

Hi Hoang, Hien tai minh muon trong luc phone cua minh live streaming thi cung record lai toan bo qua trinh streaming do thanh dang file mp4 hoac 3gp. Khong biet ban da lam dieu nay chua. Minh da thu lam la trong class VideoStream minh viet mot thread cho phep capture lai camera su dung mediarecorder giong nhu ham encodeWithMediaRecorder() nhung bi loi. Neu ban lam roi co the goi y cho minh duoc chu? Thanks!

hoang89yenthe commented 9 years ago

Hi bạn Mình cũng đang mắc vấn đề này mà chưa biết làm thế nào. Mình muốn khi streaming, bên máy remote đồng thời ghi lại video luôn, mà chưa tìm ra giải pháp

On Tue, Jun 23, 2015, 10:22 AM tungds notifications@github.com wrote:

Hi Hoang, Hien tai minh muon trong luc phone cua minh live streaming thi cung record lai toan bo qua trinh streaming do thanh dang file mp4 hoac 3gp. Khong biet ban da lam dieu nay chua. Minh da thu lam la trong class VideoStream minh viet mot thread cho phep capture lai camera su dung mediarecorder giong nhu ham encodeWithMediaRecorder() nhung bi loi. Neu ban lam roi co the goi y cho minh duoc chu? Thanks!

— Reply to this email directly or view it on GitHub https://github.com/fyhertz/libstreaming/issues/111#issuecomment-114339753 .

tungds commented 9 years ago

mình k biết bên server bạn dùng hls hay rtmp nếu là hls thì nó sẽ chunk media file thành dạng .ts bạn cần có cơ chế nhận luồng stream đó và merge các file .ts vào với nhau. Google chắc nhiều về cái này

hoang89yenthe commented 9 years ago

Mình tham khảo cái ví dụ này trên github: http://github.com/pchab/AndroidRTC Mình dùng 2 máy Android để demo.

On Tue, Jun 23, 2015, 11:23 AM tungds notifications@github.com wrote:

mình k biết bên server bạn dùng hls hay rtmp nếu là hls thì nó sẽ chunk media file thành dạng .ts bạn cần có cơ chế nhận luồng stream đó và merge các file .ts vào với nhau. Google chắc nhiều về cái này

— Reply to this email directly or view it on GitHub https://github.com/fyhertz/libstreaming/issues/111#issuecomment-114350596 .

ghost commented 9 years ago

did you ever find a solution in libstreaming?

hoang89yenthe commented 9 years ago

Yes, i found a solution :)

ghost commented 9 years ago

@hoang89yenthe Great. Explain it with codes, please.

hoang89yenthe commented 9 years ago

In my case, i used everyplay lib to record media data as mp4 file, you can google it. I dont use libstreaming lib.

hoang89yenthe commented 8 years ago

Hi fyhertz/libstreaming,

I'd like to add you to my professional network on LinkedIn.

Confirm that you know Dang: https://www.linkedin.com/e/v2?e=0-ipshr7vy-j&t=ssuw&tracking=eml-guest-invite-cta&ek=invite_guest&sharedKey=Jy2etd9n&invitationId=6151774639099043840

You received an invitation to connect. LinkedIn will use your email address to make suggestions to our members in features like People You May Know. Unsubscribe here: https://www.linkedin.com/e/v2?e=0-ipshr7vy-j&t=lun&midToken=AQFmrFVhGEd36Q&ek=invite_guest&loid=AQEU9Rltg_ErpgAAAVV9-iX6PGJX9ACWDcSaGH2nd4NVM2iEiYvoRCQ0hhDuVFQioFfG1OT4l3WAd3AmU0XQl7sLGk1N-eMc5rHPuU83YWANL8GZUBf7WlF8-dTDSfhEoccu2AjXjvlIM6nR4vKRn-kOomFdie5BfIam6W6zWo8DZmBHNsl9adQbWouiWG1Irelf&eid=0-ipshr7vy-j

This email was sent to reply@reply.github.com.

If you need assistance or have questions, please contact LinkedIn Customer Service: https://www.linkedin.com/e/v2?e=0-ipshr7vy-j&a=customerServiceUrl&ek=invite_guest

© 2016 LinkedIn Corporation, 2029 Stierlin Court, Mountain View CA 94043. LinkedIn and the LinkedIn logo are registered trademarks of LinkedIn.

hoang89yenthe commented 8 years ago

Hi fyhertz/libstreaming,

I'd like to add you to my professional network on LinkedIn.

Confirm that you know Dang: https://www.linkedin.com/e/v2?e=0-ipshr9ak-ya&t=ssuw&tracking=eml-guest-invite-cta&ek=invite_guest&sharedKey=O-eFkzgs&invitationId=6151774638717362177

You received an invitation to connect. LinkedIn will use your email address to make suggestions to our members in features like People You May Know. Unsubscribe here: https://www.linkedin.com/e/v2?e=0-ipshr9ak-ya&t=lun&midToken=AQFmrFVhGEd36Q&ek=invite_guest&loid=AQEjKynVb1Mu4wAAAVV9-hyRdv_SOFUW6MPOTZiAr8y_h1WLxQnlqyMsnrThfujyvOTPqliFOxQcCKwldfub6vcDBvkJGc4maOdmewZnnDRG0wa36IPgr36CvNHOiESrFc8qMGwUHl8e6tPCJ4bRM2VMxZ8YyO9BQ510cYIU3pxgYSede_dtapVRdAj2a_l6YjwE&eid=0-ipshr9ak-ya

This email was sent to reply@reply.github.com.

If you need assistance or have questions, please contact LinkedIn Customer Service: https://www.linkedin.com/e/v2?e=0-ipshr9ak-ya&a=customerServiceUrl&ek=invite_guest

© 2016 LinkedIn Corporation, 2029 Stierlin Court, Mountain View CA 94043. LinkedIn and the LinkedIn logo are registered trademarks of LinkedIn.

hoang89yenthe commented 8 years ago

Dang Hoang would like to connect on LinkedIn. How would you like to respond?

Accept: https://www.linkedin.com/e/v2?e=-8ph0yd-iq1bzde3-pe&t=ssuw&ek=first_guest_reminder_01&li=14&m=hero&ts=accept_text&sharedKey=O-eFkzgs&invitationId=6151774638717362177

View Dang Hoang's profile: https://www.linkedin.com/e/v2?e=-8ph0yd-iq1bzde3-pe&t=ssuw&ek=first_guest_reminder_01&li=3&m=hero&ts=profile_text&sharedKey=O-eFkzgs&invitationId=6151774638717362177

You received an invitation to connect. LinkedIn will use your email address to make suggestions to our members in features like People You May Know. Unsubscribe here: https://www.linkedin.com/e/v2?e=-8ph0yd-iq1bzde3-pe&t=lun&midToken=AQFmrFVhGEd36Q&ek=first_guest_reminder_01&li=16&m=unsub&ts=HTML&eid=-8ph0yd-iq1bzde3-pe&loid=AQGIJxZC3LjUwwAAAVWeZNEpRjvmNy2hDzUC0a4iq0HcPyNW77aFP4wwwFx_tsVzX3W8ipXA0-otAsUyHbAJZy0xPsMqVvcm9ZrNl0eSjsnHDmNJ_yJDPz8XIuoIlTH5Ffln0tiqibeTRKs0G_3KFLWvNQMIbzdL9Oe-HyhypXWOmlvh_yBocZSBQwpq7-8C_ITL

This email was sent to reply@reply.github.com.

If you need assistance or have questions, please contact LinkedIn Customer Service: https://www.linkedin.com/e/v2?e=-8ph0yd-iq1bzde3-pe&a=customerServiceUrl&ek=first_guest_reminder_01

© 2016 LinkedIn Corporation, 2029 Stierlin Court, Mountain View CA 94043. LinkedIn and the LinkedIn logo are registered trademarks of LinkedIn.

hoang89yenthe commented 8 years ago

Dang Hoang would like to connect on LinkedIn. How would you like to respond?

Accept: https://www.linkedin.com/e/v2?e=lgey5s-iq1bzerp-mi&t=ssuw&ek=first_guest_reminder_01&li=14&m=hero&ts=accept_text&sharedKey=Jy2etd9n&invitationId=6151774639099043840

View Dang Hoang's profile: https://www.linkedin.com/e/v2?e=lgey5s-iq1bzerp-mi&t=ssuw&ek=first_guest_reminder_01&li=3&m=hero&ts=profile_text&sharedKey=Jy2etd9n&invitationId=6151774639099043840

You received an invitation to connect. LinkedIn will use your email address to make suggestions to our members in features like People You May Know. Unsubscribe here: https://www.linkedin.com/e/v2?e=lgey5s-iq1bzerp-mi&t=lun&midToken=AQFmrFVhGEd36Q&ek=first_guest_reminder_01&li=16&m=unsub&ts=HTML&eid=lgey5s-iq1bzerp-mi&loid=AQFW5qrVld5HlAAAAVWeZyNNqgoXRsO7h83jSGoXcBAYGJdntcRMo3_ZCSHBY5vK-2uJUpcOcS7zHHve92Ikw25b0PH9SAL8ABVtPip8MXzPMxgvTFRjt91QX_jQMLap6nZcWhea7iQM50DzOjyAFTFfMeZVoI__f1UV6I9xWNmmVfBKxSdVOTieJdDpx3gUKK-I

This email was sent to reply@reply.github.com.

If you need assistance or have questions, please contact LinkedIn Customer Service: https://www.linkedin.com/e/v2?e=lgey5s-iq1bzerp-mi&a=customerServiceUrl&ek=first_guest_reminder_01

© 2016 LinkedIn Corporation, 2029 Stierlin Court, Mountain View CA 94043. LinkedIn and the LinkedIn logo are registered trademarks of LinkedIn.

hoang89yenthe commented 8 years ago

Dang Hoang would like to connect on LinkedIn. How would you like to respond?

Accept: https://www.linkedin.com/e/v2?e=lgey5s-iqbktraj-eo&t=ssuw&ek=second_guest_reminder_01&li=13&m=hero&ts=accept_text&sharedKey=Jy2etd9n&invitationId=6151774639099043840

View Dang Hoang's profile: https://www.linkedin.com/e/v2?e=lgey5s-iqbktraj-eo&t=ssuw&ek=second_guest_reminder_01&li=3&m=hero&ts=profile_text&sharedKey=Jy2etd9n&invitationId=6151774639099043840

You received an invitation to connect. LinkedIn will use your email address to make suggestions to our members in features like People You May Know. Unsubscribe here: https://www.linkedin.com/e/v2?e=lgey5s-iqbktraj-eo&t=lun&midToken=AQFmrFVhGEd36Q&ek=second_guest_reminder_01&li=15&m=unsub&ts=HTML&eid=lgey5s-iqbktraj-eo&loid=AQGHWcmNAKdOvwAAAVXDuywOYh71WgwcKbYfNGvwCgR3umIVB4QYTvBLs1cfdbQcTVpEWt5WclyHpWEnh2UjbfrQHWSAQSfekW4e2NlTL_IPBiOglnVx3Mff12hYOZQhM8fWrf11WlI5LtXQ9Vlj1Bnz0dCiw0sdKJ0Wn9HBO1MhiPU7a53NRhXA9UORWrk6oMaG

This email was sent to reply@reply.github.com.

If you need assistance or have questions, please contact LinkedIn Customer Service: https://www.linkedin.com/e/v2?e=lgey5s-iqbktraj-eo&a=customerServiceUrl&ek=second_guest_reminder_01

© 2016 LinkedIn Corporation, 2029 Stierlin Court, Mountain View CA 94043. LinkedIn and the LinkedIn logo are registered trademarks of LinkedIn.

hoang89yenthe commented 8 years ago

Dang Hoang would like to connect on LinkedIn. How would you like to respond?

Accept: https://www.linkedin.com/e/v2?e=-8ph0yd-iqbktqvc-vq&t=ssuw&ek=second_guest_reminder_01&li=13&m=hero&ts=accept_text&sharedKey=O-eFkzgs&invitationId=6151774638717362177

View Dang Hoang's profile: https://www.linkedin.com/e/v2?e=-8ph0yd-iqbktqvc-vq&t=ssuw&ek=second_guest_reminder_01&li=3&m=hero&ts=profile_text&sharedKey=O-eFkzgs&invitationId=6151774638717362177

You received an invitation to connect. LinkedIn will use your email address to make suggestions to our members in features like People You May Know. Unsubscribe here: https://www.linkedin.com/e/v2?e=-8ph0yd-iqbktqvc-vq&t=lun&midToken=AQFmrFVhGEd36Q&ek=second_guest_reminder_01&li=15&m=unsub&ts=HTML&eid=-8ph0yd-iqbktqvc-vq&loid=AQG13x8nPgNEwAAAAVXDvVFZ4LMnYZgyqLkEZwbEOSbMucObXHoZ54cbyaSr38m93i24kQBLQw3jqZ_f68Uze4mWsgCWIzJ4rn-6M3hfROB4Ki621gJrSD3zTC3lK8wSRDdwkLLfnnUw5IGgksaVo0g5429RCuCDSm-mU1c0R-lTQl8MM0yzba_wTYfVa2JCKd2y

This email was sent to reply@reply.github.com.

If you need assistance or have questions, please contact LinkedIn Customer Service: https://www.linkedin.com/e/v2?e=-8ph0yd-iqbktqvc-vq&a=customerServiceUrl&ek=second_guest_reminder_01

© 2016 LinkedIn Corporation, 2029 Stierlin Court, Mountain View CA 94043. LinkedIn and the LinkedIn logo are registered trademarks of LinkedIn.