Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
e751f9c4
Commit
e751f9c4
authored
Sep 13, 2008
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cosmetics.
parent
60f3b3b6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
22 deletions
+20
-22
src/video_output/vout_subpictures.c
src/video_output/vout_subpictures.c
+20
-22
No files found.
src/video_output/vout_subpictures.c
View file @
e751f9c4
...
...
@@ -1189,10 +1189,8 @@ void spu_RenderSubpictures( spu_t *p_spu, video_format_t *p_fmt,
subpicture_t
*
spu_SortSubpictures
(
spu_t
*
p_spu
,
mtime_t
display_date
,
bool
b_paused
,
bool
b_subtitle_only
)
{
int
i_
index
,
i_
channel
;
int
i_channel
;
subpicture_t
*
p_subpic
=
NULL
;
subpicture_t
*
p_ephemer
;
mtime_t
ephemer_date
;
/* Run subpicture filters */
filter_chain_SubFilter
(
p_spu
->
p_chain
,
display_date
);
...
...
@@ -1201,33 +1199,33 @@ subpicture_t *spu_SortSubpictures( spu_t *p_spu, mtime_t display_date,
* ends with NULL since p_subpic was initialized to NULL. */
for
(
i_channel
=
0
;
i_channel
<
p_spu
->
i_channel
;
i_channel
++
)
{
p_ephemer
=
0
;
ephemer_date
=
0
;
subpicture_t
*
p_ephemer
=
NULL
;
mtime_t
ephemer_date
=
0
;
int
i_index
;
for
(
i_index
=
0
;
i_index
<
VOUT_MAX_SUBPICTURES
;
i_index
++
)
{
if
(
p_spu
->
p_subpicture
[
i_index
].
i_channel
!=
i_channel
||
p_spu
->
p_subpicture
[
i_index
].
i_status
!=
READY_SUBPICTURE
||
(
b_subtitle_only
&&
!
p_spu
->
p_subpicture
[
i_index
].
b_subtitle
)
)
subpicture_t
*
p_current
=
&
p_spu
->
p_subpicture
[
i_index
];
if
(
p_current
->
i_channel
!=
i_channel
||
p_current
->
i_status
!=
READY_SUBPICTURE
||
(
b_subtitle_only
&&
!
p_current
->
b_subtitle
)
)
{
continue
;
}
if
(
display_date
&&
display_date
<
p_
spu
->
p_subpicture
[
i_index
].
i_start
)
display_date
<
p_
current
->
i_start
)
{
/* Too early, come back next monday */
continue
;
}
if
(
p_
spu
->
p_subpicture
[
i_index
].
i_start
>
ephemer_date
)
ephemer_date
=
p_
spu
->
p_subpicture
[
i_index
].
i_start
;
if
(
p_
current
->
i_start
>
ephemer_date
)
ephemer_date
=
p_
current
->
i_start
;
if
(
display_date
>
p_spu
->
p_subpicture
[
i_index
].
i_stop
&&
(
!
p_spu
->
p_subpicture
[
i_index
].
b_ephemer
||
p_spu
->
p_subpicture
[
i_index
].
i_stop
>
p_spu
->
p_subpicture
[
i_index
].
i_start
)
&&
!
(
p_spu
->
p_subpicture
[
i_index
].
b_pausable
&&
b_paused
)
)
if
(
display_date
>
p_current
->
i_stop
&&
(
!
p_current
->
b_ephemer
||
p_current
->
i_stop
>
p_current
->
i_start
)
&&
!
(
p_current
->
b_pausable
&&
b_paused
)
)
{
/* Too late, destroy the subpic */
spu_DestroySubpicture
(
p_spu
,
&
p_spu
->
p_subpicture
[
i_index
]
);
...
...
@@ -1235,16 +1233,16 @@ subpicture_t *spu_SortSubpictures( spu_t *p_spu, mtime_t display_date,
}
/* If this is an ephemer subpic, add it to our list */
if
(
p_
spu
->
p_subpicture
[
i_index
].
b_ephemer
)
if
(
p_
current
->
b_ephemer
)
{
p_
spu
->
p_subpicture
[
i_index
].
p_next
=
p_ephemer
;
p_ephemer
=
&
p_spu
->
p_subpicture
[
i_index
]
;
p_
current
->
p_next
=
p_ephemer
;
p_ephemer
=
p_current
;
continue
;
}
p_
spu
->
p_subpicture
[
i_index
].
p_next
=
p_subpic
;
p_subpic
=
&
p_spu
->
p_subpicture
[
i_index
]
;
p_
current
->
p_next
=
p_subpic
;
p_subpic
=
p_current
;
}
/* If we found ephemer subpictures, check if they have to be
...
...
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