A QThread that captures audio/video from NTV2-compatible AJA devices and uses Qt signals to emit ARGB video frames. To simplify things, I assume the input signal is YCbCr, and the input goes through a color space converter (CSC) to an ARGB FrameStore. I can also output 2 channels of Audio to the host audio system using Qt's QAudioOutput device.
More...
#include <ntv2framegrabber.h>
|
void | newFrame (const QImage &inImage, const bool inClear) |
| This is signaled (called) when a new frame has been captured and is available for display. More...
|
|
void | newStatusString (const QString &inStatus) |
| This is signaled (called) when my status string changes. More...
|
|
void | captionScreenChanged (const ushort *pInScreen) |
| This is signaled (called) when my caption screen buffer changes. More...
|
|
A QThread that captures audio/video from NTV2-compatible AJA devices and uses Qt signals to emit ARGB video frames. To simplify things, I assume the input signal is YCbCr, and the input goes through a color space converter (CSC) to an ARGB FrameStore. I can also output 2 channels of Audio to the host audio system using Qt's QAudioOutput device.
Definition at line 46 of file ntv2framegrabber.h.
◆ NTV2FrameGrabber()
NTV2FrameGrabber::NTV2FrameGrabber |
( |
QObject * |
pInParentObject = NULL | ) |
|
Constructs me.
- Parameters
-
[in] | pInParentObject | Optionally specifies my parent object. Defaults to NULL (no parent). |
Definition at line 31 of file ntv2framegrabber.cpp.
◆ ~NTV2FrameGrabber()
NTV2FrameGrabber::~NTV2FrameGrabber |
( |
| ) |
|
|
virtual |
◆ captionScreenChanged
void NTV2FrameGrabber::captionScreenChanged |
( |
const ushort * |
pInScreen | ) |
|
|
signal |
This is signaled (called) when my caption screen buffer changes.
- Parameters
-
[in] | pInScreen | Points to the (screen) array of Utf16 characters. |
◆ CheckFor4kInput()
void NTV2FrameGrabber::CheckFor4kInput |
( |
const bool |
inCheckFor4K | ) |
|
|
inline |
Enables or disables checking for 4K/UHD video (on devices that supported 4K/UHD).
- Parameters
-
[in] | inCheckFor4K | If true, enables checking for 4K/UHD video; otherwise disables it. |
Definition at line 86 of file ntv2framegrabber.h.
◆ CheckForValidInput()
bool NTV2FrameGrabber::CheckForValidInput |
( |
void |
| ) |
|
|
protected |
◆ ClearCaptionBuffer()
void NTV2FrameGrabber::ClearCaptionBuffer |
( |
const bool |
inSignalClients = (0) | ) |
|
|
protected |
◆ GetColorSpaceFromInputSource()
◆ GetDeviceIndex()
UWord NTV2FrameGrabber::GetDeviceIndex |
( |
void |
| ) |
const |
◆ GetVideoFormatFromInputSource()
◆ GrabCaptions()
void NTV2FrameGrabber::GrabCaptions |
( |
void |
| ) |
|
|
protected |
◆ IsInput3Gb()
◆ newFrame
void NTV2FrameGrabber::newFrame |
( |
const QImage & |
inImage, |
|
|
const bool |
inClear |
|
) |
| |
|
signal |
This is signaled (called) when a new frame has been captured and is available for display.
- Parameters
-
[in] | inImage | A QImage that contains the frame image. |
[in] | inClear | True if a redraw should take place – i.e., if the frame is the first of a valid video stream, or if there is currently no valid video. |
◆ newStatusString
void NTV2FrameGrabber::newStatusString |
( |
const QString & |
inStatus | ) |
|
|
signal |
This is signaled (called) when my status string changes.
- Parameters
-
[in] | inStatus | The QString containing the status message. |
◆ OutputAudio()
void NTV2FrameGrabber::OutputAudio |
( |
ULWord * |
pInOutAudioBuffer, |
|
|
const ULWord |
inNumValidBytes |
|
) |
| |
|
protected |
Writes audio samples for channels 1 and 2 that are in the given audio buffer to my QAudioOutput device, which should play out on the host.
- Parameters
-
pInOutAudioBuffer | Specifies a valid, non-NULL pointer to a buffer containing the audio samples that were captured from my AJA device for a single frame. This is not a 'const' pointer because the buffer content will be changed. On entry, the buffer will contain 6, 8 or 16 channels of 4-byte (32-bit) audio samples: 0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF... On exit, the buffer will contain unsigned 2-byte (16-bit) samples in LRLRLRLR order, which is what Qt's QAudioOutput object is expecting. (The least significant 16 bits of each sample from the AJA device are discarded.) |
inNumValidBytes | Specifies the number of valid bytes that are in the audio buffer. |
Definition at line 934 of file ntv2framegrabber.cpp.
◆ run()
void NTV2FrameGrabber::run |
( |
void |
| ) |
|
|
protectedvirtual |
◆ SetDeinterlaceNonProgressiveVideo()
void NTV2FrameGrabber::SetDeinterlaceNonProgressiveVideo |
( |
const bool |
inDeinterlace | ) |
|
|
inline |
Enables or disables deinterlacing of non-progressive video.
- Parameters
-
[in] | inDeinterlace | If true, enables deinterlacing of non-progressive video; otherwise disables it. |
Definition at line 92 of file ntv2framegrabber.h.
◆ SetDeviceIndex()
void NTV2FrameGrabber::SetDeviceIndex |
( |
const UWord |
inDeviceIndex | ) |
|
Sets the AJA device to be used for capture.
- Parameters
-
[in] | inDeviceIndex | Specifies the zero-based index number of the device to be used. |
Definition at line 91 of file ntv2framegrabber.cpp.
◆ SetFixedReference()
void NTV2FrameGrabber::SetFixedReference |
( |
bool |
fixed | ) |
|
|
inline |
◆ SetInputSource()
void NTV2FrameGrabber::SetInputSource |
( |
const NTV2InputSource |
inInputSource | ) |
|
Sets the input to be used for capture on the AJA device being used.
- Parameters
-
[in] | inInputSource | Specifies the input source to be used. |
Definition at line 77 of file ntv2framegrabber.cpp.
◆ SetTimeCodeSource()
void NTV2FrameGrabber::SetTimeCodeSource |
( |
const NTV2TCIndex |
inTCSource | ) |
|
◆ SetupAudio()
void NTV2FrameGrabber::SetupAudio |
( |
void |
| ) |
|
|
protected |
◆ SetupInput()
bool NTV2FrameGrabber::SetupInput |
( |
void |
| ) |
|
|
protected |
◆ SetWithAudio()
void NTV2FrameGrabber::SetWithAudio |
( |
const bool |
inWithAudio | ) |
|
|
inline |
Enables or disables host audio playback.
- Parameters
-
[in] | inWithAudio | If true, enables host audio playback; otherwise disables it. |
Definition at line 70 of file ntv2framegrabber.h.
◆ StopAutoCirculate()
void NTV2FrameGrabber::StopAutoCirculate |
( |
void |
| ) |
|
|
protected |
The documentation for this class was generated from the following files: