static File clipWAVFromMarkers(File srcWAV, L markers, File destWAV) { Clip clip = spectro_clipFromFile(srcWAV); L intMarkers = sorted(allToInt(markers)); // odd number of markers => clip to end if (oddLength(intMarkers)) intMarkers.add(clip.getFrameCount()*clip.getFrameTimeSamples()); L parts = intsToIntRanges(intMarkers); if (empty(parts)) deleteFile(destWAV); else spectro_intRangesToWAV(clip, parts, destWAV); ret destWAV; }