Class GstVideo
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final StringA bufferpool option to enable extra padding.static final StringAn option that can be activated on a bufferpool to request gl texture upload meta on buffers from the pool.static final StringAn option that can be activated on bufferpool to request video metadata on buffers from the pool.static final StringName of the caps feature indicating that the stream is interlaced.static final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringThis metadata stays relevant as long as video colorspace is unchanged.static final StringThis metadata stays relevant as long as video orientation is unchanged.static final StringThis metadata stays relevant as long as video size is unchanged.static final StringThis metadata is relevant for video streams.static final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final StringGstVideoAlphaMode, the alpha mode to use.static final StringG_TYPE_DOUBLE, the alpha color value to use.static final StringG_TYPE_BOOLEAN, whether gst_video_converter_frame() will return immediately without waiting for the conversion to complete.static final StringG_TYPE_UINT, the border color to use ifGST_VIDEO_CONVERTER_OPT_FILL_BORDERis set totrue.static final StringGstVideoChromaMode, set the chroma resample mode subsampled formats.static final StringGstVideoChromaMethod, The resampler method to use for chroma resampling.static final StringG_TYPE_INT, height in the destination frame, default destination heightstatic final StringG_TYPE_INT, width in the destination frame, default destination widthstatic final StringG_TYPE_INT, x position in the destination frame, default 0static final StringG_TYPE_INT, y position in the destination frame, default 0static final StringGstVideoDitherMethod, The dither method to use when changing bit depth.static final StringG_TYPE_UINT, The quantization amount to dither to.static final StringG_TYPE_BOOLEAN, if the destination rectangle does not fill the complete destination image, render a border withGST_VIDEO_CONVERTER_OPT_BORDER_ARGB.static final StringGstVideoGammaMode, set the gamma mode.static final StringGstVideoMatrixMode, set the color matrix conversion mode for converting between Y'PbPr and non-linear RGB (R'G'B').static final StringGstVideoPrimariesMode, set the primaries conversion mode.static final StringGstVideoResamplerMethod, The resampler method to use for resampling.static final StringG_TYPE_UINT, The number of taps for the resampler.static final StringG_TYPE_INT, source height to convert, default source heightstatic final StringG_TYPE_INT, source width to convert, default source widthstatic final StringG_TYPE_INT, source x position to start conversion, default 0static final StringG_TYPE_INT, source y position to start conversion, default 0static final StringG_TYPE_UINT, maximum number of threads to use.static final intDefault maximum number of errors tolerated before signaling error.static final StringThe name of the templates for the sink pad.static final StringThe name of the templates for the source pad.static final StringGeneric caps string for video wit DMABuf(GST_CAPS_FEATURE_MEMORY_DMABUF) feature, for use in pad templates.static final StringThe name of the templates for the sink pad.static final StringThe name of the templates for the source pad.static final intNumber of video formats inGstVideoFormat.static final StringList of all video formats, for use in template caps strings.static final StringDeclare all video formats as a string.static final StringThis is similar toGST_VIDEO_FORMATS_ALLbut includes formats like DMA_DRM that do not have a software converter.static final StringThis is similar toGST_VIDEO_FORMATS_ALL_STRbut includes formats like DMA_DRM for which no software converter exists.static final Stringstatic final intstatic final intstatic final StringG_TYPE_DOUBLE, B parameter of the cubic filter.static final StringG_TYPE_DOUBLE, C parameter of the cubic filter.static final StringG_TYPE_DOUBLE, specifies the size of filter envelope forGSTVIDEORESAMPLERMETHODLANCZOS.values are clamped between 1.0 and 5.0.static final StringG_TYPE_INT, limits the maximum number of taps to use.static final StringG_TYPE_DOUBLE, specifies sharpening of the filter forGSTVIDEORESAMPLERMETHODLANCZOS.values are clamped between 0.0 and 1.0.static final StringG_TYPE_DOUBLE, specifies sharpness of the filter forGSTVIDEORESAMPLERMETHODLANCZOS.values are clamped between 0.5 and 1.5.static final StringGstVideoDitherMethod, The dither method to use for propagating quatization errors.static final Stringstatic final intstatic final intstatic final intstatic final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Typestatic AncillaryMetabufferAddAncillaryMeta(Buffer buffer) Adds a newGstAncillaryMetato thebuffer.The caller is responsible for setting the appropriate fields.static VideoAFDMetabufferAddVideoAfdMeta(Buffer buffer, byte field, VideoAFDSpec spec, VideoAFDValue afd) AttachesGstVideoAFDMetametadata tobufferwith the given parameters.Attaches GstVideoAffineTransformationMeta metadata tobufferwith the given parameters.static VideoBarMetabufferAddVideoBarMeta(Buffer buffer, byte field, boolean isLetterbox, int barData1, int barData2) AttachesGstVideoBarMetametadata tobufferwith the given parameters.static VideoCaptionMetabufferAddVideoCaptionMeta(Buffer buffer, VideoCaptionType captionType, @org.jspecify.annotations.Nullable byte @Nullable [] data) AttachesGstVideoCaptionMetametadata tobufferwith the given parameters.static VideoCodecAlphaMetabufferAddVideoCodecAlphaMeta(Buffer buffer, Buffer alphaBuffer) Attaches aGstVideoCodecAlphaMetametadata tobufferwith the given alpha buffer.static VideoGLTextureUploadMetabufferAddVideoGlTextureUploadMeta(Buffer buffer, VideoGLTextureOrientation textureOrientation, int nTextures, Out<VideoGLTextureType> textureType, @Nullable VideoGLTextureUpload upload, @Nullable BoxedCopyFunc userDataCopy, @Nullable BoxedFreeFunc userDataFree) Attaches GstVideoGLTextureUploadMeta metadata tobufferwith the given parameters.static VideoMetabufferAddVideoMeta(Buffer buffer, Set<VideoFrameFlags> flags, VideoFormat format, int width, int height) Attaches GstVideoMeta metadata tobufferwith the given parameters and the default offsets and strides forformatandwidthxheight.static VideoMetabufferAddVideoMeta(Buffer buffer, VideoFrameFlags flags, VideoFormat format, int width, int height) Attaches GstVideoMeta metadata tobufferwith the given parameters and the default offsets and strides forformatandwidthxheight.static VideoMetabufferAddVideoMetaFull(Buffer buffer, Set<VideoFrameFlags> flags, VideoFormat format, int width, int height, int nPlanes, @org.jspecify.annotations.Nullable long @Nullable [] offset, @org.jspecify.annotations.Nullable int @Nullable [] stride) Attaches GstVideoMeta metadata tobufferwith the given parameters.static VideoMetabufferAddVideoMetaFull(Buffer buffer, VideoFrameFlags flags, VideoFormat format, int width, int height, int nPlanes, @org.jspecify.annotations.Nullable long @Nullable [] offset, @org.jspecify.annotations.Nullable int @Nullable [] stride) Attaches GstVideoMeta metadata tobufferwith the given parameters.static VideoOverlayCompositionMetabufferAddVideoOverlayCompositionMeta(Buffer buf, @Nullable VideoOverlayComposition comp) Sets an overlay composition on a buffer.static VideoRegionOfInterestMetabufferAddVideoRegionOfInterestMeta(Buffer buffer, String roiType, int x, int y, int w, int h) AttachesGstVideoRegionOfInterestMetametadata tobufferwith the given parameters.static VideoRegionOfInterestMetabufferAddVideoRegionOfInterestMetaId(Buffer buffer, Quark roiType, int x, int y, int w, int h) AttachesGstVideoRegionOfInterestMetametadata tobufferwith the given parameters.bufferAddVideoSeiUserDataUnregisteredMeta(Buffer buffer, MemorySegment uuid, @Nullable MemorySegment data, long size) AttachesGstVideoSEIUserDataUnregisteredMetametadata tobufferwith the given parameters.static @Nullable VideoTimeCodeMetabufferAddVideoTimeCodeMeta(Buffer buffer, VideoTimeCode tc) AttachesGstVideoTimeCodeMetametadata tobufferwith the given parameters.static @Nullable VideoTimeCodeMetabufferAddVideoTimeCodeMetaFull(Buffer buffer, int fpsN, int fpsD, DateTime latestDailyJam, Set<VideoTimeCodeFlags> flags, int hours, int minutes, int seconds, int frames, int fieldCount) AttachesGstVideoTimeCodeMetametadata tobufferwith the given parameters.static @Nullable VideoTimeCodeMetabufferAddVideoTimeCodeMetaFull(Buffer buffer, int fpsN, int fpsD, DateTime latestDailyJam, VideoTimeCodeFlags flags, int hours, int minutes, int seconds, int frames, int fieldCount) AttachesGstVideoTimeCodeMetametadata tobufferwith the given parameters.static @Nullable VideoMetabufferGetVideoMeta(Buffer buffer) Find theGstVideoMetaonbufferwith the lowestid.static @Nullable VideoMetabufferGetVideoMetaId(Buffer buffer, int id) Find theGstVideoMetaonbufferwith the givenid.static @Nullable VideoRegionOfInterestMetabufferGetVideoRegionOfInterestMetaId(Buffer buffer, int id) Find theGstVideoRegionOfInterestMetaonbufferwith the givenid.static booleanbufferPoolConfigGetVideoAlignment(Structure config, VideoAlignment align) Get the video alignment from the bufferpool configurationconfigin inalignstatic voidbufferPoolConfigSetVideoAlignment(Structure config, VideoAlignment align) Set the video alignment inalignto the bufferpool configurationconfigstatic booleanConvenience function to check if the given message is a "prepare-window-handle" message from aGstVideoOverlay.static voidstatic Typestatic Typestatic Typestatic booleanvideoBlend(VideoFrame dest, VideoFrame src, int x, int y, float globalAlpha) Lets you blend thesrcimage into thedestimagestatic voidvideoBlendScaleLinearRGBA(VideoInfo src, Buffer srcBuffer, int destHeight, int destWidth, VideoInfo dest, Out<Buffer> destBuffer) Scales a buffer containing RGBA (or AYUV) video.static booleanvideoCalculateDisplayRatio(Out<Integer> darN, Out<Integer> darD, int videoWidth, int videoHeight, int videoParN, int videoParD, int displayParN, int displayParD) Given the Pixel Aspect Ratio and size of an input video frame, and the pixel aspect ratio of the intended display device, calculates the actual display ratio the video will be rendered with.static Typestatic voidvideoCenterRect(VideoRectangle src, VideoRectangle dst, VideoRectangle result, boolean scaling) Takessrcrectangle and position it at the center ofdstrectangle with or withoutscaling.It handles clipping if thesrcrectangle is bigger than thedstone andscalingis set to FALSE.static Set<VideoChromaSite> Deprecated.Use gst_video_chroma_site_from_string() instead.static voidvideoChromaResample(VideoChromaResample resample, @Nullable MemorySegment lines, int width) Perform resampling ofwidthchroma pixels inlines.static StringDeprecated.Use gst_video_chroma_site_to_string() instead.static StringvideoChromaToString(VideoChromaSite... site) Deprecated.Use gst_video_chroma_site_to_string() instead.static Typestatic doublevideoColorTransferDecode(VideoTransferFunction func, double val) Deprecated.static doublevideoColorTransferEncode(VideoTransferFunction func, double val) Deprecated.static @Nullable SamplevideoConvertSample(Sample sample, Caps toCaps, ClockTime timeout) Converts a raw video buffer into the specified output caps.static voidvideoConvertSampleAsync(Sample sample, Caps toCaps, ClockTime timeout, @Nullable VideoConvertSampleCallback callback) Converts a raw video buffer into the specified output caps.static Typestatic intvideoDmaDrmFormatFromGstFormat(VideoFormat format, @Nullable MemorySegment modifier) Converting the video format into dma drm fourcc/modifier pair.static VideoFormatvideoDmaDrmFormatToGstFormat(int fourcc, long modifier) Converting a dma drm fourcc and modifier pair into aGstVideoFormat.static intConverting the video format into dma drm fourcc.static intvideoDmaDrmFourccFromString(String formatStr, @Nullable Out<Long> modifier) Convert theformatStrstring into the drm fourcc value.static VideoFormatvideoDmaDrmFourccToFormat(int fourcc) Converting a dma drm fourcc into the video format.static @Nullable StringvideoDmaDrmFourccToString(int fourcc, long modifier) Returns a string containing drm kind format, such as NV12:0x0100000000000002, or NULL otherwise.static booleanvideoEventIsForceKeyUnit(Event event) Checks if an event is a force key unit event.static EventvideoEventNewDownstreamForceKeyUnit(ClockTime timestamp, ClockTime streamTime, ClockTime runningTime, boolean allHeaders, int count) Creates a new downstream force key unit event.static EventvideoEventNewStillFrame(boolean inStill) Creates a new Still Frame event.static EventvideoEventNewUpstreamForceKeyUnit(ClockTime runningTime, boolean allHeaders, int count) Creates a new upstream force key unit event.static booleanvideoEventParseDownstreamForceKeyUnit(Event event, ClockTime timestamp, ClockTime streamTime, ClockTime runningTime, Out<Boolean> allHeaders, Out<Integer> count) Get timestamp, stream-time, running-time, all-headers and count in the force key unit event.static booleanvideoEventParseStillFrame(Event event, Out<Boolean> inStill) Parse aGstEvent, identify if it is a Still Frame event, and return the still-frame state from the event if it is.static booleanvideoEventParseUpstreamForceKeyUnit(Event event, ClockTime runningTime, Out<Boolean> allHeaders, Out<Integer> count) Get running-time, all-headers and count in the force key unit event.static VideoFormat[]Return all the raw video formats supported by GStreamer including special opaque formats such asVideoFormat.DMA_DRMfor which no software conversion exists.static VideoFormat[]Return all the raw video formats supported by GStreamer.static Typestatic booleanGiven the nominal duration of one video frame, this function will check some standard framerates for a close match (within 0.1%) and return one if possible,static booleanvideoIsCommonAspectRatio(int width, int height, int parN, int parD) Given a frame's dimensions and pixel aspect ratio, this function will calculate the frame's aspect ratio and compare it against a set of common well-known "standard" aspect ratios.static booleanvideoIsDmaDrmCaps(Caps caps) Check whether thecapsis a dma drm kind caps.static CapsvideoMakeRawCaps(@Nullable VideoFormat @Nullable [] formats) Return a generic raw video caps for formats defined informats.Ifformatsisnullreturns a caps for all the supported raw video formats, see gst_video_formats_raw().static CapsvideoMakeRawCapsWithFeatures(@Nullable VideoFormat @Nullable [] formats, @Nullable CapsFeatures features) Return a generic raw video caps for formats defined informatswith featuresfeatures.Ifformatsisnullreturns a caps for all the supported video formats, see gst_video_formats_raw().static Typestatic Valuestatic Valuestatic Valuestatic Valuestatic Valuestatic booleanvideoMultiviewGuessHalfAspect(VideoMultiviewMode mvMode, int width, int height, int parN, int parD) static voidvideoMultiviewVideoInfoChangeMode(VideoInfo info, VideoMultiviewMode outMviewMode, Set<VideoMultiviewFlags> outMviewFlags) Utility function that transforms the width/height/PAR and multiview mode and flags of aGstVideoInfointo the requested mode.static voidvideoMultiviewVideoInfoChangeMode(VideoInfo info, VideoMultiviewMode outMviewMode, VideoMultiviewFlags... outMviewFlags) Utility function that transforms the width/height/PAR and multiview mode and flags of aGstVideoInfointo the requested mode.static Typestatic Typestatic Typestatic booleanvideoSeiUserDataUnregisteredParsePrecisionTimeStamp(VideoSEIUserDataUnregisteredMeta userData, Out<Byte> status, Out<Long> precisionTimeStamp) Parses and returns the Precision Time Stamp (ST 0604) from the SEI User Data Unregistered bufferstatic intvideoTileGetIndex(VideoTileMode mode, int x, int y, int xTiles, int yTiles) Get the tile index of the tile at coordinatesxandyin the tiled image ofxTilesbyyTiles.static Type
-
Field Details
-
BUFFER_POOL_OPTION_VIDEO_AFFINE_TRANSFORMATION_META
- See Also:
-
BUFFER_POOL_OPTION_VIDEO_ALIGNMENT
A bufferpool option to enable extra padding. When a bufferpool supports this option, gst_buffer_pool_config_set_video_alignment() can be called.When this option is enabled on the bufferpool,
GST_BUFFER_POOL_OPTION_VIDEO_METAshould also be enabled.- See Also:
-
BUFFER_POOL_OPTION_VIDEO_GL_TEXTURE_UPLOAD_META
An option that can be activated on a bufferpool to request gl texture upload meta on buffers from the pool.When this option is enabled on the bufferpool,
GSTBUFFERPOOLOPTIONVIDEOMETAshould also be enabled.- Since:
- 1.2.2
- See Also:
-
BUFFER_POOL_OPTION_VIDEO_META
An option that can be activated on bufferpool to request video metadata on buffers from the pool.- See Also:
-
CAPS_FEATURE_FORMAT_INTERLACED
Name of the caps feature indicating that the stream is interlaced.Currently it is only used for video with 'interlace-mode=alternate' to ensure backwards compatibility for this new mode. In this mode each buffer carries a single field of interlaced video.
GSTVIDEOBUFFERFLAGTOPFIELDandGSTVIDEOBUFFERFLAGBOTTOMFIELDindicate whether the buffer carries a top or bottom field. The order of buffers/fields in the stream and the timestamps on the buffers indicate the temporal order of the fields. Top and bottom fields are expected to alternate in this mode. The frame rate in the caps still signals the frame rate, so the notional field rate will be twice the frame rate from the caps (seeGSTVIDEOINFOFIELDRATEN).- Since:
- 1.16.
- See Also:
-
CAPS_FEATURE_META_GST_VIDEO_AFFINE_TRANSFORMATION_META
- See Also:
-
CAPS_FEATURE_META_GST_VIDEO_GL_TEXTURE_UPLOAD_META
- See Also:
-
CAPS_FEATURE_META_GST_VIDEO_META
- See Also:
-
CAPS_FEATURE_META_GST_VIDEO_OVERLAY_COMPOSITION
- See Also:
-
META_TAG_VIDEO_COLORSPACE_STR
This metadata stays relevant as long as video colorspace is unchanged.- Since:
- 1.2
- See Also:
-
META_TAG_VIDEO_ORIENTATION_STR
This metadata stays relevant as long as video orientation is unchanged.- Since:
- 1.2
- See Also:
-
META_TAG_VIDEO_SIZE_STR
This metadata stays relevant as long as video size is unchanged.- Since:
- 1.2
- See Also:
-
META_TAG_VIDEO_STR
This metadata is relevant for video streams.- Since:
- 1.2
- See Also:
-
VIDEO_COLORIMETRY_BT2020
- See Also:
-
VIDEO_COLORIMETRY_BT2020_10
- See Also:
-
VIDEO_COLORIMETRY_BT2100_HLG
- See Also:
-
VIDEO_COLORIMETRY_BT2100_PQ
- See Also:
-
VIDEO_COLORIMETRY_BT601
- See Also:
-
VIDEO_COLORIMETRY_BT709
- See Also:
-
VIDEO_COLORIMETRY_SMPTE240M
- See Also:
-
VIDEO_COLORIMETRY_SRGB
- See Also:
-
VIDEO_COMP_A
public static final int VIDEO_COMP_A- See Also:
-
VIDEO_COMP_B
public static final int VIDEO_COMP_B- See Also:
-
VIDEO_COMP_G
public static final int VIDEO_COMP_G- See Also:
-
VIDEO_COMP_INDEX
public static final int VIDEO_COMP_INDEX- See Also:
-
VIDEO_COMP_PALETTE
public static final int VIDEO_COMP_PALETTE- See Also:
-
VIDEO_COMP_R
public static final int VIDEO_COMP_R- See Also:
-
VIDEO_COMP_U
public static final int VIDEO_COMP_U- See Also:
-
VIDEO_COMP_V
public static final int VIDEO_COMP_V- See Also:
-
VIDEO_COMP_Y
public static final int VIDEO_COMP_Y- See Also:
-
VIDEO_CONVERTER_OPT_ALPHA_MODE
GstVideoAlphaMode, the alpha mode to use. Default isGST_VIDEO_ALPHA_MODE_COPY.- See Also:
-
VIDEO_CONVERTER_OPT_ALPHA_VALUE
G_TYPE_DOUBLE, the alpha color value to use. Default to 1.0- See Also:
-
VIDEO_CONVERTER_OPT_ASYNC_TASKS
G_TYPE_BOOLEAN, whether gst_video_converter_frame() will return immediately without waiting for the conversion to complete. A subsequent gst_video_converter_frame_finish() must be performed to ensure completion of the conversion before subsequent use. Defaultfalse- Since:
- 1.20
- See Also:
-
VIDEO_CONVERTER_OPT_BORDER_ARGB
G_TYPE_UINT, the border color to use ifGST_VIDEO_CONVERTER_OPT_FILL_BORDERis set totrue. The color is in ARGB format. Default 0xff000000- See Also:
-
VIDEO_CONVERTER_OPT_CHROMA_MODE
GstVideoChromaMode, set the chroma resample mode subsampled formats. Default isGST_VIDEO_CHROMA_MODE_FULL.- See Also:
-
VIDEO_CONVERTER_OPT_CHROMA_RESAMPLER_METHOD
GstVideoChromaMethod, The resampler method to use for chroma resampling. Other options for the resampler can be used, see theGstVideoResampler. Default isGST_VIDEO_RESAMPLER_METHOD_LINEAR- See Also:
-
VIDEO_CONVERTER_OPT_DEST_HEIGHT
G_TYPE_INT, height in the destination frame, default destination height- See Also:
-
VIDEO_CONVERTER_OPT_DEST_WIDTH
G_TYPE_INT, width in the destination frame, default destination width- See Also:
-
VIDEO_CONVERTER_OPT_DEST_X
G_TYPE_INT, x position in the destination frame, default 0- See Also:
-
VIDEO_CONVERTER_OPT_DEST_Y
G_TYPE_INT, y position in the destination frame, default 0- See Also:
-
VIDEO_CONVERTER_OPT_DITHER_METHOD
GstVideoDitherMethod, The dither method to use when changing bit depth. Default isGST_VIDEO_DITHER_BAYER.- See Also:
-
VIDEO_CONVERTER_OPT_DITHER_QUANTIZATION
G_TYPE_UINT, The quantization amount to dither to. Components will be quantized to multiples of this value. Default is 1- See Also:
-
VIDEO_CONVERTER_OPT_FILL_BORDER
G_TYPE_BOOLEAN, if the destination rectangle does not fill the complete destination image, render a border withGST_VIDEO_CONVERTER_OPT_BORDER_ARGB. Otherwise the unusded pixels in the destination are untouched. Defaulttrue.- See Also:
-
VIDEO_CONVERTER_OPT_GAMMA_MODE
GstVideoGammaMode, set the gamma mode. Default isGST_VIDEO_GAMMA_MODE_NONE.- See Also:
-
VIDEO_CONVERTER_OPT_MATRIX_MODE
GstVideoMatrixMode, set the color matrix conversion mode for converting between Y'PbPr and non-linear RGB (R'G'B'). Default isGST_VIDEO_MATRIX_MODE_FULL.- See Also:
-
VIDEO_CONVERTER_OPT_PRIMARIES_MODE
GstVideoPrimariesMode, set the primaries conversion mode. Default isGST_VIDEO_PRIMARIES_MODE_NONE.- See Also:
-
VIDEO_CONVERTER_OPT_RESAMPLER_METHOD
GstVideoResamplerMethod, The resampler method to use for resampling. Other options for the resampler can be used, see theGstVideoResampler. Default isGST_VIDEO_RESAMPLER_METHOD_CUBIC- See Also:
-
VIDEO_CONVERTER_OPT_RESAMPLER_TAPS
G_TYPE_UINT, The number of taps for the resampler. Default is 0: let the resampler choose a good value.- See Also:
-
VIDEO_CONVERTER_OPT_SRC_HEIGHT
G_TYPE_INT, source height to convert, default source height- See Also:
-
VIDEO_CONVERTER_OPT_SRC_WIDTH
G_TYPE_INT, source width to convert, default source width- See Also:
-
VIDEO_CONVERTER_OPT_SRC_X
G_TYPE_INT, source x position to start conversion, default 0- See Also:
-
VIDEO_CONVERTER_OPT_SRC_Y
G_TYPE_INT, source y position to start conversion, default 0- See Also:
-
VIDEO_CONVERTER_OPT_THREADS
G_TYPE_UINT, maximum number of threads to use. Default 1, 0 for the number of cores.- See Also:
-
VIDEO_DECODER_MAX_ERRORS
public static final int VIDEO_DECODER_MAX_ERRORSDefault maximum number of errors tolerated before signaling error.- See Also:
-
VIDEO_DECODER_SINK_NAME
The name of the templates for the sink pad.- See Also:
-
VIDEO_DECODER_SRC_NAME
The name of the templates for the source pad.- See Also:
-
VIDEO_DMA_DRM_CAPS_MAKE
Generic caps string for video wit DMABuf(GST_CAPS_FEATURE_MEMORY_DMABUF) feature, for use in pad templates. As drm-format is supposed to be defined at run-time it's not predefined here.- Since:
- 1.24
- See Also:
-
VIDEO_ENCODER_SINK_NAME
The name of the templates for the sink pad.- See Also:
-
VIDEO_ENCODER_SRC_NAME
The name of the templates for the source pad.- See Also:
-
VIDEO_FORMATS_ALL
List of all video formats, for use in template caps strings.Formats are sorted by decreasing "quality", using these criteria by priority:
- number of components
- depth
- subsampling factor of the width
- subsampling factor of the height
- number of planes
- native endianness preferred
- pixel stride
- poffset
- prefer non-complex formats
- prefer YUV formats over RGB ones
- prefer I420 over YV12
- format name
- See Also:
-
VIDEO_FORMATS_ALL_STR
Declare all video formats as a string.Formats are sorted by decreasing "quality", using these criteria by priority:
- number of components
- depth
- subsampling factor of the width
- subsampling factor of the height
- number of planes
- native endianness preferred
- pixel stride
- poffset
- prefer non-complex formats
- prefer YUV formats over RGB ones
- prefer I420 over YV12
- format name
- Since:
- 1.24
- See Also:
-
VIDEO_FORMATS_ANY
This is similar toGST_VIDEO_FORMATS_ALLbut includes formats like DMA_DRM that do not have a software converter. This should be used for passthrough template caps.- Since:
- 1.24
- See Also:
-
VIDEO_FORMATS_ANY_STR
This is similar toGST_VIDEO_FORMATS_ALL_STRbut includes formats like DMA_DRM for which no software converter exists. This should be used for passthrough template caps.- Since:
- 1.24
- See Also:
-
VIDEO_FORMAT_LAST
public static final int VIDEO_FORMAT_LASTNumber of video formats inGstVideoFormat.- Since:
- 1.26
- See Also:
-
VIDEO_FPS_RANGE
- See Also:
-
VIDEO_MAX_COMPONENTS
public static final int VIDEO_MAX_COMPONENTS- See Also:
-
VIDEO_MAX_PLANES
public static final int VIDEO_MAX_PLANES- See Also:
-
VIDEO_RESAMPLER_OPT_CUBIC_B
G_TYPE_DOUBLE, B parameter of the cubic filter. The B parameter controls the bluriness. Values between 0.0 and 2.0 are accepted. 1/3 is the default.Below are some values of popular filters: B C Hermite 0.0 0.0 Spline 1.0 0.0 Catmull-Rom 0.0 1/2 Mitchell 1/3 1/3 Robidoux 0.3782 0.3109 Robidoux Sharp 0.2620 0.3690 Robidoux Soft 0.6796 0.1602
- See Also:
-
VIDEO_RESAMPLER_OPT_CUBIC_C
G_TYPE_DOUBLE, C parameter of the cubic filter. The C parameter controls the Keys alpha value. Values between 0.0 and 2.0 are accepted. 1/3 is the default.See
GST_VIDEO_RESAMPLER_OPT_CUBIC_Bfor some more common values- See Also:
-
VIDEO_RESAMPLER_OPT_ENVELOPE
G_TYPE_DOUBLE, specifies the size of filter envelope forGSTVIDEORESAMPLERMETHODLANCZOS.values are clamped between 1.0 and 5.0. 2.0 is the default.- See Also:
-
VIDEO_RESAMPLER_OPT_MAX_TAPS
G_TYPE_INT, limits the maximum number of taps to use. 16 is the default.- See Also:
-
VIDEO_RESAMPLER_OPT_SHARPEN
G_TYPE_DOUBLE, specifies sharpening of the filter forGSTVIDEORESAMPLERMETHODLANCZOS.values are clamped between 0.0 and 1.0. 0.0 is the default.- See Also:
-
VIDEO_RESAMPLER_OPT_SHARPNESS
G_TYPE_DOUBLE, specifies sharpness of the filter forGSTVIDEORESAMPLERMETHODLANCZOS.values are clamped between 0.5 and 1.5. 1.0 is the default.- See Also:
-
VIDEO_SCALER_OPT_DITHER_METHOD
GstVideoDitherMethod, The dither method to use for propagating quatization errors.- See Also:
-
VIDEO_SIZE_RANGE
- See Also:
-
VIDEO_TILE_TYPE_MASK
public static final int VIDEO_TILE_TYPE_MASK- See Also:
-
VIDEO_TILE_TYPE_SHIFT
public static final int VIDEO_TILE_TYPE_SHIFT- See Also:
-
VIDEO_TILE_X_TILES_MASK
public static final int VIDEO_TILE_X_TILES_MASK- See Also:
-
VIDEO_TILE_Y_TILES_SHIFT
public static final int VIDEO_TILE_Y_TILES_SHIFT- See Also:
-
-
Constructor Details
-
GstVideo
public GstVideo()
-
-
Method Details
-
javagi$ensureInitialized
public static void javagi$ensureInitialized() -
ancillaryMetaApiGetType
-
bufferAddAncillaryMeta
Adds a newGstAncillaryMetato thebuffer.The caller is responsible for setting the appropriate fields.- Parameters:
buffer- AGstBuffer- Returns:
- A new
GstAncillaryMeta, ornullif an error happened. - Since:
- 1.24
-
bufferAddVideoAfdMeta
public static VideoAFDMeta bufferAddVideoAfdMeta(Buffer buffer, byte field, VideoAFDSpec spec, VideoAFDValue afd) AttachesGstVideoAFDMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferfield- 0 for progressive or field 1 and 1 for field 2spec-GstVideoAFDSpecthat applies to AFD valueafd-GstVideoAFDValueAFD enumeration- Returns:
- the
GstVideoAFDMetaonbuffer. - Since:
- 1.18
-
bufferAddVideoAffineTransformationMeta
Attaches GstVideoAffineTransformationMeta metadata tobufferwith the given parameters.- Parameters:
buffer- aGstBuffer- Returns:
- the
GstVideoAffineTransformationMetaonbuffer. - Since:
- 1.8
-
bufferAddVideoBarMeta
public static VideoBarMeta bufferAddVideoBarMeta(Buffer buffer, byte field, boolean isLetterbox, int barData1, int barData2) AttachesGstVideoBarMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferfield- 0 for progressive or field 1 and 1 for field 2isLetterbox- if true then bar data specifies letterbox, otherwise pillarboxbarData1- IfisLetterboxis true, then the value specifies the last line of a horizontal letterbox bar area at top of reconstructed frame. Otherwise, it specifies the last horizontal luminance sample of a vertical pillarbox bar area at the left side of the reconstructed framebarData2- IfisLetterboxis true, then the value specifies the first line of a horizontal letterbox bar area at bottom of reconstructed frame. Otherwise, it specifies the first horizontal luminance sample of a vertical pillarbox bar area at the right side of the reconstructed frame.- Returns:
- the
GstVideoBarMetaonbuffer.See Table 6.11 Bar Data Syntax
https://www.atsc.org/wp-content/uploads/2015/03/a_53-Part-4-2009.pdf
- Since:
- 1.18
-
bufferAddVideoCaptionMeta
public static VideoCaptionMeta bufferAddVideoCaptionMeta(Buffer buffer, VideoCaptionType captionType, @org.jspecify.annotations.Nullable byte @Nullable [] data) AttachesGstVideoCaptionMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBuffercaptionType- The type of Closed Caption to adddata- The Closed Caption data- Returns:
- the
GstVideoCaptionMetaonbuffer. - Since:
- 1.16
-
bufferAddVideoCodecAlphaMeta
Attaches aGstVideoCodecAlphaMetametadata tobufferwith the given alpha buffer.- Parameters:
buffer- aGstBufferalphaBuffer- aGstBuffer- Returns:
- the
GstVideoCodecAlphaMetaonbuffer. - Since:
- 1.20
-
bufferAddVideoGlTextureUploadMeta
public static VideoGLTextureUploadMeta bufferAddVideoGlTextureUploadMeta(Buffer buffer, VideoGLTextureOrientation textureOrientation, int nTextures, Out<VideoGLTextureType> textureType, @Nullable VideoGLTextureUpload upload, @Nullable BoxedCopyFunc userDataCopy, @Nullable BoxedFreeFunc userDataFree) Attaches GstVideoGLTextureUploadMeta metadata tobufferwith the given parameters.- Parameters:
buffer- aGstBuffertextureOrientation- theGstVideoGLTextureOrientationnTextures- the number of texturestextureType- array ofGstVideoGLTextureTypeupload- the function to upload the buffer to a specific texture IDuserDataCopy- function to copyuserDatauserDataFree- function to freeuserData- Returns:
- the
GstVideoGLTextureUploadMetaonbuffer.
-
bufferAddVideoMeta
public static VideoMeta bufferAddVideoMeta(Buffer buffer, Set<VideoFrameFlags> flags, VideoFormat format, int width, int height) Attaches GstVideoMeta metadata tobufferwith the given parameters and the default offsets and strides forformatandwidthxheight.This function calculates the default offsets and strides and then calls gst_buffer_add_video_meta_full() with them.
- Parameters:
buffer- aGstBufferflags-GstVideoFrameFlagsformat- aGstVideoFormatwidth- the widthheight- the height- Returns:
- the
GstVideoMetaonbuffer.
-
bufferAddVideoMeta
public static VideoMeta bufferAddVideoMeta(Buffer buffer, VideoFrameFlags flags, VideoFormat format, int width, int height) Attaches GstVideoMeta metadata tobufferwith the given parameters and the default offsets and strides forformatandwidthxheight.This function calculates the default offsets and strides and then calls gst_buffer_add_video_meta_full() with them.
- Parameters:
buffer- aGstBufferflags-GstVideoFrameFlagsformat- aGstVideoFormatwidth- the widthheight- the height- Returns:
- the
GstVideoMetaonbuffer.
-
bufferAddVideoMetaFull
public static VideoMeta bufferAddVideoMetaFull(Buffer buffer, Set<VideoFrameFlags> flags, VideoFormat format, int width, int height, int nPlanes, @org.jspecify.annotations.Nullable long @Nullable [] offset, @org.jspecify.annotations.Nullable int @Nullable [] stride) Attaches GstVideoMeta metadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferflags-GstVideoFrameFlagsformat- aGstVideoFormatwidth- the widthheight- the heightnPlanes- number of planesoffset- offset of each planestride- stride of each plane- Returns:
- the
GstVideoMetaonbuffer. - Throws:
IllegalArgumentException- when length ofoffsetis less than 4IllegalArgumentException- when length ofstrideis less than 4
-
bufferAddVideoMetaFull
public static VideoMeta bufferAddVideoMetaFull(Buffer buffer, VideoFrameFlags flags, VideoFormat format, int width, int height, int nPlanes, @org.jspecify.annotations.Nullable long @Nullable [] offset, @org.jspecify.annotations.Nullable int @Nullable [] stride) Attaches GstVideoMeta metadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferflags-GstVideoFrameFlagsformat- aGstVideoFormatwidth- the widthheight- the heightnPlanes- number of planesoffset- offset of each planestride- stride of each plane- Returns:
- the
GstVideoMetaonbuffer.
-
bufferAddVideoOverlayCompositionMeta
public static VideoOverlayCompositionMeta bufferAddVideoOverlayCompositionMeta(Buffer buf, @Nullable VideoOverlayComposition comp) Sets an overlay composition on a buffer. The buffer will obtain its own reference to the composition, meaning this function does not take ownership ofcomp.- Parameters:
buf- aGstBuffercomp- aGstVideoOverlayComposition- Returns:
- a
GstVideoOverlayCompositionMeta
-
bufferAddVideoRegionOfInterestMeta
public static VideoRegionOfInterestMeta bufferAddVideoRegionOfInterestMeta(Buffer buffer, String roiType, int x, int y, int w, int h) AttachesGstVideoRegionOfInterestMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferroiType- Type of the region of interest (e.g. "face")x- X positiony- Y positionw- widthh- height- Returns:
- the
GstVideoRegionOfInterestMetaonbuffer.
-
bufferAddVideoRegionOfInterestMetaId
public static VideoRegionOfInterestMeta bufferAddVideoRegionOfInterestMetaId(Buffer buffer, Quark roiType, int x, int y, int w, int h) AttachesGstVideoRegionOfInterestMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferroiType- Type of the region of interest (e.g. "face")x- X positiony- Y positionw- widthh- height- Returns:
- the
GstVideoRegionOfInterestMetaonbuffer.
-
bufferAddVideoSeiUserDataUnregisteredMeta
public static VideoSEIUserDataUnregisteredMeta bufferAddVideoSeiUserDataUnregisteredMeta(Buffer buffer, MemorySegment uuid, @Nullable MemorySegment data, long size) AttachesGstVideoSEIUserDataUnregisteredMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferuuid- User Data Unregistered UUIDdata- SEI User Data Unregistered buffersize- size of the data buffer- Returns:
- the
GstVideoSEIUserDataUnregisteredMetaonbuffer. - Since:
- 1.22
-
bufferAddVideoTimeCodeMeta
public static @Nullable VideoTimeCodeMeta bufferAddVideoTimeCodeMeta(Buffer buffer, VideoTimeCode tc) AttachesGstVideoTimeCodeMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBuffertc- aGstVideoTimeCode- Returns:
- the
GstVideoTimeCodeMetaonbuffer,or (since 1.16)nullif the timecode was invalid. - Since:
- 1.10
-
bufferAddVideoTimeCodeMetaFull
public static @Nullable VideoTimeCodeMeta bufferAddVideoTimeCodeMetaFull(Buffer buffer, int fpsN, int fpsD, DateTime latestDailyJam, Set<VideoTimeCodeFlags> flags, int hours, int minutes, int seconds, int frames, int fieldCount) AttachesGstVideoTimeCodeMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferfpsN- framerate numeratorfpsD- framerate denominatorlatestDailyJam- aGDateTimefor the latest daily jamflags- aGstVideoTimeCodeFlagshours- hours since the daily jamminutes- minutes since the daily jamseconds- seconds since the daily jamframes- frames since the daily jamfieldCount- fields since the daily jam- Returns:
- the
GstVideoTimeCodeMetaonbuffer,or (since 1.16)nullif the timecode was invalid. - Since:
- 1.10
-
bufferAddVideoTimeCodeMetaFull
public static @Nullable VideoTimeCodeMeta bufferAddVideoTimeCodeMetaFull(Buffer buffer, int fpsN, int fpsD, DateTime latestDailyJam, VideoTimeCodeFlags flags, int hours, int minutes, int seconds, int frames, int fieldCount) AttachesGstVideoTimeCodeMetametadata tobufferwith the given parameters.- Parameters:
buffer- aGstBufferfpsN- framerate numeratorfpsD- framerate denominatorlatestDailyJam- aGDateTimefor the latest daily jamflags- aGstVideoTimeCodeFlagshours- hours since the daily jamminutes- minutes since the daily jamseconds- seconds since the daily jamframes- frames since the daily jamfieldCount- fields since the daily jam- Returns:
- the
GstVideoTimeCodeMetaonbuffer,or (since 1.16)nullif the timecode was invalid. - Since:
- 1.10
-
bufferGetVideoMeta
Find theGstVideoMetaonbufferwith the lowestid.Buffers can contain multiple
GstVideoMetametadata items when dealing with multiview buffers.- Parameters:
buffer- aGstBuffer- Returns:
- the
GstVideoMetawith lowest id (usually 0) ornullwhen there is no such metadata onbuffer.
-
bufferGetVideoMetaId
Find theGstVideoMetaonbufferwith the givenid.Buffers can contain multiple
GstVideoMetametadata items when dealing with multiview buffers.- Parameters:
buffer- aGstBufferid- a metadata id- Returns:
- the
GstVideoMetawithidornullwhen there is no such metadata onbuffer.
-
bufferGetVideoRegionOfInterestMetaId
public static @Nullable VideoRegionOfInterestMeta bufferGetVideoRegionOfInterestMetaId(Buffer buffer, int id) Find theGstVideoRegionOfInterestMetaonbufferwith the givenid.Buffers can contain multiple
GstVideoRegionOfInterestMetametadata items if multiple regions of interests are marked on a frame.- Parameters:
buffer- aGstBufferid- a metadata id- Returns:
- the
GstVideoRegionOfInterestMetawithidornullwhen there is no such metadata onbuffer.
-
bufferPoolConfigGetVideoAlignment
Get the video alignment from the bufferpool configurationconfigin inalign- Parameters:
config- aGstStructurealign- aGstVideoAlignment- Returns:
trueifconfigcould be parsed correctly.
-
bufferPoolConfigSetVideoAlignment
Set the video alignment inalignto the bufferpool configurationconfig- Parameters:
config- aGstStructurealign- aGstVideoAlignment
-
isVideoOverlayPrepareWindowHandleMessage
Convenience function to check if the given message is a "prepare-window-handle" message from aGstVideoOverlay.- Parameters:
msg- aGstMessage- Returns:
- whether
msgis a "prepare-window-handle" message
-
videoAfdMetaApiGetType
-
videoAffineTransformationMetaApiGetType
-
videoBarMetaApiGetType
-
videoBlend
Lets you blend thesrcimage into thedestimage- Parameters:
dest- TheGstVideoFramewhere to blendsrcinsrc- theGstVideoFramethat we want to blend intox- The x offset in pixel where thesrcimage should be blendedy- the y offset in pixel where thesrcimage should be blendedglobalAlpha- the global_alpha each per-pixel alpha value is multiplied with
-
videoBlendScaleLinearRGBA
public static void videoBlendScaleLinearRGBA(VideoInfo src, Buffer srcBuffer, int destHeight, int destWidth, VideoInfo dest, Out<Buffer> destBuffer) Scales a buffer containing RGBA (or AYUV) video. This is an internal helper function which is used to scale subtitle overlays, and may be deprecated in the near future. UseGstVideoScalerto scale video buffers instead.- Parameters:
src- theGstVideoInfodescribing the video data insrcBuffersrcBuffer- the source buffer containing video pixels to scaledestHeight- the height in pixels to scale the video data insrcBuffertodestWidth- the width in pixels to scale the video data insrcBuffertodest- pointer to aGstVideoInfostructure that will be filled in with the details fordestBufferdestBuffer- a pointer to aGstBuffervariable, which will be set to a newly-allocated buffer containing the scaled pixels.
-
videoCalculateDisplayRatio
public static boolean videoCalculateDisplayRatio(Out<Integer> darN, Out<Integer> darD, int videoWidth, int videoHeight, int videoParN, int videoParD, int displayParN, int displayParD) Given the Pixel Aspect Ratio and size of an input video frame, and the pixel aspect ratio of the intended display device, calculates the actual display ratio the video will be rendered with.- Parameters:
darN- Numerator of the calculated display_ratiodarD- Denominator of the calculated display_ratiovideoWidth- Width of the video frame in pixelsvideoHeight- Height of the video frame in pixelsvideoParN- Numerator of the pixel aspect ratio of the input video.videoParD- Denominator of the pixel aspect ratio of the input video.displayParN- Numerator of the pixel aspect ratio of the display devicedisplayParD- Denominator of the pixel aspect ratio of the display device- Returns:
- A boolean indicating success and a calculated Display Ratio in the dar_n and dar_d parameters. The return value is FALSE in the case of integer overflow or other error.
-
videoCaptionMetaApiGetType
-
videoCenterRect
public static void videoCenterRect(VideoRectangle src, VideoRectangle dst, VideoRectangle result, boolean scaling) Takessrcrectangle and position it at the center ofdstrectangle with or withoutscaling.It handles clipping if thesrcrectangle is bigger than thedstone andscalingis set to FALSE.- Parameters:
src- a pointer toGstVideoRectangledescribing the source areadst- a pointer toGstVideoRectangledescribing the destination arearesult- a pointer to aGstVideoRectanglewhich will receive the result areascaling- agbooleanindicating if scaling should be applied or not- Since:
- 1.20
-
videoChromaFromString
Deprecated.Use gst_video_chroma_site_from_string() instead.Convertsto aGstVideoChromaSite- Parameters:
s- a chromasite string- Returns:
- a
GstVideoChromaSiteorVideoChromaSite.UNKNOWNwhensdoes not contain a valid chroma description.
-
videoChromaResample
public static void videoChromaResample(VideoChromaResample resample, @Nullable MemorySegment lines, int width) Perform resampling ofwidthchroma pixels inlines.- Parameters:
resample- aGstVideoChromaResamplelines- pixel lineswidth- the number of pixels on one line
-
videoChromaToString
Deprecated.Use gst_video_chroma_site_to_string() instead.Convertssiteto its string representation.- Parameters:
site- aGstVideoChromaSite- Returns:
- a string describing
site.
-
videoChromaToString
Deprecated.Use gst_video_chroma_site_to_string() instead.Convertssiteto its string representation.- Parameters:
site- aGstVideoChromaSite- Returns:
- a string describing
site.
-
videoCodecAlphaMetaApiGetType
-
videoColorTransferDecode
Deprecated. -
videoColorTransferEncode
Deprecated. -
videoConvertSample
public static @Nullable Sample videoConvertSample(Sample sample, Caps toCaps, ClockTime timeout) throws GErrorException Converts a raw video buffer into the specified output caps.The output caps can be any raw video formats or any image formats (jpeg, png, ...).
The width, height and pixel-aspect-ratio can also be specified in the output caps.
- Parameters:
sample- aGstSampletoCaps- theGstCapsto convert totimeout- the maximum amount of time allowed for the processing.- Returns:
- The converted
GstSample, ornullif an error happened (in which caseerrwill point to theGError). - Throws:
GErrorException- seeGError
-
videoConvertSampleAsync
public static void videoConvertSampleAsync(Sample sample, Caps toCaps, ClockTime timeout, @Nullable VideoConvertSampleCallback callback) Converts a raw video buffer into the specified output caps.The output caps can be any raw video formats or any image formats (jpeg, png, ...).
The width, height and pixel-aspect-ratio can also be specified in the output caps.
callbackwill be called after conversion, when an error occurred or if conversion didn't finish aftertimeout.callbackwill always be called from the thread defaultGMainContext, see g_main_context_get_thread_default(). If GLib before 2.22 is used, this will always be the global default main context.destroyNotifywill be called after the callback was called anduserDatais not needed anymore.- Parameters:
sample- aGstSampletoCaps- theGstCapsto convert totimeout- the maximum amount of time allowed for the processing.callback-GstVideoConvertSampleCallbackthat will be called after conversion.
-
videoCropMetaApiGetType
-
videoDmaDrmFormatFromGstFormat
public static int videoDmaDrmFormatFromGstFormat(VideoFormat format, @Nullable MemorySegment modifier) Converting the video format into dma drm fourcc/modifier pair. If no matching fourcc found, then DRM_FORMAT_INVALID is returned andmodifierwill be set to DRM_FORMAT_MOD_INVALID.- Parameters:
format- aGstVideoFormatmodifier- return location for the modifier- Returns:
- the DRM_FORMAT_* corresponding to
format. - Since:
- 1.26
-
videoDmaDrmFormatToGstFormat
Converting a dma drm fourcc and modifier pair into aGstVideoFormat. If no matching video format is found, then GST_VIDEO_FORMAT_UNKNOWN is returned.- Parameters:
fourcc- the dma drm fourcc value.modifier- the dma drm modifier.- Returns:
- the GST_VIDEO_FORMAT_* corresponding to the
fourccandmodifierpair. - Since:
- 1.26
-
videoDmaDrmFourccFromFormat
Converting the video format into dma drm fourcc. If no matching fourcc found, then DRM_FORMAT_INVALID is returned.- Parameters:
format- aGstVideoFormat- Returns:
- the DRM_FORMAT_* corresponding to the
format. - Since:
- 1.24
-
videoDmaDrmFourccFromString
Convert theformatStrstring into the drm fourcc value. Themodifieris also parsed if we want. Please note that theformatStrshould follow the fourcc:modifier kind style, such as NV12:0x0100000000000002- Parameters:
formatStr- a drm format stringmodifier- Return the modifier informatornullto ignore.- Returns:
- The drm fourcc value or DRM_FORMAT_INVALID if
formatStris invalid. - Since:
- 1.24
-
videoDmaDrmFourccToFormat
Converting a dma drm fourcc into the video format. If no matching video format found, then GST_VIDEO_FORMAT_UNKNOWN is returned.- Parameters:
fourcc- the dma drm value.- Returns:
- the GST_VIDEO_FORMAT_* corresponding to the
fourcc. - Since:
- 1.24
-
videoDmaDrmFourccToString
Returns a string containing drm kind format, such as NV12:0x0100000000000002, or NULL otherwise.- Parameters:
fourcc- a drm fourcc value.modifier- the associated modifier value.- Returns:
- the drm kind string composed
of to
fourccandmodifier. - Since:
- 1.24
-
videoEventIsForceKeyUnit
Checks if an event is a force key unit event. Returns true for both upstream and downstream force key unit events.- Parameters:
event- AGstEventto check- Returns:
trueif the event is a valid force key unit event
-
videoEventNewDownstreamForceKeyUnit
public static Event videoEventNewDownstreamForceKeyUnit(ClockTime timestamp, ClockTime streamTime, ClockTime runningTime, boolean allHeaders, int count) Creates a new downstream force key unit event. A downstream force key unit event can be sent down the pipeline to request downstream elements to produce a key unit. A downstream force key unit event must also be sent when handling an upstream force key unit event to notify downstream that the latter has been handled.To parse an event created by gst_video_event_new_downstream_force_key_unit() use gst_video_event_parse_downstream_force_key_unit().
- Parameters:
timestamp- the timestamp of the buffer that starts a new key unitstreamTime- the stream_time of the buffer that starts a new key unitrunningTime- the running_time of the buffer that starts a new key unitallHeaders-trueto produce headers when starting a new key unitcount- integer that can be used to number key units- Returns:
- The new GstEvent
-
videoEventNewStillFrame
Creates a new Still Frame event. IfinStillistrue, then the event represents the start of a still frame sequence. If it isfalse, then the event ends a still frame sequence.To parse an event created by gst_video_event_new_still_frame() use gst_video_event_parse_still_frame().
- Parameters:
inStill- boolean value for the still-frame state of the event.- Returns:
- The new GstEvent
-
videoEventNewUpstreamForceKeyUnit
public static Event videoEventNewUpstreamForceKeyUnit(ClockTime runningTime, boolean allHeaders, int count) Creates a new upstream force key unit event. An upstream force key unit event can be sent to request upstream elements to produce a key unit.runningTimecan be set to request a new key unit at a specific running_time. If set to GST_CLOCK_TIME_NONE, upstream elements will produce a new key unit as soon as possible.To parse an event created by gst_video_event_new_downstream_force_key_unit() use gst_video_event_parse_downstream_force_key_unit().
- Parameters:
runningTime- the running_time at which a new key unit should be producedallHeaders-trueto produce headers when starting a new key unitcount- integer that can be used to number key units- Returns:
- The new GstEvent
-
videoEventParseDownstreamForceKeyUnit
public static boolean videoEventParseDownstreamForceKeyUnit(Event event, ClockTime timestamp, ClockTime streamTime, ClockTime runningTime, Out<Boolean> allHeaders, Out<Integer> count) Get timestamp, stream-time, running-time, all-headers and count in the force key unit event. See gst_video_event_new_downstream_force_key_unit() for a full description of the downstream force key unit event.runningTimewill be adjusted for any pad offsets of pads it was passing through.- Parameters:
event- AGstEventto parsetimestamp- A pointer to the timestamp in the eventstreamTime- A pointer to the stream-time in the eventrunningTime- A pointer to the running-time in the eventallHeaders- A pointer to the all_headers flag in the eventcount- A pointer to the count field of the event- Returns:
trueif the event is a valid downstream force key unit event.
-
videoEventParseStillFrame
Parse aGstEvent, identify if it is a Still Frame event, and return the still-frame state from the event if it is. If the event represents the start of a still frame, the in_still variable will be set to TRUE, otherwise FALSE. It is OK to pass NULL for the in_still variable order to just check whether the event is a valid still-frame event.Create a still frame event using gst_video_event_new_still_frame()
- Parameters:
event- AGstEventto parseinStill- A boolean to receive the still-frame status from the event, or NULL- Returns:
trueif the event is a valid still-frame event.falseif not
-
videoEventParseUpstreamForceKeyUnit
public static boolean videoEventParseUpstreamForceKeyUnit(Event event, ClockTime runningTime, Out<Boolean> allHeaders, Out<Integer> count) Get running-time, all-headers and count in the force key unit event. See gst_video_event_new_upstream_force_key_unit() for a full description of the upstream force key unit event.Create an upstream force key unit event using gst_video_event_new_upstream_force_key_unit()
runningTimewill be adjusted for any pad offsets of pads it was passing through.- Parameters:
event- AGstEventto parserunningTime- A pointer to the running_time in the eventallHeaders- A pointer to the all_headers flag in the eventcount- A pointer to the count field in the event- Returns:
trueif the event is a valid upstream force-key-unit event.falseif not
-
videoFormatsAny
Return all the raw video formats supported by GStreamer including special opaque formats such asVideoFormat.DMA_DRMfor which no software conversion exists. This should be use for passthrough template cpas.- Returns:
- an array of
GstVideoFormat - Since:
- 1.24
-
videoFormatsRaw
Return all the raw video formats supported by GStreamer.- Returns:
- an array of
GstVideoFormat - Since:
- 1.18
-
videoGlTextureUploadMetaApiGetType
-
videoGuessFramerate
public static boolean videoGuessFramerate(ClockTime duration, @Nullable Out<Integer> destN, @Nullable Out<Integer> destD) Given the nominal duration of one video frame, this function will check some standard framerates for a close match (within 0.1%) and return one if possible,It will calculate an arbitrary framerate if no close match was found, and return
false.It returns
falseif a duration of 0 is passed.- Parameters:
duration- Nominal duration of one framedestN- Numerator of the calculated frameratedestD- Denominator of the calculated framerate- Returns:
trueif a close "standard" framerate was recognised, andfalseotherwise.- Since:
- 1.6
-
videoIsCommonAspectRatio
public static boolean videoIsCommonAspectRatio(int width, int height, int parN, int parD) Given a frame's dimensions and pixel aspect ratio, this function will calculate the frame's aspect ratio and compare it against a set of common well-known "standard" aspect ratios.- Parameters:
width- Width of the video frameheight- Height of the video frameparN- Pixel aspect ratio numeratorparD- Pixel aspect ratio denominator- Returns:
trueif a known "standard" aspect ratio was recognised, andfalseotherwise.- Since:
- 1.22
-
videoIsDmaDrmCaps
Check whether thecapsis a dma drm kind caps. Please note that the caps should be fixed.- Parameters:
caps- aGstCaps- Returns:
trueif the caps is a dma drm caps.- Since:
- 1.24
-
videoMakeRawCaps
Return a generic raw video caps for formats defined informats.Ifformatsisnullreturns a caps for all the supported raw video formats, see gst_video_formats_raw().- Parameters:
formats- an array of rawGstVideoFormat, ornull- Returns:
- a video
GstCaps - Since:
- 1.18
-
videoMakeRawCapsWithFeatures
public static Caps videoMakeRawCapsWithFeatures(@Nullable VideoFormat @Nullable [] formats, @Nullable CapsFeatures features) Return a generic raw video caps for formats defined informatswith featuresfeatures.Ifformatsisnullreturns a caps for all the supported video formats, see gst_video_formats_raw().- Parameters:
formats- an array of rawGstVideoFormat, ornullfeatures- theGstCapsFeaturesto set on the caps- Returns:
- a video
GstCaps - Since:
- 1.18
-
videoMetaApiGetType
-
videoMultiviewGetDoubledHeightModes
-
videoMultiviewGetDoubledSizeModes
-
videoMultiviewGetDoubledWidthModes
-
videoMultiviewGetMonoModes
-
videoMultiviewGetUnpackedModes
-
videoMultiviewGuessHalfAspect
public static boolean videoMultiviewGuessHalfAspect(VideoMultiviewMode mvMode, int width, int height, int parN, int parD) -
videoMultiviewVideoInfoChangeMode
public static void videoMultiviewVideoInfoChangeMode(VideoInfo info, VideoMultiviewMode outMviewMode, Set<VideoMultiviewFlags> outMviewFlags) Utility function that transforms the width/height/PAR and multiview mode and flags of aGstVideoInfointo the requested mode.- Parameters:
info- AGstVideoInfostructure to operate onoutMviewMode- AGstVideoMultiviewModevalueoutMviewFlags- A set ofGstVideoMultiviewFlags- Since:
- 1.6
-
videoMultiviewVideoInfoChangeMode
public static void videoMultiviewVideoInfoChangeMode(VideoInfo info, VideoMultiviewMode outMviewMode, VideoMultiviewFlags... outMviewFlags) Utility function that transforms the width/height/PAR and multiview mode and flags of aGstVideoInfointo the requested mode.- Parameters:
info- AGstVideoInfostructure to operate onoutMviewMode- AGstVideoMultiviewModevalueoutMviewFlags- A set ofGstVideoMultiviewFlags- Since:
- 1.6
-
videoOverlayCompositionMetaApiGetType
-
videoRegionOfInterestMetaApiGetType
-
videoSeiUserDataUnregisteredMetaApiGetType
-
videoSeiUserDataUnregisteredParsePrecisionTimeStamp
public static boolean videoSeiUserDataUnregisteredParsePrecisionTimeStamp(VideoSEIUserDataUnregisteredMeta userData, Out<Byte> status, Out<Long> precisionTimeStamp) Parses and returns the Precision Time Stamp (ST 0604) from the SEI User Data Unregistered buffer- Parameters:
userData- aGstVideoSEIUserDataUnregisteredMetastatus- User Data Unregistered UUIDprecisionTimeStamp- The parsed Precision Time Stamp SEI- Returns:
- True if data is a Precision Time Stamp and it was parsed correctly
- Since:
- 1.22
-
videoTileGetIndex
Get the tile index of the tile at coordinatesxandyin the tiled image ofxTilesbyyTiles.Use this method when
modeis of typeVideoTileType.INDEXED.- Parameters:
mode- aGstVideoTileModex- x coordinatey- y coordinatexTiles- number of horizintal tilesyTiles- number of vertical tiles- Returns:
- the index of the tile at
xandyin the tiled image ofxTilesbyyTiles. - Since:
- 1.4
-
videoTimeCodeMetaApiGetType
-