Twitch SDK (Internal)
icvpixelbuffervideoframereceiver.h
Go to the documentation of this file.
1 /********************************************************************************************
2 * Twitch Broadcasting SDK
3 *
4 * This software is supplied under the terms of a license agreement with Twitch Interactive, Inc. and
5 * may not be copied or used except in accordance with the terms of that agreement
6 * Copyright (c) 2012-2016 Twitch Interactive, Inc.
7 *********************************************************************************************/
8 
9 #pragma once
10 
14 
15 #include <CoreVideo/CoreVideo.h>
16 
17 #include <memory>
18 
19 namespace ttv
20 {
21  namespace broadcast
22  {
23  class ICVPixelBufferVideoFrameReceiver;
24  }
25 }
26 
27 
32 {
33 public:
34  typedef std::function<void(const CVPixelBufferRef buffer)> UnlockFunc;
35 
39  virtual TTV_ErrorCode PackageFrame(const CVPixelBufferRef buffer, uint64_t timestamp, UnlockFunc unlockCallback, std::shared_ptr<VideoFrame>& result) = 0;
40 
41  static ReceiverTypeId GetReceiverTypeId() { static int typeId = 0; return reinterpret_cast<ReceiverTypeId>(&typeId); }
42 };
static ReceiverTypeId GetReceiverTypeId()
Definition: icvpixelbuffervideoframereceiver.h:41
JSON (JavaScript Object Notation).
Definition: adsapi.h:16
virtual TTV_ErrorCode PackageFrame(const CVPixelBufferRef buffer, uint64_t timestamp, UnlockFunc unlockCallback, std::shared_ptr< VideoFrame > &result)=0
uint32_t TTV_ErrorCode
Definition: errortypes.h:30
Definition: ivideoframereceiver.h:25
std::function< void(const CVPixelBufferRef buffer)> UnlockFunc
Definition: icvpixelbuffervideoframereceiver.h:34
size_t ReceiverTypeId
Definition: ivideoframereceiver.h:28
Definition: icvpixelbuffervideoframereceiver.h:31