patricksebastien / libpd4unity

libpd for unity 3d
101 stars 20 forks source link

How to use Externals #11

Open LaVerbenaElectronica opened 9 years ago

LaVerbenaElectronica commented 9 years ago

Hi, I don't get external objects to work. I place the .c files inside Assets > StreamingAssets > PDAssets folder, but the objects doesn't work on my patches. Do i miss something? Should I place a compiled .o file instead? I would appreciate some more information about this. I am working with Unity 5 on Mac OsX.

Thanks. Jara.

patricksebastien commented 9 years ago

You need to include the external (c file) in the compilation of libpd; call the externalName_setup() function and use this compiled version of libpd.

You can try to place the compiled external (.pd_darwin I think on Mac) in Assets > StreamingAssets > PdAssets as stated here: http://twobigears.com/labs/unity-and-libpd/

joncorcu commented 9 years ago

Hi, I've been trying to work with the communication system of the examples, but unity crashes a lot. So I´m trying to find a way to introduce a OSC library. That would be great, working with unity and PD at the same time avoiding crashes and compile the application when ready. I am working with Unity 4.6 on Windows 8.

Thanks

mjattie commented 8 years ago

Hello, I have a fairly simple question but I just can't seem to figure it out.

I'm using the expr object in PD and want to use it in my unity project, but when I'm building the libpdcsharp library with this command: (make libpdcsharp UTIL=true EXTRA=true) it should include the expr object right? (because the expr object is in EXTRA) When I rename the csharplib.dylib tocsharplib.bundle and replace the files in my unity project, it still doesn't use the expr object I used. PD vanilla works fine.

in the above comment you are saying: call the externalName_setup() function and use this compiled version of libpd. I'm not sure how to do this. I hope you are willing to help! :) (working with unity 5 on mac)