Shuriken Beat Slicer

Discuss anything new and newsworthy! See http://planet.linuxaudio.org and https://libreav.org/news for more Linux Audio News!

Announcements of proprietary software may fit better in the Marketplace.


Moderators: raboof, MattKingUSA, khz

motosega
Established Member
Posts: 72
Joined: Wed Oct 16, 2013 5:40 pm

Re: Shuriken Beat Slicer

Post by motosega »

RockHopper wrote:Hi motosega, I've added an export option for Akai MPC1000/2500 .pgm files and was hoping you'd be brave enough to test the latest code on GitHub!
fantastic! i'm so happy you decided to implement this, when its working you should definatly post to http://www.mpc-forums.com/

i've tried the pgm export (i have the mpc 500), it Almost works!!! i can load up the program file on my mpc but the samples don't load, when i go to pgm mode and look at what samples are loaded in the mpc it shows: ?samplename (the ? means not found)
this looks to me like the sample names are somehow wrong in the pgm file. if i load the samples manualy they work fine.

do you have some known working .pgm files? i could send you some if you need.

maybe it would be best to save the pgm and samples in a new folder, compact flash cards can get pretty messy with everthing in the root.

sample names should start from 01 ,when you have more than 10 it gets confusing.

annother thing i'd reccomend is that the pgm sets the sample volume to 100,
RockHopper wrote:
motosega wrote: it'd be great if it would audition the selected slice automaticaly.
Just to be clear, are you saying it would be more convenient if you could click on an audio slice, hear the sound, then move the slice straight away without releasing the mouse button, rather than having to click the "Audition" button then click the "Move" button?
sorry! i totaly didn't notice the audition button, it does exactly what i was asking for.
RockHopper wrote:
motosega wrote: maybe it would be handy to be able to unslice, (go back to the unsliced sample)
At the moment you can undo all operations including slicing the waveform. You can also slice the waveform, move the slices around, and then join them all back together with the keyboard shortcuts "Ctrl+A" followed by "J".
ok thats what i wanted.

shuriken is now working on my netbook, thanks!

keep up the good work!
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

OK, I think I've fixed the bugs in the Akai pgm export code. Also, MIDI file export is now implemented so if you could test this with the MPC that would be great! Pads are automatically assigned to MIDI notes and MIDI notes to pads when exporting the pgm file.

The MIDI file type buttons don't actually do anything at the moment, I need to update the JUCE code to the latest version to get this functionality.
motosega wrote: maybe it would be best to save the pgm and samples in a new folder, compact flash cards can get pretty messy with everthing in the root.
You can create a new dir by adding, for example, "/FatBeat" to the end of the path in the "Output Dir" box and clicking "Create"
motosega
Established Member
Posts: 72
Joined: Wed Oct 16, 2013 5:40 pm

Re: Shuriken Beat Slicer

Post by motosega »

RockHopper wrote:OK, I think I've fixed the bugs in the Akai pgm export code. Also, MIDI file export is now implemented so if you could test this with the MPC that would be great! Pads are automatically assigned to MIDI notes and MIDI notes to pads when exporting the pgm file.

The MIDI file type buttons don't actually do anything at the moment, I need to update the JUCE code to the latest version to get this functionality.
ok! pgm files are now working on the mpc500 !!!!

unfortunatley the midi files are't working yet, i can load them on the mpc but they don't play. the midi files seem to be fine in rosegarden and Muse.
the notes don't show up in the mpc sequencer (the bpm is loaded from the midi file though)

i can confirm the notes assigned to the pads corespond correctly (i looked at the midi file in Muse and the pgm in the mpc)

if the notes were displayed in shuriken on the slices that would be usefull
motosega wrote: maybe it would be best to save the pgm and samples in a new folder, compact flash cards can get pretty messy with everthing in the root.
You can create a new dir by adding, for example, "/FatBeat" to the end of the path in the "Output Dir" box and clicking "Create"
i'd prefer that the folder was added automaticaly, since i'm sure i'll be adding it every time i export.

this is really shaping up nicely! i really apreciate your work.

ewan.
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

Hi! Hopefully MIDI file export is working properly now, and the samples directory is automatically created as requested :)
motosega wrote: if the notes were displayed in shuriken on the slices that would be usefull
Yes, that would be nice
motosega
Established Member
Posts: 72
Joined: Wed Oct 16, 2013 5:40 pm

Re: Shuriken Beat Slicer

Post by motosega »

amazing, midi files on the mpc is working! i've no idea how your managing this without an mpc on your desk!

we're not quite out of the woods yet though...

on the loop i tested with it seems that the midi file is a bit too long though, i get a little silence before the loop repeats on my mpc. my first guess was that i had entered the wrong bpm for my loop, (i did) but i get this little bit of silence when the loop repeats even with the right bpm. i looked at the midi file in Muse and my suspicions were confirmed


now with all this testing i'm getting a feel for the workflow in shuriken, i'm starting to miss a few things:
i'm sure your todolist is ever growing but anyway:

looping play, pretty essensial for working with loops

bpm detection isn't working for me, it gives 0.00 bpm every time. like i mentioned yesterday, just calculating bpm by known length in bars would be fine. relevant math here:
http://testtone.com/calculators/loop-le ... calculator

these next two probably fall into the category of feature creep but anyway...

dynamic range compression as well as normalise. its normaly the first thing i do with a loop. being able to do it in shuriken would be fantastic.

being able to loop and chop just a small section of audio from a bigger file would save a lot of time switching between audacity and shuriken.

congratulations on your work so far, things are really shaping up. i can see skuriken being central to my workflow in the near future!
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

motosega wrote:on the loop i tested with it seems that the midi file is a bit too long though, i get a little silence before the loop repeats on my mpc. my first guess was that i had entered the wrong bpm for my loop, (i did) but i get this little bit of silence when the loop repeats even with the right bpm. i looked at the midi file in Muse and my suspicions were confirmed
Muse seems to add an extra bar onto the end of imported MIDI files for some reason. I exported a couple of MIDI files from Shuriken then imported them into Ardour and RoseGarden and both files looked exactly the right length. I think it might be something else that's causing the problem...

When testing Shuriken in KXStudio 14.04 (which has Qt 4.8 ) I noticed that there's always a small gap at the end of the waveform. In AVLinux (which has Qt 4.6) this doesn't happen. Can you confirm that this also happens on your desktop/netbook?

On another issue, I fixed the bug that was causing gaps to appear in the waveform when dragging a slice point whilst zoomed in, but unfortunately created another bug in the process! In AVLinux, when I zoom in and scroll the waveform whilst the window is maximised, the XFCE CPU Graph indicates that usage is around 25% with just one-and-a-bit cores being used. However, when the window is not maximised, zooming in and scrolling the waveform causes all four cores to be maxed out! This doesn't seem to happen in KXStudio 14.04, so it looks like the issue may be specific to Qt 4.6. It would be interesting to know if you experience the same problem or if this issue is specific to my computer!

motosega wrote:looping play, pretty essensial for working with loops
Definately! This will be in the next release.

motosega wrote:bpm detection isn't working for me, it gives 0.00 bpm every time. like i mentioned yesterday, just calculating bpm by known length in bars would be fine.

The threshold level and detection settings affect BPM detection as well as onset detection. Try lowering the threshold or changing the detection method, though you're quite right about the need for an additional way of calculating BPM by manually inputting the length in bars.

motosega wrote:dynamic range compression as well as normalise. its normaly the first thing i do with a loop. being able to do it in shuriken would be fantastic.

Maybe on a future release, we'll see :wink:

motosega wrote:being able to loop and chop just a small section of audio from a bigger file would save a lot of time switching between audacity and shuriken.
Yes, this will definitely be on the next release
motosega
Established Member
Posts: 72
Joined: Wed Oct 16, 2013 5:40 pm

Re: Shuriken Beat Slicer

Post by motosega »

motosega wrote:on the loop i tested with it seems that the midi file is a bit too long though, i get a little silence before the loop repeats on my mpc. my first guess was that i had entered the wrong bpm for my loop, (i did) but i get this little bit of silence when the loop repeats even with the right bpm. i looked at the midi file in Muse and my suspicions were confirmed
Muse seems to add an extra bar onto the end of imported MIDI files for some reason. I exported a couple of MIDI files from Shuriken then imported them into Ardour and RoseGarden and both files looked exactly the right length. I think it might be something else that's causing the problem...
after i wrote that i had annother go and this time it worked perfectly, i think i probably had the wrong bpm the whole time. my bad, it's working perfectly!!
When testing Shuriken in KXStudio 14.04 (which has Qt 4.8 ) I noticed that there's always a small gap at the end of the waveform. In AVLinux (which has Qt 4.6) this doesn't happen. Can you confirm that this also happens on your desktop/netbook?
i have kxstudio 14.04 on my desktop and avlinux on my netbook, and i get the same as you, a little bit of extra silence on kx studio and nothing on avlinux

On another issue, I fixed the bug that was causing gaps to appear in the waveform when dragging a slice point whilst zoomed in, but unfortunately created another bug in the process! In AVLinux, when I zoom in and scroll the waveform whilst the window is maximised, the XFCE CPU Graph indicates that usage is around 25% with just one-and-a-bit cores being used. However, when the window is not maximised, zooming in and scrolling the waveform causes all four cores to be maxed out! This doesn't seem to happen in KXStudio 14.04, so it looks like the issue may be specific to Qt 4.6. It would be interesting to know if you experience the same problem or if this issue is specific to my computer!
i've tried this and i don't get a cpu spike in either kxstudio or avlinux, neither maximised or not.

something i did notice though is that on the netbook i can't really unmaximise the window, when it's not maximised the window takes up the whole screen and the window decorations disapear.



motosega wrote:bpm detection isn't working for me, it gives 0.00 bpm every time. like i mentioned yesterday, just calculating bpm by known length in bars would be fine.

The threshold level and detection settings affect BPM detection as well as onset detection. Try lowering the threshold or changing the detection method, though you're quite right about the need for an additional way of calculating BPM by manually inputting the length in bars.
ok, i got it, if i take the threshold way down then bpm detection works, the bpm i get is double what it should be though,
this is pretty common in all bpm detection algorythmns though, most software handles this by having button to half or double the bpm.
motosega wrote:dynamic range compression as well as normalise. its normaly the first thing i do with a loop. being able to do it in shuriken would be fantastic.

Maybe on a future release, we'll see :wink:
no hurry on this one though, its icing on the cake.
motosega wrote:being able to loop and chop just a small section of audio from a bigger file would save a lot of time switching between audacity and shuriken.
Yes, this will definitely be on the next release
i'm looking forward to this!
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

Thanks for all your help testing this motosega!

I found what was causing the gap to appear at the end of the waveform in Trusty but not in Precise or AVLinux. When you import an audio file into Shuriken, first aubio tries to open it, then if that fails, sndlib tries to open it. aubio doesn't load the file itself: it first calls on libav (if aubio was compiled with libav support) and then falls back to libsndfile. The version of libav on AVLinux and Precise is too old to work with aubio 0.4, so I compiled aubio without libav support for these distros. So, quick summary...

AVLinux / Precise : No support for libav in aubio, no gap at end of waveform in Shuriken
Trusty : Support for libav in aubio, gap at end of waveform in Shuriken

It looks like there's a bug either in libav itself or in one of aubio's libav-related functions. As a double check, I made some temporary adjustments to Shuriken in Trusty so that it used sndlib rather than aubio to load files, and you guessed it, no gap at the end of the waveform.

Don't worry though, I'll find a way round about this! And hopefully a new release won't be too far around the corner...
motosega
Established Member
Posts: 72
Joined: Wed Oct 16, 2013 5:40 pm

Re: Shuriken Beat Slicer

Post by motosega »

its already at the stage where it's useful, if you make a beta release, i'll do some promoting arround the website where mpc users are hanging about. there might be some issues for mpc1000 an 2500 users that we havent found yet.

whilst i'd weary about asking for a million features, yesterday i had an interesting idea:
would it be possible to re-pitch slices by semitone increments? and duplicate slices?(idealy duplicate slices reference the same sample on disk) this would enable me to do some pretty interesting stuff with musical phrases.

ewan.
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

motosega wrote:would it be possible to re-pitch slices by semitone increments?
Yes, but that will have to wait for another release! For now I just want to get some of the basic missing features in there (like looping) and squash as many of the known bugs as possible.

motosega wrote:...and duplicate slices?(idealy duplicate slices reference the same sample on disk)
That would be easy enough to do, including the referencing bit. When you move audio slices around in Shuriken, you're actually changing references to various points in the audio buffer, the samples themselves aren't being moved. At the moment audio files are loaded in their entirety into memory, but in a future release there will be an option to stream from disk.
stanlea
Established Member
Posts: 700
Joined: Wed Apr 25, 2012 9:49 pm
Has thanked: 41 times
Been thanked: 23 times

Re: Shuriken Beat Slicer

Post by stanlea »

I'm on debian jessie and I could compile successfully shuriken, but when I try to load a wav, it freezes. In fact, when I invoke shuriken from a term, I can see that there's a problem with aubio, that can't handle the file.
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

Hi stanlea! What version of aubio have you got installed and what is the error message displayed in the terminal?
stanlea
Established Member
Posts: 700
Joined: Wed Apr 25, 2012 9:49 pm
Has thanked: 41 times
Been thanked: 23 times

Re: Shuriken Beat Slicer

Post by stanlea »

@rockhopper :

Aubio is 0.4.1-2+b1

Code: Select all

AUBIO ERROR: Could not read frame in /home/studio/explosion.wav (Erreur inconnue 541478725)
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

Looks like aubio has a few bugs in it's file handling code. I think I'll add some code to Shuriken which calls libsndfile directly, and just forget about libav for the meantime.
RockHopper
Established Member
Posts: 142
Joined: Thu Apr 18, 2013 3:19 pm
Contact:

Re: Shuriken Beat Slicer

Post by RockHopper »

Looping is now implemented if anyone wants to test! I think I've ironed out all the bugs that were causing Shuriken to crash while developing this feature, but I can't be 100% sure. If you do experience a crash, take a note of what operation you were performing at the time (e.g. moving an audio slice, clicking undo/redo, time stretching, etc.)

Also, audio files are now opened using libsndfile directly, so hopefully that will solve some of the previously mentioned issues.
Post Reply