es1370.c (b312532fd03413d0e6ae6767ec793a3e30f487b8) | es1370.c (85bc58520c0e43660cbbe51b9eb5022a0baafe9f) |
---|---|
1/* 2 * QEMU ES1370 emulation 3 * 4 * Copyright (c) 2005 Vassili Karpov (malc) 5 * 6 * Permission is hereby granted, free of charge, to any person obtaining a copy 7 * of this software and associated documentation files (the "Software"), to deal 8 * in the Software without restriction, including without limitation the rights --- 400 unchanged lines hidden (view full) --- 409 b->calc_freq (s, ctl, &old_freq, &new_freq); 410 411 if ((old_fmt != new_fmt) || (old_freq != new_freq)) { 412 d->shift = (new_fmt & 1) + (new_fmt >> 1); 413 ldebug ("channel %zu, freq = %d, nchannels %d, fmt %d, shift %d\n", 414 i, 415 new_freq, 416 1 << (new_fmt & 1), | 1/* 2 * QEMU ES1370 emulation 3 * 4 * Copyright (c) 2005 Vassili Karpov (malc) 5 * 6 * Permission is hereby granted, free of charge, to any person obtaining a copy 7 * of this software and associated documentation files (the "Software"), to deal 8 * in the Software without restriction, including without limitation the rights --- 400 unchanged lines hidden (view full) --- 409 b->calc_freq (s, ctl, &old_freq, &new_freq); 410 411 if ((old_fmt != new_fmt) || (old_freq != new_freq)) { 412 d->shift = (new_fmt & 1) + (new_fmt >> 1); 413 ldebug ("channel %zu, freq = %d, nchannels %d, fmt %d, shift %d\n", 414 i, 415 new_freq, 416 1 << (new_fmt & 1), |
417 (new_fmt & 2) ? AUD_FMT_S16 : AUD_FMT_U8, | 417 (new_fmt & 2) ? AUDIO_FORMAT_S16 : AUDIO_FORMAT_U8, |
418 d->shift); 419 if (new_freq) { 420 struct audsettings as; 421 422 as.freq = new_freq; 423 as.nchannels = 1 << (new_fmt & 1); | 418 d->shift); 419 if (new_freq) { 420 struct audsettings as; 421 422 as.freq = new_freq; 423 as.nchannels = 1 << (new_fmt & 1); |
424 as.fmt = (new_fmt & 2) ? AUD_FMT_S16 : AUD_FMT_U8; | 424 as.fmt = (new_fmt & 2) ? AUDIO_FORMAT_S16 : AUDIO_FORMAT_U8; |
425 as.endianness = 0; 426 427 if (i == ADC_CHANNEL) { 428 s->adc_voice = 429 AUD_open_in ( 430 &s->card, 431 s->adc_voice, 432 "es1370.adc", --- 493 unchanged lines hidden --- | 425 as.endianness = 0; 426 427 if (i == ADC_CHANNEL) { 428 s->adc_voice = 429 AUD_open_in ( 430 &s->card, 431 s->adc_voice, 432 "es1370.adc", --- 493 unchanged lines hidden --- |