implemented capture under macos