@@ -407,7 +407,7 @@ def with_swing(*args, &blk)
407
407
examples : [ "
408
408
live_loop :foo do
409
409
with_swing 0.1 do
410
- sample :elec_beep # plays the :elec_beep sample late except for every 4th time
410
+ sample :elec_beep # plays the :elec_beep sample late except on the 1st beat of every 4
411
411
end
412
412
sleep 0.25
413
413
end
@@ -416,15 +416,15 @@ def with_swing(*args, &blk)
416
416
live_loop :foo do
417
417
with_swing -0.1 do
418
418
sample :elec_beep # plays the :elec_beep sample slightly early
419
- end # except for every 4th time
419
+ end # on the 1st beat of every 4
420
420
sleep 0.25
421
421
end
422
422
" ,
423
423
"
424
424
live_loop :foo do
425
425
with_swing -0.1, pulse: 8 do
426
426
sample :elec_beep # plays the :elec_beep sample slightly early
427
- end # except for every 8th time
427
+ end # on the 1st beat of every 8
428
428
sleep 0.25
429
429
end
430
430
" ,
@@ -434,11 +434,11 @@ def with_swing(*args, &blk)
434
434
live_loop :foo do
435
435
with_swing 0.14, tick: :a do
436
436
sample :elec_beep # plays the :elec_beep sample slightly late
437
- end # except for every 4th time
437
+ end # on the 1st beat of every 4
438
438
439
439
with_swing -0.1, tick: :b do
440
440
sample :elec_beep, rate: 2 # plays the :elec_beep sample at double rate
441
- end # slightly early except for every 4th time
441
+ end # slightly early except on the 1st beat of every 4
442
442
sleep 0.25
443
443
end" ,
444
444
"
@@ -455,7 +455,24 @@ def with_swing(*args, &blk)
455
455
# another live loop (sync will match the timing and clock of
456
456
# the sending live loop)
457
457
end
458
- " ]
458
+ " ,
459
+ "
460
+ live_loop :foo do
461
+ with_swing 0.1, offset: 2 do
462
+ sample :elec_beep # plays the :elec_beep sample slightly late
463
+ end # on the the 3rd beat of every 4
464
+ sleep 0.25
465
+ end
466
+ " ,
467
+ "
468
+ live_loop :foo do
469
+ with_swing 0.1, pulse: 2, offset: 1 do
470
+ sample :elec_beep # plays the :elec_beep sample slightly late
471
+ end # on the 2nd beat of every 2
472
+ sleep 0.25
473
+ end
474
+ "
475
+ ]
459
476
460
477
461
478
0 commit comments