[vlc-commits] vout: don't inherit viewpoint
Thomas Guillem
git at videolan.org
Tue Jul 25 16:42:41 CEST 2017
vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Tue Jul 25 09:33:27 2017 +0200| [0cc1e189cd9b165e01cc34d46a5a443a3a436115] | committer: Thomas Guillem
vout: don't inherit viewpoint
And don't trigger viewpoint manually. This variable must be triggered only by
the owner of the viewpoint address (the input) in order to ensure the atomicity
of the struct.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=0cc1e189cd9b165e01cc34d46a5a443a3a436115
---
src/video_output/video_output.c | 8 +++-----
src/video_output/vout_intf.c | 3 +--
2 files changed, 4 insertions(+), 7 deletions(-)
diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index 9c2653d19c..a5cc3ce8b1 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -562,11 +562,9 @@ static void VoutGetDisplayCfg(vout_thread_t *vout, vout_display_cfg_t *cfg, cons
/* Load configuration */
cfg->is_fullscreen = var_GetBool(vout, "fullscreen")
|| var_GetBool(vout, "video-wallpaper");
- const vlc_viewpoint_t *p_viewpoint = var_GetAddress(vout, "viewpoint");
- if (p_viewpoint != NULL)
- cfg->viewpoint = *p_viewpoint;
- else
- cfg->viewpoint = vout->p->original.pose;
+
+ cfg->viewpoint = vout->p->original.pose;
+
cfg->display.title = title;
const int display_width = var_GetInteger(vout, "width");
const int display_height = var_GetInteger(vout, "height");
diff --git a/src/video_output/vout_intf.c b/src/video_output/vout_intf.c
index 459e8d8555..97abf1e2f7 100644
--- a/src/video_output/vout_intf.c
+++ b/src/video_output/vout_intf.c
@@ -301,7 +301,7 @@ void vout_IntfInit( vout_thread_t *p_vout )
var_Create( p_vout, "mouse-clicked", VLC_VAR_COORDS );
/* Viewpoint */
- var_Create( p_vout, "viewpoint", VLC_VAR_ADDRESS | VLC_VAR_DOINHERIT );
+ var_Create( p_vout, "viewpoint", VLC_VAR_ADDRESS );
var_AddCallback( p_vout, "viewpoint", ViewpointCallback, NULL );
var_Create( p_vout, "viewpoint-changeable", VLC_VAR_BOOL );
@@ -321,7 +321,6 @@ void vout_IntfReinit( vout_thread_t *p_vout )
var_TriggerCallback( p_vout, "sub-source" );
var_TriggerCallback( p_vout, "sub-filter" );
var_TriggerCallback( p_vout, "sub-margin" );
- var_TriggerCallback( p_vout, "viewpoint" );
}
/*****************************************************************************
More information about the vlc-commits
mailing list