Blender as a Vj-ing tool

Game Engine, Players & Web Plug-in, Virtual Reality, support for other engines

Moderators: jesterKing, stiv

F1LT3R
Posts: 0
Joined: Fri Mar 24, 2006 6:26 pm
Location: London, England
Contact:

Handy!

Post by F1LT3R »

Cool, thanks for th info on OSC, I think OSC will enable iMersed to run cross-platform with the recent Blender Versions, as MidiPy needed Python 2.3 and the current versions of Blender arew now running on 2.4.
>>>---[F1LT3R]---|>

RawShark
Posts: 0
Joined: Thu Oct 05, 2006 12:35 am
Location: DE

OSC.py needs to be patched

Post by RawShark »

Hi Julian, Hi Filter,

I experienced soem difficulties with the code from wiretap:
The CallbackManager is basically broken, so that part is basically non-functional, due to bugs in the dispatcher.
I would recommend using another patched version of OSC.py, supplied by:

http://devel.goto10.org/listing.php?rep ... rev=0&sc=0

Here the CallbackManager is working properly.

Thanx Julian, for the general Idea and the files at sysblog.

F1LT3R
Posts: 0
Joined: Fri Mar 24, 2006 6:26 pm
Location: London, England
Contact:

How do I get this to work?

Post by F1LT3R »

Could you give me some instructions on how to get this to work in Blender?

Do I need to download OSC seperately, or is all the code for using sockets already? Cause when I try to inport from OSC and oscAPI, iBlender says it cant find those modules.
>>>---[F1LT3R]---|>

RawShark
Posts: 0
Joined: Thu Oct 05, 2006 12:35 am
Location: DE

Make it Work

Post by RawShark »

Hi F1lt3r,

I have a full installation of Python 2.4, and just dropped the OSC.py under site-packages.
It's working fine with Blender 2.42a.
It may be that you have to set the PYTHONPATH Environment Variable to point to the Python Installation, for Blender to find it.

Other Option would be to put OSC.py in your Blender directory, there it should be found too. But I don't know if the socket module is included with the small Python set shipping with Blender, which maybe the problem you face.

gr33tz

RawShark

F1LT3R
Posts: 0
Joined: Fri Mar 24, 2006 6:26 pm
Location: London, England
Contact:

Tried...

Post by F1LT3R »

Hi I put the code in my blender directory and that didn't work.

Any other way?
>>>---[F1LT3R]---|>

RawShark
Posts: 0
Joined: Thu Oct 05, 2006 12:35 am
Location: DE

Then the other way

Post by RawShark »

Okay,

then its the first option:

grab a full Installation of Python 2.4 from www.python.org for your plattform.
Install it.
Start Blender.
Check the Console.
If something like the following appears:
Checking for installed Python... got it!
all is fine.

If not, set the Environment Variable PYTHONPATH, to point to the directory where you installed Python.
Check again if Blender finds it.

Then copy OSC.py either to the directory lib/site-packages in the Python Installation, or to the blender home.

Now everythin should run fine.

What you are missing propably with the Blender Python is the socket module ... so that is needed for OSC and the examples to work ... the socket module is coming with standard python.

hope this helps

gr33tz

RawShark

RawShark
Posts: 0
Joined: Thu Oct 05, 2006 12:35 am
Location: DE

Some Progress

Post by RawShark »

Hi Folks,

I actually managed to reverse the example Julian has given.
So now its not blender talking to OSC but listening.

In my test, PD is analysing the audio on the sound card, actually only grabbing it, and transferring the signal to messages which i send over OSC to blender.

An Object is moved according to the incoming messages from pd->OSC.

greetings

RawShark

kakdila
Posts: 0
Joined: Fri Jan 28, 2005 2:44 pm
Location: France

Post by kakdila »

hello,
this script is doing the same think that you say:
http://nmedia.avu.cz/~bge/page/scripts.htm
:D

F1LT3R
Posts: 0
Joined: Fri Mar 24, 2006 6:26 pm
Location: London, England
Contact:

Aha!!!

Post by F1LT3R »

:D

Now this looks promising!

No crashes. How do I get data sent and received? Do I have to run two copies of this program?
>>>---[F1LT3R]---|>

RawShark
Posts: 0
Joined: Thu Oct 05, 2006 12:35 am
Location: DE

Here is an example ...

Post by RawShark »

For Julians example, you have to start the blender scene, and start the pd patch.
The PD patch is listening for the incoming messages.

I've made a very simple example the other way around, blender receives messages from pd and moves an object accordingly.

I'm looking around for space to make that available, meanwhile, send me an pm (if you have aim or the like) and i forward an archive with my tests.

greetz

RawShark

jedrzej_s
Posts: 0
Joined: Sat Nov 26, 2005 8:19 pm
Location: Poland

Post by jedrzej_s »

I was trying this OSC... But I didn't know how setup this everything... PD patch ??? Were is it ??? How run it ?

I want have moving object - move based on sound...

Please, somebody should write step by step how used this everything... I'm noob in Blender Game Engine and Python scripts...

P.S. I working on Windows XP.

Regards

RawShark
Posts: 0
Joined: Thu Oct 05, 2006 12:35 am
Location: DE

Examples and Setup

Post by RawShark »

Hi jedrzej_s,

we are currently just testing this. so no tutorials and setup help yet.
But we are working on it.

There might be something in the next days, setup, example and tutorial.

be patient.

gr33tz

RawShark

jedrzej_s
Posts: 0
Joined: Sat Nov 26, 2005 8:19 pm
Location: Poland

Post by jedrzej_s »

@ RawShark
OK. I will wait... This project is very exciting :) !!!

Best regards !!!

RawShark
Posts: 0
Joined: Thu Oct 05, 2006 12:35 am
Location: DE

example and setup online

Post by RawShark »

Hi there,

here now a quick tutorial for testing blenders OSC remote connections to pd.
What the example is doing, is simply moving objects according to OSC messages coming from puredata, which is converting the Audio signal to messages.

Have fun with it.

http://www.keepmyfile.com/download/20d5d01122165

RawShark

jedrzej_s
Posts: 0
Joined: Sat Nov 26, 2005 8:19 pm
Location: Poland

Post by jedrzej_s »

@ RawShark:
I can't download this example file... File don't exist :(.

Post Reply