Hi Thomas,<br><br>I hope someone will find the time to integrate the flext-based externals into<br>
the autobuild structure.<br><br>Sorry but I can't: it's beyond my skills.<br><br>I've got another problem now (ubuntu 9.04 64-bit machine PD 0.42.5):<br><br>in the example buffer-1.pd (py/pyext) there's a strange behaviour:<br>
the message [mul array3 array1 array2< works only on the first half of the array3<br>instead the message [add array3 array1 array2<<br><br>the difference is in th buffer.py:<br><br>def mul(*args):<br> # create buffer objects<br>
# as long as these variables live the underlying buffers are locked<br> c = pyext.Buffer(args[0])<br> a = pyext.Buffer(args[1])<br> b = pyext.Buffer(args[2])<br><br> # slicing causes Python arrays (mapped to buffers) to be created<br>
# note the c[:] - to assign contents you must assign to a slice of the buffer<br> c[:] = a[:]*b[:] <br> <br>def add(*args):<br> c = pyext.Buffer(args[0])<br> a = pyext.Buffer(args[1])<br> b = pyext.Buffer(args[2])<br>
<br> # explicit casting to arrays is also possible<br> c[:] = N.array(a,dtype=N.float32) + N.array(b,dtype=N.float32)<br><br>therefore I think that: <br>- the direct use of the buffer doesn't work well (printing the values give me something like "0 0.123 0 0.234 0 0.345 etc.. " - correct values followed by a zero)<br>
- the casting works well<br><br>My questions are: <br>- am I missing some basic concept?<br>- this behaviour is correct (I don't think so)?<br>- this behaviour is due to the 64-bit?<br><br>Thanks, ciao, Dario.<br><br>
PS: Sorry for the bad english.<br><br><br><div class="gmail_quote">2010/3/11 Thomas Grill <span dir="ltr"><<a href="mailto:gr@grrrr.org">gr@grrrr.org</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">thanks for your kind words. I haven't given up the hope that someday<br>
someone will find the time to integrate the flext-based externals into<br>
the autobuild structure and, consequently, pd-extended.<br>
gr~~~<br>
<br>
2010/3/9 Dario Pedrioli <<a href="mailto:dariopedrioli@gmail.com">dariopedrioli@gmail.com</a>>:<br>
</div><div><div></div><div class="h5">> Thanks a lot Thomas.<br>
><br>
> Now it compile fine!<br>
><br>
> I pick the occasion to say that your work for pd (flext, pool, py, etc...)<br>
> is fantastic. Many many many thanks!<br>
><br>
> ciao, Dario<br>
><br>
> 2010/3/9 Thomas Grill <<a href="mailto:gr@grrrr.org">gr@grrrr.org</a>><br>
>><br>
>> Hi Dario,<br>
>> please check out py from svn and try again.<br>
>> gr~~~<br>
>> Am 09.03.2010 um 09:48 schrieb Dario Pedrioli:<br>
>><br>
>> Hi all,<br>
>><br>
>> I'm trying to compile py/pyext on ubuntu 9.04 64-bit machine PD 0.42.5<br>
>><br>
>> with flext rev 3659 I've got no problems.<br>
>><br>
>> with flext rev 3723 I've got the error below:<br>
>><br>
>> ubuntu@ubuntu-desktop:~/pd/<br>
>> source/py_3723$ sh ../flext_3723/build.sh pd gcc<br>
>> make -f ../flext_3723/buildsys/gnumake-sub.mak PLATFORM=lnx RTSYS=pd<br>
>> COMPILER=gcc BUILDPATH=../flext_3723/buildsys/ PKGINFO=package.txt<br>
>> BUILDCLASS=ext USRCONFIG=config.txt USRMAKE=build/gnumake-lnx-gcc.inc<br>
>> TARGETMODE=release TARGETTYPE=multi THREADED=1 _build_<br>
>> make[1]: ingresso nella directory ?/home/ubuntu/pd/source/py_3723?<br>
>> mkdir -p pd-linux/release-multi/<br>
>> g++ -c -pthread -fPIC -fvisibility-inlines-hidden -DPY_EXPORTS<br>
>> -DPY_NUMPY -DPY_USE_GIL -DNDEBUG -DFLEXT_THREADS -DFLEXT_SYS=2 -DPD<br>
>> -I/usr/include/python2.6 -I/home/ubuntu/pd/source/pd-0.42-5/src<br>
>> -I/usr/local/include/stk -I/usr/local/include/sndobj<br>
>> -I/usr/local/include/flext source/pybuffer.cpp -o<br>
>> pd-linux/release-multi/pybuffer.opp<br>
>> source/pybuffer.cpp:154: warning: deprecated conversion from string<br>
>> constant<br>
>> to ?char*?<br>
>> source/pybuffer.cpp: In function ?int buffer_ass_slice(PyObject*,<br>
>> Py_ssize_t, Py_ssize_t, PyObject*)?:<br>
>> source/pybuffer.cpp:406: error: no matching function for call to<br>
>> ?flext_multi::CopySamples(flext_multi::buffer::Element*, t_sample*, int&)?<br>
>> /usr/local/include/flext/flsupport.h:425: note: candidates are: static<br>
>> void<br>
>> flext_multi::CopySamples(t_sample*, const t_sample*, int)<br>
>><br>
>> Someone can help?<br>
>><br>
>> PS: I'm trying rev 3723 because of 64-bit buffer patch (<br>
>><br>
>> <a href="http://markmail.org/message/6v52tlvllwvcwilj#query:+page:1+mid:6hpplp4wfi4u6vkc+state:results" target="_blank">http://markmail.org/message/6v52tlvllwvcwilj#query:+page:1+mid:6hpplp4wfi4u6vkc+state:results</a><<a href="mailto:gr@grrrr.org">gr@grrrr.org</a>><br>
>> )<br>
>> My goal is to handle arrays directly in python, but with the rev 3659 I'm<br>
>> only get half of the array inside py (the other half is set to zero). Am I<br>
>> on the right way to fix my problem?<br>
>><br>
>> Thanks and ciao!<br>
>> _______________________________________________<br>
>> Pd-dev mailing list<br>
>> <a href="mailto:Pd-dev@iem.at">Pd-dev@iem.at</a><br>
>> <a href="http://lists.puredata.info/listinfo/pd-dev" target="_blank">http://lists.puredata.info/listinfo/pd-dev</a><br>
>><br>
><br>
><br>
<br>
<br>
<br>
</div></div><div><div></div><div class="h5">--<br>
Thomas Grill<br>
<a href="http://grrrr.org" target="_blank">http://grrrr.org</a><br>
</div></div></blockquote></div><br>