Keyboard bangs
Hi,
I'm new to Pd, and programming in general, and I'm having problems with some relatively simple tasks :/
I'm trying to write a patch that takes keyboard input to play notes, and then delays the note played so that it starts when the key is released, rather than when it is pressed. The note will then play for its full length (however long the user held down the key for).
To do this, I wanted to use the timer object, with a pressed key starting the timer, and a released key stopping the timer. Right now, I'm using the [keyname] object to get the key pressed/released data, but am having troubles with it.
It sends out a 1 when a key is pressed, and a 0 when it is released, and I thought this would be very helpful, but it does this continuously, so instead of getting one bang when a key is pressed, and one when it is released, I'm getting bangs all the time when a key is pressed.
Basically, I'm trying to figure out a way to have a key press send out just one bang, and likewise for a key release, so that I can use those bangs to control the timer.
Sorry for the longwinded description of such a (probably) simple problem.
Any ideas?
Thanks a lot!
- David
How to control sliders or grid objects by holding down keys?
First of all thanks for that mate!
That makes perfect sense except that when i hold down a key it doesnt send out a rapid bunch of key-downs and key ups.
It only sends out the number attached to the key object when i press the key once, and doesnt send out a stream when i old it down.
If i can make it send out a stream of key down I can make it change the slider for every keydown value and to stop moving it when it receives the key up.
So how do i change my OS so that in pd when i attach the key object it continally outputs the number of the key i am holding down?
Synthesis metal bars sound
HI,
i'm working on an installation based on this apllication made in java
i communique with pd via OSC
for each collision pd receive a bang with two parameters
height tube
position tube
i'm looking for synthesis metal bars sounds to transform this "thing" into a musical instrument
there is samples here
http://obiwannabe.co.uk/html/sound-design/sound-design-audio.html
http://obiwannabe.co.uk/sounds/effect-clonk-002-bar.mp3
http://obiwannabe.co.uk/sounds/effect-clonk-002-bar.mp3
http://obiwannabe.co.uk/sounds/effect-clonk-004-iron.mp3
http://obiwannabe.co.uk/sounds/effect-clonk-006-bar.mp3
What kind of simple patch should i have to make for this goal?
au revoir
Denis
Some new bird sounds
http://www.obiwannabe.co.uk/sounds/effect-rainforestbirds.mp3
http://www.obiwannabe.co.uk/sounds/effect-riverbirds.mp3
http://www.obiwannabe.co.uk/sounds/effect-seabirds.mp3
Background reading and inspiration
http://ccrma.stanford.edu/~tamara/publications/
http://www.acoustics.hut.fi/research/avesound/pubs/akusem04.pdf
http://www.csounds.com/ezine/winter2000/realtime/
http://www.obiwannabe.co.uk/tutorials/html/tutorial_birds.html
http://www.indiana.edu/~songbird/pubs/publications_index.html
http://web.mit.edu/fee/Public/Publications/Fee_etal1998.pdf
Errors using linux event objects
Hi all. I'm off and running with a Pd project on my Mac, but apparently using my wacom intuos 3 tablet to its full extent is a lost cause on Mac, so I've decided to hook up a separate Linux machine to gather and send tablet data.
I've converted my evil Dell XP laptop to a sexy dual-boot Ubuntu Gutsy machine, my tablet is all installed and working with the latest driver from linuxwacom.sf.net, and Pd-Extended looks and works great. I'm using the 0.40.3 pd-extended package (I know it's unsupported, but all the issues below are identical when using the 0.39.3 release, which I tried first, so hopefully you'll indulge me anyway .
Problem is that the tablet and Pd still won't play nice together. When I use any of the linux event objects (hid, hidio, linuxevent) to open my tablet device (/dev/input/wacom), it gets most of the way there, which I can see because lots of good info shows up in the Pd console, but no events are actually generated, and I see errors in the terminal window from which I launched Pd:
evdev EVIOCGABS ioctl: Invalid argument
Can anyone help with this? I realize that this really concerns the event externals, but I'm flexible about using anything which will get the job done. If you let me know what info will help, I'll provide, and if there's any other way I can be generally helpful, let me know and I'll get right on it.
Thanks in advance,
Alex
Info which may be of use...
Here's the first line from my dmesg:
dmesg
[ 0.000000] Linux version 2.6.22-14-generic (buildd@terranova) (gcc version 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)) #1 SMP Tue Dec 18 08:02:57 UTC 2007 (Ubuntu 2.6.22-14.47-generic)
Here's what shows up in the terminal when I launch Pd via "sudo pd":
priority 8 scheduling enabled.
priority 6 scheduling enabled.
tk scaling is 1.33483483483
<init> : Avifile RELEASE-0.7.47-070916-12:47-4.1.3
<init> : Available CPU flags: fpu vme de pse tsc msr mce cx8 sep mtrr pge mca cmov pat clflush dts acpi mmx fxsr sse sse2 tm pbe up est tm2
<init> : 1200.00 MHz Intel(R) Pentium(R) M processor 1600MHz detected
Here's the errors which show up in the terminal when attempting to open /dev/input/wacom with any of the event objects:
evdev EVIOCGABS ioctl: Invalid argument
evdev EVIOCGABS ioctl: Invalid argument
evdev EVIOCGABS ioctl: Invalid argument
evdev EVIOCGABS ioctl: Invalid argument
(...lots more of this...)
Here's what shows up in the Pd console (looks good):
info: open 1
info: device 6
info: total 0
info: poll 25
info: range key btn_0 0 0
info: range key btn_1 0 0
info: range key btn_2 0 0
info: range key btn_3 0 0
info: range key btn_4 0 0
info: range key btn_5 0 0
info: range key btn_6 0 0
info: range key btn_7 0 0
info: range key btn_0 0 0
info: range key btn_1 0 0
info: range key btn_2 0 0
info: range key btn_3 0 0
info: range key btn_4 0 0
info: range key btn_0 0 0
info: range key btn_1 0 0
info: range key btn_2 0 0
info: range key btn_3 0 0
info: range key btn_4 0 0
info: range key btn_5 0 0
info: range key btn_6 0 0
info: range key btn_7 0 0
info: range key btn_10 0 0
info: range key btn_11 0 0
info: range key btn_12 0 0
info: range rel rel_wheel 0 0
info: range abs abs_x 0 54204
info: range abs abs_y 0 31750
info: range abs abs_rx 0 4096
info: range abs abs_ry 0 4096
info: range abs abs_rz -900 899
info: range abs abs_throttle -1023 1023
info: range abs abs_wheel 0 0
info: range abs abs_pressure 0 0
info: range abs abs_distance 0 0
info: range abs abs_tilt_x 0 0
info: range abs abs_tilt_y 0 0
info: range abs abs_misc 0 0
info: range msc msc_serial 0 0
info: vendorID 0x0026
info: productID 0x01e9
info: name Wacom Intuos3 6x11
eom
Inside on a rainy day
Something to share that combines a few different models in a linked way.
Start with a wind model based on turbulence, objects in the path vary their signals according to wind speed and their size and texture.
http://www.obiwannabe.co.uk/sounds/effect-wind3.mp3
And a rain model with carefully distributed droplets that make little clicks according to a range of textures they hit...
http://www.obiwannabe.co.uk/sounds/effect-plainrain.mp3
Next is a window pane built around a square lamina with glass-like character Here's a few knocks on the virtual window with a virtual stick.
http://www.obiwannabe.co.uk/sounds/effect-knockonwindow.mp3
and finally I combine them all in the same auditory scene with causal linkage, so the rain lashes against the window...
http://www.obiwannabe.co.uk/sounds/effect-rainywindow.mp3
(Total object count 80 operators)
Andy
GUI for PD, or loading PD and Patch from other GUI application
Depending on the type of socket there's some buffering latency. Nothing to worry about for most applications. The nice advantage is that with IP socks you can have the GUI on a completely different machine from your DSP
Afaik some disadvantages/issues worth mentioning:
There's no equivalent to a "bang" in most toolkits, but a push-button does the job okay if you act on the button_down event.
Some of Pds GUI objects have "hidden" built in capabilities, like VU is more than just a bar graph display, it does some of the slugging necessary for a proper VU response. You might need to add a bit of extra code to some of your GUI display objects like that.
Pd slider GUIs don't have a step size, but most toolkit sliders do. This is an advantage that may give you pause for thought when redesigning a stand-alone GUI for a Pd patch.
And there's no easy way to represent graphs for arrays on a peripheral GUI. This opens a whole can of worms about good GUI design and decoupling. You either end up with a potentially slow application that shovels loads of data about when you update something, or you break good practice by calculating display code inside your GUI. There's no magic bullet. I tend to avoid fancy things like envelope graphs, meters and so on when making a remote GUI.
March sound effects
New machines
http://obiwannabe.co.uk/html/toys/machineomatic/machine-o-matic.html
And I was playing about with different short energy impulses for explosions, so
Fresh Guns
http://obiwannabe.co.uk/html/toys/gunsulike/gunsulike.html
Bombs
http://obiwannabe.co.uk/html/toys/bombfactory/bombfactory.html
and Fireworks
http://www.obiwannabe.co.uk/html/toys/fireworks/fireworks.html
I think you need [ead~] for some, sorry.
Andy
Pd workshop in Madrid
> Instituto Nacional de las Artes Escénicas y la Música
> MINISTERIO DE EDUCACIÓN, CULTURA Y DEPORTE
> Centro para la Difusión de la Música Contemporánea
>
> Curso:Introducción a la Creación de Aplicaciones Musicales con PD/MAX por
> Juan Andrés Beato y Gregorio García Karman
>
>
> 7 - 11 Marzo 2005
> teoría: 16.00 a 19.00 horas
> prácticas: del 8 al 11 de Marzo, de 11.00 a15.00 horas en grupos de 2
> alumnos (solo alumnos activos)
>
> lugar:
> LIEM-CDMC
> Museo Nacional Centro de Arte Reina Sofía, 5ª planta
> c) Santa Isabel 52, 28012 Madrid
>
>
> Pure Data (PD) es un entorno de programación gráfica para aplicaciones
> musicales que funciona bajo Windows, OSX, Linux e Irix. Desarrollado por
> Miller Puckette y de distribución libre y código abierto, constituye junto
> con MAX/MSP uno de los modelos de software musical de más impacto y
> difusión en la actualidad. La programación se realiza interconectando
> objetos gráficos, que representan instrucciones, en un entorno
> fuertemente desestructurado y optimizado para el procesado de audio y
> vídeo en tiempo real. Su objetivo es ofrecer al músico una herramienta
> intuitiva y versátil: se utiliza para crear instrumentos virtuales o
> emular el funcionamiento de equipos hardware, realizar composiciones de
> música electrónica en vivo, en instalaciones, conciertos en red y jams
> on-line. Su flexibilidad para tratar MIDI, audio, vídeo y 3D en un paquete
> integrado y con múltiples posibilidades de control, hace que encuentre
> también un número creciente de aplicaciones en el ámbito de los
> multimedia, la performance, VJing..., así como en la enseñanza, en la
> ingeniería de sonido y la musicología (arqueología electroacústica). El
> objetivo del curso es dar a conocer la filosofía y los fundamentos de
> programación de los entornos basados en el "paradigma MAX", ilustrados a
> través de ejemplos realizados en Pure Data así como de aplicaciones reales
> ya desarrolladas.
> Se tratarán los conocimientos necesarios para poder dar primeros pasos en
> este entorno, así como para que el alumno pueda desenvolverse
> posteriormente utilizándolo para la creación de aplicaciones musicales
> propias. A lo largo del curso, se realizará un repaso de los diferentes
> elementos de PD demostrando su funcionamiento junto con conceptos
> básicos del programa (orden, encapsulamiento...). Se presentarán las
> principales familas de objetos estudiando ejemplos implementados en PD de
> técnicas 'en vivo' de síntesis, control algorítmico, manipulación de
> muestras y procesado, afines a la música electroacústica. De manera
> destacada, se tratarán aspectos particulares de PD como las data
> structures, una herramienta específica de este entorno para el
> almacenamiento y visualización de datos que permite el control de PD desde
> partituras gráficas diseñadas por el usuario. También se realizará un
> repaso de los externals y librerías más relevantes utilizadas en la
> programación de aplicaciones musicales (objetos de análisis,
> comunicación, espacialización, streaming...), señalando algunos aspectos
> comunes y divergentes entre PD y su contrapartida comercial MAX. Desde una
> perspectiva más general, se tratarán cuestiones propias de los sistemas
> musicales en tiempo real como el acondicionamiento de datos de control o
> el mapping y se presentarán diferentes estrategias de control sonoro
> empleadas en la creación de aplicaciones musicales, analizando ejemplos de
> piezas realizadas con PD y MAX.
>
> Dirigido a:
> Compositores, intérpretes musicales, musicólogos, artistas sonoros,
> músicos en general tanto profesionales como estudiantes.
>
> Inscripción
> Número de plazas: 8 alumnos activos (serán seleccionados por currículum)
>
> 22 alumnos oyentes
>
> Precio de matrícula: 45 euros. Descuento del 50% a estudiantes que lo
> acrediten
> Para inscribirse envíen una carta de solicitud con su nombre, dirección,
> teléfono, correo electrónico y/o fax indicando su intención de optar a
> "alumno activo" o no, y su currículum especificando experiencia en los
> campos que cubre el curso
> Envíen por correo ordinario, electrónico o fax a:
> "Curso Introducción a la Creación de Aplicaciones Musicales con PD/MAX "
>
> LIEM-CDMC
> (Museo Nacional Centro de Arte Reina Sofía)
> c) Santa Isabel 52 , 28012 Madrid, ESPAÑA
> tel: (+34) 91 774 1072, (+34) 91 774 1073; fax: (+34) 91 774 1075
> cdmc@inaem.mcu.es [url=http://cdmc.mcu.es
]http://cdmc.mcu.es
>
> El plazo de inscripción se cerrará el primer día de clase. No obstante el
> 24 de febrero se comunicará a los asistentes su admisión como alumno
> activo u oyente.
> El pago de matrícula deberán realizarlo después de que les hayamos
> confirmado la admisión, y el primer día de clase deberán entregarnos el
> justificante del pago.
> Ingresar el importe en cualquier oficina del BBVA, a nombre del
> Instituto Nacional de las Artes Escénicas y de la Música, en la cuenta
> siguiente:
> Entidad: 0182 Sucursal: 2370 Dígito de control: 40 c/c:
> 0200201218
> Al término del curso, los alumnos recibirán un diploma acreditativo de
> asistencia.
> Cualquier información que se precise sobre estos cursos o las diversas
> actividades del CDMC, puede solicitarse en la dirección indicada
> anteriormente.
>