]> git.sesse.net Git - vlc/blobdiff - modules/video_output/glide.c
doc: Suggest to use git shortlog -s to show the author of changeset of this particula...
[vlc] / modules / video_output / glide.c
index 900686c6da48de4193fd60019675f1977cacd37c..0c2b9eb1cb8c5b17c90aa1a8565c1b16d6ee5426 100644 (file)
@@ -1,8 +1,8 @@
 /*****************************************************************************
  * glide.c : 3dfx Glide plugin for vlc
  *****************************************************************************
- * Copyright (C) 2000, 2001 VideoLAN
- * $Id: glide.c,v 1.2 2003/03/30 18:14:38 gbazin Exp $
+ * Copyright (C) 2000, 2001 the VideoLAN team
+ * $Id$
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -10,7 +10,7 @@
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
 /*****************************************************************************
  * Preamble
  *****************************************************************************/
 #include <errno.h>                                                 /* ENOMEM */
-#include <stdlib.h>                                      /* malloc(), free() */
-#include <string.h>
+
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
 
 #include <vlc/vlc.h>
-#include <vlc/intf.h>
-#include <vlc/vout.h>
+#include <vlc_interface.h>
+#include <vlc_vout.h>
 
 #ifndef __linux__
 #   include <conio.h>                                         /* for glide ? */
@@ -77,7 +79,7 @@ struct vout_sys_t
 {
     GrLfbInfo_t                 p_buffer_info;           /* back buffer info */
 
-    u8* pp_buffer[2];
+    uint8_t * pp_buffer[2];
     int i_index;
 };
 
@@ -107,8 +109,8 @@ static int Create( vlc_object_t *p_this )
     }
 
     p_vout->pf_init = Init;
-    p_vout->pf_end = End;                                     
-    p_vout->pf_manage = Manage;                                 
+    p_vout->pf_end = End;
+    p_vout->pf_manage = Manage;
     p_vout->pf_render = NULL;
     p_vout->pf_display = Display;
 
@@ -153,6 +155,7 @@ static int Init( vout_thread_t *p_vout )
 
     p_pic->p->p_pixels = p_vout->p_sys->pp_buffer[p_vout->p_sys->i_index];
     p_pic->p->i_lines = GLIDE_HEIGHT;
+    p_pic->p->i_visible_lines = GLIDE_HEIGHT;
     p_pic->p->i_pitch = p_vout->p_sys->p_buffer_info.strideInBytes;
                          /*1024 * GLIDE_BYTES_PER_PIXEL*/
     p_pic->p->i_pixel_pitch = GLIDE_BYTES_PER_PIXEL;
@@ -206,7 +209,7 @@ static int Manage( vout_thread_t *p_vout )
         switch( (char)buf )
         {
         case 'q':
-            p_vout->p_vlc->b_die = 1;
+            vlc_object_kill( p_vout->p_libvlc );
             break;
 
         default:
@@ -298,7 +301,7 @@ static int OpenDisplay( vout_thread_t *p_vout )
         return( 1 );
     }
     grLfbUnlock( GR_LFB_WRITE_ONLY, GR_BUFFER_BACKBUFFER );
-    
+
     grBufferClear( 0, 0, 0 );
 
     p_vout->p_sys->pp_buffer[0] = p_vout->p_sys->p_buffer_info.lfbPtr;