Corrupt JPEG data

Forum for questions and support relating to the 1.24.x releases only.
Post Reply
snugle
Posts: 2
Joined: Sat Feb 07, 2009 5:27 pm

Corrupt JPEG data

Post by snugle » Sat Feb 07, 2009 5:36 pm

hello,

i set up a new zm machine with following specs.

core2, 2gb ram, suse 11 64bit, 2 arecont vision ip cams

apache2, php5.25, mysql5, zm1.24 (with 1.23.3 the same behavior)

I have the problem now that zmc brings without break a jpeg error under /var/log/messages.

: ...zmc_m2[]: WAR [Corrupt JPEG data: 12 extraneous bytes before marker 0xd9]

Bytecount is different but marker 0x9d is always the same.

Machine and cams are ok, zm is working fine, machine load is heavy because of the jpeg warnings, imagequality is absolute perfect.

Where can I start debugging, any Idea ???

Thanx for your answer and best regards...

ps: sorry for my english, i hope it is understandable.

snugle
Posts: 2
Joined: Sat Feb 07, 2009 5:27 pm

Post by snugle » Sun Feb 08, 2009 12:27 pm

hello again,

after a long night, reading many threads and studing code I found a first solution.

In file zm_jpeg.c I disabled content of function

void zm_jpeg_emit_message( j_common_ptr cinfo, int msg_level ); (Line 48-76)
.

This stops error reporting from zmc. That don't solve the problem why jpeg's are corrupt,
but helps to reduce machine load.

I find many threads with similare problems so that I think it would be helpful to
add a config value for deactivating jpeg error checking.

Have a nice day...

hrabe
Posts: 47
Joined: Tue Apr 12, 2005 12:01 am

Post by hrabe » Mon Feb 09, 2009 8:16 pm

Try upgrade camera firmware... I had the same problem with panasonic camera.

User avatar
dvarapala
Posts: 53
Joined: Sat Nov 06, 2010 2:30 pm

Re: Corrupt JPEG data

Post by dvarapala » Mon Jul 04, 2011 3:48 pm

I, too, have an Arecont Vision IP camera that exhibits the same problem. It appears there is a bug in the Arecont MJPEG encoder that puts some extra junk into each frame right before the end-of-image marker. libjpeg complains about this, and zmc dutifully relays the error message from libjpeg to the log, hammering my disk with multiple error messages every second.

The workaround proposed earlier int his thread does get rid of the log hammering, but at the risk of filtering other (perhaps important) error messages.

The workaround I chose was to modify the libjpeg source to ignore the specific error while allowing other error messages to still be reported. Look in the jdmarker.c source file, in the next_marker() function. I added an if statement to suppress the error message when the next marker is 0xd9.

The true solution, of course, is for Arecont Vision to fix their firmware. ;)

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests