While trying to register a method to an AreaCaptureDevice, I had to place a parameter in the method, in order to be able to register it:
And now I also want to call this function inside OnBegin() and other places, but I need to pass this Agent parameter, and I don’t really have (or need it) in the context of that code.
How should I proceed in this kind of situation? Should I make 2methods, one just for registering and one for generic situations? Or is there an easy way to get this agent as parameter, even trough I don’t have or need it at that moment?