[vlc-devel] commit: Do the cropping from the extended panel. (Jean-Baptiste Kempf )

git version control git at videolan.org
Tue Apr 1 02:26:16 CEST 2008


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Mon Mar 31 17:27:05 2008 -0700| [051aedcb8d96c5f0f8b3239455743c9950cd1871]

Do the cropping from the extended panel.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=051aedcb8d96c5f0f8b3239455743c9950cd1871
---

 modules/gui/qt4/components/extended_panels.cpp |   17 ++++-------------
 1 files changed, 4 insertions(+), 13 deletions(-)

diff --git a/modules/gui/qt4/components/extended_panels.cpp b/modules/gui/qt4/components/extended_panels.cpp
index 25583c0..053bb69 100755
--- a/modules/gui/qt4/components/extended_panels.cpp
+++ b/modules/gui/qt4/components/extended_panels.cpp
@@ -222,24 +222,15 @@ ExtVideo::~ExtVideo()
 
 void ExtVideo::cropChange()
 {
-    char *psz_crop;
-    unsigned int height, width; //TODO set the variables if vout exists...
-
     p_vout = ( vout_thread_t * )vlc_object_find( p_intf,
                                 VLC_OBJECT_VOUT, FIND_CHILD );
     if( p_vout )
     {
-        height = p_vout->i_window_height;
-        width = p_vout->i_window_width;
-        sprintf( psz_crop,"%ix%i+%i+%i",
-                width - ui.cropLeftPx->value() - ui.cropRightPx->value(),
-                height - ui.cropBotPx->value() - ui.cropTopPx->value(),
-                ui.cropLeftPx->value(),
-                ui.cropTopPx->value() );
-
-        //    var_Set( p_vout, "crop-geometry", qtu( qs_crop ) );
+        var_SetInteger( p_vout, "crop-top", ui.cropTopPx->value() );
+        var_SetInteger( p_vout, "crop-bottom", ui.cropBotPx->value() );
+        var_SetInteger( p_vout, "crop-left", ui.cropLeftPx->value() );
+        var_SetInteger( p_vout, "crop-right", ui.cropRightPx->value() );
     }
-
 }
 
 void ExtVideo::ChangeVFiltersString( char *psz_name, vlc_bool_t b_add )




More information about the vlc-devel mailing list