Commit a8d36716 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

aout: fix out-of-place viewpoint code

parent 00f4188b
......@@ -183,7 +183,4 @@ static inline void aout_SetWavePhysicalChannels(audio_sample_format_t *fmt)
/* From filters.c */
bool aout_FiltersCanResample (aout_filters_t *filters);
void aout_ChangeViewpoint(audio_output_t *aout,
const vlc_viewpoint_t *p_viewpoint);
#endif /* !LIBVLC_AOUT_INTERNAL_H */
......@@ -463,14 +463,3 @@ void aout_DecFlush (audio_output_t *aout, bool wait)
aout_OutputFlush (aout, wait);
}
}
void aout_ChangeViewpoint(audio_output_t *aout,
const vlc_viewpoint_t *p_viewpoint)
{
aout_owner_t *owner = aout_owner (aout);
vlc_mutex_lock (&owner->vp.lock);
owner->vp.value = *p_viewpoint;
atomic_store(&owner->vp.update, true);
vlc_mutex_unlock (&owner->vp.lock);
}
......@@ -195,6 +195,8 @@ static int StereoModeCallback (vlc_object_t *obj, const char *varname,
return 0;
}
static void aout_ChangeViewpoint(audio_output_t *, const vlc_viewpoint_t *);
static int ViewpointCallback (vlc_object_t *obj, const char *var,
vlc_value_t prev, vlc_value_t cur, void *data)
{
......@@ -920,3 +922,14 @@ error:
free(tabid);
return -1;
}
static void aout_ChangeViewpoint(audio_output_t *aout,
const vlc_viewpoint_t *p_viewpoint)
{
aout_owner_t *owner = aout_owner(aout);
vlc_mutex_lock(&owner->vp.lock);
owner->vp.value = *p_viewpoint;
atomic_store(&owner->vp.update, true);
vlc_mutex_unlock(&owner->vp.lock);
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment