Changeset 739 for trunk/libffado/src/bebob/bebob_avdevice.cpp
- Timestamp:
- 11/28/07 12:02:08 (16 years ago)
- Files:
-
- trunk/libffado/src/bebob/bebob_avdevice.cpp (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/libffado/src/bebob/bebob_avdevice.cpp
r728 r739 55 55 namespace BeBoB { 56 56 57 AvDevice::AvDevice( Ieee1394Service& ieee1394service, 58 std::auto_ptr< ConfigRom >( configRom ) ) 59 : GenericAVC::AvDevice( ieee1394service, configRom ) 57 AvDevice::AvDevice(std::auto_ptr< ConfigRom >( configRom ) ) 58 : GenericAVC::AvDevice( configRom ) 60 59 , m_Mixer ( 0 ) 61 60 { … … 91 90 92 91 FFADODevice * 93 AvDevice::createDevice( Ieee1394Service& ieee1394Service, 94 std::auto_ptr<ConfigRom>( configRom )) 92 AvDevice::createDevice(std::auto_ptr<ConfigRom>( configRom )) 95 93 { 96 94 unsigned int vendorId = configRom->getNodeVendorId(); … … 99 97 switch (vendorId) { 100 98 case FW_VENDORID_TERRATEC: 101 return new Terratec::PhaseSeriesDevice( ieee1394Service,configRom);99 return new Terratec::PhaseSeriesDevice(configRom); 102 100 case FW_VENDORID_FOCUSRITE: 103 101 switch(modelId) { 104 102 case 0x00000003: 105 103 case 0x00000006: 106 return new Focusrite::SaffireProDevice( ieee1394Service,configRom);104 return new Focusrite::SaffireProDevice(configRom); 107 105 case 0x00000000: 108 return new Focusrite::SaffireDevice( ieee1394Service,configRom);106 return new Focusrite::SaffireDevice(configRom); 109 107 default: // return a plain BeBoB device 110 return new AvDevice( ieee1394Service,configRom);108 return new AvDevice(configRom); 111 109 } 112 110 default: 113 return new AvDevice( ieee1394Service,configRom);111 return new AvDevice(configRom); 114 112 } 115 113 return NULL; … … 119 117 AvDevice::discover() 120 118 { 121 unsigned int vendorId = m_pConfigRom->getNodeVendorId();122 unsigned int modelId = m_pConfigRom->getModelId();119 unsigned int vendorId = getConfigRom().getNodeVendorId(); 120 unsigned int modelId = getConfigRom().getModelId(); 123 121 124 122 GenericAVC::VendorModel vendorModel( SHAREDIR "/ffado_driver_bebob.txt" ); … … 242 240 AvDevice::getConfigurationIdSampleRate() 243 241 { 244 ExtendedStreamFormatCmd extStreamFormatCmd( *m_p1394Service);242 ExtendedStreamFormatCmd extStreamFormatCmd( get1394Service() ); 245 243 UnitPlugAddress unitPlugAddress( UnitPlugAddress::ePT_PCR, 0 ); 246 244 extStreamFormatCmd.setPlugAddress( PlugAddress( PlugAddress::ePD_Input, … … 275 273 AvDevice::getConfigurationIdNumberOfChannel( PlugAddress::EPlugDirection ePlugDirection ) 276 274 { 277 ExtendedPlugInfoCmd extPlugInfoCmd( *m_p1394Service);275 ExtendedPlugInfoCmd extPlugInfoCmd( get1394Service() ); 278 276 UnitPlugAddress unitPlugAddress( UnitPlugAddress::ePT_PCR, 279 277 getNodeId() ); … … 310 308 AvDevice::getConfigurationIdSyncMode() 311 309 { 312 SignalSourceCmd signalSourceCmd( *m_p1394Service);310 SignalSourceCmd signalSourceCmd( get1394Service() ); 313 311 SignalUnitAddress signalUnitAddr; 314 312 signalUnitAddr.m_plugId = 0x01; … … 409 407 AvDevice::loadFromCache() 410 408 { 411 Glib::ustring sDevicePath = getCachePath() + m_pConfigRom->getGuidString();409 Glib::ustring sDevicePath = getCachePath() + getConfigRom().getGuidString(); 412 410 413 411 char* configId; … … 449 447 // the path looks like this: 450 448 // PATH_TO_CACHE + GUID + CONFIGURATION_ID 451 string tmp_path = getCachePath() + m_pConfigRom->getGuidString();449 string tmp_path = getCachePath() + getConfigRom().getGuidString(); 452 450 453 451 // the following piece should do something like