DeckLinkAPIConfiguration.h 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181
  1. /* -LICENSE-START-
  2. ** Copyright (c) 2014 Blackmagic Design
  3. **
  4. ** Permission is hereby granted, free of charge, to any person or organization
  5. ** obtaining a copy of the software and accompanying documentation covered by
  6. ** this license (the "Software") to use, reproduce, display, distribute,
  7. ** execute, and transmit the Software, and to prepare derivative works of the
  8. ** Software, and to permit third-parties to whom the Software is furnished to
  9. ** do so, all subject to the following:
  10. **
  11. ** The copyright notices in the Software and this entire statement, including
  12. ** the above license grant, this restriction and the following disclaimer,
  13. ** must be included in all copies of the Software, in whole or in part, and
  14. ** all derivative works of the Software, unless such copies or derivative
  15. ** works are solely in the form of machine-executable object code generated by
  16. ** a source language processor.
  17. **
  18. ** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  19. ** IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  20. ** FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
  21. ** SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
  22. ** FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
  23. ** ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
  24. ** DEALINGS IN THE SOFTWARE.
  25. ** -LICENSE-END-
  26. */
  27. #ifndef BMD_DECKLINKAPICONFIGURATION_H
  28. #define BMD_DECKLINKAPICONFIGURATION_H
  29. #ifndef BMD_CONST
  30. #if defined(_MSC_VER)
  31. #define BMD_CONST __declspec(selectany) static const
  32. #else
  33. #define BMD_CONST static const
  34. #endif
  35. #endif
  36. // Type Declarations
  37. // Interface ID Declarations
  38. BMD_CONST REFIID IID_IDeckLinkConfiguration = /* 1E69FCF6-4203-4936-8076-2A9F4CFD50CB */ {0x1E,0x69,0xFC,0xF6,0x42,0x03,0x49,0x36,0x80,0x76,0x2A,0x9F,0x4C,0xFD,0x50,0xCB};
  39. /* Enum BMDDeckLinkConfigurationID - DeckLink Configuration ID */
  40. typedef uint32_t BMDDeckLinkConfigurationID;
  41. enum _BMDDeckLinkConfigurationID {
  42. /* Serial port Flags */
  43. bmdDeckLinkConfigSwapSerialRxTx = /* 'ssrt' */ 0x73737274,
  44. /* Video Input/Output Flags */
  45. bmdDeckLinkConfigUse1080pNotPsF = /* 'fpro' */ 0x6670726F,
  46. /* Video Input/Output Integers */
  47. bmdDeckLinkConfigHDMI3DPackingFormat = /* '3dpf' */ 0x33647066,
  48. bmdDeckLinkConfigBypass = /* 'byps' */ 0x62797073,
  49. bmdDeckLinkConfigClockTimingAdjustment = /* 'ctad' */ 0x63746164,
  50. /* Audio Input/Output Flags */
  51. bmdDeckLinkConfigAnalogAudioConsumerLevels = /* 'aacl' */ 0x6161636C,
  52. /* Video output flags */
  53. bmdDeckLinkConfigFieldFlickerRemoval = /* 'fdfr' */ 0x66646672,
  54. bmdDeckLinkConfigHD1080p24ToHD1080i5994Conversion = /* 'to59' */ 0x746F3539,
  55. bmdDeckLinkConfig444SDIVideoOutput = /* '444o' */ 0x3434346F,
  56. bmdDeckLinkConfigSingleLinkVideoOutput = /* 'sglo' */ 0x73676C6F,
  57. bmdDeckLinkConfigBlackVideoOutputDuringCapture = /* 'bvoc' */ 0x62766F63,
  58. bmdDeckLinkConfigLowLatencyVideoOutput = /* 'llvo' */ 0x6C6C766F,
  59. /* Video Output Integers */
  60. bmdDeckLinkConfigVideoOutputConnection = /* 'vocn' */ 0x766F636E,
  61. bmdDeckLinkConfigVideoOutputConversionMode = /* 'vocm' */ 0x766F636D,
  62. bmdDeckLinkConfigAnalogVideoOutputFlags = /* 'avof' */ 0x61766F66,
  63. bmdDeckLinkConfigReferenceInputTimingOffset = /* 'glot' */ 0x676C6F74,
  64. bmdDeckLinkConfigVideoOutputIdleOperation = /* 'voio' */ 0x766F696F,
  65. bmdDeckLinkConfigDefaultVideoOutputMode = /* 'dvom' */ 0x64766F6D,
  66. bmdDeckLinkConfigDefaultVideoOutputModeFlags = /* 'dvof' */ 0x64766F66,
  67. /* Video Output Floats */
  68. bmdDeckLinkConfigVideoOutputComponentLumaGain = /* 'oclg' */ 0x6F636C67,
  69. bmdDeckLinkConfigVideoOutputComponentChromaBlueGain = /* 'occb' */ 0x6F636362,
  70. bmdDeckLinkConfigVideoOutputComponentChromaRedGain = /* 'occr' */ 0x6F636372,
  71. bmdDeckLinkConfigVideoOutputCompositeLumaGain = /* 'oilg' */ 0x6F696C67,
  72. bmdDeckLinkConfigVideoOutputCompositeChromaGain = /* 'oicg' */ 0x6F696367,
  73. bmdDeckLinkConfigVideoOutputSVideoLumaGain = /* 'oslg' */ 0x6F736C67,
  74. bmdDeckLinkConfigVideoOutputSVideoChromaGain = /* 'oscg' */ 0x6F736367,
  75. /* Video Input Flags */
  76. bmdDeckLinkConfigVideoInputScanning = /* 'visc' */ 0x76697363, // Applicable to H264 Pro Recorder only
  77. bmdDeckLinkConfigUseDedicatedLTCInput = /* 'dltc' */ 0x646C7463, // Use timecode from LTC input instead of SDI stream
  78. /* Video Input Integers */
  79. bmdDeckLinkConfigVideoInputConnection = /* 'vicn' */ 0x7669636E,
  80. bmdDeckLinkConfigAnalogVideoInputFlags = /* 'avif' */ 0x61766966,
  81. bmdDeckLinkConfigVideoInputConversionMode = /* 'vicm' */ 0x7669636D,
  82. bmdDeckLinkConfig32PulldownSequenceInitialTimecodeFrame = /* 'pdif' */ 0x70646966,
  83. bmdDeckLinkConfigVANCSourceLine1Mapping = /* 'vsl1' */ 0x76736C31,
  84. bmdDeckLinkConfigVANCSourceLine2Mapping = /* 'vsl2' */ 0x76736C32,
  85. bmdDeckLinkConfigVANCSourceLine3Mapping = /* 'vsl3' */ 0x76736C33,
  86. bmdDeckLinkConfigCapturePassThroughMode = /* 'cptm' */ 0x6370746D,
  87. /* Video Input Floats */
  88. bmdDeckLinkConfigVideoInputComponentLumaGain = /* 'iclg' */ 0x69636C67,
  89. bmdDeckLinkConfigVideoInputComponentChromaBlueGain = /* 'iccb' */ 0x69636362,
  90. bmdDeckLinkConfigVideoInputComponentChromaRedGain = /* 'iccr' */ 0x69636372,
  91. bmdDeckLinkConfigVideoInputCompositeLumaGain = /* 'iilg' */ 0x69696C67,
  92. bmdDeckLinkConfigVideoInputCompositeChromaGain = /* 'iicg' */ 0x69696367,
  93. bmdDeckLinkConfigVideoInputSVideoLumaGain = /* 'islg' */ 0x69736C67,
  94. bmdDeckLinkConfigVideoInputSVideoChromaGain = /* 'iscg' */ 0x69736367,
  95. /* Audio Input Integers */
  96. bmdDeckLinkConfigAudioInputConnection = /* 'aicn' */ 0x6169636E,
  97. /* Audio Input Floats */
  98. bmdDeckLinkConfigAnalogAudioInputScaleChannel1 = /* 'ais1' */ 0x61697331,
  99. bmdDeckLinkConfigAnalogAudioInputScaleChannel2 = /* 'ais2' */ 0x61697332,
  100. bmdDeckLinkConfigAnalogAudioInputScaleChannel3 = /* 'ais3' */ 0x61697333,
  101. bmdDeckLinkConfigAnalogAudioInputScaleChannel4 = /* 'ais4' */ 0x61697334,
  102. bmdDeckLinkConfigDigitalAudioInputScale = /* 'dais' */ 0x64616973,
  103. /* Audio Output Integers */
  104. bmdDeckLinkConfigAudioOutputAESAnalogSwitch = /* 'aoaa' */ 0x616F6161,
  105. /* Audio Output Floats */
  106. bmdDeckLinkConfigAnalogAudioOutputScaleChannel1 = /* 'aos1' */ 0x616F7331,
  107. bmdDeckLinkConfigAnalogAudioOutputScaleChannel2 = /* 'aos2' */ 0x616F7332,
  108. bmdDeckLinkConfigAnalogAudioOutputScaleChannel3 = /* 'aos3' */ 0x616F7333,
  109. bmdDeckLinkConfigAnalogAudioOutputScaleChannel4 = /* 'aos4' */ 0x616F7334,
  110. bmdDeckLinkConfigDigitalAudioOutputScale = /* 'daos' */ 0x64616F73
  111. };
  112. // Forward Declarations
  113. class IDeckLinkConfiguration;
  114. /* Interface IDeckLinkConfiguration - DeckLink Configuration interface */
  115. class IDeckLinkConfiguration : public IUnknown
  116. {
  117. public:
  118. virtual HRESULT SetFlag (/* in */ BMDDeckLinkConfigurationID cfgID, /* in */ bool value) = 0;
  119. virtual HRESULT GetFlag (/* in */ BMDDeckLinkConfigurationID cfgID, /* out */ bool *value) = 0;
  120. virtual HRESULT SetInt (/* in */ BMDDeckLinkConfigurationID cfgID, /* in */ int64_t value) = 0;
  121. virtual HRESULT GetInt (/* in */ BMDDeckLinkConfigurationID cfgID, /* out */ int64_t *value) = 0;
  122. virtual HRESULT SetFloat (/* in */ BMDDeckLinkConfigurationID cfgID, /* in */ double value) = 0;
  123. virtual HRESULT GetFloat (/* in */ BMDDeckLinkConfigurationID cfgID, /* out */ double *value) = 0;
  124. virtual HRESULT SetString (/* in */ BMDDeckLinkConfigurationID cfgID, /* in */ const char *value) = 0;
  125. virtual HRESULT GetString (/* in */ BMDDeckLinkConfigurationID cfgID, /* out */ const char **value) = 0;
  126. virtual HRESULT WriteConfigurationToPreferences (void) = 0;
  127. protected:
  128. virtual ~IDeckLinkConfiguration () {} // call Release method to drop reference count
  129. };
  130. /* Functions */
  131. extern "C" {
  132. }
  133. #endif /* defined(BMD_DECKLINKAPICONFIGURATION_H) */