Unity 4.1 Dual Display not working

I found this thatțs suppose to work with two cameras and AppleTv airplay.

using UnityEngine;
using System.Collections;
 
 
namespace UnityAssets
{
	public class DualDisplay : MonoBehaviour
	{
		public Camera mainCamera, controlsCamera;
		public bool autoEnable = true;
 
 
		public bool Available
		{
			get
			{
				return enabled && Display.displays.Length > 1;
			}
		}
 
 
		public bool Active
		{
			get
			{
				return enabled && controlsCamera.enabled;
			}
			set
			{
				if (!value || !Available)
				{
					controlsCamera.enabled = false;
 
					controlsCamera.SetTargetBuffers (Display.main.colorBuffer, Display.main.depthBuffer);
					mainCamera.SetTargetBuffers (Display.main.colorBuffer, Display.main.depthBuffer);
				}
				else
				{
					Display secondDisplay = Display.displays[1];
 
					mainCamera.SetTargetBuffers (secondDisplay.colorBuffer, secondDisplay.depthBuffer);
					controlsCamera.SetTargetBuffers (Display.main.colorBuffer, Display.main.depthBuffer);
 
					controlsCamera.enabled = true;
				}
			}
		}
 
 
		void Reset ()
		{
			mainCamera = Camera.main;
		}
 
 
		void Start ()
		{
			if (mainCamera == null || controlsCamera == null)
			{
				Debug.LogError ("DualDisplay missing a camera reference");
				Destroy (this);
				return;
			}
 
			controlsCamera.enabled = false;
		}
 
 
		void Update()
		{
			if (Available)
			{
				if (autoEnable)
				{
					Active = true;
				}
			}
			else
			{
				Active = false;
			}
		}
	}
}

I am not that good at C# but can anyone take a look and see if therețs anything else we should do to make this work in 4.1? Thanks!

I’m trying to do this with my iPAD 2, mirroring is on. i have a debug string on the screen showing “Display.displays.Length” which always returns 1. any ideas why or what should i do?

Are you sure you have Unity Pro? Since Air Play only works on Unity Pro.