Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
04f177a9
Commit
04f177a9
authored
Jun 29, 2005
by
Gildas Bazin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/mux/mp4.c: added support for amr nb/wb and h263 in 3gp.
parent
5ff8a38b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
61 additions
and
0 deletions
+61
-0
modules/mux/mp4.c
modules/mux/mp4.c
+61
-0
No files found.
modules/mux/mp4.c
View file @
04f177a9
...
...
@@ -413,7 +413,10 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
case
VLC_FOURCC
(
'm'
,
'j'
,
'p'
,
'b'
):
case
VLC_FOURCC
(
'S'
,
'V'
,
'Q'
,
'1'
):
case
VLC_FOURCC
(
'S'
,
'V'
,
'Q'
,
'3'
):
case
VLC_FOURCC
(
'H'
,
'2'
,
'6'
,
'3'
):
case
VLC_FOURCC
(
'h'
,
'2'
,
'6'
,
'4'
):
case
VLC_FOURCC
(
's'
,
'a'
,
'm'
,
'r'
):
case
VLC_FOURCC
(
's'
,
'a'
,
'w'
,
'b'
):
break
;
case
VLC_FOURCC
(
's'
,
'u'
,
'b'
,
't'
):
msg_Warn
(
p_mux
,
"subtitle track added like in .mov (even when creating .mp4)"
);
...
...
@@ -882,6 +885,41 @@ static bo_t *GetWaveTag( mp4_stream_t *p_stream )
return
wave
;
}
static
bo_t
*
GetDamrTag
(
mp4_stream_t
*
p_stream
)
{
bo_t
*
damr
;
damr
=
box_new
(
"damr"
);
bo_add_fourcc
(
damr
,
"REFC"
);
bo_add_8
(
damr
,
0
);
if
(
p_stream
->
fmt
.
i_codec
==
VLC_FOURCC
(
's'
,
'a'
,
'm'
,
'r'
)
)
bo_add_16be
(
damr
,
0x81ff
);
/* Mode set (all modes for AMR_NB) */
else
bo_add_16be
(
damr
,
0x83ff
);
/* Mode set (all modes for AMR_WB) */
bo_add_16be
(
damr
,
0x1
);
/* Mode change period (no restriction) */
box_fix
(
damr
);
return
damr
;
}
static
bo_t
*
GetD263Tag
(
mp4_stream_t
*
p_stream
)
{
bo_t
*
d263
;
d263
=
box_new
(
"d263"
);
bo_add_fourcc
(
d263
,
"VLC "
);
bo_add_16be
(
d263
,
0xa
);
bo_add_8
(
d263
,
0
);
box_fix
(
d263
);
return
d263
;
}
static
bo_t
*
GetAvcCTag
(
mp4_stream_t
*
p_stream
)
{
bo_t
*
avcC
;
...
...
@@ -1044,6 +1082,12 @@ static bo_t *GetSounBox( sout_mux_t *p_mux, mp4_stream_t *p_stream )
b_descr
=
VLC_TRUE
;
break
;
case
VLC_FOURCC
(
's'
,
'a'
,
'm'
,
'r'
):
case
VLC_FOURCC
(
's'
,
'a'
,
'w'
,
'b'
):
memcpy
(
fcc
,
(
char
*
)
&
p_stream
->
fmt
.
i_codec
,
4
);
b_descr
=
VLC_TRUE
;
break
;
case
VLC_FOURCC
(
'm'
,
'p'
,
'g'
,
'a'
):
if
(
p_sys
->
b_mov
)
memcpy
(
fcc
,
".mp3"
,
4
);
...
...
@@ -1110,6 +1154,10 @@ static bo_t *GetSounBox( sout_mux_t *p_mux, mp4_stream_t *p_stream )
{
box
=
GetWaveTag
(
p_stream
);
}
else
if
(
p_stream
->
fmt
.
i_codec
==
VLC_FOURCC
(
's'
,
'a'
,
'm'
,
'r'
)
)
{
box
=
GetDamrTag
(
p_stream
);
}
else
{
box
=
GetESDS
(
p_stream
);
...
...
@@ -1149,6 +1197,10 @@ static bo_t *GetVideBox( sout_mux_t *p_mux, mp4_stream_t *p_stream )
memcpy
(
fcc
,
"SVQ3"
,
4
);
break
;
case
VLC_FOURCC
(
'H'
,
'2'
,
'6'
,
'3'
):
memcpy
(
fcc
,
"s263"
,
4
);
break
;
case
VLC_FOURCC
(
'h'
,
'2'
,
'6'
,
'4'
):
memcpy
(
fcc
,
"avc1"
,
4
);
break
;
...
...
@@ -1203,6 +1255,15 @@ static bo_t *GetVideBox( sout_mux_t *p_mux, mp4_stream_t *p_stream )
}
break
;
case
VLC_FOURCC
(
'H'
,
'2'
,
'6'
,
'3'
):
{
bo_t
*
d263
=
GetD263Tag
(
p_stream
);
box_fix
(
d263
);
box_gather
(
vide
,
d263
);
}
break
;
case
VLC_FOURCC
(
'S'
,
'V'
,
'Q'
,
'3'
):
{
bo_t
*
esds
=
GetSVQ3Tag
(
p_stream
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment