CVideoCapture.h 671 B

123456789101112131415161718192021
  1. #pragma once
  2. //#define CINTERFACE
  3. /*
  4. 在c++中以c的方式使用接口时,应当:i->lpVtbl->....,
  5. 但是编译器可能会提示lpVtbl不是相应com接口的成员。
  6. 这是因为在com头文件中有两种定义方式,即c和c++;这两种方式通过 __cplusplus和CINTERFACE来区分。
  7. */
  8. #ifndef _VIDEODATA_CALLBACK_
  9. #define _VIDEODATA_CALLBACK_
  10. typedef void(*LPVideoDataRealCallback)(unsigned char* pRgbData, int size, int width, int height, void* pContext);
  11. #endif
  12. // DXGI方式,设置视频回调函数,并开始捕获视频数据
  13. void* DXGI_VideoSourceStartCapture(int left, int top, int width, int height, LPVideoDataRealCallback pCallback, void* pUser);
  14. // 停止视频数据捕获
  15. bool DXGI_VideoSourceStopCapture(void* pSource);