##C# class for accurate timing.
Modified by - http://stackoverflow.com/a/31612770/3409931
Modified by myself to implement dispatcher task based interface for callbacks.
##C# class for accurate timing.
Modified by - http://stackoverflow.com/a/31612770/3409931
Modified by myself to implement dispatcher task based interface for callbacks.