~l0rdt/mixxx/features_replaygain

« back to all changes in this revision

Viewing changes to mixxx/src/soundmanager.cpp

  • Committer: Vittorio
  • Date: 2010-10-20 15:51:58 UTC
  • mfrom: (2456.1.4 mixxx-taglib)
  • Revision ID: l0rdt@gmx.it-20101020155158-je38ncfllu04ytbf
Merged with features_taglib branch

Show diffs side-by-side

added added

removed removed

Lines of Context:
168
168
    for (PaHostApiIndex i = 0; i < Pa_GetHostApiCount(); i++)
169
169
    {
170
170
        const PaHostApiInfo *api = Pa_GetHostApiInfo(i);
171
 
        if (QString(api->name) != "skeleton implementation") apiList.push_back(api->name);
 
171
        if (api) {
 
172
            if (QString(api->name) != "skeleton implementation") apiList.push_back(api->name);
 
173
        }
172
174
    }
173
175
 
174
176
    return apiList;
285
287
    const PaDeviceInfo* deviceInfo;
286
288
    for (int i = 0; i < iNumDevices; i++)
287
289
    {
 
290
        const PaHostApiInfo * apiInfo = NULL;
288
291
        deviceInfo = Pa_GetDeviceInfo(i);
 
292
        if (!deviceInfo)
 
293
            continue;
289
294
        /* deviceInfo fields for quick reference:
290
295
            int         structVersion
291
296
            const char *        name
298
303
            PaTime      defaultHighOutputLatency
299
304
            double      defaultSampleRate
300
305
         */
301
 
        const PaHostApiInfo * apiInfo = NULL;
302
306
        apiInfo = Pa_GetHostApiInfo(deviceInfo->hostApi);
 
307
        if (!apiInfo)
 
308
            continue;
303
309
        //if (apiInfo->name == m_hostAPI)
304
310
        {
305
311
            SoundDevicePortAudio *currentDevice = new SoundDevicePortAudio(m_pConfig, this, deviceInfo, i);