public void Evaluate(int SpreadMax)
		{
			if (FFirstRun)
			{
				FOutImage[0] = new CVImageLink();
				FFirstRun = false;
			}

			if (FInDevices[0] != FCamera || FInEnabled.IsChanged)
			{
				try
				{
					throw (new Exception("Actually, this node doesn't work yet, sorry"));
					if (FCamera != null)
					{
						Disconnect();
					}
					if (FInEnabled[0])
					{
						FCamera = FInDevices[0];
						if (FCamera != null)
						{
							Connect();
						}
					}
					FOutStatus[0] = "OK";
				}
				catch (Exception e)
				{
					FOutStatus[0] = e.Message;
				}
			}
		}
        public void Connect(CVImageLink input)
        {
            Disconnect();

            FLink = input;

            if (FLink.Allocated)
            {
                FImageAttributesFresh = true;
                FImageFresh           = true;
            }

            AddListeners();
        }
        void SetupOutput(int count)
		{
			FOutImage.SliceCount = count;
			for (int i = 0; i < count; i++)
			{
				FOutImage[i] = new CVImageLink();
			}
		}
		public AsImageDX11Instance()
		{
			Output = new CVImageLink();
		}
		public bool ConnectedTo(CVImageLink input)
		{
			return (input == FLink);
		}
		public void Disconnect()
		{
			RemoveListeners();
			FLink = null;
		}
		public void Connect(CVImageLink input)
		{
			Disconnect();

			FLink = input;

			if (FLink.Allocated)
			{
				FImageAttributesFresh = true;
				FImageFresh = true;
			}

			AddListeners();
		}
		//called when data for any output pin is requested
		public void Evaluate(int SpreadMax)
		{
			if (SpreadMax == 0)
			{
				RemoveListeners();
				return;
			}

			int slice = FPinInSlice[0];
			if (FInput != FPinInInput[slice])
			{
				FInput = FPinInInput[slice];
				AddListeners();
				if (FInput.Allocated)
				{
					UpdateAttributes(FInput.ImageAttributes);
					UpdateImage();
				}
			}
		}
 public bool ConnectedTo(CVImageLink input)
 {
     return(input == FLink);
 }
 public void Disconnect()
 {
     RemoveListeners();
     FLink = null;
 }