Exemplo n.º 1
0
def _vox_filter(vox, freq, a, b, c):
    length=sf.Length(+vox)
    vox=sf.FixSize(polish(vox,freq)) 
    vox=do_formant(vox, a, b, c, freq)
    vox=polish(vox, freq)        
    vox=excite(vox, 0.2, 2.0)
    vox=polish(vox, freq)
    notch=(freq + a) / 2.0      
    vox=mix(
        sf.Pcnt75(sf.RBJNotch(+vox, notch, 0.5)),
        sf.Pcnt25(vox)
    )
    
    if length>1024:
        rate = 3.0
        depth = 0.05
        pDepth = 0.1
    else:
        rt = 2.5
        depth = 0.025
        pDepth = 0.05
    if length > 2048:
        at = length*0.75
    else:
        at = length*0.5
    vox=create_vibrato(vox, length, longer_than=512, rate=rate, depth=depth, pitch_depth=pDepth, at=at)
    
    vox=polish(vox, freq)
    vox=sf.RBJPeaking(vox, freq, 3, 4)
    vox=polish(vox, freq)
    return sf.FixSize(vox)
Exemplo n.º 2
0
def tuned_wind(length, freq):

    with SFMemoryZone():

        sigs = []
        for i in range(1, 3):
            sig = byquad_filter(
                'peak',
                byquad_filter(
                    'peak',
                    sf.Mix(clean_noise(length, freq),
                           sf.Pcnt10(sf.SineWave(length, freq))), 1.0, 64),
                freq, 0.1, 64)

            sig = byquad_filter('peak', sig, freq, 1.0, 128)

            sig = sf.FixSize(excite(sig, 1.0, 2.0))
            sig = sf.FixSize(sf.Saturate(sf.LinearVolume(sig, 2.0)))
            sig = create_vibrato(sig,
                                 length,
                                 longer_than=0.5,
                                 rate=2.5,
                                 at=0.45,
                                 depth=0.5,
                                 pitch_depth=0.02)

            sigs.append(sig)
        sig = mix(sigs)
        return sf.FixSize(polish(sig, freq)).keep()
Exemplo n.º 3
0
def _vox_filter(vox, freq, a, b, c):
    length = sf.Length(+vox)
    vox = sf.FixSize(polish(vox, freq))
    vox = do_formant(vox, a, b, c, freq)
    vox = polish(vox, freq)
    vox = excite(vox, 0.2, 2.0)
    vox = polish(vox, freq)
    notch = (freq + a) / 2.0
    vox = mix(sf.Pcnt75(sf.RBJNotch(+vox, notch, 0.5)), sf.Pcnt25(vox))

    if length > 1024:
        vibRate = 3.0
        depth = 0.05
        pDepth = 0.1
    else:
        vibRate = 2.5
        depth = 0.025
        pDepth = 0.05
    if length > 2048:
        at = length * 0.75
    else:
        at = length * 0.5
    vox = create_vibrato(vox,
                         length,
                         longer_than=512,
                         rate=vibRate,
                         depth=depth,
                         pitch_depth=pDepth,
                         at=at)

    vox = polish(vox, freq)
    vox = sf.RBJPeaking(vox, freq, 3, 4)
    vox = polish(vox, freq)
    return sf.FixSize(vox)
Exemplo n.º 4
0
def tuned_wind(length,freq):

    sigs=[]
    for i in range(1,3):
        sig=byquad_filter(
            'peak',
            byquad_filter(
                'peak',
                sf.Mix(
                    clean_noise(length,freq),
                    sf.Pcnt10(sf.SineWave(length,freq))
                ),
                1.0,
                64
            ),
            freq,
            0.1,
            64
        )
        
        sig=byquad_filter(
            'peak',
            sig,
            freq,
            1.0,
            128
        )
    
        sig=sf.FixSize(excite(sig,1.0,2.0))
        sig=sf.FixSize(sf.Saturate(sf.NumericVolume(sig,2.0)))
        sig=create_vibrato(
            sig,length,
            longer_than=0.5,
            rate=2.5,
            at=0.45,
            depth=0.5,
            pitch_depth=0.02
        )
        
        sigs.append(sig)
    sig=mix(sigs)
    return sf.FixSize(polish(sig,freq))
Exemplo n.º 5
0
def vox_humana_inner(length,freq,a,b,c,z1=1.0,z2=1.25):
    vox=mix(
        sf.Pcnt75(sing_base(length,freq,z1)),
        sf.Pcnt25(sing_base(length,freq*2.0,z1))
    )
    length=sf.Length(+vox)
    vox=sf.FixSize(polish(vox,freq)) 
    if length>1024:
        rt=3.0
        dp=0.2
        pdp=0.1
    else:
        rt=4.5
        dp=0.1
        pdp=0.05
    if length>2048:
        a=length*0.75
    else:
        a=length*0.5
    vox=create_vibrato(vox,length,longer_than=512,rate=rt,depth=dp,pitch_depth=pdp,at=a)
    vox=do_formant(vox,a,b,c,freq)
    vox=polish(vox,freq)        
    vox=excite(vox,0.2,2.0)
    vox=polish(vox,freq)
    notch=(freq+a)/2.0      
    vox=mix(
        sf.Pcnt75(sf.RBJNotch(+vox,notch,0.5)),
        sf.Pcnt25(vox)
    )

    vox=mix(
        sf.Multiply(
            sf.FixSize(sf.Power(clean_noise(length,freq*0.5),1.5)),
            sf.ExponentialShape((0,-60),(64,-35),(128,-40),(length,-60))
        ),
        vox
    )
    
    vox=polish(vox,freq)
    vox=sf.RBJPeaking(vox,freq,3,4)
    vox=polish(vox,freq)
    return sf.FixSize(vox)
Exemplo n.º 6
0
def vox_humana_inner(length, freq, a, b, c, z1=1.0, z2=1.25):
    vox = mix(sf.Pcnt75(sing_base(length, freq, z1)),
              sf.Pcnt25(sing_base(length, freq * 2.0, z1)))
    length = sf.Length(+vox)
    vox = sf.FixSize(polish(vox, freq))
    if length > 1024:
        rt = 3.0
        dp = 0.2
        pdp = 0.1
    else:
        rt = 4.5
        dp = 0.1
        pdp = 0.05
    if length > 2048:
        a = length * 0.75
    else:
        a = length * 0.5
    vox = create_vibrato(vox,
                         length,
                         longer_than=512,
                         rate=rt,
                         depth=dp,
                         pitch_depth=pdp,
                         at=a)
    vox = do_formant(vox, a, b, c, freq)
    vox = polish(vox, freq)
    vox = excite(vox, 0.2, 2.0)
    vox = polish(vox, freq)
    notch = (freq + a) / 2.0
    vox = mix(sf.Pcnt75(sf.RBJNotch(+vox, notch, 0.5)), sf.Pcnt25(vox))

    vox = mix(
        sf.Multiply(
            sf.FixSize(sf.Power(clean_noise(length, freq * 0.5), 1.5)),
            sf.ExponentialShape((0, -60), (64, -35), (128, -40),
                                (length, -60))), vox)

    vox = polish(vox, freq)
    vox = sf.RBJPeaking(vox, freq, 3, 4)
    vox = polish(vox, freq)
    return sf.FixSize(vox)