We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › PImages call API feeds
Page Index Toggle Pages: 1
PImages call API feeds? (Read 666 times)
PImages call API feeds?
Dec 11th, 2009, 7:09pm
 
Hi, I'm fairly new to this, and I really need some help please with my program.  My processing code at the moment works with the Twitter API and the API portion is working, as I could see the feed being called in the black portion of the processing application, but I have no idea how to assign them to an image.  

Is it possible for an image in processing to call a random API feed every time the image is being clicked?  If so, how would you go about that?  

In addition, I have posted what I'm going to ask next in the Integration forum.  Would it be possible to do this using Javascript as well?  The calling of API feeds I mean and the linking them to images?  

Thanks.
Re: PImages call API feeds?
Reply #1 - Dec 12th, 2009, 2:16am
 
Click on image: check that mouse coordinates are within the bounds of the image. Plenty of examples in the forum...

Using Web API on applet: you need to sign the applet (IIRC) so it can access a Web site different of the one serving the applet.
JavaScript is restricted with regard to cross-site access, I don't recall if there is a way to workaround such restriction (I don't think so). I know browser coders study a way to do it safely (for the user).
Page Index Toggle Pages: 1