rescale on the fly

Support and queries relating to all previous versions of ZoneMinder
Locked
User avatar
zmisawesome
Posts: 10
Joined: Sun Aug 30, 2009 12:10 am
Location: Fremont, CA

rescale on the fly

Post by zmisawesome »

Here is a quick and easy script to change the video scale. It is ideal for usage with the montage view. I have a 30" monitor and a 19" monitor connected, so depending on what I am doing in my workspace, I may want all 8 camera's or a couple cameras displayed on either of the monitors. There is a vast difference in available display space on each monitor, so it is handy to be able to change the display resolution size quickly depending on which display and how many cameras in the montage etc.

Here is the bash script:

Code: Select all

#!/bin/bash


echo "
select Name,DefaultScale from Monitors order by Name\G
update Monitors set DefaultScale = $3;
select Name,DefaultScale from Monitors order by Name\G
" 
| mysql -u$1 -p$2 -Dzm

The script would be invoked as:

script.sh mysqluser mysqlpassword scale(between like 100 - 400) depending on your screen size,
then launch montage
run the script, right click in montage, click refresh (or equiv)
{Ubuntu 12.04 Precise x86_64 desktop}{I7 920}{3 channel 12GB}{EVGA X58}{NVIDIA GTX660 1:1600x1200 1:2560x1600 1:1600x1200}{8TB SATA-II}{1000Watt}{ZM:1.25.0 from synaptic package panager}
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Nice technique :D
Locked