>From 840999a6dcdb5ac513271a530ea75f41086421c5 Mon Sep 17 00:00:00 2001
From: Joseph Tulou <brezhoneg1@yahoo.fr>
Date: Fri, 30 Jan 2009 17:30:35 +0100
Subject: [PATCH] support sdl

---
 modules/video_output/sdl.c |   23 +++++++++++++++++++++++
 1 files changed, 23 insertions(+), 0 deletions(-)

diff --git a/modules/video_output/sdl.c b/modules/video_output/sdl.c
index 187e539..88820ba 100644
--- a/modules/video_output/sdl.c
+++ b/modules/video_output/sdl.c
@@ -577,6 +577,29 @@ static int Manage( vout_thread_t *p_vout )
         p_vout->i_changes |= VOUT_SIZE_CHANGE;
     }
 
+    /* autoscale toggle */
+    if( p_vout->i_changes & VOUT_SCALE_CHANGE )
+    {
+        p_vout->i_changes &= ~VOUT_SCALE_CHANGE;
+
+        p_vout->b_autoscale = var_GetBool( p_vout, "autoscale" );
+        p_vout->ll_zoom = (uint64_t) ZOOM_FP_FACTOR;
+
+        p_vout->i_changes |= VOUT_SIZE_CHANGE;
+    }
+
+    /* scaling factor (if no-autoscale) */
+    if( p_vout->i_changes & VOUT_ZOOM_CHANGE )
+    {
+        p_vout->i_changes &= ~VOUT_ZOOM_CHANGE;
+
+        p_vout->b_autoscale = false;
+        p_vout->ll_zoom =
+            (uint64_t)( ZOOM_FP_FACTOR * var_GetFloat( p_vout, "scale-factor" ) );
+
+        p_vout->i_changes |= VOUT_SIZE_CHANGE;
+    }
+
     /* Crop or Aspect Ratio Changes */
     if( p_vout->i_changes & VOUT_CROP_CHANGE ||
         p_vout->i_changes & VOUT_ASPECT_CHANGE )
-- 
1.5.2.5

