translate('auto'), '100%' => '100%', '160px' => '160px', '320px' => '320px', '352px' => '352px', '640px' => '640px', '1280px' => '1280px', '1920px' => '1920px' ); $heights = array( 'auto' => translate('auto'), '240px' => '240px', '480px' => '480px', '720px' => '720px', '1080px' => '1080px', ); $monitors = array(); $monitor_index = 0; foreach ($displayMonitors as &$row) { if ($row['Function'] == 'None') continue; if ($mid and ($row['Id'] == $mid)) $monitor_index = count($monitors); $monitors[] = new ZM\Monitor($row); if (!isset($widths[$row['Width'].'px'])) { $widths[$row['Width'].'px'] = $row['Width'].'px'; } if (!isset($heights[$row['Height'].'px'])) { $heights[$row['Height'].'px'] = $row['Height'].'px'; } unset($row); } # end foreach Monitor if (!$mid) { $mid = $monitors[0]->Id(); $monitor_index = 0; } if (!visibleMonitor($mid)) { $view = 'error'; return; } $monitor = new ZM\Monitor($mid); $nextMid = ($monitor_index == count($monitors)-1) ? $monitors[0]->Id() : $monitors[$monitor_index+1]->Id(); $cycle = isset($_REQUEST['cycle']) and ($_REQUEST['cycle'] == 'true'); $showCycle = $cycle; if (isset($_COOKIE['zmCycleShow'])) { $showCycle = $_COOKIE['zmCycleShow'] == 'true'; } #Whether to show the controls button $showPtzControls = ( ZM_OPT_CONTROL && $monitor->Controllable() && canView('Control') && $monitor->Type() != 'WebSite' ); $options = array(); if (!empty($_REQUEST['mode']) and ($_REQUEST['mode']=='still' or $_REQUEST['mode']=='stream')) { $options['mode'] = validHtmlStr($_REQUEST['mode']); } else if (isset($_COOKIE['zmWatchMode'])) { $options['mode'] = $_COOKIE['zmWatchMode']; } else { $options['mode'] = canStream() ? 'stream' : 'still'; } if (!empty($_REQUEST['maxfps']) and validFloat($_REQUEST['maxfps']) and ($_REQUEST['maxfps']>0)) { $options['maxfps'] = validHtmlStr($_REQUEST['maxfps']); } else if (isset($_COOKIE['zmWatchRate'])) { $options['maxfps'] = $_COOKIE['zmWatchRate']; } else { $options['maxfps'] = ''; // unlimited } $period = ZM_WEB_REFRESH_CYCLE; if (isset($_REQUEST['period'])) { $period = validInt($_REQUEST['period']); } else if (isset($_COOKIE['zmCyclePeriod'])) { $period = validInt($_COOKIE['zmCyclePeriod']); } if (isset($_REQUEST['scale'])) { $scale = validInt($_REQUEST['scale']); } else if ( isset($_COOKIE['zmWatchScale'.$mid]) ) { $scale = $_COOKIE['zmWatchScale'.$mid]; } else { $scale = $monitor->DefaultScale(); } $options['scale'] = $scale; if (isset($_REQUEST['width'])) { $options['width'] = validInt($_REQUEST['width']); } else if ( isset($_COOKIE['zmCycleWidth']) and $_COOKIE['zmCycleWidth'] ) { $options['width'] = $_COOKIE['zmCycleWidth']; } else { $options['width'] = ''; } if (isset($_REQUEST['height'])) { $options['height'] =validInt($_REQUEST['height']); } else if (isset($_COOKIE['zmCycleHeight']) and $_COOKIE['zmCycleHeight']) { $options['height'] = $_COOKIE['zmCycleHeight']; } else { $options['height'] = ''; } $connkey = generateConnKey(); if ( $monitor->JanusEnabled() ) { $streamMode = 'janus'; } else { $streamMode = getStreamMode(); } noCacheHeaders(); xhtmlHeaders(__FILE__, $monitor->Name().' - '.translate('Feed')); ?> Status() != 'Connected' and $monitor->Type() != 'WebSite' ) { echo '
Monitor is not capturing. We will be unable to provide an image
'; } ?>
>
Type() != 'WebSite') { echo $monitor->getMonitorStateHTML(); ?>
StreamReplayBuffer() != 0) { ?> StreamReplayBuffer() != 0) { ?>
Type() != 'WebSite' ?>
Type() != 'WebSite') ) { ?>
JanusEnabled() ) { ?>