#
View Source Vtc.Framerate.ParseError exception (vtc v0.13.15)

Exception returned when a framerate cannot be parsed.

##

struct-fields

Struct Fields

- `reason`: The reason the error occurred.

##

failure-reasons

Failure Reasons

The following values can appear in the `:reason` fields:

- `:bad_drop_rate`: Returned when the playback speed of a framerate with an ntsc value of :drop is not divisible by 3000/1001 (29.97), for more on why drop-frame framerates must be a multiple of 29.97, see: https://www.davidheidelberger.com/2010/06/10/drop-frame-timecode/

- `:invalid_ntsc`: Returned when the ntsc value is not one of the allowed atom values.

- `:unrecognized_format`: Returned when a string value is not a recognized format.

- `:imprecise` - Returned when a float was passed with an NTSC value of nil. Without the ability to round to the nearest valid NTSC value, floats are not precise enough to build an arbitrary framerate.

# Link to this section Summary

## Types

t()

Type of `ParseError`

## Functions

message(map)

Returns a message for the error reason.

# Link to this section Types

Link to this type

# t()

View Source

    @type t() :: %Vtc.Framerate.ParseError{
      __exception__: true,
      reason:
        :non_positive
        | :bad_drop_rate
        | :invalid_ntsc
        | :invalid_ntsc_rate
        | :unrecognized_format
        | :imprecise
    }

Type of `ParseError`

# Link to this section Functions

Link to this function

# message(map)

View Source

    @spec message(t()) :: String.t()

Returns a message for the error reason.