~ubuntu-branches/debian/sid/bristol/sid

« back to all changes in this revision

Viewing changes to bristol/bristolhammond.c

  • Committer: Bazaar Package Importer
  • Author(s): Alessio Treglia
  • Date: 2011-02-15 02:54:23 UTC
  • mfrom: (13.1.6 experimental)
  • Revision ID: james.westby@ubuntu.com-20110215025423-g8hcla5gyl08mae3
Tags: 0.60.8-2
* Upload to unstable.
* Relax JACK's build-deps to let this build in sid.

Show diffs side-by-side

added added

removed removed

Lines of Context:
344
344
        {
345
345
                pbHLast += (*hpf - pbHLast) * 0.2;
346
346
                *hpf -= pbHLast;
347
 
                *hpf++ *= 2;
 
347
                *hpf++ *= 0.8;
348
348
        }
349
349
 
350
350
        audiomain->palette[(*baudio->sound[5]).index]->specs->io[0].buf =
369
369
 
370
370
/*
371
371
 * Operate one hammond voice will function as the upper manual for a B3. If
372
 
 * requested there may also be a second manual active, with limited 
373
 
 * functionality regarding percussives, etc.
 
372
 * requested there may also be a second manual active, it will have limited 
 
373
 * functionality regarding percussives, etc. We should rewrite this, the voices
 
374
 * should not actually produce any sound: they should build a gaintable for the
 
375
 * harmonics that need to be tapped off the gearbox with offsets for new notes.
 
376
 * Then we call therequiem() that will generate any wheels that have non-zero
 
377
 * gain and mix them all down.
374
378
 */
375
379
int
376
380
operateOneHammondVoice(audioMain *audiomain, Baudio *baudio,
402
406
        audiomain->palette[(*baudio->sound[0]).index]->specs->io[2].buf = tmpbuf2;
403
407
 
404
408
        (*baudio->sound[0]).operate(
405
 
                (audiomain->palette)[5],
 
409
                (audiomain->palette)[B_HAMMOND],
406
410
                voice,
407
411
                (*baudio->sound[0]).param,
408
412
                voice->locals[voice->index][0]);
414
418
         */
415
419
        audiomain->palette[(*baudio->sound[1]).index]->specs->io[0].buf = tmpbuf1;
416
420
        (*baudio->sound[1]).operate(
417
 
                (audiomain->palette)[1],
 
421
                (audiomain->palette)[B_ENV],
418
422
                voice,
419
423
                (*baudio->sound[1]).param,
420
424
                voice->locals[voice->index][1]);
429
433
                = baudio->leftbuf;
430
434
 
431
435
        (*baudio->sound[2]).operate(
432
 
                (audiomain->palette)[2],
 
436
                (audiomain->palette)[B_DCA],
433
437
                voice,
434
438
                (*baudio->sound[2]).param,
435
439
                voice->locals[voice->index][2]);
448
452
                        = baudio->leftbuf;
449
453
 
450
454
        (*baudio->sound[2]).operate(
451
 
                (audiomain->palette)[2],
 
455
                (audiomain->palette)[B_DCA],
452
456
                voice,
453
457
                (*baudio->sound[2]).param,
454
458
                voice->locals[voice->index][2]);
 
459
 
455
460
        return(0);
456
461
}
457
462
 
494
499
                        = tmpbuf3;
495
500
 
496
501
                (*baudio->sound[3]).operate(
497
 
                        (audiomain->palette)[5],
 
502
                        (audiomain->palette)[B_HAMMOND],
498
503
                        voice,
499
504
                        (*baudio->sound[3]).param,
500
505
                        voice->locals[voice->index][3]);
512
517
                        = tmpbuf3;
513
518
 
514
519
                (*baudio->sound[0]).operate(
515
 
                        (audiomain->palette)[5],
 
520
                        (audiomain->palette)[B_HAMMOND],
516
521
                        voice,
517
522
                        (*baudio->sound[0]).param,
518
523
                        voice->locals[voice->index][0]);
525
530
         */
526
531
        audiomain->palette[(*baudio->sound[1]).index]->specs->io[0].buf = tmpbuf1;
527
532
        (*baudio->sound[1]).operate(
528
 
                (audiomain->palette)[1],
 
533
                (audiomain->palette)[B_ENV],
529
534
                voice,
530
535
                (*baudio->sound[1]).param,
531
536
                voice->locals[voice->index][1]);
539
544
        audiomain->palette[(*baudio->sound[2]).index]->specs->io[2].buf = tmpbuf4;
540
545
 
541
546
        (*baudio->sound[2]).operate(
542
 
                (audiomain->palette)[2],
 
547
                (audiomain->palette)[B_DCA],
543
548
                voice,
544
549
                (*baudio->sound[2]).param,
545
550
                voice->locals[voice->index][2]);
670
675
        /*
671
676
         * Hammond oscillator
672
677
         */
673
 
        initSoundAlgo(5, 0, baudio, audiomain, baudio->sound);
 
678
        initSoundAlgo(B_HAMMOND, 0, baudio, audiomain, baudio->sound);
674
679
        /*
675
680
         * Envelope for note_on conditioning.
676
681
         */
677
 
        initSoundAlgo(1, 1, baudio, audiomain, baudio->sound);
 
682
        initSoundAlgo(B_ENV, 1, baudio, audiomain, baudio->sound);
678
683
        /*
679
684
         * this envelope needs an amp.
680
685
         */
681
 
        initSoundAlgo(2, 2, baudio, audiomain, baudio->sound);
 
686
        initSoundAlgo(B_DCA, 2, baudio, audiomain, baudio->sound);
682
687
        /*
683
688
         * Hammond oscillator
684
689
         */
685
 
        initSoundAlgo(5, 3, baudio, audiomain, baudio->sound);
 
690
        initSoundAlgo(B_HAMMOND, 3, baudio, audiomain, baudio->sound);
686
691
 
687
692
        baudio->param = hammondGlobalController;
688
693
        baudio->destroy = destroyOneHammondB3Voice;