Is there any way to load an image from a URL into pd, to be mapped onto pix_image or something of the sort?
I've spent a lot of time looking around, and I've only found info on sending and receiving strings.
-
Load image from web
-
i don't know if that is possibile using native pd objects but i did it once using the [shell] object. from pd you can run your php script or whatever to find and download the image then load that in gem using [pix_image]
-
That's a great idea. After trying the wget command through shell, I got no result. Using popen at least got me a result in a print, but the image was never downloaded (works when I do it straight from a shell). No idea why. Super frustrating.
Heres my patch:
[wget -nd -P ~/desktop/crawl_test -H -p -r http://a0.twimg.com/profile_images/3365275252/7704a443ac1299704c23abd4e43ce449_normal.jpeg(
|
|
[popen]
| |
| [print done]
[print]And the debug monitor says:
sending wget -nd -P ~/desktop/crawl_test -H -p -r http://a0.twimg.com/profile_images/3365275252/7704a443ac1299704c23abd4e43ce449_normal.jpeg
done: bangbut my designated save folder is still empty
-
have you tried with curl?
curl http://a0.twimg.com/profile_images/3365275252/7704a443ac1299704c23abd4e43ce449_normal.jpeg -o image.jpeg
if i send this message to [shell] it works as expected. be aware that if you don't set a different path the file will be downloaded in your root folder.
-
it is possible to c# load an image from url , i am certain about this. while your other questions i cannot answer you. check the codes yourself.
-
namespace RE__Test
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}private void button1_Click(object sender, EventArgs e)
{
REImage reImage = REFile.GetImageFromURL("http://www.rasteredge.com/Sample.png", new PNGDecoder());REFile.SaveImageFile(reImage, "c:/reimage.png", new PNGEncoder());
}
}
}
i heard that these codes are helpful while you are load image. hope it helps you. i also have codes to load image from file, let me know if you need those sample codes and trial packagte.