Changeset 5107:c04d0ee02dc0 in roaraudio


Ignore:
Timestamp:
07/25/11 17:06:46 (13 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

small updates to make core a bit cleaner

File:
1 edited

Legend:

Unmodified
Added
Removed
  • roard/driver_rsound.c

    r5056 r5107  
    3030 
    3131int     driver_rsound_open         (struct roar_vio_calls * inst, char * device, struct roar_audio_info * info, int fh, struct roar_stream_server * sstream) { 
    32  rsound_t * self; 
     32 rsound_t * self = NULL; 
     33 int autoconfig  = 0; 
    3334 int tmp, tmp2; 
    3435 
    3536 if ( fh != -1 ) 
    3637  return -1; 
     38 
     39 if ( ROAR_STREAM(sstream)->id != -1 ) { 
     40  autoconfig = streams_get_flag(ROAR_STREAM(sstream)->id, ROAR_FLAG_AUTOCONF); 
     41 } 
    3742 
    3843 if ( rsd_init(&self) == -1 ) { 
     
    7580 tmp = -1; // unknown by RSound 
    7681 
    77  if ( info->bits > 16 && streams_get_flag(ROAR_STREAM(sstream)->id, ROAR_FLAG_AUTOCONF) ) { 
     82 if ( info->bits > 16 && autoconfig ) { 
    7883  info->bits = 32; 
    7984 } 
     
    129134 
    130135#ifdef RSD_S16_NE 
    131  if ( tmp == -1 && streams_get_flag(ROAR_STREAM(sstream)->id, ROAR_FLAG_AUTOCONF) ) { 
     136 if ( tmp == -1 && autoconfig ) { 
    132137  info->bits  = 16; 
    133138  info->codec = ROAR_CODEC_DEFAULT; 
Note: See TracChangeset for help on using the changeset viewer.