Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
71b72d07
Commit
71b72d07
authored
Nov 30, 2006
by
Derk-Jan Hartman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* microDVD should use the framerate of the movie if that is known, before falling back to 25fps
parent
f585ed64
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
modules/demux/subtitle.c
modules/demux/subtitle.c
+6
-2
No files found.
modules/demux/subtitle.c
View file @
71b72d07
...
...
@@ -201,6 +201,7 @@ static int Open ( vlc_object_t *p_this )
if
(
f_fps
>=
1
.
0
)
{
p_sys
->
i_microsecperframe
=
(
int64_t
)(
(
float
)
1000000
/
f_fps
);
msg_Dbg
(
p_demux
,
"Override subtitle fps %f"
,
f_fps
);
}
p_input
=
(
input_thread_t
*
)
vlc_object_find
(
p_demux
,
VLC_OBJECT_INPUT
,
FIND_PARENT
);
...
...
@@ -210,6 +211,7 @@ static int Open ( vlc_object_t *p_this )
if
(
f_fps
>=
1
.
0
)
p_sys
->
i_original_mspf
=
(
int64_t
)(
(
float
)
1000000
/
f_fps
);
msg_Dbg
(
p_demux
,
"Movie fps: %f"
,
f_fps
);
vlc_object_release
(
p_input
);
}
...
...
@@ -701,7 +703,8 @@ static int ParseMicroDvd( demux_t *p_demux, subtitle_t *p_subtitle )
int
i_stop
;
unsigned
int
i
;
int
i_microsecperframe
=
40000
;
/* default to 25 fps */
/* Try sub-fps value if set, movie rate if know, else 25fps (40000) */
int
i_microsecperframe
=
p_sys
->
i_original_mspf
>
0
?
p_sys
->
i_original_mspf
:
40000
;
if
(
p_sys
->
i_microsecperframe
>
0
)
i_microsecperframe
=
p_sys
->
i_microsecperframe
;
...
...
@@ -729,8 +732,9 @@ next:
if
(
i_start
==
1
&&
i_stop
==
1
)
{
/* We found a possible setting of the framerate "{1}{1}23.976" */
/* Use it unless sub-fps was set */
float
tmp
=
us_strtod
(
buffer_text
,
NULL
);
if
(
tmp
>
0
.
0
&&
!
var_GetFloat
(
p_demux
,
"sub-fps"
)
>
0
.
0
)
if
(
tmp
>
0
.
0
&&
var_GetFloat
(
p_demux
,
"sub-fps"
)
<=
0
.
0
)
p_sys
->
i_microsecperframe
=
(
int64_t
)(
(
float
)
1000000
/
tmp
);
goto
next
;
}
...
...
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