gi-gstvideo-1.0.18: GI/GstVideo/Flags.hs
{- |
Copyright : Will Thompson, Iñaki García Etxebarria and Jonas Platte
License : LGPL-2.1
Maintainer : Iñaki García Etxebarria (inaki@blueleaf.cc)
-}
#define ENABLE_OVERLOADING (MIN_VERSION_haskell_gi_overloading(1,0,0) \
&& !defined(__HADDOCK_VERSION__))
module GI.GstVideo.Flags
(
-- * Flags
-- ** VideoBufferFlags #flag:VideoBufferFlags#
VideoBufferFlags(..) ,
-- ** VideoChromaFlags #flag:VideoChromaFlags#
VideoChromaFlags(..) ,
-- ** VideoChromaSite #flag:VideoChromaSite#
VideoChromaSite(..) ,
-- ** VideoCodecFrameFlags #flag:VideoCodecFrameFlags#
VideoCodecFrameFlags(..) ,
-- ** VideoDitherFlags #flag:VideoDitherFlags#
VideoDitherFlags(..) ,
-- ** VideoFlags #flag:VideoFlags#
VideoFlags(..) ,
-- ** VideoFormatFlags #flag:VideoFormatFlags#
VideoFormatFlags(..) ,
-- ** VideoFrameFlags #flag:VideoFrameFlags#
VideoFrameFlags(..) ,
-- ** VideoFrameMapFlags #flag:VideoFrameMapFlags#
VideoFrameMapFlags(..) ,
-- ** VideoMultiviewFlags #flag:VideoMultiviewFlags#
VideoMultiviewFlags(..) ,
-- ** VideoOverlayFormatFlags #flag:VideoOverlayFormatFlags#
VideoOverlayFormatFlags(..) ,
-- ** VideoPackFlags #flag:VideoPackFlags#
VideoPackFlags(..) ,
-- ** VideoResamplerFlags #flag:VideoResamplerFlags#
VideoResamplerFlags(..) ,
-- ** VideoScalerFlags #flag:VideoScalerFlags#
VideoScalerFlags(..) ,
-- ** VideoTimeCodeFlags #flag:VideoTimeCodeFlags#
VideoTimeCodeFlags(..) ,
) where
import Data.GI.Base.ShortPrelude
import qualified Data.GI.Base.ShortPrelude as SP
import qualified Data.GI.Base.Overloading as O
import qualified Prelude as P
import qualified Data.GI.Base.Attributes as GI.Attributes
import qualified Data.GI.Base.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GValue as B.GValue
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
import qualified Data.GI.Base.Properties as B.Properties
import qualified Data.Text as T
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GHC.OverloadedLabels as OL
-- Flags VideoTimeCodeFlags
{- |
Flags related to the time code information.
For drop frame, only 30000\/1001 and 60000\/1001 frame rates are supported.
/Since: 1.10/
-}
data VideoTimeCodeFlags =
VideoTimeCodeFlagsNone
{- ^
No flags
-}
| VideoTimeCodeFlagsDropFrame
{- ^
Whether we have drop frame rate
-}
| VideoTimeCodeFlagsInterlaced
{- ^
Whether we have interlaced video
-}
| AnotherVideoTimeCodeFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoTimeCodeFlags where
fromEnum VideoTimeCodeFlagsNone = 0
fromEnum VideoTimeCodeFlagsDropFrame = 1
fromEnum VideoTimeCodeFlagsInterlaced = 2
fromEnum (AnotherVideoTimeCodeFlags k) = k
toEnum 0 = VideoTimeCodeFlagsNone
toEnum 1 = VideoTimeCodeFlagsDropFrame
toEnum 2 = VideoTimeCodeFlagsInterlaced
toEnum k = AnotherVideoTimeCodeFlags k
instance P.Ord VideoTimeCodeFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
instance IsGFlag VideoTimeCodeFlags
-- Flags VideoScalerFlags
{- |
Different scale flags.
-}
data VideoScalerFlags =
VideoScalerFlagsNone
{- ^
no flags
-}
| VideoScalerFlagsInterlaced
{- ^
Set up a scaler for interlaced content
-}
| AnotherVideoScalerFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoScalerFlags where
fromEnum VideoScalerFlagsNone = 0
fromEnum VideoScalerFlagsInterlaced = 1
fromEnum (AnotherVideoScalerFlags k) = k
toEnum 0 = VideoScalerFlagsNone
toEnum 1 = VideoScalerFlagsInterlaced
toEnum k = AnotherVideoScalerFlags k
instance P.Ord VideoScalerFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_scaler_flags_get_type" c_gst_video_scaler_flags_get_type ::
IO GType
instance BoxedFlags VideoScalerFlags where
boxedFlagsType _ = c_gst_video_scaler_flags_get_type
instance IsGFlag VideoScalerFlags
-- Flags VideoResamplerFlags
{- |
Different resampler flags.
/Since: 1.6/
-}
data VideoResamplerFlags =
VideoResamplerFlagsNone
{- ^
no flags
-}
| VideoResamplerFlagsHalfTaps
{- ^
when no taps are given, half the
number of calculated taps. This can be used when making scalers
for the different fields of an interlaced picture. Since 1.10
-}
| AnotherVideoResamplerFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoResamplerFlags where
fromEnum VideoResamplerFlagsNone = 0
fromEnum VideoResamplerFlagsHalfTaps = 1
fromEnum (AnotherVideoResamplerFlags k) = k
toEnum 0 = VideoResamplerFlagsNone
toEnum 1 = VideoResamplerFlagsHalfTaps
toEnum k = AnotherVideoResamplerFlags k
instance P.Ord VideoResamplerFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_resampler_flags_get_type" c_gst_video_resampler_flags_get_type ::
IO GType
instance BoxedFlags VideoResamplerFlags where
boxedFlagsType _ = c_gst_video_resampler_flags_get_type
instance IsGFlag VideoResamplerFlags
-- Flags VideoPackFlags
{- |
The different flags that can be used when packing and unpacking.
-}
data VideoPackFlags =
VideoPackFlagsNone
{- ^
No flag
-}
| VideoPackFlagsTruncateRange
{- ^
When the source has a smaller depth
than the target format, set the least significant bits of the target
to 0. This is likely sightly faster but less accurate. When this flag
is not specified, the most significant bits of the source are duplicated
in the least significant bits of the destination.
-}
| VideoPackFlagsInterlaced
{- ^
The source is interlaced. The unpacked
format will be interlaced as well with each line containing
information from alternating fields. (Since 1.2)
-}
| AnotherVideoPackFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoPackFlags where
fromEnum VideoPackFlagsNone = 0
fromEnum VideoPackFlagsTruncateRange = 1
fromEnum VideoPackFlagsInterlaced = 2
fromEnum (AnotherVideoPackFlags k) = k
toEnum 0 = VideoPackFlagsNone
toEnum 1 = VideoPackFlagsTruncateRange
toEnum 2 = VideoPackFlagsInterlaced
toEnum k = AnotherVideoPackFlags k
instance P.Ord VideoPackFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_pack_flags_get_type" c_gst_video_pack_flags_get_type ::
IO GType
instance BoxedFlags VideoPackFlags where
boxedFlagsType _ = c_gst_video_pack_flags_get_type
instance IsGFlag VideoPackFlags
-- Flags VideoOverlayFormatFlags
{- |
Overlay format flags.
-}
data VideoOverlayFormatFlags =
VideoOverlayFormatFlagsNone
{- ^
no flags
-}
| VideoOverlayFormatFlagsPremultipliedAlpha
{- ^
RGB are premultiplied by A\/255.
-}
| VideoOverlayFormatFlagsGlobalAlpha
{- ^
a global-alpha value != 1 is set.
-}
| AnotherVideoOverlayFormatFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoOverlayFormatFlags where
fromEnum VideoOverlayFormatFlagsNone = 0
fromEnum VideoOverlayFormatFlagsPremultipliedAlpha = 1
fromEnum VideoOverlayFormatFlagsGlobalAlpha = 2
fromEnum (AnotherVideoOverlayFormatFlags k) = k
toEnum 0 = VideoOverlayFormatFlagsNone
toEnum 1 = VideoOverlayFormatFlagsPremultipliedAlpha
toEnum 2 = VideoOverlayFormatFlagsGlobalAlpha
toEnum k = AnotherVideoOverlayFormatFlags k
instance P.Ord VideoOverlayFormatFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_overlay_format_flags_get_type" c_gst_video_overlay_format_flags_get_type ::
IO GType
instance BoxedFlags VideoOverlayFormatFlags where
boxedFlagsType _ = c_gst_video_overlay_format_flags_get_type
instance IsGFlag VideoOverlayFormatFlags
-- Flags VideoMultiviewFlags
{- |
GstVideoMultiviewFlags are used to indicate extra properties of a
stereo\/multiview stream beyond the frame layout and buffer mapping
that is conveyed in the 'GI.GstVideo.Enums.VideoMultiviewMode'.
-}
data VideoMultiviewFlags =
VideoMultiviewFlagsNone
{- ^
No flags
-}
| VideoMultiviewFlagsRightViewFirst
{- ^
For stereo streams, the
normal arrangement of left and right views is reversed.
-}
| VideoMultiviewFlagsLeftFlipped
{- ^
The left view is vertically
mirrored.
-}
| VideoMultiviewFlagsLeftFlopped
{- ^
The left view is horizontally
mirrored.
-}
| VideoMultiviewFlagsRightFlipped
{- ^
The right view is
vertically mirrored.
-}
| VideoMultiviewFlagsRightFlopped
{- ^
The right view is
horizontally mirrored.
-}
| VideoMultiviewFlagsHalfAspect
{- ^
For frame-packed
multiview modes, indicates that the individual
views have been encoded with half the true width or height
and should be scaled back up for display. This flag
is used for overriding input layout interpretation
by adjusting pixel-aspect-ratio.
For side-by-side, column interleaved or checkerboard packings, the
pixel width will be doubled. For row interleaved and top-bottom
encodings, pixel height will be doubled.
-}
| VideoMultiviewFlagsMixedMono
{- ^
The video stream contains both
mono and multiview portions, signalled on each buffer by the
absence or presence of the /@gSTVIDEOBUFFERFLAGMULTIPLEVIEW@/
buffer flag.
-}
| AnotherVideoMultiviewFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoMultiviewFlags where
fromEnum VideoMultiviewFlagsNone = 0
fromEnum VideoMultiviewFlagsRightViewFirst = 1
fromEnum VideoMultiviewFlagsLeftFlipped = 2
fromEnum VideoMultiviewFlagsLeftFlopped = 4
fromEnum VideoMultiviewFlagsRightFlipped = 8
fromEnum VideoMultiviewFlagsRightFlopped = 16
fromEnum VideoMultiviewFlagsHalfAspect = 16384
fromEnum VideoMultiviewFlagsMixedMono = 32768
fromEnum (AnotherVideoMultiviewFlags k) = k
toEnum 0 = VideoMultiviewFlagsNone
toEnum 1 = VideoMultiviewFlagsRightViewFirst
toEnum 2 = VideoMultiviewFlagsLeftFlipped
toEnum 4 = VideoMultiviewFlagsLeftFlopped
toEnum 8 = VideoMultiviewFlagsRightFlipped
toEnum 16 = VideoMultiviewFlagsRightFlopped
toEnum 16384 = VideoMultiviewFlagsHalfAspect
toEnum 32768 = VideoMultiviewFlagsMixedMono
toEnum k = AnotherVideoMultiviewFlags k
instance P.Ord VideoMultiviewFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_multiview_flags_get_type" c_gst_video_multiview_flags_get_type ::
IO GType
instance BoxedFlags VideoMultiviewFlags where
boxedFlagsType _ = c_gst_video_multiview_flags_get_type
instance IsGFlag VideoMultiviewFlags
-- Flags VideoFrameMapFlags
{- |
Additional mapping flags for 'GI.GstVideo.Structs.VideoFrame.videoFrameMap'.
/Since: 1.6/
-}
data VideoFrameMapFlags =
VideoFrameMapFlagsNoRef
{- ^
Don\'t take another reference of the buffer and store it in
the GstVideoFrame. This makes sure that the buffer stays
writable while the frame is mapped, but requires that the
buffer reference stays valid until the frame is unmapped again.
-}
| VideoFrameMapFlagsLast
{- ^
Offset to define more flags
-}
| AnotherVideoFrameMapFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoFrameMapFlags where
fromEnum VideoFrameMapFlagsNoRef = 65536
fromEnum VideoFrameMapFlagsLast = 16777216
fromEnum (AnotherVideoFrameMapFlags k) = k
toEnum 65536 = VideoFrameMapFlagsNoRef
toEnum 16777216 = VideoFrameMapFlagsLast
toEnum k = AnotherVideoFrameMapFlags k
instance P.Ord VideoFrameMapFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_frame_map_flags_get_type" c_gst_video_frame_map_flags_get_type ::
IO GType
instance BoxedFlags VideoFrameMapFlags where
boxedFlagsType _ = c_gst_video_frame_map_flags_get_type
instance IsGFlag VideoFrameMapFlags
-- Flags VideoFrameFlags
{- |
Extra video frame flags
-}
data VideoFrameFlags =
VideoFrameFlagsNone
{- ^
no flags
-}
| VideoFrameFlagsInterlaced
{- ^
The video frame is interlaced. In mixed
interlace-mode, this flag specifies if the frame is interlaced or
progressive.
-}
| VideoFrameFlagsTff
{- ^
The video frame has the top field first
-}
| VideoFrameFlagsRff
{- ^
The video frame has the repeat flag
-}
| VideoFrameFlagsOnefield
{- ^
The video frame has one field
-}
| VideoFrameFlagsMultipleView
{- ^
The video contains one or
more non-mono views
-}
| VideoFrameFlagsFirstInBundle
{- ^
The video frame is the first
in a set of corresponding views provided as sequential frames.
-}
| VideoFrameFlagsTopField
{- ^
The video frame has the top field only. This
is the same as GST_VIDEO_FRAME_FLAG_TFF | GST_VIDEO_FRAME_FLAG_ONEFIELD
(Since: 1.16).
-}
| VideoFrameFlagsBottomField
{- ^
The video frame has the bottom field
only. This is the same as GST_VIDEO_FRAME_FLAG_ONEFIELD
(GST_VIDEO_FRAME_FLAG_TFF flag unset) (Since: 1.16).
-}
| AnotherVideoFrameFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoFrameFlags where
fromEnum VideoFrameFlagsNone = 0
fromEnum VideoFrameFlagsInterlaced = 1
fromEnum VideoFrameFlagsTff = 2
fromEnum VideoFrameFlagsRff = 4
fromEnum VideoFrameFlagsOnefield = 8
fromEnum VideoFrameFlagsMultipleView = 16
fromEnum VideoFrameFlagsFirstInBundle = 32
fromEnum VideoFrameFlagsTopField = 10
fromEnum VideoFrameFlagsBottomField = 8
fromEnum (AnotherVideoFrameFlags k) = k
toEnum 0 = VideoFrameFlagsNone
toEnum 1 = VideoFrameFlagsInterlaced
toEnum 2 = VideoFrameFlagsTff
toEnum 4 = VideoFrameFlagsRff
toEnum 8 = VideoFrameFlagsOnefield
toEnum 16 = VideoFrameFlagsMultipleView
toEnum 32 = VideoFrameFlagsFirstInBundle
toEnum 10 = VideoFrameFlagsTopField
toEnum 8 = VideoFrameFlagsBottomField
toEnum k = AnotherVideoFrameFlags k
instance P.Ord VideoFrameFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_frame_flags_get_type" c_gst_video_frame_flags_get_type ::
IO GType
instance BoxedFlags VideoFrameFlags where
boxedFlagsType _ = c_gst_video_frame_flags_get_type
instance IsGFlag VideoFrameFlags
-- Flags VideoFormatFlags
{- |
The different video flags that a format info can have.
-}
data VideoFormatFlags =
VideoFormatFlagsYuv
{- ^
The video format is YUV, components are numbered
0=Y, 1=U, 2=V.
-}
| VideoFormatFlagsRgb
{- ^
The video format is RGB, components are numbered
0=R, 1=G, 2=B.
-}
| VideoFormatFlagsGray
{- ^
The video is gray, there is one gray component
with index 0.
-}
| VideoFormatFlagsAlpha
{- ^
The video format has an alpha components with
the number 3.
-}
| VideoFormatFlagsLe
{- ^
The video format has data stored in little
endianness.
-}
| VideoFormatFlagsPalette
{- ^
The video format has a palette. The palette
is stored in the second plane and indexes are stored in the first plane.
-}
| VideoFormatFlagsComplex
{- ^
The video format has a complex layout that
can\'t be described with the usual information in the 'GI.GstVideo.Structs.VideoFormatInfo.VideoFormatInfo'.
-}
| VideoFormatFlagsUnpack
{- ^
This format can be used in a
'GI.GstVideo.Callbacks.VideoFormatUnpack' and 'GI.GstVideo.Callbacks.VideoFormatPack' function.
-}
| VideoFormatFlagsTiled
{- ^
The format is tiled, there is tiling information
in the last plane.
-}
| AnotherVideoFormatFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoFormatFlags where
fromEnum VideoFormatFlagsYuv = 1
fromEnum VideoFormatFlagsRgb = 2
fromEnum VideoFormatFlagsGray = 4
fromEnum VideoFormatFlagsAlpha = 8
fromEnum VideoFormatFlagsLe = 16
fromEnum VideoFormatFlagsPalette = 32
fromEnum VideoFormatFlagsComplex = 64
fromEnum VideoFormatFlagsUnpack = 128
fromEnum VideoFormatFlagsTiled = 256
fromEnum (AnotherVideoFormatFlags k) = k
toEnum 1 = VideoFormatFlagsYuv
toEnum 2 = VideoFormatFlagsRgb
toEnum 4 = VideoFormatFlagsGray
toEnum 8 = VideoFormatFlagsAlpha
toEnum 16 = VideoFormatFlagsLe
toEnum 32 = VideoFormatFlagsPalette
toEnum 64 = VideoFormatFlagsComplex
toEnum 128 = VideoFormatFlagsUnpack
toEnum 256 = VideoFormatFlagsTiled
toEnum k = AnotherVideoFormatFlags k
instance P.Ord VideoFormatFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_format_flags_get_type" c_gst_video_format_flags_get_type ::
IO GType
instance BoxedFlags VideoFormatFlags where
boxedFlagsType _ = c_gst_video_format_flags_get_type
instance IsGFlag VideoFormatFlags
-- Flags VideoFlags
{- |
Extra video flags
-}
data VideoFlags =
VideoFlagsNone
{- ^
no flags
-}
| VideoFlagsVariableFps
{- ^
a variable fps is selected, fps_n and fps_d
denote the maximum fps of the video
-}
| VideoFlagsPremultipliedAlpha
{- ^
Each color has been scaled by the alpha
value.
-}
| AnotherVideoFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoFlags where
fromEnum VideoFlagsNone = 0
fromEnum VideoFlagsVariableFps = 1
fromEnum VideoFlagsPremultipliedAlpha = 2
fromEnum (AnotherVideoFlags k) = k
toEnum 0 = VideoFlagsNone
toEnum 1 = VideoFlagsVariableFps
toEnum 2 = VideoFlagsPremultipliedAlpha
toEnum k = AnotherVideoFlags k
instance P.Ord VideoFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_flags_get_type" c_gst_video_flags_get_type ::
IO GType
instance BoxedFlags VideoFlags where
boxedFlagsType _ = c_gst_video_flags_get_type
instance IsGFlag VideoFlags
-- Flags VideoDitherFlags
{- |
Extra flags that influence the result from @/gst_video_chroma_resample_new()/@.
-}
data VideoDitherFlags =
VideoDitherFlagsNone
{- ^
no flags
-}
| VideoDitherFlagsInterlaced
{- ^
the input is interlaced
-}
| VideoDitherFlagsQuantize
{- ^
quantize values in addition to adding dither.
-}
| AnotherVideoDitherFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoDitherFlags where
fromEnum VideoDitherFlagsNone = 0
fromEnum VideoDitherFlagsInterlaced = 1
fromEnum VideoDitherFlagsQuantize = 2
fromEnum (AnotherVideoDitherFlags k) = k
toEnum 0 = VideoDitherFlagsNone
toEnum 1 = VideoDitherFlagsInterlaced
toEnum 2 = VideoDitherFlagsQuantize
toEnum k = AnotherVideoDitherFlags k
instance P.Ord VideoDitherFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_dither_flags_get_type" c_gst_video_dither_flags_get_type ::
IO GType
instance BoxedFlags VideoDitherFlags where
boxedFlagsType _ = c_gst_video_dither_flags_get_type
instance IsGFlag VideoDitherFlags
-- Flags VideoCodecFrameFlags
{- |
Flags for 'GI.GstVideo.Structs.VideoCodecFrame.VideoCodecFrame'
-}
data VideoCodecFrameFlags =
VideoCodecFrameFlagsDecodeOnly
{- ^
is the frame only meant to be decoded
-}
| VideoCodecFrameFlagsSyncPoint
{- ^
is the frame a synchronization point (keyframe)
-}
| VideoCodecFrameFlagsForceKeyframe
{- ^
should the output frame be made a keyframe
-}
| VideoCodecFrameFlagsForceKeyframeHeaders
{- ^
should the encoder output stream headers
-}
| AnotherVideoCodecFrameFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoCodecFrameFlags where
fromEnum VideoCodecFrameFlagsDecodeOnly = 1
fromEnum VideoCodecFrameFlagsSyncPoint = 2
fromEnum VideoCodecFrameFlagsForceKeyframe = 4
fromEnum VideoCodecFrameFlagsForceKeyframeHeaders = 8
fromEnum (AnotherVideoCodecFrameFlags k) = k
toEnum 1 = VideoCodecFrameFlagsDecodeOnly
toEnum 2 = VideoCodecFrameFlagsSyncPoint
toEnum 4 = VideoCodecFrameFlagsForceKeyframe
toEnum 8 = VideoCodecFrameFlagsForceKeyframeHeaders
toEnum k = AnotherVideoCodecFrameFlags k
instance P.Ord VideoCodecFrameFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
instance IsGFlag VideoCodecFrameFlags
-- Flags VideoChromaSite
{- |
Various Chroma sitings.
-}
data VideoChromaSite =
VideoChromaSiteUnknown
{- ^
unknown cositing
-}
| VideoChromaSiteNone
{- ^
no cositing
-}
| VideoChromaSiteHCosited
{- ^
chroma is horizontally cosited
-}
| VideoChromaSiteVCosited
{- ^
chroma is vertically cosited
-}
| VideoChromaSiteAltLine
{- ^
choma samples are sited on alternate lines
-}
| VideoChromaSiteCosited
{- ^
chroma samples cosited with luma samples
-}
| VideoChromaSiteJpeg
{- ^
jpeg style cositing, also for mpeg1 and mjpeg
-}
| VideoChromaSiteMpeg2
{- ^
mpeg2 style cositing
-}
| VideoChromaSiteDv
{- ^
DV style cositing
-}
| AnotherVideoChromaSite Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoChromaSite where
fromEnum VideoChromaSiteUnknown = 0
fromEnum VideoChromaSiteNone = 1
fromEnum VideoChromaSiteHCosited = 2
fromEnum VideoChromaSiteVCosited = 4
fromEnum VideoChromaSiteAltLine = 8
fromEnum VideoChromaSiteCosited = 6
fromEnum VideoChromaSiteJpeg = 1
fromEnum VideoChromaSiteMpeg2 = 2
fromEnum VideoChromaSiteDv = 14
fromEnum (AnotherVideoChromaSite k) = k
toEnum 0 = VideoChromaSiteUnknown
toEnum 1 = VideoChromaSiteNone
toEnum 2 = VideoChromaSiteHCosited
toEnum 4 = VideoChromaSiteVCosited
toEnum 8 = VideoChromaSiteAltLine
toEnum 6 = VideoChromaSiteCosited
toEnum 1 = VideoChromaSiteJpeg
toEnum 2 = VideoChromaSiteMpeg2
toEnum 14 = VideoChromaSiteDv
toEnum k = AnotherVideoChromaSite k
instance P.Ord VideoChromaSite where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_chroma_site_get_type" c_gst_video_chroma_site_get_type ::
IO GType
instance BoxedFlags VideoChromaSite where
boxedFlagsType _ = c_gst_video_chroma_site_get_type
instance IsGFlag VideoChromaSite
-- Flags VideoChromaFlags
{- |
Extra flags that influence the result from @/gst_video_chroma_resample_new()/@.
-}
data VideoChromaFlags =
VideoChromaFlagsNone
{- ^
no flags
-}
| VideoChromaFlagsInterlaced
{- ^
the input is interlaced
-}
| AnotherVideoChromaFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoChromaFlags where
fromEnum VideoChromaFlagsNone = 0
fromEnum VideoChromaFlagsInterlaced = 1
fromEnum (AnotherVideoChromaFlags k) = k
toEnum 0 = VideoChromaFlagsNone
toEnum 1 = VideoChromaFlagsInterlaced
toEnum k = AnotherVideoChromaFlags k
instance P.Ord VideoChromaFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_chroma_flags_get_type" c_gst_video_chroma_flags_get_type ::
IO GType
instance BoxedFlags VideoChromaFlags where
boxedFlagsType _ = c_gst_video_chroma_flags_get_type
instance IsGFlag VideoChromaFlags
-- Flags VideoBufferFlags
{- |
Additional video buffer flags. These flags can potentially be used on any
buffers carrying video data - even encoded data.
Note that these are only valid for 'GI.Gst.Structs.Caps.Caps' of type: video\/...
They can conflict with other extended buffer flags.
-}
data VideoBufferFlags =
VideoBufferFlagsInterlaced
{- ^
If the 'GI.Gst.Structs.Buffer.Buffer' is interlaced. In mixed
interlace-mode, this flags specifies if the frame is
interlaced or progressive.
-}
| VideoBufferFlagsTff
{- ^
If the 'GI.Gst.Structs.Buffer.Buffer' is interlaced, then the first field
in the video frame is the top field. If unset, the
bottom field is first.
-}
| VideoBufferFlagsRff
{- ^
If the 'GI.Gst.Structs.Buffer.Buffer' is interlaced, then the first field
(as defined by the 'GI.GstVideo.Flags.VideoBufferFlagsTff' flag setting)
is repeated.
-}
| VideoBufferFlagsOnefield
{- ^
If the 'GI.Gst.Structs.Buffer.Buffer' is interlaced, then only the
first field (as defined by the 'GI.GstVideo.Flags.VideoBufferFlagsTff'
flag setting) is to be displayed (Since: 1.16).
-}
| VideoBufferFlagsMultipleView
{- ^
The 'GI.Gst.Structs.Buffer.Buffer' contains one or more specific views,
such as left or right eye view. This flags is set on
any buffer that contains non-mono content - even for
streams that contain only a single viewpoint. In mixed
mono \/ non-mono streams, the absense of the flag marks
mono buffers.
-}
| VideoBufferFlagsFirstInBundle
{- ^
When conveying stereo\/multiview content with
frame-by-frame methods, this flag marks the first buffer
in a bundle of frames that belong together.
-}
| VideoBufferFlagsTopField
{- ^
The video frame has the top field only. This is the
same as GST_VIDEO_BUFFER_FLAG_TFF |
GST_VIDEO_BUFFER_FLAG_ONEFIELD (Since: 1.16).
-}
| VideoBufferFlagsBottomField
{- ^
The video frame has the bottom field only. This is
the same as GST_VIDEO_BUFFER_FLAG_ONEFIELD
(GST_VIDEO_BUFFER_FLAG_TFF flag unset) (Since: 1.16).
-}
| VideoBufferFlagsLast
{- ^
Offset to define more flags
-}
| AnotherVideoBufferFlags Int
-- ^ Catch-all for unknown values
deriving (Show, Eq)
instance P.Enum VideoBufferFlags where
fromEnum VideoBufferFlagsInterlaced = 1048576
fromEnum VideoBufferFlagsTff = 2097152
fromEnum VideoBufferFlagsRff = 4194304
fromEnum VideoBufferFlagsOnefield = 8388608
fromEnum VideoBufferFlagsMultipleView = 16777216
fromEnum VideoBufferFlagsFirstInBundle = 33554432
fromEnum VideoBufferFlagsTopField = 10485760
fromEnum VideoBufferFlagsBottomField = 8388608
fromEnum VideoBufferFlagsLast = 268435456
fromEnum (AnotherVideoBufferFlags k) = k
toEnum 1048576 = VideoBufferFlagsInterlaced
toEnum 2097152 = VideoBufferFlagsTff
toEnum 4194304 = VideoBufferFlagsRff
toEnum 8388608 = VideoBufferFlagsOnefield
toEnum 16777216 = VideoBufferFlagsMultipleView
toEnum 33554432 = VideoBufferFlagsFirstInBundle
toEnum 10485760 = VideoBufferFlagsTopField
toEnum 8388608 = VideoBufferFlagsBottomField
toEnum 268435456 = VideoBufferFlagsLast
toEnum k = AnotherVideoBufferFlags k
instance P.Ord VideoBufferFlags where
compare a b = P.compare (P.fromEnum a) (P.fromEnum b)
foreign import ccall "gst_video_buffer_flags_get_type" c_gst_video_buffer_flags_get_type ::
IO GType
instance BoxedFlags VideoBufferFlags where
boxedFlagsType _ = c_gst_video_buffer_flags_get_type
instance IsGFlag VideoBufferFlags