DJ/VJ scratching system
First my story: (you can skip down to END OF STORY if you want)
Ever since I saw Mike Relm go to town with a DVDJ, I've wanted a system where I could scratch and cue video. However, I haven't wanted to spend the $2500 for a DVDJ. As I was researching, I found a number of different systems. I am not a DJ by trade, so to get a system like Traktor or Serrato with their video modules plus turntables plus hardware plus a DJ mixer, soon everything gets really expensive. But in looking around, I found the Ms.Pinky system and after a little bit, I found a USB turntable on Woot for $60. So I bought it. It was marketed as a DJ turntable, but I knew that it wasn't really serious since it had a belt drive, but it came with a slip-pad and the USB connection meant that I wouldn't need a preamp. And so I spend the $100 on the Ms.Pinky vinyl plus software license (now only $80). This worked decently, but I had a lot of trouble really getting it totally on point. The relative mode worked well, but sometimes would skip if I scratched too vigorously. The absolute mode I couldn't get to work at all. After reading a little more, I came to the conclusion that my signal from vinyl to computer just wasn't strong enough, so I would need maybe a new needle or maybe a different turntable and I didn't really want to spend the money experimenting. I think that the Ms. Pinky system is probably a very good system with the right equipment, but I don't do this professionally, so I don't want to spend the loot on a system.
Earlier, before I bought Ms.Pinky (about two years ago), I had also looked around for a cheap MIDI USB DJ controller and not found one. Well, about a month ago, I saw the ION Discover DJ controller was on sale at Bed, Bath & Beyond for $50. They sold out before I could get one, but Vann's was selling it for $70, so I decided that that was good enough and bought one. I had planned to try to use it with Ms. Pinky since you can hook up MIDI controllers to it. But it turns out that you can hook up MIDI controllers to every control except the turntable, so that was a no go. If I had Max/MSP/Jitter, I could have changed that, but that's also way expensive. So, how should I scratch? My controller came with DJ'ing software and there's also some freeware, like Mixxx, but none of this has video support. So I look around and find Pure Data and GEM.
And I see lots of questions about scratching, how to do it. And there are even some tutorials and small patches out there, but as I look at them, none of them are quite what I'm looking for. The YouTube tutorial is really problematic because it's no good at all for scratching a song. It can create a scratching sound for a small sample, but it's taking the turntable's speed and using that as the position in the sample. If you did that with a longer song, it wouldn't even sound like a scratch. And then there are some which do work right, but none of them keep track of where you are in the playback. So, whenever you start scratching, you're starting from the beginning of the song or the middle.
So, I looked at all this and I said, "Hey, I can do this. I've got my spring break coming up. Looking at how easy PD looks and how much other good (if imperfect) work other people have done, I bet that I could build a good system for audio and video scratching within a week." And, I have.
END OF STORY
So that's what I'm presenting to you, my free audio and video scratching system in Pure Data (Pd-extended, really). I use the name DJ Lease Def, so it's the Lease Def DJ system. It's not quite perfect because it loads its samples into tables using soundfiler which means that it has a huge delay when you load a new file during which the whole thing goes silent. I am unhappy about this, but unsure how to fix it. Otherwise, it's pretty nifty. Anyway, rather than be one big patch, it relies on a system of patches which work with each other. Each of the different parts will come in several versions and you can choose which one you want to use and load up the different parts and they should work together correctly. Right now, for most of the parts there's only one version, but I'll be adding others later.
There's a more detailed instruction manual in the .zip file, but the summary is that you load:
the engine (only one version right now): loads the files, does the actual signal processing and playback
one control patch (three versions to choose from currently, two GUI versions and a MIDI version specific to the Ion Discover DJ): is used to do most of the controlling of the engine other than loading files such as scratching, fading, adjusting volume, etc.
zero or one cueing patch (one version, optional): manages the controls for jumping around to different points in songs
zero or one net patch (one version: video playback): does some sort of add-on. Will probably most commonly be used for video. The net patches have to run in a separate instance of Pd-extended and they listen for signals from the engine via local UDP packets. This is set-up this way because when the audio and video tried to run in the same instance, I would get periodic little pops, clicks, and other unsmoothnesses. The audio part renders 1000 times per second for maximum fidelity, but the video part only renders like 30 or 60 times per second. Pure Data is not quite smooth enough to handle this in a clever real-time multithreading manner to ensure that they both always get their time slices. But you put them in separate processes, it all works fine.
So, anyway, it's real scratching beginning exactly where you were in playing the song and when you stop scratching it picks up just where you left off, you can set and jump to cue points, and it does video which will follow right along with both the scratching and cuing. So I'm pretty proud of it. The downsides are that you have to separate the audio and video files, that the audio has to be uncompressed aiff or wav (and that loading a new file pauses everything for like 10 seconds), that for really smooth video when you're scratching or playing backwards you have to encode it with a codec with no inter-frame encoding such as MJPEG, which results in bigger video files (but the playback scratches perfectly as a result).
So anyway, check it out, let me know what you think. If you have any questions or feedback please share. If anyone wants to build control patches for other MIDI hardware, please do and share them with me. I'd be glad to include them in the download. The different patches communicate using send and receive with a standard set of symbols. I've included documentation about what the expected symbols and values are. Also, if anyone wants me to write patches for some piece of hardware that you have, if you can give me one, I'll be glad to do it.
Keith Irwin (DJ Lease Def)
Which fft-code is built into Pd binaries?
Does anyone happen to know which fft-code is built into Pd / Pd-extended binary releases?
The source file d_fft.c states that it interfaces 'to one of the Mayer, Ooura or fftw FFT packages to implement the "fft~", etc, Pd objects. ... The configure script can be used to select which one.'
The configure.in script in SVN says about fftw:
AC_SUBST(fftw, no)
AC_ARG_ENABLE(fftw, [ --enable-fftw use FFTW package],
fftw=$enableval)
dnl Check for fftw package
if test x$fftw = "xyes";
then
AC_CHECK_LIB(fftw, fftw_one,PDLIB="$PDLIB -lfftw",
echo "fftw package not found - using built-in FFT"; fftw=no)
So it depends on the build machines. On the other hand, [partconv~] from Ben Saylor depends on fftw and this object works fine, at least in 0.42.5-extended build for OSX.
From these bits I conclude that fftw is built into Pd binaries and also used for [fft~] & co. Is that correct? fftw claims to be the fastest. Not that it is very important to me, I am just curious.
Katja
Interaction Design Student Patches Available
Greetings all,
I have just posted a collection of student patches for an interaction design course I was teaching at Emily Carr University of Art and Design. I hope that the patches will be useful to people playing around with Pure Data in a learning environment, installation artwork and other uses.
The link is: http://bit.ly/8OtDAq
or: http://www.sfu.ca/~leonardp/VideoGameAudio/main.htm#patches
The patches include multi-area motion detection, colour tracking, live audio looping, live video looping, collision detection, real-time video effects, real-time audio effects, 3D object manipulation and more...
Cheers,
Leonard
Pure Data Interaction Design Patches
These are projects from the Emily Carr University of Art and Design DIVA 202 Interaction Design course for Spring 2010 term. All projects use Pure Data Extended and run on Mac OS X. They could likely be modified with small changes to run on other platforms as well. The focus was on education so the patches are sometimes "works in progress" technically but should be quite useful for others learning about PD and interaction design.
NOTE: This page may move, please link from: http://www.VideoGameAudio.com for correct location.
Instructor: Leonard J. Paul
Students: Ben, Christine, Collin, Euginia, Gabriel K, Gabriel P, Gokce, Huan, Jing, Katy, Nasrin, Quinton, Tony and Sandy
GabrielK-AsteroidTracker - An entire game based on motion tracking. This is a simple arcade-style game in which the user must navigate the spaceship through a field of oncoming asteroids. The user controls the spaceship by moving a specifically coloured object in front of the camera.
Features: Motion tracking, collision detection, texture mapping, real-time music synthesis, game logic
GabrielP-DogHead - Maps your face from the webcam onto different dog's bodies in real-time with an interactive audio loop jammer. Fun!
Features: Colour tracking, audio loop jammer, real-time webcam texture mapping
Euginia-DanceMix - Live audio loop playback of four separate channels. Loop selection is random for first two channels and sequenced for last two channels. Slow volume muting of channels allows for crossfading. Tempo-based video crossfading.
Features: Four channel live loop jammer (extended from Hardoff's ma4u patch), beat-based video cross-cutting
Huan-CarDance - Rotates 3D object based on the audio output level so that it looks like it's dancing to the music.
Features: 3D object display, 3d line synthesis, live audio looper
Ben-VideoGameWiiMix - Randomly remixes classic video game footage and music together. Uses the wiimote to trigger new video by DarwiinRemote and OSC messages.
Features: Wiimote control, OSC, tempo-based video crossmixing, music loop remixing and effects
Christine-eMotionAudio - Mixes together video with recorded sounds and music depending on the amount of motion in the webcam. Intensity level of music increases and speed of video playback increases with more motion.
Features: Adaptive music branching, motion blur, blob size motion detection, video mixing
Collin-LouderCars - Videos of cars respond to audio input level.
Features: Video switching, audio input level detection.
Gokce-AVmixer - Live remixing of video and audio loops.
Features: video remixing, live audio looper
Jing-LadyGaga-ing - Remixes video from Lady Gaga's videos with video effects and music effects.
Features: Video warping, video stuttering, live audio looper, audio effects
KatyC_Bunnies - Triggers video and audio using multi-area motion detection. There are three areas on each side to control the video and audio loop selections. Video and audio loops are loaded from directories.
Features: Multi-area motion detection, audio loop directory loader, video loop directory loader
Nasrin-AnimationMixer - Hand animation videos are superimposed over the webcam image and chosen by multi-area motion sensing. Audio loop playback is randomly chosen with each new video.
Features: Multi-area motion sensing, audio loop directory loader
Quintons-AmericaRedux - Videos are remixed in response to live audio loop playback. Some audio effects are mirrored with corresponding video effects.
Features: Real-time video effects, live audio looper
Tony-MusicGame - A music game where the player needs to find how to piece together the music segments triggered by multi-area motion detection on a webcam.
Features: Multi-area motion detection, audio loop directory loader
Sandy-Exerciser - An exercise game where you move to the motions of the video above the webcam video. Stutter effects on video and live audio looper.
Features: Video stutter effect, real-time webcam video effects
PdLive!
Thanks C.!
The amazing jazzdrumbox patch is from Andy, many of the patches here come from forums and posts from users.
The drummachine is actually mine so thanks
There is so many patch because it's a collection (even if some patches are very close to each others, maybe I'll make a selection later)
- the CTL patches deal with data ( for instance : midi seq, midi automations, or fiddle and bonk analyse to track signal and send midi notes and vel)
- Fx are fx
- S patches are instruments to be played with midi keyboard, or with ctl patches.
- z patches are used in other patches and can be used to create new ones.
Instruments patches are meant to be browsed with your classic browser, and I wanted them to be opened in a new pd window. But I guess I could add a menus to the main mixer patch to open synth, ctl patches and fx
The workflow 'should' be to first select your sounds/instruments select the audio bus then they are caught in the main window and that's were the patching begins with effects and controls. The main limitation is that I only have 5 audio buses for now, but I should add some more later on, a signal router may come in handy at that time .
How to Enjoy Your Favorite Videos on Portable Devices at Will For Mac
Are you a Mac user?
Do you still feel frustrated that you can't enjoy your favorite videos on portable devices at will?
Now, a professional software---Aiseesoft Video Converter for Mac(http://www.aiseesoft.com/video-converter-for-mac.html)
can help you to solve all the problems. With it, you can convert between all popular video and audio formats with super fast conversion speed and high output quality, such as AVI, MP4, MOV, MKV, WMV, DivX, XviD, MPEG-1/2, 3GP, 3G2, VOB Video, MP3, AAC, and AC3 Audio etc. In addition, the best video converter for Mac can also extract audio from video file and convert video to MP3, AC3, and AAC...as you want.
OK, let's move to how to use the amazing software.
Step 0: Download and install Aiseesoft Video Converter for Mac.
After a while, you can use the following interface:
http://www.aiseesoft.com/images/guide/dvd-converter-suite-mac/video.jpg
Step 2. Load Video
You can load your video by clicking "Add File" button or clicking "File" button, you can choose "add file" on a drop-down list.
Step 3. Output format and Settings
From the "Profile" drop-down list you can find one format that meets your requirement.
After doing the 3 steps above, you can click "start" button to start conversion.
Wait a minute, the conversion will be soon finished.
Tips:
1. Trim
"Trim" function is for you to select the clips you want to convert.
There are 3 ways that you can trim your video.
a. You can drag the buttons(1) to set the start and end time
b. You can preview the video first and when you want to start trim click the left one of the pair buttons(2) when you want to end click the right one.
c. You can set the exact start and end time on the right side of the pop-up window.
It is for you to select the clips you want to convert.
http://www.aiseesoft.com/images/guide/dvd-ripper-for-mac/trim.jpg
2. Crop
Cut off the black edges of the original movie video and watch in full screen using the "Crop" function.
There are 3 ways that you can crop your video.
a. We provide 7 modes on our "Crop Mode"(1)
b. You can set your own mode on the right side of the pop-up window(2)
c. You can drag frame to set your own crop mode(3)
You can cut off the black edges of the original movie video and watch in full screen using the "Crop" function.
http://www.aiseesoft.com/images/guide/dvd-ripper-for-mac/crop.jpg
3. Snapshot and merge into one file
If you like the current image of the video you can use the "Snapshot" option. Just click the "Snapshot" button the image will be saved and you can click the "Open" button next to "Snapshot" button to open your picture.
If you want to make several files output as one you can choose "Merge into one file".
If you are windows users, you can go to Aiseesoft Total Video Converter(http://www.aiseesoft.com/total-video-converter.html) to get more information.
V2MSy is out (alpha)
Hi, my patch v2MSy (video to midi synth) is downloadable from <http://adrjork.altervista.org/puredatatutorials.html>. I hope you like it. Basically it's smilar to MetaSynth but my patch works with video or webcam in real time, and not with image. The patch transforms the central Y axis of the video into 128 MIDI signals (from bottom to top) at 25fps (metro at 40ms). The result is a detailed "notation" of the video's central axis where the white pixels represent velocity=127 and black pixels represent velocity=0 (very similar to carillons' mechanism where video stays for the cylinder!)
The patch contains also two indipendent subpatches: an interface for BCF2000 and a "poor" interface for keyboard&mouse.
You need a receiving software to "play" or "write" MIDI noteouts (like a sequencer).
To connect the patch to the receiving-software I use a virtual MIDI cable. I think you can use MidiYoke in Windows, or ALSA in Linux, or IAC driver in Mac. But if you want also feedback for your motorized BCF2000 you should set PD's MIDI settings with "multiple devices"...that doesn't work! Because it seems that only the 1st output device works... So I do in this way:
IAC driver (I use Mac) + MIDI Patchbay
and I set:
-BCF2000 as PD MIDI input
-IAC driver as PD MIDI output
-IAC driver as Patchbay input
-BCF2000 as Patchbay output
In this way, Logic receives MIDI signals from v2MSy, and my Behringer has feedback!
Please, test the patch in Windows or Linux and write if ALSA and MidiYoke do the work and give feedback. Thanks.
But remember that...it's only an "alpha" patch, and it needs powerful hardware.
Different ways of Implementing Delay Loops
Ta Toxonic - I'll take a look at the patch tonight. Good of you to take the time. Apologies if I've misunderstood though, but I think what you're describing is not quite what I mean: The pitch shift is separated out from the delay time - you're running a pitch shift effect into a separate delay line, which is not going to give the same effect. The delay time will not shorten as the pitch rises. I'll take a look at your patch tonight though as I may have misunderstood what you're getting at.
Maelstorm - thanks also. I understand why the pitch changes on a delay pedal. The pitchshifter patch was a bit of a red herring - though of course it's the same principle. The difference between what you're (both, I think) talking about and what I'm talking about is the way that the pitch changes.
Assuming a stable C tone playing into the delay:
With the standard simple PD delay set up, if you move the read point of a vd~ then you get a glissando as it accellerates, a constant pitch change as it moves at constant speed. So if you turn the knob to change the delay time in the middle of a tone you start with a constant pitch (C), then get a rise of pitch, then it levels out at a new pitch (as you turn then stop turning the knob),
_
___/
If you feed back into the delay, the glissando is repeated as the read speed changed while the write speed was constant:
_ _ _ _
/ |/ |/ |/ |
The effect I'm looking to emulate on the other hand is more akin to changing the speed of a phasor~ reading an array - the pitch change is not a blip, but a stable interval's transposition - eg: you turn the knob, the pitch of the repeats rise by a given interval and stays at that pitch as it repeats (now more quickly):
______
___/
If you play a constant C tone, then speed up the delay until it is a major third higher, you get a major third diad (until the delay dies away), rather than a C tone with a repeating squiggle overlaid.
The effect is the same as you get by speeding up a tape loop delay (though the pedal I'm trying to imitate is a digital delay) which is why I think the rate of the write and read heads are being increased by the same amount.
[edit, just tried to make this clearer and removed a couple of errors]
Announce: mmm-0.1.0-eden
hi forum.
we proudly announce the first public release of our compact composer
for pd, mmm.
grab it at http://netpd.org/mmm-0.1.0.zip
mmm is best described in it's faq, see below. don't expect too much
yet, there is still a lot to be done. comments, bugreports, cash, are
welcome.
have fun with it!
christopher charles & enrique erne
faq for mmm-0.1.0 - eden
what is mmm?
mmm is a pd patch collection aimed at providing a studiolike(?),
streamlined, dynamic interface for making synthetic music.
screenshots?
http://www.netpd.org/mmm.png
ymmv depending on your operating system. we put some effort in
detecting the operating system and setting the fontsize according to
it, but quirky xorg or dpi settings might screw things up again.
where can i get it?
we currently host the mmm at http://netpd.org/mmm-0.1.0.zip ,
alternatively, you can grab netpd, enter the chat, and if either of
the authors is online, download it directly through netpd and start
rocking.
what does "mmm" stand for?
mmm was originally just the working title, but we came to like it
somehow. the original meaning is "music making machine" but you can
substitute every m for whatever you want. so "massive multiplayer
music" is okay with us, too.
what is the inspiration?
having worked on/with the bagoftricks (lots inconsistently coloured
gop-patches to be connected freely) and netpd (lots of
inconsistent-looking windows to clutter up the screen), we came to
mock up an clean, dynamic interface in which modules don't bring their
own gop or open their own window, but log onto the interface that's
provided for them by the motherpatch. all modules sharing the same
interface made it easy for them to share the same sequencer and
arranger.
what are the dependencies?
mmm should work with pd-0.39 and zexy installed. iemlib is important
for many synth and effects patches, and there's even set of gem
modules you can chain if you want.
is it actually usable?
no. this 0.1.0 release is rather a tech demo and a taste of things to
potentially come. you can crunch some acid loops out of it already,
but don't sell your protools studio equipment to start working with
mmm on monday.
how does it work?
mmm's interface (mmmmain.pd) is divided into 3 parts: there is the
module/channel view, where you can chain up synths and effects on 8
different channels. select an empty field on a channel, and then use
the scrollbox on the left to select a patch and open it. when clicking
on a patch you loaded up in the module view, the 2nd view comes into
play: from there you control the patch's sliders on the left, right of
it is the stepsequencer for each of the slider (means everything is
sequencable!). yet you won't hear anything until you did the following
2 things: press play in the uppermost row of mmmmain, and set up the
arranger to play the stepsequence. the arranger is not module-based,
but controls all modules of a channel are grouped in the arranger. for
now, you can only select pattern 01 or nothing to play in the
arranger. so set up a loop for the first pattern (loopstart:0,
looplength:1) set the first field on the channel you got your patch on
in the arranger to p01 and start making some noise.
does it work online?
yes. mmm is compatible to netpd and will automatically log on to
netpd's server if you have the netpd chat open. you can also download
the whole mmm package through netpd. feel free to jam around the
world.
what's not working yet / what is planned?
as for now, there is no support for samples whatsoever, it isn't
planned to support them soon. further, there is no hard disk recorder
available yet, but it is planned. the arranger/sequencer combo is very
crippled at the moment, only supporting 1 16-step-pattern to choose
from and 1 page of 16 patterns in the arranger. this will change
rather soon. next there are plans for luxury editing functions,
especially in the sequencer like copy, paste, random pattern,
interpolation and so on. plans exist for full keyboard control, but
this will be worked on not too soon. the module roster is far from
being complete yet, more is to come.
can i save my stuff?
should be possible with the buttons above the channels. don't rely on
the result though, this is still 0.1.0
can i add my own modules?
modules are not to hard to write, but for now, the list of selectable
modules is hardcoded. look at all the 4m-* patches in the patches
folder to see how they are ticking. contact us for adding your patch
to the mmm or try to figure out yourself how it works
what's the license?
mmm is licensed under the gnu lgpl. if you think this is a too useful
product to be free of charge, please consider donating the amount of
money you would've paid for it (or the amount of money you got from
selling your protools equipment on monday) to a trust of your choice.
who are the authors?
mmm is developed by enrique erne (eni, swiss, pd{at}mild.ch) and
christopher charles (syntax_tn, germany, chr.m.charles{at}gmail.com).
we can be contacted via email, irc (#dataflow) or directly in the
netpd chat. several patches within mmm are based upon netpd versions
of them, check netpd for the original authors. mmm shares some of it's
netcode with netpd, by roman haefeli.
disclaimer.
we cannot give you any guarantees on using mmm, not even that you
have fun. it should be relatively harmless, but don't come crying to
us if mmm accidently hijacks your *mule and downloads david hasslehoff
recordings to your computer.
eofaq
Favorite ways of doing GUI
i think one thing you should take into account when designing a GUI is something that will fit well ontop of the work you've already done. if your patch has a message handling structure already embedded in it (one that is sufficient to control all parameters of your patch), it would be very easy to employ either of the trends mentioned above.
if your patch has a set up where many sub-patches on a main canvas, perhaps the graph-on-parent method would work well.
another consideration is displaying information from your patch (not just controlling or changing it).
though i guess the main thing is usability. certain components and controls are going to fit your patch better than others. if your patch needs to be used in some type of performance, what features will make the patch easiest to use for the performer.
i do not know much about it other than it exists, but joseph sarlo at UCSD is working on GrlPd...sometype of layer for making GUI's for your patches. the link is [url=http://crca.ucsd.edu/~jsarlo/gripd/
]http://crca.ucsd.edu/~jsarlo/gripd/
i hope this helped some and perhaps it will stimulate some forum discussion.
Saving video files in the pd patch?
as promised...a little tutorial on setting default values and restoring saved values in a pd patch. i hope this helps.
the patch is at [url=http://www.geocities.com/z_fron/saving.zip
]http://www.geocities.com/z_fron/saving.zip
sorry it's a zip file, but geocities won't let you upload .pd files for some reason.
pidaid, let me know if you need help applying this to your videos. i am not quite clear on what you mean you want to save the file names or save the actual video in the patch. saving filenames and having them loaded automatically when you start your patch shouldn't be a problem, but there is no way to save the video in the patch file (.pd files just contain text.) although....(this is pretty farfetched), you could save an image or video with in a patch if there were a way to convert the image or video into an array. but then you'd have to convert it back to a video and it would really be a waste of time and by no means useful or necessary or benificial in anyway that i can see.
cheers,
hilbert~