AJA NTV2 SDK  18.0.0.2122
NTV2 SDK 18.0.0.2122
ntv2llburn.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: MIT */
8 #ifndef _NTV2LLBURN_H
9 #define _NTV2LLBURN_H
10 
11 #include "ntv2enums.h"
12 #include "ntv2devicefeatures.h"
13 #include "ntv2devicescanner.h"
14 #include "ntv2democommon.h"
15 #include "ntv2utils.h"
16 #include "ajabase/common/types.h"
20 #include "ajabase/system/thread.h"
21 #include "ajabase/system/process.h"
23 #include <set>
24 
25 
33 {
34  // Public Instance Methods
35  public:
41  NTV2LLBurn (const BurnConfig & inConfig);
42  virtual ~NTV2LLBurn ();
43 
47  virtual AJAStatus Init (void);
48 
53  virtual AJAStatus Run (void);
54 
58  virtual void Quit (void);
59 
65  virtual void GetStatus (ULWord & outFramesProcessed, ULWord & outFramesDropped);
66 
67 
68  // Protected Instance Methods
69  protected:
73  virtual AJAStatus SetupVideo (void);
74 
78  virtual AJAStatus SetupAudio (void);
79 
83  virtual void RouteInputSignal (void);
84 
88  virtual void RouteOutputSignal (void);
89 
93  virtual AJAStatus SetupHostBuffers (void);
94 
98  virtual void StartRunThread (void);
99 
103  virtual void ProcessFrames (void);
104 
108  virtual bool InputSignalHasTimecode (void);
109 
113  virtual bool AnalogLTCInputHasTimecode (void);
114 
115 
116  // Protected Class Methods
117  protected:
125  static void RunThreadStatic (AJAThread * pThread, void * pContext);
126 
127 
128  // Private Member Data
129  private:
130  BurnConfig mConfig;
131  AJAThread mRunThread;
132  CNTV2Card mDevice;
133  NTV2DeviceID mDeviceID;
134  NTV2VideoFormat mVideoFormat;
135  NTV2FormatDesc mFormatDesc;
136  NTV2TaskMode mSavedTaskMode;
137  NTV2OutputDest mOutputDest;
138  NTV2AudioSystem mAudioSystem;
139  AJATimeCodeBurn mTCBurner;
140 
141  bool mGlobalQuit;
142  NTV2ChannelSet mRP188Outputs;
143 
144  NTV2Buffer mpHostVideoBuffer;
145  NTV2Buffer mpHostAudioBuffer;
146  NTV2Buffer mpHostF1AncBuffer;
147  NTV2Buffer mpHostF2AncBuffer;
148 
149  uint32_t mAudioInLastAddress;
150  uint32_t mAudioOutLastAddress;
151 
152  uint32_t mFramesProcessed;
153  uint32_t mFramesDropped;
154 
155  uint32_t mInputStartFrame;
156  uint32_t mInputEndFrame;
157  uint32_t mOutputStartFrame;
158  uint32_t mOutputEndFrame;
159 
160 }; // NTV2LLBurn
161 
162 #endif // _NTV2LLBURN_H
NTV2AudioSystem
Used to identify an Audio System on an NTV2 device. See Audio System Operation for more information...
Definition: ntv2enums.h:3895
Declares common types used in the ajabase library.
virtual AJAStatus SetupHostBuffers(void)
Sets up my circular buffers.
Definition: ntv2llburn.cpp:403
virtual AJAStatus SetupAudio(void)
Sets up everything I need for capturing and playing audio.
Definition: ntv2llburn.cpp:351
I interrogate and control an AJA video/audio capture/playout device.
Definition: ntv2card.h:28
NTV2TaskMode
Describes the task mode state. See also: Sharing AJA Devices With Other Applications.
AJAStatus
Definition: types.h:380
enum _NTV2VideoFormat NTV2VideoFormat
Identifies a particular video format.
virtual void ProcessFrames(void)
Repeatedly captures, burns, and plays frames without using AutoCirculate (until global quit flag set)...
Definition: ntv2llburn.cpp:542
Declares the AJATime class.
NTV2LLBurn(const BurnConfig &inConfig)
Constructs me using the given configuration settings.
Definition: ntv2llburn.cpp:31
Declares the AJATimeCodeBurn class.
uint32_t ULWord
Definition: ajatypes.h:223
virtual AJAStatus SetupVideo(void)
Sets up everything I need for capturing and playing video.
Definition: ntv2llburn.cpp:164
virtual void RouteInputSignal(void)
Sets up board routing for capture.
Definition: ntv2llburn.cpp:425
virtual AJAStatus Run(void)
Runs me.
Definition: ntv2llburn.cpp:501
NTV2DeviceID
Identifies a specific AJA NTV2 device model number. The NTV2DeviceID is actually the PROM part number...
Definition: ntv2enums.h:20
Enumerations for controlling NTV2 devices.
Declares the AJAThread class.
Describes a video frame for a given video standard or format and pixel format, including the total nu...
virtual void Quit(void)
Gracefully stops me from running.
Definition: ntv2llburn.cpp:69
Configures an NTV2Burn or NTV2FieldBurn instance.
virtual bool InputSignalHasTimecode(void)
Returns true if the current input signal has timecode embedded in it; otherwise returns false...
Definition: ntv2llburn.cpp:921
static void RunThreadStatic(AJAThread *pThread, void *pContext)
This is the worker thread&#39;s static callback function that gets called when the thread runs...
Definition: ntv2llburn.cpp:525
Declares the CNTV2DeviceScanner class.
Declares the AJAProcess class.
Describes a user-space buffer on the host computer. I have an address and a length, plus some optional attributes (allocated by SDK?, page-aligned? etc.).
virtual bool AnalogLTCInputHasTimecode(void)
Returns true if there is a valid LTC signal on my device&#39;s primary analog LTC input port; otherwise r...
Definition: ntv2llburn.cpp:935
virtual void RouteOutputSignal(void)
Sets up board routing for playout.
Definition: ntv2llburn.cpp:447
Declares the AJATimeCode class.
virtual void GetStatus(ULWord &outFramesProcessed, ULWord &outFramesDropped)
Provides status information about my input (capture) and output (playout) processes.
Definition: ntv2llburn.cpp:895
std::set< NTV2Channel > NTV2ChannelSet
A set of distinct NTV2Channel values.
Declares numerous NTV2 utility functions.
virtual ~NTV2LLBurn()
Definition: ntv2llburn.cpp:48
virtual AJAStatus Init(void)
Initializes me and prepares me to Run.
Definition: ntv2llburn.cpp:80
enum NTV2OutputDestination NTV2OutputDest
This file contains some structures, constants, classes and functions that are used in some of the dem...
virtual void StartRunThread(void)
Starts my main worker thread.
Definition: ntv2llburn.cpp:514
Declares the enumeration constants used in the ajabase library.
Declares device capability functions.
Captures video and audio from a signal provided to an input of an AJA device, burns timecode into the...
Definition: ntv2llburn.h:32