Sampler Playback - ping-pong
-
Well its been a while since a feature request so how about this one:
Samplers can play forwards or reverse, could we add ping-pong (i.e forward and then reverse)??
-
@Lindon You hold down a key, it plays to the end, then plays it backwards, or you press a key it plays forwards, you press same key again it plays backwards?
-
@d-healey hold down a key and it plays forwards to the end then start so play backwards...the other is fairly easy to script isnt it?
-
-
@Lindon Have also been thinking about this
(just not yet deep enough into HISE to look into this possibility or ask an informed question - still trying to compile a hello world plugin : )Would it be possible to combine two Samplers? - one populated with a reverse copy of the sample and some silent prefix, at the same length as the original sample? Could the first one with the direct version be populated with a silent suffix, so it's also double in length? - and this programmatically? If that would be possible, then both could be looped and maybe some crossfade between the intersections?
No idea if something like this is (automatically) achievable.
-
@bthj said in Sampler Playback - ping-pong:
@Lindon Have also been thinking about this
(just not yet deep enough into HISE to look into this possibility or ask an informed question - still trying to compile a hello world plugin : )Would it be possible to combine two Samplers? - one populated with a reverse copy of the sample and some silent prefix, at the same length as the original sample? Could the first one with the direct version be populated with a silent suffix, so it's also double in length? - and this programmatically? If that would be possible, then both could be looped and maybe some crossfade between the intersections?
No idea if something like this is (automatically) achievable.
wow thats a crazy screwball way to do it -- programmatically not do able but you could just sound design it that way... still an ugly number of samplers (you doubled the number required..)
Personally I prefer just asking for @Christoph-Hart to code up another playback mechanism...
-
@Lindon Nah, that is so edge-casey and I'd rather not convolute the basic streaming code with logic like this.
I would rather suggest to go down the script node route for this - you can load sample maps into a file player node and then use a ramp generator to power the playback position, from there you can go super crazy with the playing direction.
-
@Christoph-Hart said in Sampler Playback - ping-pong:
@Lindon Nah, that is so edge-casey and I'd rather not convolute the basic streaming code with logic like this.
I would rather suggest to go down the script node route for this - you can load sample maps into a file player node and then use a ramp generator to power the playback position, from there you can go super crazy with the playing direction.
ooh cool, I will investigate... thanks.
-
@Lindon You will need to set the PlaybackMode to SignalIn, then it will take the input signal as playback position and scrub through the sample. The most basic use case it to put a
core.ramp
before the node, but in your case it would rather be a really really slow triangle oscillator. -
@Christoph-Hart
That's cool. Thanks for sharing information. -
@Lindon said in Sampler Playback - ping-pong:
ooh cool, I will investigate... thanks.
Sorry for the necro-bump, did you manage to accomplish anything? Any suggestions? Did you manage to use 'core.ramp' in scriptnode for ping-pong sampler playback?
-
@Mighty23 said in Sampler Playback - ping-pong:
@Lindon said in Sampler Playback - ping-pong:
ooh cool, I will investigate... thanks.
Sorry for the necro-bump, did you manage to accomplish anything? Any suggestions? Did you manage to use 'core.ramp' in scriptnode for ping-pong sampler playback?
sadly the suggestion form Christoph was really really basic, in that it fails to accommodate the loop in a sample - so in then I gave up on it. Sorry.
-
@Mighty23 said in Sampler Playback - ping-pong:
@Lindon said in Sampler Playback - ping-pong:
ooh cool, I will investigate... thanks.
Sorry for the necro-bump, did you manage to accomplish anything? Any suggestions? Did you manage to use 'core.ramp' in scriptnode for ping-pong sampler playback?
The SignalIn mode of flle_player is really cool . Great for things like drum replacement, single cycle waveforms (this is the best, play around with math nodes between your oscillator and sampler for sync and PWM like effects) , even waveshaping., But perhaps not something you'd want to use for "normal" sample playback. As Lindon say, baked in loops don't work and it can sound pretty grainy. Here's a snippet:
HiseSnippet 1880.3oc4Y0zaaTDFd1jLNeUJskpJ3lO.RsnRv1w4KgP4SmhglDSbHhaQS1cb7nr6Lt6tNIlpJgDG4WP4D23u.bqm3HBwEj5IjPhqj+Av6rytdm0dcriUSaQrQJxy6LyNOyy79979N1UbElTOOgKxXp8Z0fhLtFtZKte80qSXbT4MPFWGuEwym5lUYZsVMHddTKjgwnOPZvXxwPAOmu7ZDaB2jFaBg1WvLoOj4v7isVYkOiYauIwhtGyQazEWorofutvVzDvyn3bnFDyiIGQ2lHG1HXzmP7piLdeLY1YspM+7KtjkYw4xuTMxBVlGN6RyQsJTbV5RTKqEl05vZ0PFYJYw7EtU8I9TOjwXqIrZUst3TtZA1m4wNzlJajGUEVYk4ME1VxsnzJZ85LaqJQDkGBYfqDSaipnsai2hYwZaOl9tQPGYimgNAZLRR3MZB3kuWvKEHYnAowTP5l3pltrF9w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IhWrL3BIWsIACvShU71vaHeN0S9hKkKe94g7vGSOUQ1pATnvRKkq3byWnvrEWbgEmK71oa5ReTSHnrUmvrXGvbbbg.nrZSegCHAF3Roi5w6MEEWfQLniSGp7Qj.I6tRoktHLTmDljf02ewpznA8LKeOOyd.r4PIFWZKu9Bg62BoDwpTWVsU6M228T34d+wx8yaXfd6YBJvsSl67kSG5ZA1Hs.0L3FTRGJgSqBQC5nawjvYzmfxwRrfwUJsGw8HpuW3M24TSUdkfLCksjImcXbGxYwrgz53X0tAcYC0GILTWkhrDbKJKKpUvziRapG+qyLiiMgZk6P85ZXHNn9Lpd5lahlSeHmQRPNIDfLRO5JNtn6HryWNsHrziUTaL0KnOgbw16IE09vJAGcifbRv0VmIr2t4o1S7xjO5R3EgwDKqd3B0S89IdMgt0UaGAc06OLoTsg4zzYX7HtJQE4rzPUmBbomHnST88O8o+zxCZ1otP0yl7q+skUxkx9dw.oWPDE.IX7uzO6.a8DRSggqVPbk2lZvgklthJ7MgnxTJgWo8zpWTMi9J61Kk1LCV1bkoDwmI1Nw61+9G94u84k+kk6Yd22.tDgM8.YtJZG4XtkJ8qd+oskS9Ftj0Hq8EPp2BxaqWabx7kuG9wU1cmOsz56cvl67vMJs6SdnPzv6C2h5SVi46s3LDVMjFSZjzaBab873NzeGaPODJziZ2tNtBP.GRLONs5tOuuUZ8pnfwtJvehfB7Ce4uIdWgvOkZzezGO0u+MO+jtpQuXwK0lJISdGY+4VR8rvByWbwBysXAsKJzc44+4m+i+0.TjYhhFR1XHtj4ZBwwNjfuSig6G+4kw2.iCwzUbPX0OxM2DAVfvOd38v2R1NadzIcJ+Iuc9AllIeUcMwBC6DmcXmXwgchyMrSb9gchKLrSbw9OQ4OrQnturRSPVqRIkpnQIN4P6vqF+uDMBX4C
Couple of the things to point out:
- Adjusting the gain going into the file player will affect the pitch
- The min/max node allows us to set start (min) and end (max) points for the loop, but again this will effect the pitch. If you're clever there might be a way to correct this by adjusting the gain, or oscillator pitch in conjunction with min/max
- Drop in a tempo sync and covert ms to freq to can clock playback rate to DAW bpm
- Set your oscillator to a saw for forward playback, invert min/max for reverse.
Also, we can track pitch to midi if we loose the start/end controls and drop in another oscillator. So here the first oscillator is controlling the "scrub" position, while the second tracks the pitch (more or less, it's a bit more convoluted than that).
HiseSnippet 1958.3oc4Ys7aaTDFeVmLNuZg1RUE8lO.nVTIX637RHTd5TLjGl3PDRbHLY2wwix5cb2ccRLUUpR8BR7WP3Bbi+EfabhafPhCH0SHgDWoW3L7M6rq2YsW+jlVdrQJxyiuc9M+9daWzlqScb31HsI2qQMJR6R3RMrbqrVEByBUXcj1Kf2h33RsSImZ0F0HNNTCjl1H2ULg1Dih7ddxRqRLIV5zvoPn84Lc5lrpL2vYKt76wLM2fXP2iUUY24VtfN2ZMtIuNfmQvoQ0H5GSNhtMQrsDXz6PbpfzdcLYlYLJO2bKrngdtYyrXYx7F5GNyhyRMxlaF5hTCi4mw3vxkQZIyavb41kbItTGj1nqxMZTpB+TK4ArOygcnIULHCpDbxxo2faZHthhYQqUgYZTLfnbPHMbwPZaDIscc7VLCVy4Couq3sPpPITIPsDQg2HQfWlNAuXfjlBjFUBoqhKoayp4Fth.OSgKXAZyxDPOoBE4dQZeKdMNrAK2oqRNltgMLno.2ZtzouSJ3e29sJW2R2kwsRws1l6R2w5V2dx6O4DS9fIS05RkKG6ZhiwlaZRsicYgogc2D7VV0qdH09NoNgXVm1biv0OJmlr+3Tc4sVYibqBVL2cpQ8G2ciBjOsAe5CJrNwkHTJ9yA6qF01kIfi15zS.WBoJZB75Tmic40.mh1zefkC2ntIwMp4jvoyeAfOhnCEJJKGlaCUmxAvFKcWsw5WHdUbQlqdk3wXhXvHvTWDXz2y7x37kKS0cCA3n3M9vg0Mr+O9oBNdomkWTUui+l9yXwMno7ll5vbn1Y5Rr0ereisVquistc8pkLYFT6hPPV3Ri0lB1GL6J0MX7MXlTuIS.SFDa3N3AwOrqgd6neXTyak8GSPujOGhC+zwG44nabjTESDfwRrp0L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