Montage Links

Anything you want added or changed in future versions of ZoneMinder? Post here and there's a chance it will get in! Search to make sure it hasn't already been requested.
Post Reply
rrichards_gnaps
Posts: 10
Joined: Tue Mar 01, 2005 4:03 pm
Location: Boston Massachusetts, USA

Montage Links

Post by rrichards_gnaps »

Would it be possible to allow each camera image in the montage view have a link to its individual camera view/event list. This way the operator would not have to minimize the montage view to bring up the console to then select the individual camera that they need at any one time.
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

It would be possible, as least for browsers that don't require Cambozola. If it's something you need urgently then it should be pretty easy for you to hack your copy to enable it.

Phil
rrichards_gnaps
Posts: 10
Joined: Tue Mar 01, 2005 4:03 pm
Location: Boston Massachusetts, USA

Post by rrichards_gnaps »

I was thinking maybe the easier way would be to just make the link in the title for each of the camera views in the montage. I'll give it a shot and let you know how It comes out.
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

Yep, that makes sense, though you would of course then have two streams open for the same camera which might be slightly redundant. I'll take a look at this and see if it conflicts with any else first.

Phil
pathway
Posts: 64
Joined: Wed Nov 29, 2006 6:29 pm

Post by pathway »

Just searched and found this thread before I submitted my own: I would love this feature... Even if it closed the Montage to prevent the double-streaming.

Reason: If somebody is monitoring a montage, and sees something going on in camera 4, he/she will want to bring that camera up to it's full resolution for personal monitoring. Currently, the user has to close the montage, and open said camera from the ZM console... it would make sense if a link was already supplied.

Thank you,

--Pathway
User avatar
ammaross
Posts: 61
Joined: Mon Mar 12, 2007 8:34 pm
Location: Utah, USA

Montage Links

Post by ammaross »

I also desired this feature, and so I went ahead and hacked something that works quite well (even in IE).

If you break your ZM for following these directions, it's not my fault! Back up the file we are editing!

Open zm_html_view_montagefeed.php in your zm base dir.
On line 98: (might be different for you, I'll post surrounding code..., the lines with a + starting are the new lines):

Code: Select all

window.setTimeout( "window.location.reload(true)", <?= ZM_WEB_REFRESH_IMAGE*1000 ?> );
<?php
	}
}
+
+function newWindow(Url,Name,Width,Height)
+{
+	var Win = window.open(Url,Name,"resizable,status=no,width="+Width+",height="+Height);
+}
</script>
</head>
<body>
<table width="100%" align="center" border="0" cellspacing="0" cellpadding="0">
<tr><td align="center">
<?php
+print( "<a href=\"javascript: newWindow( '$PHP_SELF?view=watch&mid=".$monitor['Id']."', 'zmWatch".$monitor['Id']."', ".($monitor['Width']+$jws['watch']['w']).", ".($monitor['Height']+$jws['watch']['h'])." );\">" );
+
if ( $mode == "stream" )
{
(Note: The above code has been modified per ZM's suggestion in the following post)

And at the bottom:

Code: Select all

	}
}
?>
+</a>
</td></tr>
</table>
</body>
</html>
This will allow you to click on the feeds to open a monitor window with recent recordings.

I did opt to ommit the reScale() call for width and height, as well as disregarded the check:

Code: Select all

$running && ($monitor['Function'] != 'None') && canView( 'Stream' )
Since for it to be visable in the montage view, everything but the canView( 'Stream' ) would need to be true, and the canView( 'Stream' ) is a user permission check I assume...

Zoneminder, could you review this?
Last edited by ammaross on Tue Nov 13, 2007 7:22 pm, edited 2 times in total.
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

That looks mostly sensible I think though I can;t check it works as my dev machine is dead until it's replacement arrives later in the week.

The only thing that leaps out is that you might want to add the jws array for the window size rather than just use the monitor size as the 'watch' view has a bunch of other stuff in it. So do $monitor['Width'] + $jws['watch']['w'] rather than just $monitor['Width']. See zm_html_view_console.php for an example.
Phil
Post Reply