public bool Disconnect() { var hr = Pin.Disconnect(); ThrowExceptionForHR(hr); InitAMMediaType(); return(hr == 0); }
void onInputTypeChanged(bool wasInput, bool isInput) { var pin = PinCollection.Get("Value"); if (pin != null) { Pin.Disconnect(pin); } PinCollection.Clear(); if (IsInput) { PinCollection.AddInput("Value", Type); } else { PinCollection.AddOutput("Value", Type); } }
void onInputTypeChanged(bool wasInput, bool isInput) { string removeName = (IsInput) ? "OUT" : "IN"; var pin = PinCollection.Get(removeName); if (pin != null) { Pin.Disconnect(pin); } PinCollection.Clear(); if (IsInput) { PinCollection.AddInTransition("IN"); } else { PinCollection.AddOutTransition("OUT"); } }