0

How can I use the IMREAD function with a URL that requires basic authentication in MATLAB 2014a? (not the old matlab). It works well for matlab R2013a as described in this link http://www.mathworks.com/matlabcentral/answers/100103-can-i-perform-basic-authentication-with-urlread-in-matlab but the above method doesn't work for matlab R2014a because it has different coding in its function files. help needed. thanks in advance.

sid
  • 1
  • 1
    Read carefully. The instructions at the the link you gave are for pre-R2013a, which needs to be "hacked" to support this functionality. I have not tried it, but `urlread` in R2013a+ should support this directly – see the `'Authentication'` property. – horchler Nov 16 '14 at 17:11
  • but how to use it for imread?. as imread calls urlwrite function itself , how can i give username password arguements for imread? – sid Nov 16 '14 at 19:08
  • BY using this function i can authenticate a url and copy its content , but how to do this for imread to get ipcamera images. url=urlread('http://192.168.0.1','Authentication','Basic','Username','admin','Password','admin'); – sid Nov 16 '14 at 19:19
  • if i do this , i get error : img = imread('http://192.168.194.20/image/jpeg.cgi','Authentication','Basic','Username','admin','Password','admin'); Error using imread (line 330) Can't read URL "http://192.168.194.20/image/jpeg.cgi". – sid Nov 16 '14 at 19:28

0 Answers0