Changeset 64595f0c4ccd8b19941e294584e5391e3e08b8e1

Show
Ignore:
Timestamp:
08/20/05 11:48:31 (3 years ago)
Author:
Clément Stenac <zorglub@videolan.org>
git-committer:
Clément Stenac <zorglub@videolan.org> 1124531311 +0000
git-parent:

[48b0025af3d608513a51af4a3232734a45ebce69]

git-author:
Clément Stenac <zorglub@videolan.org> 1124531311 +0000
Message:

Fix Xosd interface (Debian #324039)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • modules/visualization/xosd.c

    rfe087a3 r64595f0  
    100100{ 
    101101    intf_thread_t *p_intf = (intf_thread_t *)p_this; 
     102    xosd *p_osd; 
    102103 
    103104    /* Allocate instance and initialize some members */ 
     
    116117 
    117118    /* Initialize library */ 
    118     p_intf->p_sys->p_osd = 
    119119#if defined(HAVE_XOSD_VERSION_0) || defined(HAVE_XOSD_VERSION_1) 
     120    p_osd  = p_intf->p_sys->p_osd = 
    120121        xosd_init( config_GetPsz( p_intf, "xosd-font" ), 
    121122                   config_GetPsz( p_intf,"xosd-colour" ), 3, 
    122123                   XOSD_top, 0, 1 ); 
     124    if( p_intf->p_sys->p_osd == NULL ) 
     125    { 
     126        msg_Err( p_intf, "couldn't initialize libxosd" ); 
     127        return VLC_EGENERIC; 
     128    } 
    123129#else 
    124         xosd_init( config_GetPsz( p_intf, "xosd-font" ), 
    125                    config_GetPsz( p_intf,"xosd-colour" ), 3, 
    126                     XOSD_top, 0, 0, 1 ); 
     130    p_osd = p_intf->p_sys->p_osd = xosd_create( 1 ); 
     131    if( p_osd == NULL ) 
     132    { 
     133        msg_Err( p_intf, "couldn't initialize libxosd" ); 
     134        return VLC_EGENERIC; 
     135    } 
     136    xosd_set_colour( p_osd, config_GetPsz( p_intf,"xosd-colour" ) ); 
     137    xosd_set_timeout( p_osd, 3 ); 
    127138#endif 
    128139 
    129     if( p_intf->p_sys->p_osd == NULL ) 
    130     { 
    131         msg_Err( p_intf, "couldn't initialize libxosd" ); 
    132         return VLC_EGENERIC; 
    133     } 
    134140 
    135141    playlist_t *p_playlist = 
     
    166172 
    167173    /* Initialize to NULL */ 
    168     xosd_display( p_intf->p_sys->p_osd, 
    169                   0, 
    170                   XOSD_string, 
    171                   "xosd interface initialized" ); 
     174    xosd_display( p_osd, 0, XOSD_string, "XOSD interface initialized" ); 
    172175 
    173176    p_intf->pf_run = Run;