[vlc-devel] [PATCH 4/4] video_output: don't pass the subpicture to internal vout_display_Display()
Steve Lhomme
robux4 at ycbcr.xyz
Fri Oct 26 11:33:13 CEST 2018
---
src/video_output/display.c | 2 +-
src/video_output/video_output.c | 4 +++-
src/video_output/vout_wrapper.h | 6 +-----
3 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/src/video_output/display.c b/src/video_output/display.c
index 17ad94ac7fa..1e215bc42c4 100644
--- a/src/video_output/display.c
+++ b/src/video_output/display.c
@@ -1087,7 +1087,7 @@ static void SplitterDisplay(vout_display_t *vd, picture_t *picture)
for (int i = 0; i < sys->count; i++) {
if (sys->picture[i])
- vout_display_Display(sys->display[i], sys->picture[i], NULL);
+ vout_display_Display(sys->display[i], sys->picture[i]);
}
}
static int SplitterControl(vout_display_t *vd, int query, va_list args)
diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index db8cc6d9ee3..cc95c4d8741 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -1233,7 +1233,9 @@ static int ThreadDisplayRenderPicture(vout_thread_t *vout, bool is_forced)
/* Display the direct buffer returned by vout_RenderPicture */
sys->displayed.date = vlc_tick_now();
- vout_display_Display(vd, todisplay, subpic);
+ vout_display_Display(vd, todisplay);
+ if (subpic)
+ subpicture_Delete(subpic);
vout_statistic_AddDisplayed(&sys->statistic, 1);
diff --git a/src/video_output/vout_wrapper.h b/src/video_output/vout_wrapper.h
index 58df546735e..89265568a22 100644
--- a/src/video_output/vout_wrapper.h
+++ b/src/video_output/vout_wrapper.h
@@ -51,15 +51,11 @@ static inline void vout_display_Prepare(vout_display_t *vd,
/**
* It display a picture.
*/
-static inline void vout_display_Display(vout_display_t *vd,
- picture_t *picture,
- subpicture_t *subpicture)
+static inline void vout_display_Display(vout_display_t *vd, picture_t *picture)
{
if (vd->display)
vd->display(vd, picture);
picture_Release(picture);
- if (subpicture)
- subpicture_Delete(subpicture);
}
/**
--
2.17.1
More information about the vlc-devel
mailing list