I have been inspired by the processing software as have i been inspired by open source ethos for sometime. Sometime ago i became wowed by pure data (audio primarily beingmy background). At first it seemed like an uphill struggle getting to grips with PD. It now seems the hill has steepend with processing......
I would long for and would be extremely greatfull if someone could please help me or indeed direct me towards resolving my issues. Firstly i am managing to now send 3 messages to PD as individual signals, and now realise i need to send the variable "coordinates" of the x and y. I have managed to send the 0 ie "brightestX=0".
I now wonder if I should be sending the message from the videoLoadPixels part of the code so PD can recieve the variating x and y positions.
I realise that this really is child play for some people however everyone has to start somewhere.
Thanks
/**
* oscP5sendreceive by andreas schlegel
* example shows how to send and receive osc messages.
I am extremely new to processing but have used OSC on several projects before. I seem to be struggling to understand how to send the x and y positions to pure data.
So far I have managed to get pure data and processing to talk to each other. I know that the message needs to be sent in the void draw part of the code and the OscP5 needs to be told which message to pass on.
Should I be asking for
for (int y = 0; y < video.height; y++) {
for (int x = 0; x < video.width; x++) {
to be sent ......
please can anyone help in my confusion..I realise this is a bit like trying to spell before learning the alphabet...but i really cant contain my excitement at being able to achieve this
thanks
import oscP5.*;
import netP5.*;
import processing.video.*;
OscP5 oscP5;
NetAddress myRemoteLocation;
Capture video;
void setup() {
size(640, 480);
video = new Capture(this, width, height, 30);
noStroke();
smooth();
oscP5 = new OscP5(this,40000);
myRemoteLocation = new NetAddress("127.0.0.1",12000);
}
void draw() {
if (video.available()) {
video.read();
image(video, 0, 0, width, height);
int brightestX = 0;
int brightestY = 0;
float brightestValue = 0; //
I was thinking my OSCp5 message may need to go here using int brightestX and Y as the send message