Для просмотра видео на сайте использую сл. скрипт :
Код:
<html>
<head>
<META HTTP-EQUIV=Content-Type CONTENT="text/html;">
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="-1">
<TITLE>DCS-950</TITLE>
<script language="JavaScript">
<!--
function start(ddns,pppoe,control,stream)
{
var CookieValue;
document.CSViewer1.SetID("admin");
document.CSViewer1.SetPwd("pass");
document.login_form.f_LOGIN.value=document.CSViewer1.encode();
random_cookie();
document.CSViewer1.SetBasePortNumber(control);
document.CSViewer1.SetStreamPortNumber(stream);
document.CSViewer1.SetHttpPortNumber(port);
document.CSViewer1.SetRemoteIP(ip);
CookieValue=GetCookieValue();
CookieValue=CookieValue.substring(0,CookieValue.length-1);
document.CSViewer1.SetClientCookie(CookieValue);
version = form1.version.value.substr(0,14);
document.CSViewer1.SetFirmwareVer(version);
document.CSViewer1.SetModelID('1100')
document.CSViewer1.ViewerOpen();
document.CSViewer1.AudioStop();
ZoomIn_Open();
}
function leave()
{
document.CSViewer1.ViewerClose();
}
function GetCookieValue()
{
var CookieValue,startof,endof;
CookieValue=document.cookie;
startof=CookieValue.indexOf("=",0);
endof=CookieValue.length;
CookieValue=CookieValue.substring(startof+1,endof) + "f";
return CookieValue;
}
function ZoomIn_Open()
{
document.CSViewer1.PanTilt(0);
document.CSViewer1.ZoomIn(1);
}
function random_cookie()
{
Random_value=Math.floor(Math.random()*1000000000000000);
document.cookie="AGID" + "=" + Random_value;
CookieValue=document.cookie;
start=CookieValue.indexOf("=",0);
endof=CookieValue.length;
CookieValue=CookieValue.substring(start+1,endof);
if (CookieValue.length!=15) {
random_cookie();
} else {
document.login_form.f_CookieValue.value=CookieValue; //get cookie
}
}
-->
</script>
</head>
<body BGCOLOR="c6cbcf" onload="javascript:start('','','5000','5001');" onUnload = "javascript:leave();" leftmargin=0 topmargin=0>
<FORM method=post action=/goform/formLogin target=_top name=login_form>
<input type="hidden" name="f_CookieValue" >
<INPUT type="hidden" name=f_LOGIN >
</form>
<script language="javascript">
<!--
var ip = "85.218.159.135";
var port = location.port;
if (port == "") port = 82;
document.write("<object classid='clsid:EFFDEEEC-F9E1-4461-91D2-DAEB8CC595F1' id='CSViewer1' codebase='http://" + ip +":"+ port+ "/CSViewer.cab#version=2,24,730,2007' width='640' height='480'>");
document.write("</object>");
-->
</script>
<form method="POST" name="form1">
<input type="hidden" name="version" value="1.72.1031.2007">
</form>
</body>
</html>
Мне нужно получить уменьшенное изображение с камеры.
Когда меняю в скрипте width='320' height='240' , сайт показывает верхнюю левую часть изображения.
А как получить уменьшенное ?