{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.MediaConvert.Types.MotionImageInserter
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.MediaConvert.Types.MotionImageInserter where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.MediaConvert.Types.MotionImageInsertionFramerate
import Amazonka.MediaConvert.Types.MotionImageInsertionMode
import Amazonka.MediaConvert.Types.MotionImageInsertionOffset
import Amazonka.MediaConvert.Types.MotionImagePlayback
import qualified Amazonka.Prelude as Prelude

-- | Overlay motion graphics on top of your video. The motion graphics that
-- you specify here appear on all outputs in all output groups. For more
-- information, see
-- https:\/\/docs.aws.amazon.com\/mediaconvert\/latest\/ug\/motion-graphic-overlay.html.
--
-- /See:/ 'newMotionImageInserter' smart constructor.
data MotionImageInserter = MotionImageInserter'
  { -- | If your motion graphic asset is a .mov file, keep this setting
    -- unspecified. If your motion graphic asset is a series of .png files,
    -- specify the frame rate of the overlay in frames per second, as a
    -- fraction. For example, specify 24 fps as 24\/1. Make sure that the
    -- number of images in your series matches the frame rate and your intended
    -- overlay duration. For example, if you want a 30-second overlay at 30
    -- fps, you should have 900 .png images. This overlay frame rate doesn\'t
    -- need to match the frame rate of the underlying video.
    MotionImageInserter -> Maybe MotionImageInsertionFramerate
framerate :: Prelude.Maybe MotionImageInsertionFramerate,
    -- | Specify the .mov file or series of .png files that you want to overlay
    -- on your video. For .png files, provide the file name of the first file
    -- in the series. Make sure that the names of the .png files end with
    -- sequential numbers that specify the order that they are played in. For
    -- example, overlay_000.png, overlay_001.png, overlay_002.png, and so on.
    -- The sequence must start at zero, and each image file name must have the
    -- same number of digits. Pad your initial file names with enough zeros to
    -- complete the sequence. For example, if the first image is overlay_0.png,
    -- there can be only 10 images in the sequence, with the last image being
    -- overlay_9.png. But if the first image is overlay_00.png, there can be
    -- 100 images in the sequence.
    MotionImageInserter -> Maybe Text
input :: Prelude.Maybe Prelude.Text,
    -- | Choose the type of motion graphic asset that you are providing for your
    -- overlay. You can choose either a .mov file or a series of .png files.
    MotionImageInserter -> Maybe MotionImageInsertionMode
insertionMode :: Prelude.Maybe MotionImageInsertionMode,
    -- | Use Offset to specify the placement of your motion graphic overlay on
    -- the video frame. Specify in pixels, from the upper-left corner of the
    -- frame. If you don\'t specify an offset, the service scales your overlay
    -- to the full size of the frame. Otherwise, the service inserts the
    -- overlay at its native resolution and scales the size up or down with any
    -- video scaling.
    MotionImageInserter -> Maybe MotionImageInsertionOffset
offset :: Prelude.Maybe MotionImageInsertionOffset,
    -- | Specify whether your motion graphic overlay repeats on a loop or plays
    -- only once.
    MotionImageInserter -> Maybe MotionImagePlayback
playback :: Prelude.Maybe MotionImagePlayback,
    -- | Specify when the motion overlay begins. Use timecode format (HH:MM:SS:FF
    -- or HH:MM:SS;FF). Make sure that the timecode you provide here takes into
    -- account how you have set up your timecode configuration under both job
    -- settings and input settings. The simplest way to do that is to set both
    -- to start at 0. If you need to set up your job to follow timecodes
    -- embedded in your source that don\'t start at zero, make sure that you
    -- specify a start time that is after the first embedded timecode. For more
    -- information, see
    -- https:\/\/docs.aws.amazon.com\/mediaconvert\/latest\/ug\/setting-up-timecode.html
    -- Find job-wide and input timecode configuration settings in your JSON job
    -- settings specification at settings>timecodeConfig>source and
    -- settings>inputs>timecodeSource.
    MotionImageInserter -> Maybe Text
startTime :: Prelude.Maybe Prelude.Text
  }
  deriving (MotionImageInserter -> MotionImageInserter -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MotionImageInserter -> MotionImageInserter -> Bool
$c/= :: MotionImageInserter -> MotionImageInserter -> Bool
== :: MotionImageInserter -> MotionImageInserter -> Bool
$c== :: MotionImageInserter -> MotionImageInserter -> Bool
Prelude.Eq, ReadPrec [MotionImageInserter]
ReadPrec MotionImageInserter
Int -> ReadS MotionImageInserter
ReadS [MotionImageInserter]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MotionImageInserter]
$creadListPrec :: ReadPrec [MotionImageInserter]
readPrec :: ReadPrec MotionImageInserter
$creadPrec :: ReadPrec MotionImageInserter
readList :: ReadS [MotionImageInserter]
$creadList :: ReadS [MotionImageInserter]
readsPrec :: Int -> ReadS MotionImageInserter
$creadsPrec :: Int -> ReadS MotionImageInserter
Prelude.Read, Int -> MotionImageInserter -> ShowS
[MotionImageInserter] -> ShowS
MotionImageInserter -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MotionImageInserter] -> ShowS
$cshowList :: [MotionImageInserter] -> ShowS
show :: MotionImageInserter -> String
$cshow :: MotionImageInserter -> String
showsPrec :: Int -> MotionImageInserter -> ShowS
$cshowsPrec :: Int -> MotionImageInserter -> ShowS
Prelude.Show, forall x. Rep MotionImageInserter x -> MotionImageInserter
forall x. MotionImageInserter -> Rep MotionImageInserter x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MotionImageInserter x -> MotionImageInserter
$cfrom :: forall x. MotionImageInserter -> Rep MotionImageInserter x
Prelude.Generic)

-- |
-- Create a value of 'MotionImageInserter' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'framerate', 'motionImageInserter_framerate' - If your motion graphic asset is a .mov file, keep this setting
-- unspecified. If your motion graphic asset is a series of .png files,
-- specify the frame rate of the overlay in frames per second, as a
-- fraction. For example, specify 24 fps as 24\/1. Make sure that the
-- number of images in your series matches the frame rate and your intended
-- overlay duration. For example, if you want a 30-second overlay at 30
-- fps, you should have 900 .png images. This overlay frame rate doesn\'t
-- need to match the frame rate of the underlying video.
--
-- 'input', 'motionImageInserter_input' - Specify the .mov file or series of .png files that you want to overlay
-- on your video. For .png files, provide the file name of the first file
-- in the series. Make sure that the names of the .png files end with
-- sequential numbers that specify the order that they are played in. For
-- example, overlay_000.png, overlay_001.png, overlay_002.png, and so on.
-- The sequence must start at zero, and each image file name must have the
-- same number of digits. Pad your initial file names with enough zeros to
-- complete the sequence. For example, if the first image is overlay_0.png,
-- there can be only 10 images in the sequence, with the last image being
-- overlay_9.png. But if the first image is overlay_00.png, there can be
-- 100 images in the sequence.
--
-- 'insertionMode', 'motionImageInserter_insertionMode' - Choose the type of motion graphic asset that you are providing for your
-- overlay. You can choose either a .mov file or a series of .png files.
--
-- 'offset', 'motionImageInserter_offset' - Use Offset to specify the placement of your motion graphic overlay on
-- the video frame. Specify in pixels, from the upper-left corner of the
-- frame. If you don\'t specify an offset, the service scales your overlay
-- to the full size of the frame. Otherwise, the service inserts the
-- overlay at its native resolution and scales the size up or down with any
-- video scaling.
--
-- 'playback', 'motionImageInserter_playback' - Specify whether your motion graphic overlay repeats on a loop or plays
-- only once.
--
-- 'startTime', 'motionImageInserter_startTime' - Specify when the motion overlay begins. Use timecode format (HH:MM:SS:FF
-- or HH:MM:SS;FF). Make sure that the timecode you provide here takes into
-- account how you have set up your timecode configuration under both job
-- settings and input settings. The simplest way to do that is to set both
-- to start at 0. If you need to set up your job to follow timecodes
-- embedded in your source that don\'t start at zero, make sure that you
-- specify a start time that is after the first embedded timecode. For more
-- information, see
-- https:\/\/docs.aws.amazon.com\/mediaconvert\/latest\/ug\/setting-up-timecode.html
-- Find job-wide and input timecode configuration settings in your JSON job
-- settings specification at settings>timecodeConfig>source and
-- settings>inputs>timecodeSource.
newMotionImageInserter ::
  MotionImageInserter
newMotionImageInserter :: MotionImageInserter
newMotionImageInserter =
  MotionImageInserter'
    { $sel:framerate:MotionImageInserter' :: Maybe MotionImageInsertionFramerate
framerate = forall a. Maybe a
Prelude.Nothing,
      $sel:input:MotionImageInserter' :: Maybe Text
input = forall a. Maybe a
Prelude.Nothing,
      $sel:insertionMode:MotionImageInserter' :: Maybe MotionImageInsertionMode
insertionMode = forall a. Maybe a
Prelude.Nothing,
      $sel:offset:MotionImageInserter' :: Maybe MotionImageInsertionOffset
offset = forall a. Maybe a
Prelude.Nothing,
      $sel:playback:MotionImageInserter' :: Maybe MotionImagePlayback
playback = forall a. Maybe a
Prelude.Nothing,
      $sel:startTime:MotionImageInserter' :: Maybe Text
startTime = forall a. Maybe a
Prelude.Nothing
    }

-- | If your motion graphic asset is a .mov file, keep this setting
-- unspecified. If your motion graphic asset is a series of .png files,
-- specify the frame rate of the overlay in frames per second, as a
-- fraction. For example, specify 24 fps as 24\/1. Make sure that the
-- number of images in your series matches the frame rate and your intended
-- overlay duration. For example, if you want a 30-second overlay at 30
-- fps, you should have 900 .png images. This overlay frame rate doesn\'t
-- need to match the frame rate of the underlying video.
motionImageInserter_framerate :: Lens.Lens' MotionImageInserter (Prelude.Maybe MotionImageInsertionFramerate)
motionImageInserter_framerate :: Lens' MotionImageInserter (Maybe MotionImageInsertionFramerate)
motionImageInserter_framerate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MotionImageInserter' {Maybe MotionImageInsertionFramerate
framerate :: Maybe MotionImageInsertionFramerate
$sel:framerate:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionFramerate
framerate} -> Maybe MotionImageInsertionFramerate
framerate) (\s :: MotionImageInserter
s@MotionImageInserter' {} Maybe MotionImageInsertionFramerate
a -> MotionImageInserter
s {$sel:framerate:MotionImageInserter' :: Maybe MotionImageInsertionFramerate
framerate = Maybe MotionImageInsertionFramerate
a} :: MotionImageInserter)

-- | Specify the .mov file or series of .png files that you want to overlay
-- on your video. For .png files, provide the file name of the first file
-- in the series. Make sure that the names of the .png files end with
-- sequential numbers that specify the order that they are played in. For
-- example, overlay_000.png, overlay_001.png, overlay_002.png, and so on.
-- The sequence must start at zero, and each image file name must have the
-- same number of digits. Pad your initial file names with enough zeros to
-- complete the sequence. For example, if the first image is overlay_0.png,
-- there can be only 10 images in the sequence, with the last image being
-- overlay_9.png. But if the first image is overlay_00.png, there can be
-- 100 images in the sequence.
motionImageInserter_input :: Lens.Lens' MotionImageInserter (Prelude.Maybe Prelude.Text)
motionImageInserter_input :: Lens' MotionImageInserter (Maybe Text)
motionImageInserter_input = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MotionImageInserter' {Maybe Text
input :: Maybe Text
$sel:input:MotionImageInserter' :: MotionImageInserter -> Maybe Text
input} -> Maybe Text
input) (\s :: MotionImageInserter
s@MotionImageInserter' {} Maybe Text
a -> MotionImageInserter
s {$sel:input:MotionImageInserter' :: Maybe Text
input = Maybe Text
a} :: MotionImageInserter)

-- | Choose the type of motion graphic asset that you are providing for your
-- overlay. You can choose either a .mov file or a series of .png files.
motionImageInserter_insertionMode :: Lens.Lens' MotionImageInserter (Prelude.Maybe MotionImageInsertionMode)
motionImageInserter_insertionMode :: Lens' MotionImageInserter (Maybe MotionImageInsertionMode)
motionImageInserter_insertionMode = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MotionImageInserter' {Maybe MotionImageInsertionMode
insertionMode :: Maybe MotionImageInsertionMode
$sel:insertionMode:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionMode
insertionMode} -> Maybe MotionImageInsertionMode
insertionMode) (\s :: MotionImageInserter
s@MotionImageInserter' {} Maybe MotionImageInsertionMode
a -> MotionImageInserter
s {$sel:insertionMode:MotionImageInserter' :: Maybe MotionImageInsertionMode
insertionMode = Maybe MotionImageInsertionMode
a} :: MotionImageInserter)

-- | Use Offset to specify the placement of your motion graphic overlay on
-- the video frame. Specify in pixels, from the upper-left corner of the
-- frame. If you don\'t specify an offset, the service scales your overlay
-- to the full size of the frame. Otherwise, the service inserts the
-- overlay at its native resolution and scales the size up or down with any
-- video scaling.
motionImageInserter_offset :: Lens.Lens' MotionImageInserter (Prelude.Maybe MotionImageInsertionOffset)
motionImageInserter_offset :: Lens' MotionImageInserter (Maybe MotionImageInsertionOffset)
motionImageInserter_offset = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MotionImageInserter' {Maybe MotionImageInsertionOffset
offset :: Maybe MotionImageInsertionOffset
$sel:offset:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionOffset
offset} -> Maybe MotionImageInsertionOffset
offset) (\s :: MotionImageInserter
s@MotionImageInserter' {} Maybe MotionImageInsertionOffset
a -> MotionImageInserter
s {$sel:offset:MotionImageInserter' :: Maybe MotionImageInsertionOffset
offset = Maybe MotionImageInsertionOffset
a} :: MotionImageInserter)

-- | Specify whether your motion graphic overlay repeats on a loop or plays
-- only once.
motionImageInserter_playback :: Lens.Lens' MotionImageInserter (Prelude.Maybe MotionImagePlayback)
motionImageInserter_playback :: Lens' MotionImageInserter (Maybe MotionImagePlayback)
motionImageInserter_playback = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MotionImageInserter' {Maybe MotionImagePlayback
playback :: Maybe MotionImagePlayback
$sel:playback:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImagePlayback
playback} -> Maybe MotionImagePlayback
playback) (\s :: MotionImageInserter
s@MotionImageInserter' {} Maybe MotionImagePlayback
a -> MotionImageInserter
s {$sel:playback:MotionImageInserter' :: Maybe MotionImagePlayback
playback = Maybe MotionImagePlayback
a} :: MotionImageInserter)

-- | Specify when the motion overlay begins. Use timecode format (HH:MM:SS:FF
-- or HH:MM:SS;FF). Make sure that the timecode you provide here takes into
-- account how you have set up your timecode configuration under both job
-- settings and input settings. The simplest way to do that is to set both
-- to start at 0. If you need to set up your job to follow timecodes
-- embedded in your source that don\'t start at zero, make sure that you
-- specify a start time that is after the first embedded timecode. For more
-- information, see
-- https:\/\/docs.aws.amazon.com\/mediaconvert\/latest\/ug\/setting-up-timecode.html
-- Find job-wide and input timecode configuration settings in your JSON job
-- settings specification at settings>timecodeConfig>source and
-- settings>inputs>timecodeSource.
motionImageInserter_startTime :: Lens.Lens' MotionImageInserter (Prelude.Maybe Prelude.Text)
motionImageInserter_startTime :: Lens' MotionImageInserter (Maybe Text)
motionImageInserter_startTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MotionImageInserter' {Maybe Text
startTime :: Maybe Text
$sel:startTime:MotionImageInserter' :: MotionImageInserter -> Maybe Text
startTime} -> Maybe Text
startTime) (\s :: MotionImageInserter
s@MotionImageInserter' {} Maybe Text
a -> MotionImageInserter
s {$sel:startTime:MotionImageInserter' :: Maybe Text
startTime = Maybe Text
a} :: MotionImageInserter)

instance Data.FromJSON MotionImageInserter where
  parseJSON :: Value -> Parser MotionImageInserter
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"MotionImageInserter"
      ( \Object
x ->
          Maybe MotionImageInsertionFramerate
-> Maybe Text
-> Maybe MotionImageInsertionMode
-> Maybe MotionImageInsertionOffset
-> Maybe MotionImagePlayback
-> Maybe Text
-> MotionImageInserter
MotionImageInserter'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"framerate")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"input")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"insertionMode")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"offset")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"playback")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"startTime")
      )

instance Prelude.Hashable MotionImageInserter where
  hashWithSalt :: Int -> MotionImageInserter -> Int
hashWithSalt Int
_salt MotionImageInserter' {Maybe Text
Maybe MotionImageInsertionFramerate
Maybe MotionImageInsertionMode
Maybe MotionImageInsertionOffset
Maybe MotionImagePlayback
startTime :: Maybe Text
playback :: Maybe MotionImagePlayback
offset :: Maybe MotionImageInsertionOffset
insertionMode :: Maybe MotionImageInsertionMode
input :: Maybe Text
framerate :: Maybe MotionImageInsertionFramerate
$sel:startTime:MotionImageInserter' :: MotionImageInserter -> Maybe Text
$sel:playback:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImagePlayback
$sel:offset:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionOffset
$sel:insertionMode:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionMode
$sel:input:MotionImageInserter' :: MotionImageInserter -> Maybe Text
$sel:framerate:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionFramerate
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MotionImageInsertionFramerate
framerate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
input
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MotionImageInsertionMode
insertionMode
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MotionImageInsertionOffset
offset
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MotionImagePlayback
playback
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
startTime

instance Prelude.NFData MotionImageInserter where
  rnf :: MotionImageInserter -> ()
rnf MotionImageInserter' {Maybe Text
Maybe MotionImageInsertionFramerate
Maybe MotionImageInsertionMode
Maybe MotionImageInsertionOffset
Maybe MotionImagePlayback
startTime :: Maybe Text
playback :: Maybe MotionImagePlayback
offset :: Maybe MotionImageInsertionOffset
insertionMode :: Maybe MotionImageInsertionMode
input :: Maybe Text
framerate :: Maybe MotionImageInsertionFramerate
$sel:startTime:MotionImageInserter' :: MotionImageInserter -> Maybe Text
$sel:playback:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImagePlayback
$sel:offset:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionOffset
$sel:insertionMode:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionMode
$sel:input:MotionImageInserter' :: MotionImageInserter -> Maybe Text
$sel:framerate:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionFramerate
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe MotionImageInsertionFramerate
framerate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
input
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MotionImageInsertionMode
insertionMode
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MotionImageInsertionOffset
offset
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MotionImagePlayback
playback
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
startTime

instance Data.ToJSON MotionImageInserter where
  toJSON :: MotionImageInserter -> Value
toJSON MotionImageInserter' {Maybe Text
Maybe MotionImageInsertionFramerate
Maybe MotionImageInsertionMode
Maybe MotionImageInsertionOffset
Maybe MotionImagePlayback
startTime :: Maybe Text
playback :: Maybe MotionImagePlayback
offset :: Maybe MotionImageInsertionOffset
insertionMode :: Maybe MotionImageInsertionMode
input :: Maybe Text
framerate :: Maybe MotionImageInsertionFramerate
$sel:startTime:MotionImageInserter' :: MotionImageInserter -> Maybe Text
$sel:playback:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImagePlayback
$sel:offset:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionOffset
$sel:insertionMode:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionMode
$sel:input:MotionImageInserter' :: MotionImageInserter -> Maybe Text
$sel:framerate:MotionImageInserter' :: MotionImageInserter -> Maybe MotionImageInsertionFramerate
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"framerate" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MotionImageInsertionFramerate
framerate,
            (Key
"input" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
input,
            (Key
"insertionMode" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MotionImageInsertionMode
insertionMode,
            (Key
"offset" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MotionImageInsertionOffset
offset,
            (Key
"playback" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MotionImagePlayback
playback,
            (Key
"startTime" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
startTime
          ]
      )