[vlc-devel] [PATCH 06/26] audio filters: split the call to vout_Request()
Steve Lhomme
robux4 at ycbcr.xyz
Mon Sep 23 14:21:01 CEST 2019
On 2019-09-21 9:30, Rémi Denis-Courmont wrote:
> Le perjantaina 20. syyskuuta 2019, 17.28.36 EEST Steve Lhomme a écrit :
>> ---
>> src/audio_output/filters.c | 15 ++++++++++-----
>> 1 file changed, 10 insertions(+), 5 deletions(-)
>>
>> diff --git a/src/audio_output/filters.c b/src/audio_output/filters.c
>> index dad467b44f0..d2c1a04feb9 100644
>> --- a/src/audio_output/filters.c
>> +++ b/src/audio_output/filters.c
>> @@ -38,7 +38,7 @@
>> #include <vlc_filter.h>
>> #include <libvlc.h>
>> #include "aout_internal.h"
>> -#include "../video_output/vout_internal.h" /* for vout_Request */
>> +#include "../video_output/vout_internal.h" /* for vout_RequestDisplay */
>>
>> static filter_t *CreateFilter(vlc_object_t *obj, vlc_clock_t *clock,
>> const char *type, const char *name,
>> @@ -395,11 +395,16 @@ vout_thread_t *aout_filter_GetVout(filter_t *filter,
>> const video_format_t *fmt)
>>
>> video_format_AdjustColorSpace(&adj_fmt);
>>
>> - if (vout_Request(&cfg, NULL, NULL)) {
>> - vout_Close(vout);
>> - vout = NULL;
>> + if (vout_HoldDevice(&cfg, NULL) == 0)
>
> This does not look right. If a use case does not need the surface allocator
> "decoder device", it should not need to request it.
I agree. I'll change that.
> I don't get why you change
> the vout_Request() API at all.
Because of tight link between the vout thread, the window lifecycle and
the "decoder device". It can't be done closer to the decoder than that.
>> + {
>> + if (vout_RequestDisplay(&cfg, NULL) == 0)
>> + {
>> + return vout;
>> + }
>> }
>> - return vout;
>> +
>> + vout_Close(vout);
>> + return NULL;
>> }
>>
>> static int AppendFilter(vlc_object_t *obj, const char *type, const char
>> *name,
>
>
> --
> 雷米‧德尼-库尔蒙
> http://www.remlab.net/
>
>
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
>
More information about the vlc-devel
mailing list