libZSservicesZSamazonka-rekognitionZSamazonka-rekognition
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.Rekognition.Types.BlackFrame

Description

 
Synopsis

Documentation

data BlackFrame Source #

A filter that allows you to control the black frame detection by specifying the black levels and pixel coverage of black pixels in a frame. As videos can come from multiple sources, formats, and time periods, they may contain different standards and varying noise levels for black frames that need to be accounted for. For more information, see StartSegmentDetection.

See: newBlackFrame smart constructor.

Constructors

BlackFrame' 

Fields

  • maxPixelThreshold :: Maybe Double

    A threshold used to determine the maximum luminance value for a pixel to be considered black. In a full color range video, luminance values range from 0-255. A pixel value of 0 is pure black, and the most strict filter. The maximum black pixel value is computed as follows: max_black_pixel_value = minimum_luminance + MaxPixelThreshold *luminance_range.

    For example, for a full range video with BlackPixelThreshold = 0.1, max_black_pixel_value is 0 + 0.1 * (255-0) = 25.5.

    The default value of MaxPixelThreshold is 0.2, which maps to a max_black_pixel_value of 51 for a full range video. You can lower this threshold to be more strict on black levels.

  • minCoveragePercentage :: Maybe Double

    The minimum percentage of pixels in a frame that need to have a luminance below the max_black_pixel_value for a frame to be considered a black frame. Luminance is calculated using the BT.709 matrix.

    The default value is 99, which means at least 99% of all pixels in the frame are black pixels as per the MaxPixelThreshold set. You can reduce this value to allow more noise on the black frame.

Instances

Instances details
Eq BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

Read BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

Show BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

Generic BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

Associated Types

type Rep BlackFrame :: Type -> Type #

NFData BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

Methods

rnf :: BlackFrame -> () #

Hashable BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

ToJSON BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

type Rep BlackFrame Source # 
Instance details

Defined in Amazonka.Rekognition.Types.BlackFrame

type Rep BlackFrame = D1 ('MetaData "BlackFrame" "Amazonka.Rekognition.Types.BlackFrame" "libZSservicesZSamazonka-rekognitionZSamazonka-rekognition" 'False) (C1 ('MetaCons "BlackFrame'" 'PrefixI 'True) (S1 ('MetaSel ('Just "maxPixelThreshold") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Double)) :*: S1 ('MetaSel ('Just "minCoveragePercentage") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Double))))

newBlackFrame :: BlackFrame Source #

Create a value of BlackFrame with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:maxPixelThreshold:BlackFrame', blackFrame_maxPixelThreshold - A threshold used to determine the maximum luminance value for a pixel to be considered black. In a full color range video, luminance values range from 0-255. A pixel value of 0 is pure black, and the most strict filter. The maximum black pixel value is computed as follows: max_black_pixel_value = minimum_luminance + MaxPixelThreshold *luminance_range.

For example, for a full range video with BlackPixelThreshold = 0.1, max_black_pixel_value is 0 + 0.1 * (255-0) = 25.5.

The default value of MaxPixelThreshold is 0.2, which maps to a max_black_pixel_value of 51 for a full range video. You can lower this threshold to be more strict on black levels.

$sel:minCoveragePercentage:BlackFrame', blackFrame_minCoveragePercentage - The minimum percentage of pixels in a frame that need to have a luminance below the max_black_pixel_value for a frame to be considered a black frame. Luminance is calculated using the BT.709 matrix.

The default value is 99, which means at least 99% of all pixels in the frame are black pixels as per the MaxPixelThreshold set. You can reduce this value to allow more noise on the black frame.

blackFrame_maxPixelThreshold :: Lens' BlackFrame (Maybe Double) Source #

A threshold used to determine the maximum luminance value for a pixel to be considered black. In a full color range video, luminance values range from 0-255. A pixel value of 0 is pure black, and the most strict filter. The maximum black pixel value is computed as follows: max_black_pixel_value = minimum_luminance + MaxPixelThreshold *luminance_range.

For example, for a full range video with BlackPixelThreshold = 0.1, max_black_pixel_value is 0 + 0.1 * (255-0) = 25.5.

The default value of MaxPixelThreshold is 0.2, which maps to a max_black_pixel_value of 51 for a full range video. You can lower this threshold to be more strict on black levels.

blackFrame_minCoveragePercentage :: Lens' BlackFrame (Maybe Double) Source #

The minimum percentage of pixels in a frame that need to have a luminance below the max_black_pixel_value for a frame to be considered a black frame. Luminance is calculated using the BT.709 matrix.

The default value is 99, which means at least 99% of all pixels in the frame are black pixels as per the MaxPixelThreshold set. You can reduce this value to allow more noise on the black frame.