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
7ae04107
Commit
7ae04107
authored
Dec 11, 2015
by
Thomas Guillem
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
picture_pool: change picture_pool_Cancel arguments
Add a boolean to reset the cancel state to false.
parent
65d23455
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
8 deletions
+9
-8
include/vlc_picture_pool.h
include/vlc_picture_pool.h
+4
-4
src/misc/picture_pool.c
src/misc/picture_pool.c
+4
-3
src/video_output/video_output.c
src/video_output/video_output.c
+1
-1
No files found.
include/vlc_picture_pool.h
View file @
7ae04107
...
...
@@ -160,11 +160,11 @@ unsigned picture_pool_Reset( picture_pool_t * );
/**
* Cancel the picture pool.
*
* It won't return any pictures via picture_pool_Get or picture_pool_Wait
after
*
this call. This function will also unblock picture_pool_Wait. Call
* picture_pool_Reset
to reset the cancel stat
e.
* It won't return any pictures via picture_pool_Get or picture_pool_Wait
if
*
canceled is true. This function will also unblock picture_pool_Wait.
* picture_pool_Reset
will also reset the cancel state to fals
e.
*/
void
picture_pool_Cancel
(
picture_pool_t
*
);
void
picture_pool_Cancel
(
picture_pool_t
*
,
bool
canceled
);
/**
* Reserves pictures from a pool and creates a new pool with those.
...
...
src/misc/picture_pool.c
View file @
7ae04107
...
...
@@ -277,13 +277,14 @@ picture_t *picture_pool_Wait(picture_pool_t *pool)
return
clone
;
}
void
picture_pool_Cancel
(
picture_pool_t
*
pool
)
void
picture_pool_Cancel
(
picture_pool_t
*
pool
,
bool
canceled
)
{
vlc_mutex_lock
(
&
pool
->
lock
);
assert
(
pool
->
refs
>
0
);
pool
->
canceled
=
true
;
vlc_cond_broadcast
(
&
pool
->
wait
);
pool
->
canceled
=
canceled
;
if
(
canceled
)
vlc_cond_broadcast
(
&
pool
->
wait
);
vlc_mutex_unlock
(
&
pool
->
lock
);
}
...
...
src/video_output/video_output.c
View file @
7ae04107
...
...
@@ -1457,7 +1457,7 @@ static int ThreadReinit(vout_thread_t *vout,
static
void
ThreadCancel
(
vout_thread_t
*
vout
)
{
picture_pool_Cancel
(
vout
->
p
->
decoder_pool
);
picture_pool_Cancel
(
vout
->
p
->
decoder_pool
,
true
);
}
static
int
ThreadControl
(
vout_thread_t
*
vout
,
vout_control_cmd_t
cmd
)
...
...
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