Jump to content
rrdavid

Embed Axis 7010 Encoder Video Into Website

Recommended Posts

Live Video from Axis Encoder

 

 

var BaseURL = "http://172.20.0.20/";

 

 

var Camera = "";

var ImageResolution = "704x480";var DisplayWidth = "704";var DisplayHeight = "480";

 

// This is the path to the image generating file inside the camera itself

var File = "axis-cgi/mjpg/video.cgi?resolution="+ImageResolution;

// No changes required below this point

if (Camera != "") {File += "&camera=" + Camera;}

var output = "";

if ((navigator.appName == "Microsoft Internet Explorer") &&

(navigator.platform != "MacPPC") && (navigator.platform != "Mac68k"))

{

// If Internet Explorer under Windows then use ActiveX

output = '

output += 'CODEBASE="';

output += BaseURL;

output += 'activex/AMC.cab">';

output += '';

output += '';

output += '';

output += '';

output += '';

output += '';

output += '
Axis Media Control
';

output += 'The AXIS Media Control, which enables you ';

output += 'to view live image streams in Microsoft Internet';

output += ' Explorer, could not be registered on your computer.';

output += '

';

} else {

// If not IE for Windows use the browser itself to display

theDate = new Date();

output = 'output += DisplayHeight;

output += '" WIDTH="';

output += DisplayWidth;

output += '" ALT="Camera Image">';

}

document.write(output);

document.Player.ToolbarConfiguration = "play,+snapshot,+fullscreen";

 

Share this post


Link to post
Share on other sites

also, if you rotated you image at all (ie- landscape to portrait), you'll need to adjust the display height and width:

 

landscape:

var ImageResolution = "704x480";var DisplayWidth = "480";var DisplayHeight = "704";

 

portrait:

var ImageResolution = "704x480";var DisplayWidth = "704";var DisplayHeight = "480";

 

(otherwise, the image will stretch to fit)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×