Directx screen capture refactored to DLL