Re: [PD] Draw with mouse in GEM
Hi Marie, You could use [gemmouse] to locate your cursor in the gemwin and there's an object that lets you manipulate a mesh at points but I can't remember what it's called. The other object that comes to mind is [model] which allows you to import 3D models from external software, which isn't what you're asking but might be useful. I don't know of a way to draw with polygons in GEM, if there is one I'd love to hear about it too. cheers Richie On Wed, 6 Sep 2017 at 3:09 pm, Jean-Marie Adrien wrote: > Hello > Is there an object to draw a closed shape with the mouse in a GEM window > so that it can be processed afterwards like generic objects such as squares > and circles ? > Thanks > JM > ___ > Pd-list@lists.iem.at mailing list > UNSUBSCRIBE and account-management -> > https://lists.puredata.info/listinfo/pd-list > -- www.glitchpop.com ___ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
[PD] Draw with mouse in GEM
Hello Is there an object to draw a closed shape with the mouse in a GEM window so that it can be processed afterwards like generic objects such as squares and circles ? Thanks JM ___ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
Re: [PD] listing to json port?
you know, this is really ironic, the last hours I've been fiddling around building a very simple Pd websockets server. I finally got it to work but thought: "well, someone must have already done this" and wanted to ask on the list when I saw your mail! this guy's patch is quite crazy, he's even doing the SHA1 hashing of the Sec-Websocket-Key in Pd... where I made an external (using libopenssl). Anyway, I think I'll continue with my work, creating the basic building blocks as externals (which seems more maintainable to me... the pure vanilla solution is a bit complex to say the least) and then sharing the result on the list. websockets are actually pretty exciting. but I'm curious: are there other (better) ways to talk to a browser app with Pd in realtime situations? WebRTC looks quite promising... Christof > Gesendet: Dienstag, 05. September 2017 um 20:09 Uhr > Von: "ub@xdv" > An: pd-list@lists.iem.at > Betreff: Re: [PD] listing to json port? > > On 05.09.2017 11:17, IOhannes m zmoelnig wrote: > > On 09/05/17 02:31, João Pais wrote: > Hello list, > > I wanted to know if it's possible to listen to a port 6437, where some > json messages are coming in. I've seen in my webbrowser that the port is > indeed active, but when I try udpreceive nothing comes out - which > probably means that I'm not getting the process. > >>> > >>> tcpreceive? > >> > >> that would probably work, but I guess the javascript code is necessary > >> to open the port in the first place. Is there a way of Pd opening a html > >> file with that? > > > > i'm not sure i understand the problem. > > you write: > > > >> if it's possible to listen to a port 6437 > > > > the answer is: yes of course. > > there are two things to keep in mind though: > > - you must know whether the protocol is TCP/IP or UDP. without that > > information, the port is pretty useless. > > since this is about JSON and web-technology, chances are high that the > > protocol is indeed TCP/IP, that's why is suggested to use [tcpreceive] > > instead of [udpreceive]. > > - on a given machine, you can only have a single listener listening on a > > given port. so if you have a webbrowser already monitoring the data, you > > can *not* also have Pd doing the same (on the same machine). > > > > in any case, there also might be some confusion about "listening". it > > could well be, that you are trying to talk to a webserver that speaks > > JSON via a REST API. in which case, your Pd patch wouldn't *listen* but > > instead connect to the webserver ([tcpclient]). > there is an external called purest-json (on deken) to deal with > json-REST-APIs, but i have never tried it. > > also it could be json over websockets, which makes a lot of sense for > realtime applications. > there is a very interesting 100%-vanilla-websocket-server patch here: > https://sourceforge.net/projects/websocketserverinapatch/files/ > no json in this one though. > > cheers, > ub > > ___ > Pd-list@lists.iem.at mailing list > UNSUBSCRIBE and account-management -> > https://lists.puredata.info/listinfo/pd-list > ___ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
Re: [PD] listing to json port?
On 05.09.2017 20:09, ub@xdv wrote: > On 05.09.2017 11:17, IOhannes m zmoelnig wrote: >> On 09/05/17 02:31, João Pais wrote: > Hello list, > > I wanted to know if it's possible to listen to a port 6437, where some > json messages are coming in. I've seen in my webbrowser that the port is > indeed active, but when I try udpreceive nothing comes out - which > probably means that I'm not getting the process. tcpreceive? >>> >>> that would probably work, but I guess the javascript code is necessary >>> to open the port in the first place. Is there a way of Pd opening a html >>> file with that? >> >> i'm not sure i understand the problem. >> you write: >> >>> if it's possible to listen to a port 6437 >> >> the answer is: yes of course. >> there are two things to keep in mind though: >> - you must know whether the protocol is TCP/IP or UDP. without that >> information, the port is pretty useless. >> since this is about JSON and web-technology, chances are high that the >> protocol is indeed TCP/IP, that's why is suggested to use [tcpreceive] >> instead of [udpreceive]. >> - on a given machine, you can only have a single listener listening on a >> given port. so if you have a webbrowser already monitoring the data, you >> can *not* also have Pd doing the same (on the same machine). >> >> in any case, there also might be some confusion about "listening". it >> could well be, that you are trying to talk to a webserver that speaks >> JSON via a REST API. in which case, your Pd patch wouldn't *listen* but >> instead connect to the webserver ([tcpclient]). > there is an external called purest-json (on deken) to deal with > json-REST-APIs, but i have never tried it. oops, i missed, that you mentioned that alread. suppose one should really read before posting. sorry. > also it could be json over websockets, which makes a lot of sense for > realtime applications. > there is a very interesting 100%-vanilla-websocket-server patch here: > https://sourceforge.net/projects/websocketserverinapatch/files/ > no json in this one though. > > cheers, > ub > > ___ > Pd-list@lists.iem.at mailing list > UNSUBSCRIBE and account-management -> > https://lists.puredata.info/listinfo/pd-list > ___ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
Re: [PD] listing to json port?
On 05.09.2017 11:17, IOhannes m zmoelnig wrote: > On 09/05/17 02:31, João Pais wrote: Hello list, I wanted to know if it's possible to listen to a port 6437, where some json messages are coming in. I've seen in my webbrowser that the port is indeed active, but when I try udpreceive nothing comes out - which probably means that I'm not getting the process. >>> >>> tcpreceive? >> >> that would probably work, but I guess the javascript code is necessary >> to open the port in the first place. Is there a way of Pd opening a html >> file with that? > > i'm not sure i understand the problem. > you write: > >> if it's possible to listen to a port 6437 > > the answer is: yes of course. > there are two things to keep in mind though: > - you must know whether the protocol is TCP/IP or UDP. without that > information, the port is pretty useless. > since this is about JSON and web-technology, chances are high that the > protocol is indeed TCP/IP, that's why is suggested to use [tcpreceive] > instead of [udpreceive]. > - on a given machine, you can only have a single listener listening on a > given port. so if you have a webbrowser already monitoring the data, you > can *not* also have Pd doing the same (on the same machine). > > in any case, there also might be some confusion about "listening". it > could well be, that you are trying to talk to a webserver that speaks > JSON via a REST API. in which case, your Pd patch wouldn't *listen* but > instead connect to the webserver ([tcpclient]). there is an external called purest-json (on deken) to deal with json-REST-APIs, but i have never tried it. also it could be json over websockets, which makes a lot of sense for realtime applications. there is a very interesting 100%-vanilla-websocket-server patch here: https://sourceforge.net/projects/websocketserverinapatch/files/ no json in this one though. cheers, ub ___ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
Re: [PD] listing to json port?
On 09/05/17 02:31, João Pais wrote: >>> Hello list, >>> >>> I wanted to know if it's possible to listen to a port 6437, where some >>> json messages are coming in. I've seen in my webbrowser that the port is >>> indeed active, but when I try udpreceive nothing comes out - which >>> probably means that I'm not getting the process. >> >> tcpreceive? > > that would probably work, but I guess the javascript code is necessary > to open the port in the first place. Is there a way of Pd opening a html > file with that? i'm not sure i understand the problem. you write: > if it's possible to listen to a port 6437 the answer is: yes of course. there are two things to keep in mind though: - you must know whether the protocol is TCP/IP or UDP. without that information, the port is pretty useless. since this is about JSON and web-technology, chances are high that the protocol is indeed TCP/IP, that's why is suggested to use [tcpreceive] instead of [udpreceive]. - on a given machine, you can only have a single listener listening on a given port. so if you have a webbrowser already monitoring the data, you can *not* also have Pd doing the same (on the same machine). in any case, there also might be some confusion about "listening". it could well be, that you are trying to talk to a webserver that speaks JSON via a REST API. in which case, your Pd patch wouldn't *listen* but instead connect to the webserver ([tcpclient]). in any case, purest-json is a library (available via deken) that facilitates the interaction with JSON-based REST apis quite a lot. you probably should have a look at it. also note that with modern Pd, you can exchange your [tcpreceive]/[udpreceive] with the builtin [netreceive], which as gotten a binary mode ("-b") that will output the same format as [tcpreceive]. fgasdrm IOhannes signature.asc Description: OpenPGP digital signature ___ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list