timecodetool

package
v0.0.16 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 1, 2025 License: MIT Imports: 4 Imported by: 0

README

TimecodeTool package

This package represents all the front facing APIs for both the CLI and the library.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var VERSION string

Functions

This section is empty.

Types

type CalcResponse

type CalcResponse struct {
	SpanResponse
	LastTimecode string `json:"lastTimecode"`
	Steps        []CalculationStep
}

func NewCalculateTimecodes added in v0.0.7

func NewCalculateTimecodes(inTc string, operations []string, fps float64, excludeLastTimecode bool) *CalcResponse

type CalculationStep

type CalculationStep struct {
	Operation string `json:"operation"` // "+" or "-"
	Timecode  string `json:"timecode"`  // Timecode for the operation
	Frames    int    `json:"frames"`    // Equivalent frames for the operation
}

type SpanResponse

type SpanResponse struct {
	InputFirstTimecode  string  `json:"inputFirstTimecode"`
	InputLastTimecode   string  `json:"inputLastTimecode,omitempty"`
	InputFps            float64 `json:"inputFps"`
	Valid               bool    `json:"valid"`
	ErrorMsg            string  `json:"errorMsg"`
	IsDf                bool    `json:"isDf"`
	ExcludeLastTimecode bool    `json:"excludeLastTimecode"`
	StartFrameIdx       int     `json:"startFrameIdx"`
	LastFrameIdx        int     `json:"lastFrameIdx"`
	LengthFrames        int     `json:"lengthFrames"`
	LengthTime          string  `json:"lengthTime"`
	LengthTimecode      string  `json:"lengthTimecode"`
	LengthSeconds       float64 `json:"lengthSeconds"`
	NextTimecode        string  `json:"nextTimecode"`
}

func NewSpanTimecode added in v0.0.7

func NewSpanTimecode(startTc string, endTc string, fps float64, excludeLastTimecode bool) *SpanResponse

type ValidateResponse

type ValidateResponse struct {
	InputTimecode string  `json:"inputTimecode"`
	InputFps      float64 `json:"inputFps"`
	Valid         bool    `json:"valid"`
	ErrorMsg      string  `json:"errorMsg"`
	IsDf          bool    `json:"isDf"`
	FrameIdx      int     `json:"frameIdx"`
	NextTimecode  string  `json:"nextTimecode"`
}

func NewValidateTimecode added in v0.0.7

func NewValidateTimecode(startTc string, fps float64) *ValidateResponse

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL