hi,
I got these two cams and I found out that one can get a snapshot from it using this url:
http://<ip>/snapshot.jpg?account=<user>&password=<password>
this works for both cams and it works fine in any browser and via wget on console.
If I set zoneminder's monitor to use a snapshot I downloaded before it shows that if you open the monitor view. So far the cameras seem to deliver correct jpegs.
Thus if you set the monitor to be of type remote with the ip as url
and the rest as path
and corret image size and colour depth all you get to see is a black image.
If you enable extra debug the debug log says that it got an unrecognised content type " and as a follow up of that its unable to capture this monitor.
And this is what I don't understand..wget and any browser detects that this is of content: image/jpeg or something like that and dls it or displays it correctly. So why on earth does zoneminder run into such issues here?
In fact the reason is that the camera doesn't ship the correct content type. Browser seem to ignore this and though display the pic while Zonemidner doesn't. The only way to work around this was to patch and recompile Zoneminder. Since a colleague of mine did that I don't yet have any docs about it.
However I could provide a debian package for 64bit systems (built on ubuntu 8.10 server 64bit) if anyone needs it.
Since our system is 64bit there currently is no 32bit package.
cheers
Sebastian
cheers
Seastian
[SOLVED]Aviosys 9060-I and Rimax IPcam 7100
well...
unfortunately I don't have a patch for zm. I could as I wrote only provide you with a x68 debian package of it currently.
If it helps and you provide me with an emal address I will send you a .diff file.
This is a generic and annoying problem which is not a fault of zoneminder or its developers! Its the fault of the manufacturers of ip camers who almost all keep encapsulating their images in activex *brrrrr* or java *shuffle* :/
Only a few cams do officially provide you with the option to get an unencapsulated image or even a jpeg stream.
Now this is a somewhat dirty hack which might cause security issues. So use it at your own risk...
cheers
Sebastian
If it helps and you provide me with an emal address I will send you a .diff file.
This is a generic and annoying problem which is not a fault of zoneminder or its developers! Its the fault of the manufacturers of ip camers who almost all keep encapsulating their images in activex *brrrrr* or java *shuffle* :/
Only a few cams do officially provide you with the option to get an unencapsulated image or even a jpeg stream.
Now this is a somewhat dirty hack which might cause security issues. So use it at your own risk...
cheers
Sebastian
I solved the problem thanks to sw2090. Here is the diff code:
Best regards,
aNt1X
Code: Select all
--- zm_remote_camera_http.cpp.old 2009-07-08 11:34:38.000000000 +0200
+++ zm_remote_camera_http.cpp 2009-07-08 11:35:27.000000000 +0200
@@ -295,7 +295,7 @@
}
}
- if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) )
+ if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) || !*content_type )
{
// Single image
mode = SINGLE_IMAGE;
@@ -395,7 +395,7 @@
}
case CONTENT :
{
- if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) )
+ if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) || !*content_type )
{
format = JPEG;
}
@@ -728,7 +728,7 @@
}
}
- if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) )
+ if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) || !*content_type )
{
// Single image
mode = SINGLE_IMAGE;
@@ -895,7 +895,7 @@
}
case CONTENT :
{
- if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) )
+ if ( !strcasecmp( content_type, "image/jpeg" ) || !strcasecmp( content_type, "image/jpg" ) || !*content_type )
{
format = JPEG;
}
aNt1X
Last edited by aNt1X on Wed Jul 08, 2009 9:51 am, edited 1 time in total.
yo
thx to marco for figuring it out.
keep in mind that the patch somewhat deactivates zm's http header check which can cause security issues. Thus it seems to be the only way to make it work unless the ip cam manufactures stop making proprietary apis in their firmwares....
cheers
Sebastian
keep in mind that the patch somewhat deactivates zm's http header check which can cause security issues. Thus it seems to be the only way to make it work unless the ip cam manufactures stop making proprietary apis in their firmwares....
cheers
Sebastian
Sorry. I've been reading the thread and I don't really understand it (... yes I'm newbie and I don't speak English very well ...)
I have a Rimax 7100 that doesn't work with ZoneMinder v1.24.2. I see that it's a problem with the camera and I have to use some code to fix it, but... Which file (index.php, functions.php...) should I supposed to put the code in?
Thanks in advance. I'm really lost :S.
I have a Rimax 7100 that doesn't work with ZoneMinder v1.24.2. I see that it's a problem with the camera and I have to use some code to fix it, but... Which file (index.php, functions.php...) should I supposed to put the code in?
Thanks in advance. I'm really lost :S.