to write D3DHook_CaptureImageBuffer