schema_version: 7.0
type: filter
identifier: color_transform
title: Colorspace & Transfer Characteristics
version: 1
copyright: Meltytech, LLC
license: LGPLv2.1
language: en
tags:
  - Video
  - Hidden
description: >
  Convert the image color to whatever was requested by the consumer.
  This filter is designed for use as a normalizer for the loader producer.
  If the "force_trc" property is set on this filter, the filter will force
  the output trc to be "force_trc";
  Otherwise, if a property "consumer.mlt_color_trc" exists on the frame, then it
  normalizes the image to the trc requested by the consumer.
parameters:
  - identifier: method
    argument: yes
    title: Method
    type: string
    values:
      - auto # Choose best available
      - avfilter.zscale
      - sws_colortransform
      - avfilter.scale
    description: |
      The underlying conversion method to use. The method is based on the
      encapsulated filter that is used. 'auto' will choose the best available
      in this order:
        * avfilter.zscale
        * sws_colortransform
        * avfilter.scale
        One can set the environment variable MLT_COLOR_TRANSFORM to override this.
    required: no
    readonly: no
    mutable: no
    default: auto

  - identifier: force_trc
    title: Force TRC
    type: string
    description: |
      Force the TRC to be as specified by this parameter instead of consumer.mlt_color_trc
      This property can be used to "undo" a TRC set by this filter when used as a normalizer
    required: no
    readonly: no
    mutable: no
    default: unset
