ipcam-view icon indicating copy to clipboard operation
ipcam-view copied to clipboard

after camera messoa 640X480 Error the Malformed \uxxxx encoding

Open crgg opened this issue 6 years ago • 11 comments

java.lang.IllegalArgumentException: Malformed \uxxxx encoding.
    at java.util.Properties.loadConvert(Properties.java:569)
    at java.util.Properties.load0(Properties.java:391)
    at java.util.Properties.load(Properties.java:342)
    at CameraMJPeg.MjpegInputStreamDefault.parseContentLength(MjpegInputStreamDefault.java:59)
    at CameraMJPeg.MjpegInputStreamDefault.readMjpegFrame(MjpegInputStreamDefault.java:71)
    at CameraMJPeg.MjpegViewDefault$MjpegViewThread.run(MjpegViewDefault.java:141)

Show the image perfect after couple sec release this error

crgg avatar Jun 21 '18 15:06 crgg

private int parseContentLength(byte[] headerBytes) throws IOException, NumberFormatException { ByteArrayInputStream headerIn = new ByteArrayInputStream(headerBytes); Properties props = new Properties(); props.load(headerIn); // here the error return Integer.parseInt(props.getProperty(CONTENT_LENGTH)); }

crgg avatar Jun 21 '18 15:06 crgg

Hi, thanks for reporting the issue, is the url public or private? Is hard to test it without a proper example. Are you sure that the format is MJPEG? Several user in the past reported similar issue but the stream format wasn't correct

niqdev avatar Jun 21 '18 18:06 niqdev

yes, I'm using another desktop application that only accepts MJEG and works well. is url internal network

crgg avatar Jun 23 '18 01:06 crgg

url is private working well for couple minutes

crgg avatar Jun 23 '18 01:06 crgg

this url public http://71.201.238.186/ipcam/mjpegcif.cgi

crgg avatar Jun 23 '18 01:06 crgg

ONLY in this resolution working well (352x240)

crgg avatar Jun 23 '18 02:06 crgg

Are you happy with the lower resolution? Would that make the difference on your mobile app? It looks like is a very specific edge case, not sure how can i help on this

niqdev avatar Jun 23 '18 10:06 niqdev

Yes, this the problem must be 640x480. the lower is 352x240. camera are running in 640x480 I can change this. yes you can help , how to I'm can change via code this resolution.

crgg avatar Jun 23 '18 16:06 crgg

You can't change the resolution via code, usually you should be able to pass it as parameter to your url. But you need to look at the docs of your camera, for example set the url to something like http://71.201.238.186/ipcam/mjpegcif.cgi?size=XXX

niqdev avatar Jun 25 '18 16:06 niqdev

hi, sorry me again but this option

public class MjpegViewDefault extends AbstractMjpegView { @Override public void setResolution(int width, int height) { throw new UnsupportedOperationException("not implemented"); } }

crgg avatar Jul 03 '18 12:07 crgg

Hi, can you please provide more details?

niqdev avatar Jul 03 '18 19:07 niqdev