]> git.sesse.net Git - casparcg/blob - BluefishSDK_V5_10_0_42/Inc/BlueC_Api.h
ntsc-audio-exp: Better synchronization of audio-cadence.
[casparcg] / BluefishSDK_V5_10_0_42 / Inc / BlueC_Api.h
1 // The following ifdef block is the standard way of creating macros which make exporting \r
2 // from a DLL simpler. All files within this DLL are compiled with the BLUEC_API_EXPORTS\r
3 // symbol defined on the command line. this symbol should not be defined on any project\r
4 // that uses this DLL. This way any other project whose source files include this file see \r
5 // BLUEC_API_API functions as being imported from a DLL, whereas this DLL sees symbols\r
6 // defined with this macro as being exported.\r
7 #ifdef BLUEFISH_EXPORTS\r
8 #define BLUE_CSDK_API __declspec(dllexport)\r
9 #else\r
10 #define BLUE_CSDK_API __declspec(dllimport)\r
11 #endif\r
12 #include "BlueTypes.h"\r
13 #include "BlueDriver_p.h"\r
14 \r
15 #define IGNORE_SYNC_WAIT_TIMEOUT_VALUE  (0xFFFFFFFF)\r
16 \r
17 \r
18 #pragma once\r
19 \r
20 //\r
21 //typedef enum _blue_video_engine_flags\r
22 //{\r
23 //      BLUE_CAPTURE_PREVIEW_ON_OUTPUT_CHANNEL_A=0x1,\r
24 //      BLUE_CAPTURE_PREVIEW_ON_OUTPUT_CHANNEL_B=0x2,\r
25 //      BLUE_CAPTURE_PREVIEW_ON_OUTPUT_CHANNEL_C=0x3,\r
26 //      BLUE_CAPTURE_PREVIEW_ON_OUTPUT_CHANNEL_D=0x4\r
27 //}blue_video_engine_flags;\r
28 //\r
29 typedef enum _EBLUEDMA_DIRECTION\r
30 {\r
31         BLUEDMA_WRITE=0,\r
32         BLUEDMA_READ=1,\r
33         BLUEDMA_INVALID=3\r
34 }EBLUEDMA_DIRECTION;\r
35 \r
36 typedef struct _EBlueConnectorPropertySetting\r
37 {\r
38         EBlueVideoChannel channel;\r
39         EBlueConnectorIdentifier connector;\r
40         EBlueConnectorSignalDirection   signaldirection;\r
41         EBlueConnectorProperty propType;\r
42         VARIANT Value;\r
43 }EBlueConnectorPropertySetting;\r
44 \r
45 \r
46 typedef struct _blue_card_property\r
47 {\r
48         EBlueVideoChannel       video_channel;\r
49         EBlueCardProperty       prop;\r
50         VARIANT  value;\r
51 }blue_card_property;\r
52 \r
53 \r
54 extern "C" {\r
55 BLUE_CSDK_API unsigned int blue_device_count();\r
56 BLUE_CSDK_API void * blue_attach_to_device(int device_id);\r
57 BLUE_CSDK_API BERR blue_detach_from_device(void ** device_handle);\r
58 \r
59 //\r
60 //BLUE_CSDK_API BERR blue_set_video_engine(             void * device_handle,\r
61 //                                                                                      EBlueVideoChannel video_channel,\r
62 //                                                                                      EEngineMode * video_engine,\r
63 //                                                                                      BLUE_UINT32 video_engine_flag);\r
64 BLUE_CSDK_API BERR blue_video_dma(                      void * device_handle,\r
65                                                                                         EBLUEDMA_DIRECTION      dma_direction,\r
66                                                                                         void * pFrameBuffer,\r
67                                                                                         BLUE_UINT32 FrameSize,\r
68                                                                                         BLUE_UINT32 BufferId,\r
69                                                                                         BLUE_UINT32 * dma_bytes_transferred,\r
70                                                                                         BLUE_UINT32 CardFrameOffset,\r
71                                                                                         OVERLAPPED      * pAsync\r
72                                                                         );\r
73 \r
74 \r
75 /*\r
76         functions used to set the card property . This includes the video property \r
77         and the video connection/routing property.\r
78 */\r
79 BLUE_CSDK_API BERR      blue_set_video_property(                void * device_handle,\r
80                                                                                         BLUE_UINT32 prop_count,\r
81                                                                                         blue_card_property * card_prop);\r
82 \r
83 BLUE_CSDK_API BERR      blue_get_video_property(                void * device_handle,\r
84                                                                                         BLUE_UINT32 prop_count,\r
85                                                                                         blue_card_property * card_prop);\r
86 \r
87 BLUE_CSDK_API BERR      blue_get_connector_property(void * device_handle,\r
88                                                                         BLUE_UINT32 VideoChannel,\r
89                                                                         BLUE_UINT32 *settingsCount,     // In: element count of settings array\r
90                                                                                                                                 // Out: if settings is non-NULL, number of valid elements\r
91                                                                                                                                 // Out: if settings is NULL, number of elements required\r
92                                                                         EBlueConnectorPropertySetting *settings // Caller allocates/frees memory\r
93                                                                         );\r
94 \r
95 BLUE_CSDK_API BERR      blue_set_connector_property(\r
96                                                                                         void * device_handle,\r
97                                                                                         BLUE_UINT32 settingsCount,\r
98                                                                                         EBlueConnectorPropertySetting *settings\r
99                                                                                         );\r
100 \r
101 //BLUE_CSDK_API BERR blue_wait_video_interrupt(void * device_handle,\r
102 //                                                                                      EBlueVideoChannel  video_channel,\r
103 //                                                                                      EUpdateMethod upd_fmt,\r
104 //                                                                                      BLUE_UINT32 field_wait_count,\r
105 //                                                                                      BLUE_UINT32 *field_count\r
106 //                                                                                      );\r
107 }