Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
051cddc7
Commit
051cddc7
authored
Jul 24, 2004
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* mp4.c: really(?) fixed the tkhd invalid width (thx bond for the
report).
parent
377df083
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
8 deletions
+14
-8
modules/mux/mp4.c
modules/mux/mp4.c
+14
-8
No files found.
modules/mux/mp4.c
View file @
051cddc7
...
@@ -1554,12 +1554,18 @@ static bo_t *GetMoovBox( sout_mux_t *p_mux )
...
@@ -1554,12 +1554,18 @@ static bo_t *GetMoovBox( sout_mux_t *p_mux )
}
}
else
if
(
p_stream
->
fmt
.
i_cat
==
VIDEO_ES
)
else
if
(
p_stream
->
fmt
.
i_cat
==
VIDEO_ES
)
{
{
int
i_width
=
p_stream
->
fmt
.
video
.
i_width
;
int
i_width
=
p_stream
->
fmt
.
video
.
i_width
<<
16
;
if
(
p_stream
->
fmt
.
video
.
i_aspect
>
0
)
if
(
p_stream
->
fmt
.
video
.
i_aspect
>
0
)
{
{
i_width
=
p_stream
->
fmt
.
video
.
i_aspect
*
i_width
=
(
int64_t
)
p_stream
->
fmt
.
video
.
i_aspect
*
(
p_stream
->
fmt
.
video
.
i_height
<<
16
)
/
VOUT_ASPECT_FACTOR
;
((
int64_t
)
p_stream
->
fmt
.
video
.
i_height
<<
16
)
/
VOUT_ASPECT_FACTOR
;
}
}
fprintf
(
stderr
,
"%dx%d -> %dx%d a=%d/%d=%f
\n
"
,
p_stream
->
fmt
.
video
.
i_width
,
p_stream
->
fmt
.
video
.
i_height
,
i_width
,
p_stream
->
fmt
.
video
.
i_height
,
p_stream
->
fmt
.
video
.
i_aspect
,
VOUT_ASPECT_FACTOR
,
(
float
)
p_stream
->
fmt
.
video
.
i_aspect
/
(
float
)
VOUT_ASPECT_FACTOR
);
// width (presentation)
// width (presentation)
bo_add_32be
(
tkhd
,
i_width
);
bo_add_32be
(
tkhd
,
i_width
);
// height(presentation)
// height(presentation)
...
@@ -1567,7 +1573,7 @@ static bo_t *GetMoovBox( sout_mux_t *p_mux )
...
@@ -1567,7 +1573,7 @@ static bo_t *GetMoovBox( sout_mux_t *p_mux )
}
}
else
else
{
{
int
i_width
=
320
;
int
i_width
=
320
<<
16
;
int
i_height
=
200
;
int
i_height
=
200
;
int
i
;
int
i
;
for
(
i
=
0
;
i
<
p_sys
->
i_nb_streams
;
i
++
)
for
(
i
=
0
;
i
<
p_sys
->
i_nb_streams
;
i
++
)
...
@@ -1576,15 +1582,15 @@ static bo_t *GetMoovBox( sout_mux_t *p_mux )
...
@@ -1576,15 +1582,15 @@ static bo_t *GetMoovBox( sout_mux_t *p_mux )
if
(
tk
->
fmt
.
i_cat
==
VIDEO_ES
)
if
(
tk
->
fmt
.
i_cat
==
VIDEO_ES
)
{
{
if
(
p_stream
->
fmt
.
video
.
i_aspect
)
if
(
p_stream
->
fmt
.
video
.
i_aspect
)
i_width
=
p_stream
->
fmt
.
video
.
i_aspect
*
i_width
=
(
int64_t
)
p_stream
->
fmt
.
video
.
i_aspect
*
p_stream
->
fmt
.
video
.
i_height
/
VOUT_ASPECT_FACTOR
;
((
int64_t
)
p_stream
->
fmt
.
video
.
i_height
<<
16
)
/
VOUT_ASPECT_FACTOR
;
else
else
i_width
=
p_stream
->
fmt
.
video
.
i_width
;
i_width
=
p_stream
->
fmt
.
video
.
i_width
<<
16
;
i_height
=
p_stream
->
fmt
.
video
.
i_height
;
i_height
=
p_stream
->
fmt
.
video
.
i_height
;
break
;
break
;
}
}
}
}
bo_add_32be
(
tkhd
,
i_width
<<
16
);
// width (presentation)
bo_add_32be
(
tkhd
,
i_width
);
// width (presentation)
bo_add_32be
(
tkhd
,
i_height
<<
16
);
// height(presentation)
bo_add_32be
(
tkhd
,
i_height
<<
16
);
// height(presentation)
}
}
...
...
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