Support sound recording of MP4A streams
This commit is contained in:
parent
f24594a8f7
commit
2790f61836
3 changed files with 6 additions and 1 deletions
|
@ -215,6 +215,7 @@ mk_build_tracks(mk_mux_t *mkm, const struct streaming_start *ss)
|
|||
codec_id = "A_EAC3";
|
||||
break;
|
||||
|
||||
case SCT_MP4A:
|
||||
case SCT_AAC:
|
||||
tracktype = 2;
|
||||
codec_id = "A_AAC";
|
||||
|
@ -252,6 +253,7 @@ mk_build_tracks(mk_mux_t *mkm, const struct streaming_start *ss)
|
|||
switch(ssc->ssc_type) {
|
||||
case SCT_H264:
|
||||
case SCT_MPEG2VIDEO:
|
||||
case SCT_MP4A:
|
||||
case SCT_AAC:
|
||||
if(ssc->ssc_gh)
|
||||
ebml_append_bin(t, 0x63a2,
|
||||
|
@ -723,7 +725,7 @@ mk_write_frame_i(mk_mux_t *mkm, mk_track *t, th_pkt_t *pkt)
|
|||
data = pktbuf_ptr(pkt->pkt_payload);
|
||||
len = pktbuf_len(pkt->pkt_payload);
|
||||
|
||||
if(t->type == SCT_AAC) {
|
||||
if(t->type == SCT_AAC || t->type == SCT_MP4A) {
|
||||
// Skip ADTS header
|
||||
if(len < 7)
|
||||
return;
|
||||
|
|
|
@ -78,6 +78,7 @@ apply_header(streaming_start_component_t *ssc, th_pkt_t *pkt)
|
|||
return;
|
||||
|
||||
switch(ssc->ssc_type) {
|
||||
case SCT_MP4A:
|
||||
case SCT_AAC:
|
||||
ssc->ssc_gh = pktbuf_alloc(NULL, 2);
|
||||
d = pktbuf_ptr(ssc->ssc_gh);
|
||||
|
@ -121,6 +122,7 @@ header_complete(streaming_start_component_t *ssc, int not_so_picky)
|
|||
if(ssc->ssc_gh == NULL &&
|
||||
(ssc->ssc_type == SCT_H264 ||
|
||||
ssc->ssc_type == SCT_MPEG2VIDEO ||
|
||||
ssc->ssc_type == SCT_MP4A ||
|
||||
ssc->ssc_type == SCT_AAC))
|
||||
return 0;
|
||||
return 1;
|
||||
|
|
|
@ -1189,6 +1189,7 @@ extjs_servicedetails(http_connection_t *hc,
|
|||
break;
|
||||
|
||||
case SCT_AC3:
|
||||
case SCT_MP4A:
|
||||
case SCT_AAC:
|
||||
case SCT_MPEG2AUDIO:
|
||||
htsmsg_add_str(c, "details", st->es_lang);
|
||||
|
|
Loading…
Add table
Reference in a new issue