Load Image from URL fails

Hi, I have a still image from an IP cam in the following URL:
http://172.16.20.210/media/cam0/still.jpg?res=max

I’m just trying to load it like this:

  
im1.loadImage("[http://172.16.20.210/media/cam0/still.jpg?res=max"](http://172.16.20.210/media/cam0/still.jpg?res=max"))  

And I get this errors:

[error] unable to guess format
[error] Couldn’t load image from http://172.16.20.210/media/cam0/still.jpg?res=max
[error] Error while loading image
[warning] ofGLRenderer::draw(): texture is not allocated

Could it be a problem because of the URL not ending in .jpg?

I get a timeout on that url but to load an image from a URL you should check the ‘imageLoaderWebExample’ in the examples/graphics dir in your OF folder structure. This will help you manage the server response.

Thanks for the reply. My URL is from my local network. I have an IP camera that gives this still image URL. Testing it with the example I get the following message:

401 Unauthorized,

I’ve also tried adding user and password in front of the IP with no luck. I can access it from my web browser with no problem.

are you logged into something with your browser? I would talk to your network admin to find out the auth procedure to access the video feed.

The camera does have user and password, both admin. so I can access in my broser in this both ways:

http://172.16.20.210/media/cam0/still.jpg?res=max
http://admin:admin@172.16.20.210/media/cam0/still.jpg?res=max

I’m trying

  
ofLoadURLAsync("[http://admin:admin@172.16.20.210/media/cam0/still.jpg?res=max","tsingy-forest"](http://admin:admin@172.16.20.210/media/cam0/still.jpg?res=max","tsingy-forest"));  

In the example you mentioned.