21 #if defined (AJALinux) 25 #define Enum2Str(e) {e, #e}, 29 #define DEFAULT_PATT_GAIN 0.9 // some patterns pay attention to this... 30 #define HD_NUMCOMPONENTPIXELS_2K 2048 31 #define HD_NUMCOMPONENTPIXELS_1080_2K 2048 32 #define HD_NUMCOMPONENTPIXELS_1080 1920 34 #define CCIR601_10BIT_BLACK 64 // 0x040 35 #define CCIR601_10BIT_WHITE 940 // 0x3AC 36 #define CCIR601_10BIT_CHROMAOFFSET 512 // 0x200 38 #define CCIR601_8BIT_BLACK 16 // 0x10 39 #define CCIR601_8BIT_WHITE 235 // 0xEB 40 #define CCIR601_8BIT_CHROMAOFFSET 128 // 0x80 43 #define FRAME_0_BASE (0x0) 44 #define FRAME_1080_10BIT_LINEPITCH (1280*4) 45 #define FRAME_1080_8BIT_LINEPITCH (1920*2) 46 #define FRAME_QUADHD_10BIT_SIZE (FRAME_1080_10BIT_LINEPITCH*2160) 47 #define FRAME_QUADHD_8BIT_SIZE (FRAME_1080_8BIT_LINEPITCH*2160) 48 #define FRAME_BASE(__frameNum__,__frameSize__) ((__frameNum__)*(__frameSize__)) 56 bool bUseSmpteRange=
false,
bool bAlphaFromLuma=
false);
58 AJAExport void StackQuadrants (uint8_t* pSrc, uint32_t srcWidth, uint32_t srcHeight, uint32_t srcRowBytes, uint8_t* pDst);
59 AJAExport void CopyFromQuadrant (uint8_t* srcBuffer, uint32_t srcHeight, uint32_t srcRowBytes, uint32_t srcQuadrant, uint8_t* dstBuffer, uint32_t quad13Offset=0);
60 AJAExport void CopyToQuadrant (uint8_t* srcBuffer, uint32_t srcHeight, uint32_t srcRowBytes, uint32_t dstQuadrant, uint8_t* dstBuffer, uint32_t quad13Offset=0);
179 bool vancEnabled=
false,
181 bool wideVANC=
false);
201 const ULWord inDstBytesPerLine,
202 const UWord inDstTotalLines);
220 const ULWord inDstBytesPerLine,
221 const UWord inDstTotalLines);
278 const ULWord inDstBytesPerLine,
279 const UWord inDstTotalLines,
280 const UWord inDstVertLineOffset,
281 const UWord inDstHorzPixelOffset,
282 const UByte * pSrcBuffer,
283 const ULWord inSrcBytesPerLine,
284 const UWord inSrcTotalLines,
285 const UWord inSrcVertLineOffset,
286 const UWord inSrcVertLinesToCopy,
287 const UWord inSrcHorzPixelOffset,
288 const UWord inSrcHorzPixelsToCopy);
312 #define GetHdmiV2StandardFromVideoFormat(__vf__) ::GetNTV2StandardFromVideoFormat (__vf__) 363 const UWord inHeightLines,
364 const UWord inWidthPixels,
365 const bool inIsInterlaced,
366 const bool inIsLevelB,
593 #define GetTCIndexesForSDIInput GetTCIndexesForSDIConnector 594 #define NTV2ChannelToCaptureCrosspoint NTV2ChannelToInputCrosspoint 595 #define NTV2ChannelToIngestCrosspoint NTV2ChannelToInputCrosspoint 596 #define NTV2ChannelToInputChannelSpec NTV2ChannelToInputCrosspoint 597 #define NTV2ChannelToPlayoutCrosspoint NTV2ChannelToOutputCrosspoint 598 #define NTV2ChannelToOutputChannelSpec NTV2ChannelToOutputCrosspoint 743 int iNumChans,
bool bKeepAudio24Bits);
764 ULWord & inOutCurrentSample,
765 const ULWord inNumSamples,
766 const double inSampleRate,
767 const double inAmplitude,
768 const double inFrequency,
770 const bool inByteSwap,
771 const ULWord inNumChannels);
792 ULWord & inOutCurrentSample,
793 const ULWord inNumSamples,
794 const double inSampleRate,
795 const double inAmplitude,
796 const double inFrequency,
798 const bool inByteSwap,
799 const ULWord inNumChannels);
822 ULWord & inOutCurrentSample,
823 const ULWord inNumSamples,
824 const double inSampleRate,
825 const double * pInAmplitudes,
826 const double * pInFrequencies,
828 const bool inByteSwap,
829 const ULWord inNumChannels);
850 ULWord & inOutCurrentSample,
851 const ULWord inNumSamples,
852 const double inSampleRate,
853 const double inAmplitude,
854 const double inFrequency,
856 const bool inByteSwap,
857 const ULWord inNumChannels);
860 ULWord & inOutCurrentSample,
861 const ULWord inNumSamples,
863 const bool inEndianConvert,
864 const ULWord inNumChannels);
926 std::ostream & Print (std::ostream & inOutStream)
const;
939 const ULWord inSecondActiveLine,
940 const bool inFirstFieldTop,
942 : smpteFirstActiveLine (inFirstActiveLine),
943 smpteSecondActiveLine (inSecondActiveLine),
944 firstFieldTop (inFirstFieldTop),
945 mStandard (inStandard) { }
976 setCountOnly(inFrameCount);
980 setExactRange (inFirstFrame, inLastFrame);
984 inline UWord count (
void)
const {
return isCountOnly() ? mFrameCount : 0;}
987 inline operator bool()
const {
return valid();}
992 return lastFrame() >= firstFrame();
997 mFrameCount = mFirstFrame = mLastFrame = 0;
1002 mIsCountOnly =
false;
1004 mFirstFrame = inFirstFrame;
1005 mLastFrame = inLastFrame;
1010 mIsCountOnly =
false;
1012 mFirstFrame = inFirstFrame;
1013 mLastFrame = mFirstFrame + inCount - 1;
1018 mIsCountOnly =
true;
1019 mFrameCount = inCount;
1020 mFirstFrame = mLastFrame = 0;
1023 std::string setFromString (
const std::string & inStr);
1024 std::string toString (
const bool inNormalized =
false)
const;
1144 #if !defined(NTV2_DEPRECATE_17_6) 1150 #endif // !defined(NTV2_DEPRECATE_17_6) 1151 #if !defined(NTV2_DEPRECATE_16_1) 1153 #endif // !defined(NTV2_DEPRECATE_16_1) 1176 #define NTV2CrosspointIDToString NTV2OutputCrosspointIDToString 1177 #if defined (AJAMac) 1181 #endif // NTV2UTILS_H NTV2Channel NTV2InputSourceToChannel(const NTV2InputSource inInputSource)
Converts a given NTV2InputSource to its equivalent NTV2Channel value.
Declares common video macros and structs used in the SDK.
bool isFrameRange(void) const
NTV2TCIndexes GetTCIndexesForSDIConnector(const NTV2Channel inSDIConnector)
std::string NTV2AudioBufferSizeToString(const NTV2AudioBufferSize inValue, const bool inForRetailDisplay=false)
NTV2FrameRate GetNTV2FrameRateFromVideoFormat(const NTV2VideoFormat inVideoFormat)
bool IsMultiFormatCompatible(const NTV2FrameRate inFrameRate1, const NTV2FrameRate inFrameRate2)
Compares two frame rates and returns true if they are "compatible" (with respect to a multiformat-cap...
uint32_t CalcRowBytesForFormat(const NTV2FrameBufferFormat inPF, const uint32_t pixWidth)
std::string NTV2FrameGeometryToString(const NTV2FrameGeometry inValue, const bool inForRetailDisplay=false)
defined(NTV2_DEPRECATE_17_6)
std::string NTV2AudioSystemToString(const NTV2AudioSystem inValue, const bool inCompactDisplay=false)
std::ostream & operator<<(std::ostream &inOutStream, const NTV2FrameSize &inFrameDimensions)
Writes the given NTV2FrameSize to the specified output stream.
std::string NTV2HDMIBitDepthToString(const NTV2HDMIBitDepth inValue, const bool inCompactDisplay=false)
NTV2AudioSystem
Used to identify an Audio System on an NTV2 device. See Audio System Operation for more information...
bool GetInstalledMacDriverVersion(UWord &outMaj, UWord &outMin, UWord &outPt, UWord &outBld, UWord &outType)
std::string NTV2IpErrorEnumToString(const NTV2IpError inIpErrorEnumValue)
Specifies SDI input/output kinds.
std::set< NTV2TCIndex > NTV2TCIndexes
NTV2VideoFormat GetSupportedNTV2VideoFormatFromInputVideoFormat(const NTV2VideoFormat inVideoFormat)
NTV2DeviceID NTV2GetDeviceIDFromBitfileName(const std::string &inBitfileName)
LWord64 GetTotalAudioSamplesFromFrameNbrZeroUpToFrameNbr(NTV2FrameRate frameRate, NTV2AudioRate audioRate, ULWord frameNbrNonInclusive)
std::string NTV2ModeToString(const NTV2Mode inValue, const bool inCompactDisplay=false)
NTV2Channel NTV2TimecodeIndexToChannel(const NTV2TCIndex inTCIndex)
Converts the given NTV2TCIndex value into the appropriate NTV2Channel value.
bool YUVComponentsTo10BitYUVPackedBuffer(const std::vector< uint16_t > &inYCbCrLine, NTV2Buffer &inFrameBuffer, const NTV2FormatDescriptor &inDescriptor, const UWord inLineOffset)
Packs up to one raster line of uint16_t YUV components into an NTV2_FBF_10BIT_YCBCR frame buffer...
UWord NTV2GetSDKVersionComponent(const int inVersionComponent=0)
Returns an SDK version component value.
bool firstFieldTop
True if the first field on the wire is the top-most field in the raster (field dominance) ...
std::string NTV2WidgetIDToString(const NTV2WidgetID inValue, const bool inCompactDisplay=false)
NTV2Crosspoint
Logically, these are an NTV2Channel combined with an NTV2Mode.
NTV2TimecodeIndex NTV2InputSourceToTimecodeIndex(const NTV2InputSource inInputSource, const bool inEmbeddedLTC=false)
Converts a given NTV2InputSource to its equivalent NTV2TimecodeIndex value.
bool Is8BitFrameBufferFormat(const NTV2FrameBufferFormat fbFormat)
NTV2DeviceIDSet NTV2GetSupportedDevices(const NTV2DeviceKinds inKinds=NTV2_DEVICEKIND_ALL)
Returns an NTV2DeviceIDSet of devices supported by the SDK.
NTV2AudioBufferSize
Represents the size of the audio buffer used by a device audio system for storing captured samples or...
NTV2HDMIColorSpace
Indicates or specifies HDMI Color Space.
ULWordSet NTV2RegisterNumberSet
A set of distinct ULWord values.
NTV2Channel GetNTV2ChannelForIndex(const ULWord inIndex0)
NTV2FrameGeometry GetQuarterSizedGeometry(const NTV2FrameGeometry inGeometry)
bool setCountOnly(const UWord inCount)
NTV2FieldID
These values are used to identify fields for interlaced video. See Field/Frame Interrupts and CNTV2Ca...
NTV2FrameBufferFormat
Identifies a particular video frame buffer pixel format. See Device Frame Buffer Formats for details...
defined(NTV2_DEPRECATE_17_6)
NTV2TaskMode
Describes the task mode state. See also: Sharing AJA Devices With Other Applications.
NTV2VANCMode GetVANCModeForGeometry(const NTV2FrameGeometry inFrameGeometry)
NTV2OutputDestination
Identifies a specific video output destination.
enum _NTV2ScanMethod NTV2ScanMethod
Identifies a particular scan method.
std::string NTV2OutputDestinationToString(const NTV2OutputDestination inValue, const bool inForRetailDisplay=false)
enum _NTV2VideoFormat NTV2VideoFormat
Identifies a particular video format.
Used to describe Start of Active Video (SAV) location and field dominance for a given NTV2Standard...
NTV2OutputDestination NTV2ChannelToOutputDestination(const NTV2Channel inChannel, const NTV2IOKinds inKinds=NTV2_IOKINDS_SDI)
Converts the given NTV2Channel value into its ordinary equivalent NTV2OutputDestination.
double GetFramesPerSecond(const NTV2FrameRate inFrameRate)
NTV2OutputCrosspointIDs::iterator NTV2OutputCrosspointIDsIter
A convenient non-const iterator for NTV2OutputCrosspointIDs.
NTV2ACFrameRange & makeInvalid(void)
ULWord GetIndexForNTV2Channel(const NTV2Channel inChannel)
std::string NTV2AncDataRgnToStr(const NTV2AncDataRgn inValue, const bool inCompactDisplay=false)
bool IsAlphaChannelFormat(const NTV2FrameBufferFormat format)
NTV2EmbeddedAudioInput NTV2InputSourceToEmbeddedAudioInput(const NTV2InputSource inInputSource)
Converts a given NTV2InputSource to its equivalent NTV2EmbeddedAudioInput value.
NTV2InputSource NTV2ChannelToInputSource(const NTV2Channel inChannel, const NTV2IOKinds inKinds=NTV2_IOKINDS_SDI)
#define NTV2_DEPRECATED_17_6(__f__)
void UnPack10BitDPXtoForRP215withEndianSwap(UWord *rawrp215Buffer, ULWord *DPXLinebuffer, ULWord numPixels)
NTV2AudioSystem NTV2InputSourceToAudioSystem(const NTV2InputSource inInputSource)
Converts a given NTV2InputSource to its equivalent NTV2AudioSystem value.
bool PackLine_UWordSequenceTo10BitYUV(const UWordSequence &in16BitYUVLine, ULWord *pOut10BitYUVLine, const ULWord inNumPixels)
Packs a line of 16-bit-per-component YCbCr (NTV2_FBF_10BIT_YCBCR) video into 10-bit-per-component YCb...
std::string NTV2GetVDevFolderPath(const bool inAddTrailingPathDelim=false)
std::string NTV2RegisterNumberToString(const NTV2RegisterNumber inValue)
void setHDRDefaultsForBT2020(HDRRegValues &outRegVals)
std::string NTV2DownConvertModeToString(const NTV2DownConvertMode inValue, const bool inCompactDisplay=false)
std::string NTV2RegNumSetToString(const NTV2RegisterNumberSet &inValue)
bool IsProgressiveTransport(const NTV2VideoFormat format)
NTV2EmbeddedAudioClock
This enum value determines/states the device audio clock reference source. It was important to set th...
std::string NTV2ColorCorrectionModeToString(const NTV2ColorCorrectionMode inValue, const bool inCompactDisplay=false)
NTV2StringList::iterator NTV2StringListIter
INTERRUPT_ENUMS NTV2ChannelToInputInterrupt(const NTV2Channel inChannel)
Converts the given NTV2Channel value into the equivalent input INTERRUPT_ENUMS value.
NTV2FrameGeometry GetNormalizedFrameGeometry(const NTV2FrameGeometry inFrameGeometry)
NTV2DeviceIDSet::iterator NTV2DeviceIDSetIter
A convenient non-const iterator for NTV2DeviceIDSet.
UWord firstFrame(void) const
NTV2Standard GetNTV2StandardFromScanGeometry(const UByte inScanGeometry, const bool inIsProgressiveTransport)
std::string NTV2BreakoutTypeToString(const NTV2BreakoutType inValue, const bool inCompactDisplay=false)
ULWord smpteSecondActiveLine
SMPTE line number of second active line of video.
NTV2HDMIAudioChannels
Indicates or specifies the HDMI audio channel count.
ULWord NTV2AudioBufferSizeToByteCount(const NTV2AudioBufferSize inBufferSize)
Converts the given NTV2BufferSize value into its exact byte count.
void UnPack10BitDPXtoForRP215(UWord *rawrp215Buffer, ULWord *DPXLinebuffer, ULWord numPixels)
std::string NTV2DieTempScaleToString(const NTV2DieTempScale inValue, const bool inUseUTF8=false)
std::string NTV2InterruptEnumToString(const INTERRUPT_ENUMS inInterruptEnumValue)
NTV2HDMIRange
Indicates or specifies the HDMI RGB range.
bool HasVANCGeometries(const NTV2FrameGeometry inFrameGeometry)
NTV2EmbeddedAudioInput NTV2ChannelToEmbeddedAudioInput(const NTV2Channel inChannel)
Converts the given NTV2Channel value into its equivalent NTV2EmbeddedAudioInput.
NTV2Channel
These enum values are mostly used to identify a specific widget_framestore. They're also commonly use...
std::string NTV2AudioFormatToString(const NTV2AudioFormat inValue, const bool inCompactDisplay=false)
NTV2Crosspoint GetNTV2CrosspointInputForIndex(const ULWord inIndex0)
NTV2FrameGeometry GetGeometryFromFrameDimensions(const NTV2FrameSize &inFD)
void setHDRDefaultsForDCIP3(HDRRegValues &outRegVals)
bool GetChangedRegisters(const NTV2RegisterReads &inBefore, const NTV2RegisterReads &inAfter, NTV2RegNumSet &outChanged)
bool IsProgressivePicture(const NTV2VideoFormat format)
void UnPack10BitYCbCrBuffer(uint32_t *packedBuffer, uint16_t *ycbcrBuffer, uint32_t numPixels)
void PackTo10BitYCbCrBuffer(const uint16_t *ycbcrBuffer, uint32_t *packedBuffer, const uint32_t numPixels)
void MaskYCbCrLine(UWord *ycbcrLine, UWord signalMask, ULWord numPixels)
NTV2TCIndex NTV2ChannelToTimecodeIndex(const NTV2Channel inChannel, const bool inEmbeddedLTC=false, const bool inIsF2=false)
Converts the given NTV2Channel value into the equivalent NTV2TCIndex value.
NTV2Crosspoint GetNTV2CrosspointChannelForIndex(const ULWord inIndex0)
bool CopyRaster(const NTV2PixelFormat inPixelFormat, UByte *pDstBuffer, const ULWord inDstBytesPerLine, const UWord inDstTotalLines, const UWord inDstVertLineOffset, const UWord inDstHorzPixelOffset, const UByte *pSrcBuffer, const ULWord inSrcBytesPerLine, const UWord inSrcTotalLines, const UWord inSrcVertLineOffset, const UWord inSrcVertLinesToCopy, const UWord inSrcHorzPixelOffset, const UWord inSrcHorzPixelsToCopy)
Copies all or part of a source raster image into a destination raster at a given position.
std::string NTV2MixerInputControlToString(const NTV2MixerKeyerInputControl inValue, const bool inCompactDisplay=false)
NTV2FrameRate GetFrameRateFamily(const NTV2FrameRate inFrameRate)
NTV2TCIndex
These enum values are indexes into the capture/playout AutoCirculate timecode arrays.
NTV2InputCrosspointIDs::const_iterator NTV2InputCrosspointIDsConstIter
A convenient const iterator for NTV2InputCrosspointIDs.
std::string PercentEncode(const std::string &inStr)
bool UnpackLine_10BitYUVtoU16s(std::vector< uint16_t > &outYCbCrLine, const NTV2Buffer &inFrameBuffer, const NTV2FormatDescriptor &inDescriptor, const UWord inLineOffset)
Unpacks up to one raster line of an NTV2_FBF_10BIT_YCBCR frame buffer into an array of uint16_t value...
AutoCirculate Frame Range.
ULWord smpteFirstActiveLine
SMPTE line number of first (top-most) active line of video.
std::string NTV2InputSourceToString(const NTV2InputSource inValue, const bool inForRetailDisplay=false)
NTV2Channel NTV2OutputDestinationToChannel(const NTV2OutputDestination inOutputDest)
Converts a given NTV2OutputDestination to its equivalent NTV2Channel value.
std::string AutoCircVidProcModeToString(const AutoCircVidProcMode inValue, const bool inCompactDisplay=false)
NTV2FrameRate
Identifies a particular video frame rate.
std::string NTV2StandardToString(const NTV2Standard inValue, const bool inForRetailDisplay=false)
std::string NTV2InputCrosspointIDToString(const NTV2InputCrosspointID inValue, const bool inForRetailDisplay=false)
NTV2FrameRate GetNTV2FrameRateFromNumeratorDenominator(const ULWord inNumerator, const ULWord inDenominator)
std::string NTV2AudioChannelQuadToString(const NTV2Audio4ChannelSelect inValue, const bool inCompactDisplay=false)
NTV2Standard
Identifies a particular video standard.
ULWord GetDisplayHeight(const NTV2VideoFormat videoFormat)
std::string NTV2GetBitfileName(const NTV2DeviceID inValue)
NTV2DeviceID
Identifies a specific AJA NTV2 device model number. The NTV2DeviceID is actually the PROM part number...
NTV2IOKinds GetNTV2InputSourceKind(const NTV2InputSource inSrc)
bool IsVideoFormatB(const NTV2VideoFormat format)
std::string NTV2ScanMethodToString(const NTV2ScanMethod inValue, const bool inCompactDisplay=false)
Enumerations for controlling NTV2 devices.
NTV2Standard GetQuarterSizedStandard(const NTV2Standard inGeometry)
struct NTV2SmpteLineNumber NTV2SmpteLineNumber
Used to describe Start of Active Video (SAV) location and field dominance for a given NTV2Standard...
NTV2FrameGeometry GetVANCFrameGeometry(const NTV2FrameGeometry inFrameGeometry, const NTV2VANCMode inVancMode)
NTV2DeviceIDSet::const_iterator NTV2DeviceIDSetConstIter
A convenient const iterator for NTV2DeviceIDSet.
NTV2ReferenceSource
These enum values identify a specific source for the device's (output) reference clock.
NTV2BreakoutType
Identifies the Breakout Boxes and Cables that may be attached to an AJA NTV2 device.
std::string NTV2TaskModeToString(const NTV2TaskMode inValue, const bool inCompactDisplay=false)
Defines the import/export macros for producing DLLs or LIBs.
NTV2Crosspoint NTV2InputSourceToChannelSpec(const NTV2InputSource inInputSource)
Converts a given NTV2InputSource to its equivalent NTV2Crosspoint value.
bool convertHDRRegisterToFloatValues(const HDRRegValues &inRegVals, HDRFloatValues &outFloatVals)
NTV2InputCrosspointIDs::iterator NTV2InputCrosspointIDsIter
A convenient non-const iterator for NTV2InputCrosspointIDs.
enum NTV2AncillaryDataRegion NTV2AncDataRgn
NTV2StringSet::const_iterator NTV2StringSetConstIter
void Make8BitWhiteLine(UByte *lineData, ULWord numPixels=1920, NTV2FrameBufferFormat=NTV2_FBF_8BIT_YCBCR)
std::string NTV2EmbeddedAudioClockToString(const NTV2EmbeddedAudioClock inValue, const bool inForRetailDisplay=false)
ULWord GetVideoActiveSize(const NTV2VideoFormat inVideoFormat, const NTV2FrameBufferFormat inFBFormat, const NTV2VANCMode inVancMode=NTV2_VANCMODE_OFF)
Declares the most fundamental data types used by NTV2. Since Windows NT was the first principal devel...
NTV2AudioLoopBack
This enum value determines/states if an audio output embedder will embed silence (zeroes) or de-embed...
NTV2VideoFormat GetTransportCompatibleFormat(const NTV2VideoFormat inFormat, const NTV2VideoFormat inTargetFormat)
NTV2VideoFormat GetQuarterSizedVideoFormat(const NTV2VideoFormat inVideoFormat)
std::string NTV2HDMIProtocolToString(const NTV2HDMIProtocol inValue, const bool inCompactDisplay=false)
bool IsTransportCompatibleFormat(const NTV2VideoFormat inFormat1, const NTV2VideoFormat inFormat2)
enum _INTERRUPT_ENUMS_ INTERRUPT_ENUMS
void CopyRGBAImageToFrame(ULWord *pSrcBuffer, ULWord srcHeight, ULWord srcWidth, ULWord *pDstBuffer, ULWord dstHeight, ULWord dstWidth)
std::string NTV2GetVersionString(const bool inDetailed=false)
void Fill4k8BitYCbCrVideoFrame(PULWord _baseVideoAddress, NTV2FrameBufferFormat frameBufferFormat, YCbCrPixel color, bool vancEnabled=false, bool b4k=false, bool wideVANC=false)
ULWord NTV2FramesizeToByteCount(const NTV2Framesize inFrameSize)
Converts the given NTV2Framesize value into an exact byte count.
NTV2ACFrameRange(const UWord inFrameCount=0)
NTV2RegisterNumberSet NTV2RegNumSet
A set of distinct NTV2RegisterNumbers.
NTV2AudioChannelPair
Identifies a pair of audio channels.
std::vector< std::string > NTV2StringList
void MaskUnPacked10BitYCbCrBuffer(uint16_t *ycbcrUnPackedBuffer, uint16_t signalMask, uint32_t numPixels)
Specifies any/all devices.
NTV2MixerKeyerInputControl
These enum values identify the Mixer/Keyer foreground and background input control values...
std::string NTV2VANCModeToString(const NTV2VANCMode inValue, const bool inCompactDisplay=false)
void CopyFromQuadrant(uint8_t *srcBuffer, uint32_t srcHeight, uint32_t srcRowBytes, uint32_t srcQuadrant, uint8_t *dstBuffer, uint32_t quad13Offset=0)
bool Is8KFormat(const NTV2VideoFormat format)
ULWord GetNTV2FrameGeometryWidth(const NTV2FrameGeometry inFrameGeometry)
void ConvertUnpacked10BitYCbCrToPixelFormat(uint16_t *unPackedBuffer, uint32_t *packedBuffer, uint32_t numPixels, NTV2FrameBufferFormat pixelFormat, bool bUseSmpteRange=false, bool bAlphaFromLuma=false)
#define NTV2_SHOULD_BE_DEPRECATED(__f__)
void Make8BitLine(UByte *lineData, UByte Y, UByte Cb, UByte Cr, ULWord numPixels=1920, NTV2FrameBufferFormat=NTV2_FBF_8BIT_YCBCR)
NTV2RegWrites NTV2RegisterReads
NTV2InputSource GetNTV2InputSourceForIndex(const ULWord inIndex0, const NTV2IOKinds inKinds=NTV2_IOKINDS_SDI)
std::vector< uint16_t > UWordSequence
An ordered sequence of UWord (uint16_t) values.
ULWord GetIndexForNTV2InputSource(const NTV2InputSource inValue)
NTV2Crosspoint GetNTV2CrosspointForIndex(const ULWord inIndex0)
std::set< NTV2FrameGeometry > NTV2GeometrySet
A set of distinct NTV2FrameGeometry values.
bool IsVideoFormatJ2KSupported(const NTV2VideoFormat format)
std::string NTV2HDMIAudioChannelsToString(const NTV2HDMIAudioChannels inValue, const bool inCompactDisplay=false)
std::string NTV2VideoFormatToString(const NTV2VideoFormat inValue, const bool inUseFrameRate=false)
NTV2HDMIProtocol
Indicates or specifies the HDMI protocol.
#define NTV2_IS_VALID_STANDARD(__s__)
std::string NTV2GetPluginsFolderPath(const bool inAddTrailingPathDelim=false)
void CopyToQuadrant(uint8_t *srcBuffer, uint32_t srcHeight, uint32_t srcRowBytes, uint32_t dstQuadrant, uint8_t *dstBuffer, uint32_t quad13Offset=0)
bool SetRasterLinesWhite(const NTV2PixelFormat inPixelFormat, UByte *pDstBuffer, const ULWord inDstBytesPerLine, const UWord inDstTotalLines)
Sets all or part of a destination raster image to legal white.
bool IsVideoFormatA(const NTV2VideoFormat format)
std::string NTV2IsoConvertModeToString(const NTV2IsoConvertMode inValue, const bool inCompactDisplay=false)
void Make10BitLine(UWord *lineData, const UWord Y, const UWord Cb, const UWord Cr, const ULWord numPixels=1920)
std::string NTV2TCIndexToString(const NTV2TCIndex inValue, const bool inCompactDisplay=false)
std::string NTV2AudioChannelOctetToString(const NTV2Audio8ChannelSelect inValue, const bool inCompactDisplay=false)
std::vector< NTV2InputCrosspointID > NTV2InputCrosspointIDs
An ordered sequence of NTV2InputCrosspointID values.
ULWord GetVideoWriteSize(const NTV2VideoFormat inVideoFormat, const NTV2FrameBufferFormat inFBFormat, const NTV2VANCMode inVancMode=NTV2_VANCMODE_OFF)
Identical to the GetVideoActiveSize function, except rounds the result up to the nearest 4K page size...
void Make10BitWhiteLine(UWord *pOutLineData, const ULWord inNumPixels=1920)
Writes a line of unpacked, legal SMPTE 10-bit Y/C white values into the given buffer.
std::string NTV2AudioChannelPairToString(const NTV2AudioChannelPair inValue, const bool inCompactDisplay=false)
std::string NTV2UpConvertModeToString(const NTV2UpConvertMode inValue, const bool inCompactDisplay=false)
void Make10BitBlackLine(UWord *pOutLineData, const ULWord inNumPixels=1920)
Writes a line of unpacked, legal SMPTE 10-bit Y/C black values into the given buffer.
ULWord GetIndexForNTV2Crosspoint(const NTV2Crosspoint inChannel)
void UnPack10BitDPXtoRGBAlpha10BitPixel(RGBAlpha10BitPixel *rgba10BitBuffer, const ULWord *DPXLinebuffer, ULWord numPixels, bool bigEndian)
NTV2Framesize
Kona2/Xena2 specific enums.
NTV2ACFrameRange(const UWord inFirstFrame, const UWord inLastFrame)
bool convertHDRFloatToRegisterValues(const HDRFloatValues &inFVals, HDRRegValues &outRegVals)
NTV2FrameGeometry Get4xSizedGeometry(const NTV2FrameGeometry inGeometry)
bool AddAudioTone(ULWord &outNumBytesWritten, NTV2Buffer &inAudioBuffer, ULWord &inOutCurrentSample, const ULWord inNumSamples, const double inSampleRate, const double inAmplitude, const double inFrequency, const ULWord inNumBits, const bool inByteSwap, const ULWord inNumChannels)
Fills the given buffer with 32-bit (ULWord) audio tone samples.
bool NTV2IsCompatibleBitfileName(const std::string &inBitfileName, const NTV2DeviceID inDeviceID)
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.).
std::string NTV2HDMIRangeToString(const NTV2HDMIRange inValue, const bool inCompactDisplay=false)
NTV2Mode
Used to identify the mode of a widget_framestore, or the direction of an AutoCirculate stream: either...
int RecordCopyAudio(PULWord pAja, PULWord pSR, int iStartSample, int iNumBytes, int iChan0, int iNumChans, bool bKeepAudio24Bits)
std::string toString(const bool inNormalized=false) const
NTV2DeviceIDList::iterator NTV2DeviceIDListIter
A convenient non-const iterator for NTV2DeviceIDList.
NTV2InputSource
Identifies a specific video input source.
std::string NTV2DeviceIDToString(const NTV2DeviceID inValue, const bool inForRetailDisplay=false)
bool IsRGBFormat(const NTV2FrameBufferFormat format)
NTV2RegNumSet ToRegNumSet(const NTV2RegisterReads &inRegReads)
bool StringToSerialNum64(const std::string &inSerNumStr, uint64_t &outSerNum)
bool operator==(const json_pointer< RefStringTypeLhs > &lhs, const json_pointer< RefStringTypeRhs > &rhs) noexcept
std::string PercentDecode(const std::string &inStr)
NTV2FrameGeometry
Identifies a particular video frame geometry.
std::string NTV2HDMIColorSpaceToString(const NTV2HDMIColorSpace inValue, const bool inCompactDisplay=false)
std::string NTV2GetFirmwareFolderPath(const bool inAddTrailingPathDelim=false)
bool Fill8BitYCbCrVideoFrame(void *pBaseVideoAddress, const NTV2Standard inStandard, const NTV2FrameBufferFormat inFBF, const YCbCrPixel inPixelColor, const NTV2VANCMode inVancMode=NTV2_VANCMODE_OFF)
void Make8BitBlackLine(UByte *lineData, ULWord numPixels=1920, NTV2FrameBufferFormat=NTV2_FBF_8BIT_YCBCR)
NTV2SmpteLineNumber GetSmpteLineNumber(const NTV2Standard inStandard)
For the given video standard, returns the SMPTE-designated line numbers for Field 1 and Field 2 that ...
std::string NTV2M31VideoPresetToString(const M31VideoPreset val, const bool retailDisplay=false)
NTV2Standard Get4xSizedStandard(const NTV2Standard inGeometry, const bool bIs4k=false)
void UnpackLine_10BitYUVto16BitYUV(const ULWord *pIn10BitYUVLine, UWord *pOut16BitYUVLine, const ULWord inNumPixels)
Unpacks a line of 10-bit-per-component YCbCr video into 16-bit-per-component YCbCr (NTV2_FBF_10BIT_YC...
std::string NTV2CrosspointToString(const NTV2Crosspoint inChannel)
Describes the horizontal and vertical size dimensions of a raster, bitmap, frame or image...
std::string NTV2WidgetTypeToString(const NTV2WidgetType inValue, const bool inCompactDisplay=false)
std::string NTV2FramesizeToString(const NTV2Framesize inValue, const bool inCompactDisplay=false)
bool setRangeWithCount(const UWord inCount, const UWord inFirstFrame)
NTV2OutputCrosspointID
Identifies a widget output, a signal source, that potentially can drive another widget's input (ident...
double GetAudioSamplesPerSecond(const NTV2AudioRate inAudioRate)
Returns the audio sample rate as a number of audio samples per second.
NTV2InputCrosspointID
Identifies a widget input that potentially can accept a signal emitted from another widget's output (...
void PackLine_16BitYUVto10BitYUV(const UWord *pIn16BitYUVLine, ULWord *pOut10BitYUVLine, const ULWord inNumPixels)
Packs a line of 16-bit-per-component YCbCr (NTV2_FBF_10BIT_YCBCR) video into 10-bit-per-component YCb...
uint16_t NTV2DeviceKinds
A combination of NTV2DeviceKindFilter values.
void StackQuadrants(uint8_t *pSrc, uint32_t srcWidth, uint32_t srcHeight, uint32_t srcRowBytes, uint8_t *pDst)
NTV2Crosspoint NTV2ChannelToInputCrosspoint(const NTV2Channel inChannel)
bool IsRaw(const NTV2FrameBufferFormat format)
NTV2Crosspoint NTV2ChannelToOutputCrosspoint(const NTV2Channel inChannel)
std::string NTV2AudioRateToString(const NTV2AudioRate inValue, const bool inForRetailDisplay=false)
bool IsNTV2CrosspointOutput(const NTV2Crosspoint inChannel)
ULWord GetAudioSamplesPerFrame(const NTV2FrameRate inFrameRate, const NTV2AudioRate inAudioRate, ULWord inCadenceFrame=0, bool inIsSMPTE372Enabled=false)
Returns the number of audio samples for a given video frame rate, audio sample rate, and frame number. This is useful since AJA devices use fixed audio sample rates (typically 48KHz), and some video frame rates will necessarily result in some frames having more audio samples than others.
NTV2FrameRate GetFrameRateFromScale(long scale, long duration, NTV2FrameRate playFrameRate)
std::string NTV2RegisterWriteModeToString(const NTV2RegisterWriteMode inValue, const bool inForRetailDisplay=false)
NTV2VideoLimiting
These enum values identify the available SDI video output limiting modes.
bool setExactRange(const UWord inFirstFrame, const UWord inLastFrame)
std::string NTV2ReferenceSourceToString(const NTV2ReferenceSource inValue, const bool inForRetailDisplay=false)
void RePackLineDataForYCbCrDPX(ULWord *packedycbcrLine, ULWord numULWords)
NTV2VANCMode
These enum values identify the available VANC modes.
std::string NTV2AudioSourceToString(const NTV2AudioSource inValue, const bool inCompactDisplay=false)
std::string NTV2AudioMonitorSelectToString(const NTV2AudioMonitorSelect v, const bool b=false)
std::vector< NTV2OutputCrosspointID > NTV2OutputCrosspointIDs
An ordered sequence of NTV2OutputCrosspointID values.
ULWord GetDisplayWidth(const NTV2VideoFormat videoFormat)
std::string NTV2FrameBufferFormatToString(const NTV2FrameBufferFormat inValue, const bool inForRetailDisplay=false)
NTV2RegisterWriteMode
These values are used to determine when certain register writes actually take effect. See CNTV2Card::SetRegisterWriteMode or Field/Frame Interrupts.
NTV2GeometrySet GetRelatedGeometries(const NTV2FrameGeometry inFrameGeometry)
std::string NTV2MixerKeyerModeToString(const NTV2MixerKeyerMode inValue, const bool inCompactDisplay=false)
NTV2VideoFormat GetFirstMatchingVideoFormat(const NTV2FrameRate inFrameRate, const UWord inHeightLines, const UWord inWidthPixels, const bool inIsInterlaced, const bool inIsLevelB, const bool inIsPSF)
NTV2AudioSource
This enum value determines/states where an audio system will obtain its audio samples.
bool NTV2DeviceCanDoFormat(const NTV2DeviceID inDevID, const NTV2FrameRate inFR, const NTV2FrameGeometry inFG, const NTV2Standard inStd)
ULWord GetNTV2FrameGeometryHeight(const NTV2FrameGeometry inFrameGeometry)
NTV2AudioSystem NTV2ChannelToAudioSystem(const NTV2Channel inChannel)
Converts the given NTV2Channel value into its equivalent NTV2AudioSystem.
NTV2InputSource NTV2TimecodeIndexToInputSource(const NTV2TCIndex inTCIndex)
Converts the given NTV2TCIndex value into the appropriate NTV2InputSource value.
bool IsNTV2CrosspointInput(const NTV2Crosspoint inChannel)
void MakeUnPacked10BitYCbCrBuffer(uint16_t *buffer, uint16_t Y, uint16_t Cb, uint16_t Cr, uint32_t numPixels)
NTV2VideoFormat GetInputForConversionMode(const NTV2ConversionMode conversionMode)
NTV2OutputCrosspointIDs::const_iterator NTV2OutputCrosspointIDsConstIter
A convenient const iterator for NTV2OutputCrosspointIDs.
NTV2Standard GetNTV2StandardFromVideoFormat(const NTV2VideoFormat inVideoFormat)
bool Is4KFormat(const NTV2VideoFormat format)
void ConvertLineTo8BitYCbCr(const uint16_t *ycbcr10BitBuffer, uint8_t *ycbcr8BitBuffer, const uint32_t numPixels)
std::string SerialNum64ToString(const uint64_t &inSerNum)
std::string NTV2BitfileTypeToString(const NTV2BitfileType inValue, const bool inCompactDisplay=false)
ULWord GetVaricamRepeatCount(const NTV2FrameRate inSequenceRate, const NTV2FrameRate inPlayRate, const ULWord inCadenceFrame=0)
std::string NTV2AudioLoopBackToString(const NTV2AudioLoopBack inValue, const bool inForRetailDisplay=false)
bool Fill10BitYCbCrVideoFrame(void *pBaseVideoAddress, const NTV2Standard inStandard, const NTV2FrameBufferFormat inPixelFormat, const YCbCr10BitPixel inPixelColor, const NTV2VANCMode inVancMode=NTV2_VANCMODE_OFF)
std::string NTV2OutputCrosspointIDToString(const NTV2OutputCrosspointID inValue, const bool inForRetailDisplay=false)
std::set< NTV2DeviceID > NTV2DeviceIDSet
A set of NTV2DeviceIDs.
NTV2ConversionMode GetConversionMode(const NTV2VideoFormat inFormat, const NTV2VideoFormat outFormat)
NTV2AudioSource NTV2InputSourceToAudioSource(const NTV2InputSource inInputSource)
Identifies the first field in time for an interlaced video frame, or the first and only field in a pr...
INTERRUPT_ENUMS NTV2ChannelToOutputInterrupt(const NTV2Channel inChannel)
Converts the given NTV2Channel value into the equivalent output INTERRUPT_ENUMS value.
std::string NTV2VideoLimitingToString(const NTV2VideoLimiting inValue, const bool inCompactDisplay=false)
NTV2Audio4ChannelSelect
Identifies a contiguous, adjacent group of four audio channels.
UWord lastFrame(void) const
bool UnpackLine_10BitYUVtoUWordSequence(const void *pIn10BitYUVLine, UWordSequence &out16BitYUVLine, ULWord inNumPixels)
Unpacks a line of NTV2_FBF_10BIT_YCBCR video into 16-bit-per-component YUV data.
std::string NTV2ChannelToString(const NTV2Channel inValue, const bool inForRetailDisplay=false)
std::string NTV2EmbeddedAudioInputToString(const NTV2EmbeddedAudioInput inValue, const bool inCompactDisplay=false)
Declares enums and structs used by all platform drivers and the SDK.
bool IsPSF(const NTV2VideoFormat format)
NTV2RegisterReads FromRegNumSet(const NTV2RegNumSet &inRegNumSet)
std::vector< NTV2DeviceID > NTV2DeviceIDList
An ordered list of NTV2DeviceIDs.
bool IsYCbCrFormat(const NTV2FrameBufferFormat format)
NTV2FrameGeometry GetGeometryFromStandard(const NTV2Standard inStandard)
NTV2DeviceIDList::const_iterator NTV2DeviceIDListConstIter
A convenient const iterator for NTV2DeviceIDList.
double GetFrameTime(const NTV2FrameRate inFrameRate)
bool SetRasterLinesBlack(const NTV2PixelFormat inPixelFormat, UByte *pDstBuffer, const ULWord inDstBytesPerLine, const UWord inDstTotalLines)
Sets all or part of a destination raster image to legal black.
NTV2EmbeddedAudioInput
This enum value determines/states which SDI video input will be used to supply audio samples to an au...
ULWord GetIndexForNTV2CrosspointInput(const NTV2Crosspoint inChannel)
NTV2HDMIBitDepth
Indicates or specifies the HDMI video bit depth.
NTV2VideoFormat GetQuadSizedVideoFormat(const NTV2VideoFormat inVideoFormat, const bool isSquareDivision=true)
bool Is2KFormat(const NTV2VideoFormat format)
#define NTV2_DEPRECATED_16_1(__f__)
ULWord GetIndexForNTV2CrosspointChannel(const NTV2Crosspoint inChannel)
NTV2Channel NTV2CrosspointToNTV2Channel(const NTV2Crosspoint inCrosspointChannel)
NTV2MixerKeyerMode
These enum values identify the mixer mode.
NTV2Audio8ChannelSelect
Identifies a contiguous, adjacent group of eight audio channels.
This identifies the mode in which there are no VANC lines in the frame buffer.
NTV2StringList::const_iterator NTV2StringListConstIter
NTV2Standard GetStandardFromGeometry(const NTV2FrameGeometry inGeometry, const bool inIsProgressive=true)
std::string NTV2FrameRateToString(const NTV2FrameRate inValue, const bool inForRetailDisplay=false)
ULWord AddAudioTestPattern(ULWord *pAudioBuffer, ULWord &inOutCurrentSample, const ULWord inNumSamples, const ULWord inModulus, const bool inEndianConvert, const ULWord inNumChannels)
NTV2VideoFormat GetOutputForConversionMode(const NTV2ConversionMode conversionMode)
std::set< std::string > NTV2StringSet
enum NTV2TCIndex NTV2TimecodeIndex
bool GetRegNumChanges(const NTV2RegNumSet &inBefore, const NTV2RegNumSet &inAfter, NTV2RegNumSet &outGone, NTV2RegNumSet &outSame, NTV2RegNumSet &outAdded)
NTV2ReferenceSource NTV2InputSourceToReferenceSource(const NTV2InputSource inInputSource)
Converts a given NTV2InputSource to its equivalent NTV2ReferenceSource value.
ULWord GetScaleFromFrameRate(const NTV2FrameRate inFrameRate)
NTV2FrameGeometry GetNTV2FrameGeometryFromVideoFormat(const NTV2VideoFormat inVideoFormat)
bool isCountOnly(void) const
NTV2InputSource GetNTV2HDMIInputSourceForIndex(const ULWord inIndex0)