* ./plugins/beos/vout_beos.cpp: fixed BeOS video output.
* Collection of useful common types and macros definitions
*****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN
- * $Id: common.h,v 1.78 2002/02/24 22:06:50 sam Exp $
+ * $Id: common.h,v 1.79 2002/02/27 03:47:56 sam Exp $
*
* Authors: Samuel Hocevar <sam@via.ecp.fr>
* Vincent Seguin <seguin@via.ecp.fr>
/* PAD: PAD(n, d) = CEIL(n ,d) * d */
#define PAD(n, d) ( ((n) % (d)) ? ((((n) / (d)) + 1) * (d)) : (n) )
-/* MAX and MIN: self explanatory */
-#ifndef MAX
-# define MAX(a, b) ( ((a) > (b)) ? (a) : (b) )
+/* __MAX and __MIN: self explanatory */
+#ifndef __MAX
+# define __MAX(a, b) ( ((a) > (b)) ? (a) : (b) )
#endif
-#ifndef MIN
-# define MIN(a, b) ( ((a) < (b)) ? (a) : (b) )
+#ifndef __MIN
+# define __MIN(a, b) ( ((a) < (b)) ? (a) : (b) )
#endif
/* MSB (big endian)/LSB (little endian) conversions - network order is always
* This header provides a portable threads implementation.
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
- * $Id: threads.h,v 1.35 2002/02/25 23:59:07 sam Exp $
+ * $Id: threads.h,v 1.36 2002/02/27 03:47:56 sam Exp $
*
* Authors: Jean-Marc Dressler <polux@via.ecp.fr>
* Samuel Hocevar <sam@via.ecp.fr>
# include <cthreads.h>
#elif defined( HAVE_KERNEL_SCHEDULER_H ) /* BeOS */
-# undef MAX
-# undef MIN
# include <kernel/OS.h>
# include <kernel/scheduler.h>
# include <byteorder.h>
* vout_beos.cpp: beos video output display method
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
- * $Id: vout_beos.cpp,v 1.42 2002/02/24 20:51:09 gbazin Exp $
+ * $Id: vout_beos.cpp,v 1.43 2002/02/27 03:47:56 sam Exp $
*
* Authors: Jean-Marc Dressler <polux@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
* VOUT_ASPECT_FACTOR / p_vout->render.i_aspect;
}
- /* Open and initialize device */
- if( BeosOpenDisplay( p_vout ) )
- {
- intf_ErrMsg("vout error: can't open display");
- free( p_vout->p_sys );
- return( 1 );
- }
-
return( 0 );
}
*****************************************************************************/
int vout_Init( vout_thread_t *p_vout )
{
- VideoWindow *p_win = p_vout->p_sys->p_window;
-
int i_index;
picture_t *p_pic;
I_OUTPUTPICTURES = 0;
+ /* Open and initialize device */
+ if( BeosOpenDisplay( p_vout ) )
+ {
+ intf_ErrMsg("vout error: can't open display");
+ return 0;
+ }
+
p_vout->output.i_width = p_vout->p_sys->i_width;
p_vout->output.i_height = p_vout->p_sys->i_height;
p_vout->output.i_aspect = p_vout->p_sys->i_width
- * VOUT_ASPECT_FACTOR
- / p_vout->p_sys->i_height;
+ * VOUT_ASPECT_FACTOR / p_vout->p_sys->i_height;
p_vout->output.i_chroma = FOURCC_RV32;
p_pic = NULL;
*****************************************************************************/
void vout_End( vout_thread_t *p_vout )
{
- /* place code here to end the video */
+ BeosCloseDisplay( p_vout );
}
/*****************************************************************************
*****************************************************************************/
void vout_Destroy( vout_thread_t *p_vout )
{
- BeosCloseDisplay( p_vout );
free( p_vout->p_sys );
}
*****************************************************************************/
int vout_Manage( vout_thread_t *p_vout )
{
- VideoWindow * p_win = p_vout->p_sys->p_window;
+// VideoWindow * p_win = p_vout->p_sys->p_window;
// p_win->resizeIfRequired(p_vout->p_sys->pp_buffer[p_vout->p_sys->i_index].i_pic_width,
// p_vout->p_sys->pp_buffer[p_vout->p_sys->i_index].i_pic_height);
*****************************************************************************/
static int BeosOpenDisplay( vout_thread_t *p_vout )
{
- p_vout->p_sys->p_window = new VideoWindow(
- config_GetIntVariable( VOUT_WIDTH_VAR ) - 1,
- config_GetIntVariable( VOUT_HEIGHT_VAR ) - 1,
- p_vout );
+ p_vout->p_sys->p_window = new VideoWindow( p_vout->p_sys->i_width - 1,
+ p_vout->p_sys->i_height - 1,
+ p_vout );
if( p_vout->p_sys->p_window == NULL )
{
* dummy.c : dummy plugin for vlc
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
- * $Id: dummy.c,v 1.15 2002/02/24 20:51:09 gbazin Exp $
+ * $Id: dummy.c,v 1.16 2002/02/27 03:47:56 sam Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
SET_DESCRIPTION( "dummy functions module" )
/* Capability score set to 0 because we don't want to be spawned
* unless explicitly requested to */
- ADD_CAPABILITY( AOUT, 0 )
- ADD_CAPABILITY( VOUT, 0 )
- ADD_CAPABILITY( INTF, 0 )
+ ADD_CAPABILITY( AOUT, 1 )
+ ADD_CAPABILITY( VOUT, 1 )
+ ADD_CAPABILITY( INTF, 1 )
/* This one is ok. */
ADD_CAPABILITY( INPUT, 100 )
ADD_SHORTCUT( "dummy" )
* -dvd_udf to find files
*****************************************************************************
* Copyright (C) 1998-2001 VideoLAN
- * $Id: input_dvd.c,v 1.121 2002/02/24 20:51:09 gbazin Exp $
+ * $Id: input_dvd.c,v 1.122 2002/02/27 03:47:56 sam Exp $
*
* Author: Stéphane Borel <stef@via.ecp.fr>
*
* can be very wide out of such zones */
if( title.p_cell_play[p_dvd->i_prg_cell].i_category & 0xf000 )
{
- p_dvd->i_sector = MAX(
+ p_dvd->i_sector = __MAX(
cell.i_start_sector,
title.p_cell_play[p_dvd->i_prg_cell].i_start_sector );
}
- p_dvd->i_end_sector = MIN(
+ p_dvd->i_end_sector = __MIN(
cell.i_end_sector,
title.p_cell_play[p_dvd->i_prg_cell].i_end_sector );
#undef cell
/* Find start and end sectors of new cell */
#if 1
- p_dvd->i_sector = MAX(
+ p_dvd->i_sector = __MAX(
p_dvd->p_ifo->vts.cell_inf.p_cell_map[p_dvd->i_cell].i_start_sector,
title.p_cell_play[p_dvd->i_prg_cell].i_start_sector );
- p_dvd->i_end_sector = MIN(
+ p_dvd->i_end_sector = __MIN(
p_dvd->p_ifo->vts.cell_inf.p_cell_map[p_dvd->i_cell].i_end_sector,
title.p_cell_play[p_dvd->i_prg_cell].i_end_sector );
#else
* wall.c : Wall video plugin for vlc
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
- * $Id: wall.c,v 1.13 2002/02/24 20:51:09 gbazin Exp $
+ * $Id: wall.c,v 1.14 2002/02/27 03:47:56 sam Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
psz_method = NULL;
}
- p_vout->p_sys->i_col = MAX( 1, MIN( 15, p_vout->p_sys->i_col ) );
- p_vout->p_sys->i_row = MAX( 1, MIN( 15, p_vout->p_sys->i_row ) );
+ p_vout->p_sys->i_col = __MAX( 1, __MIN( 15, p_vout->p_sys->i_col ) );
+ p_vout->p_sys->i_row = __MAX( 1, __MIN( 15, p_vout->p_sys->i_row ) );
intf_WarnMsg( 3, "filter info: opening a %i x %i wall",
p_vout->p_sys->i_col, p_vout->p_sys->i_row );
* and spawn threads.
*****************************************************************************
* Copyright (C) 1998-2001 VideoLAN
- * $Id: main.c,v 1.156 2002/02/26 18:25:40 gbazin Exp $
+ * $Id: main.c,v 1.157 2002/02/27 03:47:56 sam Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
p_main->i_warning_level = 0;
-
#if defined( ENABLE_NLS ) && defined ( HAVE_GETTEXT )
/*
* Support for getext
intf_WarnMsg( 2, "module: module bank initialized, found %i modules",
p_module_bank->i_count );
-
/* Check for help on plugins */
if( (p_tmp = config_GetPszVariable( "pluginhelp" )) )
{
{
/* A long option has been recognized */
- module_config_t *p_config;
+ module_config_t *p_conf;
/* Store the configuration option */
- p_config = config_FindConfig( p_longopts[i_index].name );
+ p_conf = config_FindConfig( p_longopts[i_index].name );
- switch( p_config->i_type )
+ switch( p_conf->i_type )
{
case MODULE_CONFIG_ITEM_STRING:
case MODULE_CONFIG_ITEM_FILE:
* vout_pictures.c : picture management functions
*****************************************************************************
* Copyright (C) 2000 VideoLAN
- * $Id: vout_pictures.c,v 1.16 2002/02/19 00:50:20 sam Exp $
+ * $Id: vout_pictures.c,v 1.17 2002/02/27 03:47:56 sam Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
}
else
{
- *pi_width = MIN( i_width, p_vout->render.i_width );
- *pi_height = MIN( i_height, p_vout->render.i_height );
+ *pi_width = __MIN( i_width, p_vout->render.i_width );
+ *pi_height = __MIN( i_height, p_vout->render.i_height );
}
if( VOUT_ASPECT_FACTOR * *pi_width / *pi_height < p_vout->render.i_aspect )