AJA NTV2 SDK  17.1.1.1245
NTV2 SDK 17.1.1.1245
main.cpp
Go to the documentation of this file.
1 /* SPDX-License-Identifier: MIT */
10 // Includes
11 #include "ajatypes.h"
13 #include "ajabase/pnp/pnp.h"
14 #include "ntv2ccgrabber.h"
15 #include "ntv2utils.h"
16 #include <signal.h>
17 #include <iostream>
18 #include <iomanip>
19 #if defined (MSWindows) || defined (AJAWindows)
20  #define SIGQUIT SIGBREAK
21 #endif
22 
23 using namespace std;
24 
25 
26 // Globals
27 static bool gGlobalQuit (false); // Set this "true" to exit gracefully
28 static AJAPnp gPlugAndPlay; // To detect device disconnects
29 
30 
31 static void SignalHandler (int inSignal)
32 {
33  (void) inSignal;
34  gGlobalQuit = true;
36 }
37 
38 
44 static void PnpCallback (const AJAPnpMessage inMessage, void * pUserData) // static
45 {
46  (void) pUserData;
47  if (inMessage == AJA_Pnp_DeviceAdded || inMessage == AJA_Pnp_DeviceRemoved)
48  {
49  static unsigned sAttaches (0);
50  static unsigned sDetaches (0);
51  if (inMessage == AJA_Pnp_DeviceAdded)
52  sAttaches++;
53  if (inMessage == AJA_Pnp_DeviceRemoved)
54  sDetaches++;
55  if (sAttaches > 1 || inMessage == AJA_Pnp_DeviceRemoved)
56  {
57  SignalHandler (SIGQUIT);
58  cerr << "## WARNING: Terminating 'ntv2ccgrabber' due to device " << (inMessage == AJA_Pnp_DeviceAdded ? "attach" : "detach") << endl;
59  }
60  }
61 
62 } // PnpCallback
63 
64 
65 
66 int main (int argc, const char ** argv)
67 {
68  const string legalChannels (NTV2CCGrabber::GetLine21ChannelNames("|"));
70  const string legalOutputModes(CCGrabberConfig::OutputModeToString(kOutputMode_INVALID));
71  const string legalFramesSpec ("{frameCount}[@{firstFrameNum}] or {firstFrameNum}-{lastFrameNum}");
72  char * pDeviceSpec (AJA_NULL); // Device spec
73  char * pInputSrcSpec (AJA_NULL); // SDI source spec
74  char * pTimecodeSpec (AJA_NULL); // Timecode source spec
75  char * pPixelFormat (AJA_NULL); // Pixel format spec
76  char * pCaptionChannel (AJA_NULL); // Caption channel of interest (cc1, cc2 ... text1, text2, ...)
77  char * pCaptionSource (AJA_NULL); // Caption source of interest (line21, 608vanc, 608anc ...)
78  char * pOutputMode (AJA_NULL); // Output mode (stream, screen, file ...)
79  char * pFramesSpec (AJA_NULL); // AutoCirculate frames spec
80  int channelNumber (1); // Channel (framestore) spec
81  int burnCaptions (0); // Burn-in captions?
82  int doMultiFormat (0); // MultiFormat mode?
83  int useVanc (0); // Use Vanc (tall frame) geometry?
84  int grabAudio (0); // Grab audio?
85  int showVersion (0); // Show version?
87 
88  ::setlocale (LC_ALL, ""); // Might have to emit UTF-8 Unicode
89 
91 
92  // Command line option descriptions:
93  const CNTV2DemoCommon::PoptOpts optionsTable [] =
94  {
95  {"version", 0, POPT_ARG_NONE, &showVersion, 0, "show version & exit", AJA_NULL },
96  {"device", 'd', POPT_ARG_STRING, &pDeviceSpec, 0, "device to use", "index#, serial#, or model" },
97  {"channel", 'c', POPT_ARG_INT, &channelNumber, 0, "channel to use", "1-8" },
98  {"multiFormat", 'm', POPT_ARG_NONE, &doMultiFormat, 0, "use multi-format/channel", AJA_NULL },
99  {"pixelFormat", 'p', POPT_ARG_STRING, &pPixelFormat, 0, "pixel format to use", "'?' or 'list' to list" },
100  {"frames", 0, POPT_ARG_STRING, &pFramesSpec, 0, "frames to AutoCirculate", "num[@min] or min-max" },
101  {"input", 'i', POPT_ARG_STRING, &pInputSrcSpec, 0, "which SDI input", "1-8, ?=list" },
102  {"tcsource", 't', POPT_ARG_STRING, &pTimecodeSpec, 0, "timecode source", "'?' or 'list' to list" },
103  {"608chan", 0, POPT_ARG_STRING, &pCaptionChannel, 0, "608 cap chan to monitor", legalChannels.c_str() },
104  {"608src", 0, POPT_ARG_STRING, &pCaptionSource, 0, "608 source to use", legal608Sources.c_str() },
105  {"output", 0, POPT_ARG_STRING, &pOutputMode, 0, "608 output mode", legalOutputModes.c_str() },
106  {"burn", 'b', POPT_ARG_NONE, &burnCaptions, 0, "burn-in captions", AJA_NULL },
107  {"vanc", 'v', POPT_ARG_NONE, &useVanc, 0, "use vanc geometry", AJA_NULL },
108  {"audio", 'a', POPT_ARG_NONE, &grabAudio, 0, "also capture audio", AJA_NULL },
111  };
112 
113  // Read command line arguments...
114  CNTV2DemoCommon::Popt popt(argc, argv, optionsTable);
115  if (!popt)
116  {cerr << "## ERROR: " << popt.errorStr() << endl; return 2;}
117 
118  const string deviceSpec (pDeviceSpec ? pDeviceSpec : "0");
119  const string inputSourceStr (pInputSrcSpec ? CNTV2DemoCommon::ToLower(string(pInputSrcSpec)) : "");
120  const string tcSourceStr (pTimecodeSpec ? CNTV2DemoCommon::ToLower(string(pTimecodeSpec)) : "");
121  const string pixelFormatStr (pPixelFormat ? pPixelFormat : "");
122  const string framesSpec (pFramesSpec ? pFramesSpec : "");
123  if (showVersion)
124  {cout << argv[0] << ", NTV2 SDK " << ::NTV2Version() << endl; return 0;}
125 
126  // Device
127  const string legalDevices(CNTV2DemoCommon::GetDeviceStrings());
128  if (deviceSpec == "?" || deviceSpec == "list")
129  {cout << legalDevices << endl; return 0;}
130  if (!CNTV2DemoCommon::IsValidDevice(deviceSpec))
131  {cout << "## ERROR: No such device '" << deviceSpec << "'" << endl << legalDevices; return 1;}
132 
133  CCGrabberConfig config(deviceSpec);
134 
135  // Channel
136  if ((channelNumber < 1) || (channelNumber > 8))
137  {cerr << "## ERROR: Invalid channel number " << channelNumber << " -- expected 1 thru 8" << endl; return 1;}
138  config.fInputChannel = NTV2Channel(channelNumber - 1);
139 
140  // Input source
141  const string legalSources(CNTV2DemoCommon::GetInputSourceStrings(NTV2_IOKINDS_SDI, deviceSpec));
142  if (inputSourceStr == "?" || inputSourceStr == "list")
143  {cout << legalSources << endl; return 0;}
144  if (!inputSourceStr.empty())
145  {
148  {cerr << "## ERROR: Input source '" << inputSourceStr << "' not one of these:" << endl << legalSources << endl; return 1;}
149  } // if input source specified
150 
151  // Timecode source
152  const string legalTCSources(CNTV2DemoCommon::GetTCIndexStrings(TC_INDEXES_ALL, deviceSpec));
153  if (tcSourceStr == "?" || tcSourceStr == "list")
154  {cout << legalTCSources << endl; return 0;}
155  if (!tcSourceStr.empty())
156  {
159  {cerr << "## ERROR: Timecode source '" << tcSourceStr << "' not one of these:" << endl << legalTCSources << endl; return 1;}
160  }
161 
162  // Pixel format
163  const string legalFBFs(CNTV2DemoCommon::GetPixelFormatStrings(PIXEL_FORMATS_ALL, deviceSpec));
164  if (pixelFormatStr == "?" || pixelFormatStr == "list")
165  {cout << CNTV2DemoCommon::GetPixelFormatStrings (PIXEL_FORMATS_ALL, deviceSpec) << endl; return 0;}
166  else if (!pixelFormatStr.empty())
167  {
170  {cerr << "## ERROR: Invalid '--pixelFormat' value '" << pixelFormatStr << "' -- expected values:" << endl << legalFBFs << endl; return 2;}
171  }
172 
173  // Caption channel
174  if (pCaptionChannel)
175  {
176  config.fCaptionChannel = ::StrToNTV2Line21Channel(string(pCaptionChannel));
178  {cerr << "## ERROR: Bad '608chan' value '" << pCaptionChannel << "' -- expected '" << legalChannels << "'" << endl; return 1;}
179  }
180 
181  // Caption Source
182  const string captionSrcStr(pCaptionSource ? pCaptionSource : "");
183  if (captionSrcStr == "?" || captionSrcStr == "list")
184  {cout << "## NOTE: Legal --608src values: " << legal608Sources << endl; return 0;}
185  else if (!captionSrcStr.empty())
186  {
189  {cerr << "## ERROR: Bad '608src' value '" << captionSrcStr << "' -- expected '" << legal608Sources << "'" << endl; return 1;}
190  }
191 
192  // Output mode
193  const string outputModeStr(pOutputMode ? pOutputMode : "");
194  if (outputModeStr == "?" || outputModeStr == "list")
195  {cout << "## NOTE: Legal --output values: " << legalOutputModes << endl; return 0;}
196  else if (!outputModeStr.empty())
197  {
198  config.fOutputMode = CCGrabberConfig::StringToOutputMode(outputModeStr);
199  if (!IS_VALID_OutputMode(config.fOutputMode))
200  {cerr << "## ERROR: Bad 'output' value '" << outputModeStr << "' -- expected '" << legalOutputModes << "'" << endl; return 1;}
201  }
202 
203  if (!config.GetNumSourceSpecs())
204  {
205  cerr << "## WARNING: No input channel, or input source, or timecode source specified -- will use NTV2_INPUTSOURCE_SDI1, NTV2_CHANNEL1" << endl;
206  config.fInputChannel = NTV2_CHANNEL1;
208  }
209 
210  // AutoCirculate frames
211  if (!framesSpec.empty())
212  {
213  const string parseResult(config.fFrames.setFromString(framesSpec));
214  if (!parseResult.empty())
215  {cerr << "## ERROR: Bad 'frames' spec '" << framesSpec << "'\n## " << parseResult << endl; return 1;}
216  }
217  if (!config.fFrames.valid())
218  {cerr << "## ERROR: Bad 'frames' spec '" << framesSpec << "'\n## Expected " << legalFramesSpec << endl; return 1;}
219 
220  // Configure the grabber...
221  config.fBurnCaptions = burnCaptions ? true : false;
222  config.fDoMultiFormat = doMultiFormat ? true : false;
223  config.fUseVanc = useVanc ? true : false;
224  config.fWithAudio = grabAudio ? true : false;
225 
226  NTV2CCGrabber ccGrabber (config);
227 
228  // Initialize the ccGrabber instance...
229  AJAStatus status (ccGrabber.Init());
230  if (AJA_FAILURE(status))
231  {cerr << "## ERROR: 'ntv2ccgrabber' initialization failed with status " << status << endl; return 2;}
232 
233  ::signal (SIGINT, SignalHandler);
234  #if defined (AJAMac)
235  ::signal (SIGHUP, SignalHandler);
236  ::signal (SIGQUIT, SignalHandler);
237  #endif
238 
239  // Run the ccGrabber...
240  if (AJA_FAILURE(ccGrabber.Run()))
241  {cerr << "## ERROR: 'ntv2ccgrabber' capture thread failed to run -- check for AutoCirculate messages in AJALogger?" << endl; return 2;}
242 
243  // Loop until someone tells us to stop...
244  while (!gGlobalQuit)
245  {
246  const char keyPressed (CNTV2DemoCommon::ReadCharacterPress());
247  if (keyPressed == 'q' || keyPressed == 'Q')
248  SignalHandler(SIGQUIT);
249  else if (keyPressed >= '1' && keyPressed <= '9')
250  ccGrabber.SetCaptionDisplayChannel(NTV2Line21Channel(keyPressed - '1'));
251  else if (keyPressed == '?')
252  cerr << endl << "## HELP: 1=CC1 2=CC2 3=CC3 4=CC4 5=Txt1 6=Txt2 7=Txt3 8=Txt4 Q=Quit H=HUD O=Output S=608Src P=PixFmt ?=Help" << endl;
253  else if (keyPressed == 'h' || keyPressed == 'H')
254  ccGrabber.ToggleHUD();
255  else if (keyPressed == 'v' || keyPressed == 'V')
256  ccGrabber.ToggleVANC();
257  else if (keyPressed == 'o' || keyPressed == 'O')
258  ccGrabber.SwitchOutput();
259  else if (keyPressed == 'p' || keyPressed == 'P')
260  ccGrabber.SwitchPixelFormat();
261  else if (keyPressed == 's' || keyPressed == 'S')
262  ccGrabber.Switch608Source();
263  AJATime::Sleep(500);
264  }
265  cerr << endl;
266  return 0;
267 
268 } // main
CaptureConfig::fDoMultiFormat
bool fDoMultiFormat
If true, use multi-format/multi-channel mode, if device supports it; otherwise normal mode.
Definition: ntv2democommon.h:276
AJAPnp
This is a platform-agnostic plug-and-play class that notifies a client when AJA devices are attached/...
Definition: pnp.h:51
CCGrabberConfig::fTimecodeSrc
NTV2TCIndex fTimecodeSrc
Timecode source to use (if any)
Definition: ntv2ccgrabber.h:67
CCGrabberConfig::StringToOutputMode
static OutputMode StringToOutputMode(const std::string &inModeStr)
Definition: ntv2ccgrabber.cpp:1613
CNTV2DemoCommon::GetInputSourceFromString
static NTV2InputSource GetInputSourceFromString(const std::string &inStr)
Returns the NTV2InputSource that matches the given string.
Definition: ntv2democommon.cpp:706
poptOption
Definition: options_popt.h:148
CCGrabberConfig::fOutputMode
OutputMode fOutputMode
Desired output (captionStream, Screen etc)
Definition: ntv2ccgrabber.h:65
ntv2ccgrabber.h
Header file for NTV2CCGrabber demonstration class.
CCGrabberConfig::fCaptionChannel
NTV2Line21Channel fCaptionChannel
Caption channel to monitor (defaults to CC1)
Definition: ntv2ccgrabber.h:68
PnpCallback
static void PnpCallback(const AJAPnpMessage inMessage, void *pUserData)
This function gets called whenever an AJA device is attached or detached to/from the host.
Definition: main.cpp:44
CNTV2DemoCommon::ReadCharacterPress
static char ReadCharacterPress(void)
Returns the character that represents the last key that was pressed on the keyboard without waiting f...
Definition: ntv2democommon.cpp:946
NTV2Channel
NTV2Channel
These enum values are mostly used to identify a specific widget_framestore. They're also commonly use...
Definition: ntv2enums.h:1305
AJAPnpMessage
AJAPnpMessage
Definition: pnp.h:22
NTV2CCGrabber::SwitchPixelFormat
virtual void SwitchPixelFormat(void)
Switches/rotates –pixelFormat.
Definition: ntv2ccgrabber.cpp:962
NTV2_IS_VALID_TIMECODE_INDEX
#define NTV2_IS_VALID_TIMECODE_INDEX(__x__)
Definition: ntv2enums.h:3903
CaptureConfig::fPixelFormat
NTV2PixelFormat fPixelFormat
Pixel format to use.
Definition: ntv2democommon.h:273
main
int main(int argc, const char **argv)
Definition: main.cpp:30
AJA_Pnp_PciVideoDevices
@ AJA_Pnp_PciVideoDevices
Definition: pnp.h:16
kCaptionDataSrc_INVALID
@ kCaptionDataSrc_INVALID
Definition: ntv2ccgrabber.h:53
NTV2ACFrameRange::setFromString
std::string setFromString(const std::string &inStr)
Definition: ntv2utils.cpp:4155
NTV2_CHANNEL1
@ NTV2_CHANNEL1
Specifies channel or Frame Store 1 (or the first item).
Definition: ntv2enums.h:1307
AJAPnp::Install
virtual AJAStatus Install(AJAPnpCallback callback, void *refCon=NULL, uint32_t devices=0)
Installs the given plug-n-play notification callback function, replacing any callback function that m...
Definition: pnp.cpp:38
nlohmann::json_abiNLOHMANN_JSON_ABI_TAG_LEGACY_DISCARDED_VALUE_COMPARISON_v3_11_NLOHMANN_JSON_VERSION_PATCH::detail::void
j template void())
Definition: json.hpp:4893
POPT_ARG_INT
#define POPT_ARG_INT
Definition: options_popt.h:58
NTV2CCGrabber::Run
virtual AJAStatus Run(void)
Runs me.
Definition: ntv2ccgrabber.cpp:605
CCGrabberConfig::fCaptionSrc
CaptionDataSrc fCaptionSrc
Caption data source (Line21? 608 VANC? 608 Anc? etc)
Definition: ntv2ccgrabber.h:66
NTV2CCGrabber::ToggleHUD
virtual void ToggleHUD(void)
Toggles the Head-Up-Display.
Definition: ntv2ccgrabber.h:176
ajatypes.h
Declares the most fundamental data types used by NTV2. Since Windows NT was the first principal devel...
CNTV2DemoCommon::GetTCIndexFromString
static NTV2TCIndex GetTCIndexFromString(const std::string &inStr)
Returns the NTV2TCIndex that matches the given string.
Definition: ntv2democommon.cpp:809
CNTV2DemoCommon::GetDeviceStrings
static std::string GetDeviceStrings(const NTV2DeviceKinds inKinds=NTV2_DEVICEKIND_ALL)
Definition: ntv2democommon.cpp:490
kOutputMode_INVALID
@ kOutputMode_INVALID
Definition: ntv2ccgrabber.h:39
NTV2CCGrabber::SwitchOutput
virtual void SwitchOutput(void)
Switches/rotates –output mode.
Definition: ntv2ccgrabber.cpp:940
POPT_AUTOHELP
#define POPT_AUTOHELP
Definition: options_popt.h:220
NTV2_INPUTSOURCE_SDI1
@ NTV2_INPUTSOURCE_SDI1
Identifies the 1st SDI video input.
Definition: ntv2enums.h:1228
AJAPnp::Uninstall
virtual AJAStatus Uninstall()
Uninstalls any previously-installed callback notifier.
Definition: pnp.cpp:45
CNTV2DemoCommon::IsValidDevice
static bool IsValidDevice(const std::string &inDeviceSpec)
Definition: ntv2democommon.cpp:430
AJAStatus
AJAStatus
Definition: types.h:378
gGlobalQuit
static bool gGlobalQuit((0))
AJATime::Sleep
static void Sleep(const int32_t inMilliseconds)
Suspends execution of the current thread for a given number of milliseconds.
Definition: systemtime.cpp:284
CNTV2DemoCommon::ToLower
static std::string ToLower(const std::string &inStr)
Returns the given string after converting it to lower case.
Definition: ntv2democommon.cpp:926
NTV2CCGrabber::GetLine21ChannelNames
static std::string GetLine21ChannelNames(std::string inDelimiter=", ")
Returns a string containing a concatenation of human-readable names of every available NTV2Line21Chan...
Definition: ntv2ccgrabber.cpp:1556
CNTV2DemoCommon::GetPixelFormatFromString
static NTV2FrameBufferFormat GetPixelFormatFromString(const std::string &inStr)
Returns the NTV2FrameBufferFormat that matches the given string.
Definition: ntv2democommon.cpp:653
CCGrabberConfig
This class is used to configure an NTV2CCGrabber instance.
Definition: ntv2ccgrabber.h:62
NTV2CCGrabber::Init
virtual AJAStatus Init(void)
Initializes me and prepares me to Run.
Definition: ntv2ccgrabber.cpp:119
SignalHandler
static void SignalHandler(int inSignal)
Definition: main.cpp:31
PIXEL_FORMATS_ALL
@ PIXEL_FORMATS_ALL
Definition: ntv2democommon.h:240
StrToNTV2Line21Channel
NTV2Line21Channel StrToNTV2Line21Channel(const std::string &inStr)
Converts the given string into the equivalent NTV2Line21Channel value.
options_popt.h
NTV2_IS_VALID_INPUT_SOURCE
#define NTV2_IS_VALID_INPUT_SOURCE(_inpSrc_)
Definition: ntv2enums.h:1243
CNTV2DemoCommon::Popt
Definition: ntv2democommon.h:801
ntv2utils.h
Declares numerous NTV2 utility functions.
CNTV2DemoCommon::Popt::errorStr
virtual const std::string & errorStr(void) const
Definition: ntv2democommon.h:809
NTV2Version
std::string NTV2Version(const bool inDetailed=false)
Definition: ntv2version.cpp:41
CCGrabberConfig::CaptionDataSrcToString
static std::string CaptionDataSrcToString(const CaptionDataSrc inDataSrc)
Definition: ntv2ccgrabber.cpp:1649
AJA_Pnp_DeviceRemoved
@ AJA_Pnp_DeviceRemoved
Definition: pnp.h:25
CNTV2DemoCommon::GetTCIndexStrings
static std::string GetTCIndexStrings(const NTV2TCIndexKinds inKinds=TC_INDEXES_ALL, const std::string inDeviceSpecifier=std::string(), const bool inIsInputOnly=(!(0)))
Definition: ntv2democommon.cpp:773
IS_VALID_OutputMode
#define IS_VALID_OutputMode(_x_)
Definition: ntv2ccgrabber.h:42
pnp.h
Declares the AJAPnp (plug-and-play) class.
IS_VALID_CaptionDataSrc
#define IS_VALID_CaptionDataSrc(_x_)
Definition: ntv2ccgrabber.h:56
AJADebug::Open
static AJAStatus Open(bool incrementRefCount=false)
Definition: debug.cpp:44
NTV2_CC608_ChannelMax
@ NTV2_CC608_ChannelMax
Definition: ntv2caption608types.h:97
AJA_NULL
#define AJA_NULL
Definition: ajatypes.h:197
CaptureConfig::fFrames
NTV2ACFrameRange fFrames
AutoCirculate frame count or range.
Definition: ntv2democommon.h:272
CaptureConfig::fInputChannel
NTV2Channel fInputChannel
The device channel to use.
Definition: ntv2democommon.h:270
CNTV2DemoCommon::GetInputSourceStrings
static std::string GetInputSourceStrings(const NTV2IOKinds inKinds=NTV2_IOKINDS_ALL, const std::string inDeviceSpecifier=std::string())
Definition: ntv2democommon.cpp:678
NTV2CCGrabber::SetCaptionDisplayChannel
virtual void SetCaptionDisplayChannel(const NTV2Line21Channel inNewChannel)
Changes the caption channel I'm displaying.
Definition: ntv2ccgrabber.cpp:1526
NTV2CCGrabber
I can decode captions from frames captured from an AJA device in real time. I can optionally play the...
Definition: ntv2ccgrabber.h:111
NTV2Line21Channel
NTV2Line21Channel
The CEA-608 caption channels: CC1 thru CC4, TX1 thru TX4, plus XDS.
Definition: ntv2caption608types.h:82
NTV2CCGrabber::Switch608Source
virtual void Switch608Source(void)
Switches/rotates –608src.
Definition: ntv2ccgrabber.cpp:951
std
Definition: json.hpp:5362
POPT_TABLEEND
#define POPT_TABLEEND
Definition: options_popt.h:215
true
#define true
Definition: ntv2devicefeatures.h:26
CCGrabberConfig::OutputModeToString
static std::string OutputModeToString(const OutputMode inMode)
Definition: ntv2ccgrabber.cpp:1598
CNTV2DemoCommon::GetPixelFormatStrings
static std::string GetPixelFormatStrings(const NTV2PixelFormatKinds inKinds=PIXEL_FORMATS_ALL, const std::string inDeviceSpecifier=std::string())
Definition: ntv2democommon.cpp:600
gPlugAndPlay
static AJAPnp gPlugAndPlay
Definition: main.cpp:28
NTV2ACFrameRange::valid
bool valid(void) const
Definition: ntv2utils.h:977
NTV2_IOKINDS_SDI
@ NTV2_IOKINDS_SDI
Specifies SDI input/output kinds.
Definition: ntv2enums.h:1251
CCGrabberConfig::fUseVanc
bool fUseVanc
If true, use Vanc, even if the device supports Anc insertion.
Definition: ntv2ccgrabber.h:70
AJA_Pnp_DeviceAdded
@ AJA_Pnp_DeviceAdded
Definition: pnp.h:24
CCGrabberConfig::StringToCaptionDataSrc
static CaptionDataSrc StringToCaptionDataSrc(const std::string &inDataSrcStr)
Definition: ntv2ccgrabber.cpp:1664
NTV2_IS_VALID_FRAME_BUFFER_FORMAT
#define NTV2_IS_VALID_FRAME_BUFFER_FORMAT(__s__)
Definition: ntv2enums.h:251
AJA_FAILURE
#define AJA_FAILURE(_status_)
Definition: types.h:371
POPT_ARG_STRING
#define POPT_ARG_STRING
Definition: options_popt.h:57
CCGrabberConfig::fBurnCaptions
bool fBurnCaptions
If true, burn-in captions on 2nd channel.
Definition: ntv2ccgrabber.h:69
CCGrabberConfig::GetNumSourceSpecs
unsigned GetNumSourceSpecs(void) const
Definition: ntv2ccgrabber.h:87
POPT_ARG_NONE
#define POPT_ARG_NONE
Definition: options_popt.h:56
CaptureConfig::fInputSource
NTV2InputSource fInputSource
The device input connector to use.
Definition: ntv2democommon.h:271
TC_INDEXES_ALL
@ TC_INDEXES_ALL
Definition: ntv2democommon.h:252
NTV2CCGrabber::ToggleVANC
virtual void ToggleVANC(void)
Toggles the use of VANC. (Debug, experimental)
Definition: ntv2ccgrabber.cpp:933
CaptureConfig::fWithAudio
bool fWithAudio
If true, also capture Audio.
Definition: ntv2democommon.h:278