{- |
Copyright  : Will Thompson, Iñaki García Etxebarria and Jonas Platte
License    : LGPL-2.1
Maintainer : Iñaki García Etxebarria (garetxe@gmail.com)

This interface is implemented by elements which can perform some color
balance operation on video frames they process. For example, modifying
the brightness, contrast, hue or saturation.

Example elements are \'xvimagesink\' and \'colorbalance\'
-}

module GI.GstVideo.Interfaces.ColorBalance
    ( 

-- * Exported types
    ColorBalance(..)                        ,
    noColorBalance                          ,
    IsColorBalance                          ,
    toColorBalance                          ,


 -- * Methods
-- ** getBalanceType #method:getBalanceType#
#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
    ColorBalanceGetBalanceTypeMethodInfo    ,
#endif
    colorBalanceGetBalanceType              ,


-- ** getValue #method:getValue#
#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
    ColorBalanceGetValueMethodInfo          ,
#endif
    colorBalanceGetValue                    ,


-- ** listChannels #method:listChannels#
#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
    ColorBalanceListChannelsMethodInfo      ,
#endif
    colorBalanceListChannels                ,


-- ** setValue #method:setValue#
#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
    ColorBalanceSetValueMethodInfo          ,
#endif
    colorBalanceSetValue                    ,


-- ** valueChanged #method:valueChanged#
#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
    ColorBalanceValueChangedMethodInfo      ,
#endif
    colorBalanceValueChanged                ,




 -- * Signals
-- ** valueChanged #signal:valueChanged#
    C_ColorBalanceValueChangedCallback      ,
    ColorBalanceValueChangedCallback        ,
#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
    ColorBalanceValueChangedSignalInfo      ,
#endif
    afterColorBalanceValueChanged           ,
    genClosure_ColorBalanceValueChanged     ,
    mk_ColorBalanceValueChangedCallback     ,
    noColorBalanceValueChangedCallback      ,
    onColorBalanceValueChanged              ,
    wrap_ColorBalanceValueChangedCallback   ,




    ) 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.GError as B.GError
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
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 GI.GObject.Objects.Object as GObject.Object
import {-# SOURCE #-} qualified GI.GstVideo.Enums as GstVideo.Enums
import {-# SOURCE #-} qualified GI.GstVideo.Objects.ColorBalanceChannel as GstVideo.ColorBalanceChannel

-- interface ColorBalance 
newtype ColorBalance = ColorBalance (ManagedPtr ColorBalance)
noColorBalance :: Maybe ColorBalance
noColorBalance = Nothing

-- signal ColorBalance::value-changed
type ColorBalanceValueChangedCallback =
    GstVideo.ColorBalanceChannel.ColorBalanceChannel ->
    Int32 ->
    IO ()

noColorBalanceValueChangedCallback :: Maybe ColorBalanceValueChangedCallback
noColorBalanceValueChangedCallback = Nothing

type C_ColorBalanceValueChangedCallback =
    Ptr () ->                               -- object
    Ptr GstVideo.ColorBalanceChannel.ColorBalanceChannel ->
    Int32 ->
    Ptr () ->                               -- user_data
    IO ()

foreign import ccall "wrapper"
    mk_ColorBalanceValueChangedCallback :: C_ColorBalanceValueChangedCallback -> IO (FunPtr C_ColorBalanceValueChangedCallback)

genClosure_ColorBalanceValueChanged :: ColorBalanceValueChangedCallback -> IO Closure
genClosure_ColorBalanceValueChanged cb = do
    let cb' = wrap_ColorBalanceValueChangedCallback cb
    mk_ColorBalanceValueChangedCallback cb' >>= newCClosure


wrap_ColorBalanceValueChangedCallback ::
    ColorBalanceValueChangedCallback ->
    Ptr () ->
    Ptr GstVideo.ColorBalanceChannel.ColorBalanceChannel ->
    Int32 ->
    Ptr () ->
    IO ()
wrap_ColorBalanceValueChangedCallback _cb _ channel value _ = do
    channel' <- (newObject GstVideo.ColorBalanceChannel.ColorBalanceChannel) channel
    _cb  channel' value


onColorBalanceValueChanged :: (IsColorBalance a, MonadIO m) => a -> ColorBalanceValueChangedCallback -> m SignalHandlerId
onColorBalanceValueChanged obj cb = liftIO $ do
    let cb' = wrap_ColorBalanceValueChangedCallback cb
    cb'' <- mk_ColorBalanceValueChangedCallback cb'
    connectSignalFunPtr obj "value-changed" cb'' SignalConnectBefore

afterColorBalanceValueChanged :: (IsColorBalance a, MonadIO m) => a -> ColorBalanceValueChangedCallback -> m SignalHandlerId
afterColorBalanceValueChanged obj cb = liftIO $ do
    let cb' = wrap_ColorBalanceValueChangedCallback cb
    cb'' <- mk_ColorBalanceValueChangedCallback cb'
    connectSignalFunPtr obj "value-changed" cb'' SignalConnectAfter


#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
data ColorBalanceValueChangedSignalInfo
instance SignalInfo ColorBalanceValueChangedSignalInfo where
    type HaskellCallbackType ColorBalanceValueChangedSignalInfo = ColorBalanceValueChangedCallback
    connectSignal _ obj cb connectMode = do
        let cb' = wrap_ColorBalanceValueChangedCallback cb
        cb'' <- mk_ColorBalanceValueChangedCallback cb'
        connectSignalFunPtr obj "value-changed" cb'' connectMode

type instance O.SignalList ColorBalance = ColorBalanceSignalList
type ColorBalanceSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo), '("valueChanged", ColorBalanceValueChangedSignalInfo)] :: [(Symbol, *)])

#endif

foreign import ccall "gst_color_balance_get_type"
    c_gst_color_balance_get_type :: IO GType

instance GObject ColorBalance where
    gobjectType _ = c_gst_color_balance_get_type
    

class GObject o => IsColorBalance o
#if MIN_VERSION_base(4,9,0)
instance {-# OVERLAPPABLE #-} (GObject a, O.UnknownAncestorError ColorBalance a) =>
    IsColorBalance a
#endif
instance IsColorBalance ColorBalance
instance GObject.Object.IsObject ColorBalance

toColorBalance :: (MonadIO m, IsColorBalance o) => o -> m ColorBalance
toColorBalance = liftIO . unsafeCastTo ColorBalance

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
instance O.HasAttributeList ColorBalance
type instance O.AttributeList ColorBalance = ColorBalanceAttributeList
type ColorBalanceAttributeList = ('[ ] :: [(Symbol, *)])
#endif

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
#endif

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
type family ResolveColorBalanceMethod (t :: Symbol) (o :: *) :: * where
    ResolveColorBalanceMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
    ResolveColorBalanceMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
    ResolveColorBalanceMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
    ResolveColorBalanceMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
    ResolveColorBalanceMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
    ResolveColorBalanceMethod "listChannels" o = ColorBalanceListChannelsMethodInfo
    ResolveColorBalanceMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
    ResolveColorBalanceMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
    ResolveColorBalanceMethod "ref" o = GObject.Object.ObjectRefMethodInfo
    ResolveColorBalanceMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
    ResolveColorBalanceMethod "replaceData" o = GObject.Object.ObjectReplaceDataMethodInfo
    ResolveColorBalanceMethod "replaceQdata" o = GObject.Object.ObjectReplaceQdataMethodInfo
    ResolveColorBalanceMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
    ResolveColorBalanceMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
    ResolveColorBalanceMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
    ResolveColorBalanceMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
    ResolveColorBalanceMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
    ResolveColorBalanceMethod "valueChanged" o = ColorBalanceValueChangedMethodInfo
    ResolveColorBalanceMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
    ResolveColorBalanceMethod "getBalanceType" o = ColorBalanceGetBalanceTypeMethodInfo
    ResolveColorBalanceMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
    ResolveColorBalanceMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
    ResolveColorBalanceMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
    ResolveColorBalanceMethod "getValue" o = ColorBalanceGetValueMethodInfo
    ResolveColorBalanceMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
    ResolveColorBalanceMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
    ResolveColorBalanceMethod "setValue" o = ColorBalanceSetValueMethodInfo
    ResolveColorBalanceMethod l o = O.MethodResolutionFailed l o

instance (info ~ ResolveColorBalanceMethod t ColorBalance, O.MethodInfo info ColorBalance p) => O.IsLabelProxy t (ColorBalance -> p) where
    fromLabelProxy _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)

#if MIN_VERSION_base(4,9,0)
instance (info ~ ResolveColorBalanceMethod t ColorBalance, O.MethodInfo info ColorBalance p) => O.IsLabel t (ColorBalance -> p) where
#if MIN_VERSION_base(4,10,0)
    fromLabel = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#else
    fromLabel _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info)
#endif
#endif

#endif

-- method ColorBalance::get_balance_type
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "balance", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalance"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "The #GstColorBalance implementation", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TInterface (Name {namespace = "GstVideo", name = "ColorBalanceType"}))
-- throws : False
-- Skip return : False

foreign import ccall "gst_color_balance_get_balance_type" gst_color_balance_get_balance_type :: 
    Ptr ColorBalance ->                     -- balance : TInterface (Name {namespace = "GstVideo", name = "ColorBalance"})
    IO CUInt

{- |
Get the 'GI.GstVideo.Enums.ColorBalanceType' of this implementation.
-}
colorBalanceGetBalanceType ::
    (B.CallStack.HasCallStack, MonadIO m, IsColorBalance a) =>
    a
    {- ^ /@balance@/: The 'GI.GstVideo.Interfaces.ColorBalance.ColorBalance' implementation -}
    -> m GstVideo.Enums.ColorBalanceType
    {- ^ __Returns:__ A the 'GI.GstVideo.Enums.ColorBalanceType'. -}
colorBalanceGetBalanceType balance = liftIO $ do
    balance' <- unsafeManagedPtrCastPtr balance
    result <- gst_color_balance_get_balance_type balance'
    let result' = (toEnum . fromIntegral) result
    touchManagedPtr balance
    return result'

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
data ColorBalanceGetBalanceTypeMethodInfo
instance (signature ~ (m GstVideo.Enums.ColorBalanceType), MonadIO m, IsColorBalance a) => O.MethodInfo ColorBalanceGetBalanceTypeMethodInfo a signature where
    overloadedMethod _ = colorBalanceGetBalanceType

#endif

-- method ColorBalance::get_value
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "balance", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalance"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #GstColorBalance instance", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "channel", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalanceChannel"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #GstColorBalanceChannel instance", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TBasicType TInt)
-- throws : False
-- Skip return : False

foreign import ccall "gst_color_balance_get_value" gst_color_balance_get_value :: 
    Ptr ColorBalance ->                     -- balance : TInterface (Name {namespace = "GstVideo", name = "ColorBalance"})
    Ptr GstVideo.ColorBalanceChannel.ColorBalanceChannel -> -- channel : TInterface (Name {namespace = "GstVideo", name = "ColorBalanceChannel"})
    IO Int32

{- |
Retrieve the current value of the indicated channel, between min_value
and max_value.

See Also: The 'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel'.@/min_value/@ and
        'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel'.@/max_value/@ members of the
        'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel' object.
-}
colorBalanceGetValue ::
    (B.CallStack.HasCallStack, MonadIO m, IsColorBalance a, GstVideo.ColorBalanceChannel.IsColorBalanceChannel b) =>
    a
    {- ^ /@balance@/: A 'GI.GstVideo.Interfaces.ColorBalance.ColorBalance' instance -}
    -> b
    {- ^ /@channel@/: A 'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel' instance -}
    -> m Int32
    {- ^ __Returns:__ The current value of the channel. -}
colorBalanceGetValue balance channel = liftIO $ do
    balance' <- unsafeManagedPtrCastPtr balance
    channel' <- unsafeManagedPtrCastPtr channel
    result <- gst_color_balance_get_value balance' channel'
    touchManagedPtr balance
    touchManagedPtr channel
    return result

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
data ColorBalanceGetValueMethodInfo
instance (signature ~ (b -> m Int32), MonadIO m, IsColorBalance a, GstVideo.ColorBalanceChannel.IsColorBalanceChannel b) => O.MethodInfo ColorBalanceGetValueMethodInfo a signature where
    overloadedMethod _ = colorBalanceGetValue

#endif

-- method ColorBalance::list_channels
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "balance", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalance"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #GstColorBalance instance", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Just (TGList (TInterface (Name {namespace = "GstVideo", name = "ColorBalanceChannel"})))
-- throws : False
-- Skip return : False

foreign import ccall "gst_color_balance_list_channels" gst_color_balance_list_channels :: 
    Ptr ColorBalance ->                     -- balance : TInterface (Name {namespace = "GstVideo", name = "ColorBalance"})
    IO (Ptr (GList (Ptr GstVideo.ColorBalanceChannel.ColorBalanceChannel)))

{- |
Retrieve a list of the available channels.
-}
colorBalanceListChannels ::
    (B.CallStack.HasCallStack, MonadIO m, IsColorBalance a) =>
    a
    {- ^ /@balance@/: A 'GI.GstVideo.Interfaces.ColorBalance.ColorBalance' instance -}
    -> m [GstVideo.ColorBalanceChannel.ColorBalanceChannel]
    {- ^ __Returns:__ A
         GList containing pointers to 'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel'
         objects. The list is owned by the 'GI.GstVideo.Interfaces.ColorBalance.ColorBalance'
         instance and must not be freed. -}
colorBalanceListChannels balance = liftIO $ do
    balance' <- unsafeManagedPtrCastPtr balance
    result <- gst_color_balance_list_channels balance'
    result' <- unpackGList result
    result'' <- mapM (newObject GstVideo.ColorBalanceChannel.ColorBalanceChannel) result'
    touchManagedPtr balance
    return result''

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
data ColorBalanceListChannelsMethodInfo
instance (signature ~ (m [GstVideo.ColorBalanceChannel.ColorBalanceChannel]), MonadIO m, IsColorBalance a) => O.MethodInfo ColorBalanceListChannelsMethodInfo a signature where
    overloadedMethod _ = colorBalanceListChannels

#endif

-- method ColorBalance::set_value
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "balance", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalance"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #GstColorBalance instance", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "channel", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalanceChannel"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #GstColorBalanceChannel instance", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "value", argType = TBasicType TInt, direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "The new value for the channel.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "gst_color_balance_set_value" gst_color_balance_set_value :: 
    Ptr ColorBalance ->                     -- balance : TInterface (Name {namespace = "GstVideo", name = "ColorBalance"})
    Ptr GstVideo.ColorBalanceChannel.ColorBalanceChannel -> -- channel : TInterface (Name {namespace = "GstVideo", name = "ColorBalanceChannel"})
    Int32 ->                                -- value : TBasicType TInt
    IO ()

{- |
Sets the current value of the channel to the passed value, which must
be between min_value and max_value.

See Also: The 'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel'.@/min_value/@ and
        'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel'.@/max_value/@ members of the
        'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel' object.
-}
colorBalanceSetValue ::
    (B.CallStack.HasCallStack, MonadIO m, IsColorBalance a, GstVideo.ColorBalanceChannel.IsColorBalanceChannel b) =>
    a
    {- ^ /@balance@/: A 'GI.GstVideo.Interfaces.ColorBalance.ColorBalance' instance -}
    -> b
    {- ^ /@channel@/: A 'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel' instance -}
    -> Int32
    {- ^ /@value@/: The new value for the channel. -}
    -> m ()
colorBalanceSetValue balance channel value = liftIO $ do
    balance' <- unsafeManagedPtrCastPtr balance
    channel' <- unsafeManagedPtrCastPtr channel
    gst_color_balance_set_value balance' channel' value
    touchManagedPtr balance
    touchManagedPtr channel
    return ()

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
data ColorBalanceSetValueMethodInfo
instance (signature ~ (b -> Int32 -> m ()), MonadIO m, IsColorBalance a, GstVideo.ColorBalanceChannel.IsColorBalanceChannel b) => O.MethodInfo ColorBalanceSetValueMethodInfo a signature where
    overloadedMethod _ = colorBalanceSetValue

#endif

-- method ColorBalance::value_changed
-- method type : OrdinaryMethod
-- Args : [Arg {argCName = "balance", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalance"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #GstColorBalance instance", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "channel", argType = TInterface (Name {namespace = "GstVideo", name = "ColorBalanceChannel"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #GstColorBalanceChannel whose value has changed", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "value", argType = TBasicType TInt, direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "The new value of the channel", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}]
-- Lengths : []
-- returnType : Nothing
-- throws : False
-- Skip return : False

foreign import ccall "gst_color_balance_value_changed" gst_color_balance_value_changed :: 
    Ptr ColorBalance ->                     -- balance : TInterface (Name {namespace = "GstVideo", name = "ColorBalance"})
    Ptr GstVideo.ColorBalanceChannel.ColorBalanceChannel -> -- channel : TInterface (Name {namespace = "GstVideo", name = "ColorBalanceChannel"})
    Int32 ->                                -- value : TBasicType TInt
    IO ()

{- |
A helper function called by implementations of the GstColorBalance
interface. It fires the 'GI.GstVideo.Interfaces.ColorBalance.ColorBalance'::@/value-changed/@ signal on the
instance, and the 'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel'::@/value-changed/@ signal on the
channel object.
-}
colorBalanceValueChanged ::
    (B.CallStack.HasCallStack, MonadIO m, IsColorBalance a, GstVideo.ColorBalanceChannel.IsColorBalanceChannel b) =>
    a
    {- ^ /@balance@/: A 'GI.GstVideo.Interfaces.ColorBalance.ColorBalance' instance -}
    -> b
    {- ^ /@channel@/: A 'GI.GstVideo.Objects.ColorBalanceChannel.ColorBalanceChannel' whose value has changed -}
    -> Int32
    {- ^ /@value@/: The new value of the channel -}
    -> m ()
colorBalanceValueChanged balance channel value = liftIO $ do
    balance' <- unsafeManagedPtrCastPtr balance
    channel' <- unsafeManagedPtrCastPtr channel
    gst_color_balance_value_changed balance' channel' value
    touchManagedPtr balance
    touchManagedPtr channel
    return ()

#if defined(ENABLE_OVERLOADING) && !defined(__HADDOCK_VERSION__)
data ColorBalanceValueChangedMethodInfo
instance (signature ~ (b -> Int32 -> m ()), MonadIO m, IsColorBalance a, GstVideo.ColorBalanceChannel.IsColorBalanceChannel b) => O.MethodInfo ColorBalanceValueChangedMethodInfo a signature where
    overloadedMethod _ = colorBalanceValueChanged

#endif