Photosine 0.5
Loading...
Searching...
No Matches

#include <Timecode.h>

Classes

struct  SimpleTimecode

Public Member Functions

 Timecode (int64_t frameNumber, FrameRate newFrameRate)
 Timecode ()
 Timecode (juce::ValueTree tree)
 Timecode (const Timecode &t)
FrameRate getFrameRate ()
int64_t getFrameCount () const
int getHours ()
int getMinutes ()
int getSeconds ()
int getFrames ()
int64_t getFrameOffset ()
bool getDropFrame ()
bool isThisFirstFrameOfSecond ()
juce::String toString ()
Timecode getLocalTime ()
juce::ValueTree toValueTree ()
bool operator> (Timecode const &comparisonTimecode)
bool operator>= (Timecode const &comparisonTimecode)
bool operator< (Timecode const &comparisonTimecode)
bool operator<= (Timecode const &comparisonTimecode)
Timecode operator- (Timecode const &comparisonTimecode)
Timecode operator+ (Timecode const &comparisonTimecode)
Timecode operator+= (Timecode const &comparisonTimecode)
Timecode operator+ (int const &comparisonInt)
Timecode operator+= (int const &comparisonInt)
Timecode operator++ (int)

Private Member Functions

void initializeFromFrameNumber (int64_t frameNumber, FrameRate newFrameRate)
SimpleTimecode calculateFromFrameNumber (int64_t frameNumber, FrameRate newFrameRate)
void fromValueTree (juce::ValueTree treeToUse)
juce::ValueTree createNewValueTree ()

Private Attributes

SimpleTimecode tcData
FrameRate frData
bool dropFrame
int64_t offset
int64_t count
int64_t dfCount
juce::Identifier nominalFrameRateID = "nominalFrameRate"
juce::Identifier trueFrameRateID = "trueFrameRate"
juce::Identifier trueFrameCountID = "trueFrameCount"
juce::Identifier dropFrameCountID = "dropFrameCount"
juce::Identifier isDropFrameID = "isDropFrame"
juce::Identifier frameOffsetID = "frameOffset"
juce::Identifier hhValueID = "hhValue"
juce::Identifier mmValueID = "mmValue"
juce::Identifier ssValueID = "ssValue"
juce::Identifier ffValueID = "ffValue"

Detailed Description

All-encapsulating class for video timecode and related functions.

Constructor & Destructor Documentation

◆ Timecode() [1/4]

Time::Timecode::Timecode ( int64_t frameNumber,
FrameRate newFrameRate )

Initialize a Timecode object from absolue frame number and frame rate

◆ Timecode() [2/4]

Time::Timecode::Timecode ( )

Creates a new empty Timecode

◆ Timecode() [3/4]

Time::Timecode::Timecode ( juce::ValueTree tree)

Creates a new Timecode from juce::ValueTree

◆ Timecode() [4/4]

Time::Timecode::Timecode ( const Timecode & t)

Member Function Documentation

◆ calculateFromFrameNumber()

Time::Timecode::SimpleTimecode Time::Timecode::calculateFromFrameNumber ( int64_t frameNumber,
FrameRate newFrameRate )
private

Generates simple timecode values (HH:MM:SS:FF) given frame number. Requires less processing than creating an additional Timecode object and used to do the calculations called from initializeFromFrameNumber()

◆ createNewValueTree()

juce::ValueTree Time::Timecode::createNewValueTree ( )
private

Create value tree from default

◆ fromValueTree()

void Time::Timecode::fromValueTree ( juce::ValueTree treeToUse)
private

◆ getDropFrame()

bool Time::Timecode::getDropFrame ( )

True if timecode is Drop Frame (DF)

◆ getFrameCount()

int64_t Time::Timecode::getFrameCount ( ) const

Total number of elapsed frames since time address 00:00:00:00

◆ getFrameOffset()

int64_t Time::Timecode::getFrameOffset ( )

Offsets frameCount from address 00:00:00:00 allowing for a separate clip timecode

◆ getFrameRate()

Time::FrameRate Time::Timecode::getFrameRate ( )

Frame rate of the timecode

◆ getFrames()

int Time::Timecode::getFrames ( )

Int value of FF on the timecode address

◆ getHours()

int Time::Timecode::getHours ( )

Int value of HH on the timecode address

◆ getLocalTime()

Time::Timecode Time::Timecode::getLocalTime ( )

Gets a Timecode without the offset, adjusting the absoluteFrame calculations. Good to get local timecode for a clip

◆ getMinutes()

int Time::Timecode::getMinutes ( )

Int value of MM on the timecode address

◆ getSeconds()

int Time::Timecode::getSeconds ( )

Int value of SS on the timecode address

◆ initializeFromFrameNumber()

void Time::Timecode::initializeFromFrameNumber ( int64_t frameNumber,
FrameRate newFrameRate )
private

Initializes this Timecode from frame number and frame rate. Called from constructor.

◆ isThisFirstFrameOfSecond()

bool Time::Timecode::isThisFirstFrameOfSecond ( )

Check if frame is dropped.

◆ operator+() [1/2]

Time::Timecode Time::Timecode::operator+ ( int const & comparisonInt)

◆ operator+() [2/2]

Time::Timecode Time::Timecode::operator+ ( Timecode const & comparisonTimecode)

◆ operator++()

Time::Timecode Time::Timecode::operator++ ( int )

◆ operator+=() [1/2]

Time::Timecode Time::Timecode::operator+= ( int const & comparisonInt)

◆ operator+=() [2/2]

Time::Timecode Time::Timecode::operator+= ( Timecode const & comparisonTimecode)

◆ operator-()

Time::Timecode Time::Timecode::operator- ( Timecode const & comparisonTimecode)

◆ operator<()

bool Time::Timecode::operator< ( Timecode const & comparisonTimecode)

◆ operator<=()

bool Time::Timecode::operator<= ( Timecode const & comparisonTimecode)

◆ operator>()

bool Time::Timecode::operator> ( Timecode const & comparisonTimecode)

◆ operator>=()

bool Time::Timecode::operator>= ( Timecode const & comparisonTimecode)

◆ toString()

juce::String Time::Timecode::toString ( )

Get Timecode formatted as hh:mm::ss::ff as a juce::String

◆ toValueTree()

juce::ValueTree Time::Timecode::toValueTree ( )

Member Data Documentation

◆ count

int64_t Time::Timecode::count
private

◆ dfCount

int64_t Time::Timecode::dfCount
private

◆ dropFrame

bool Time::Timecode::dropFrame
private

◆ dropFrameCountID

juce::Identifier Time::Timecode::dropFrameCountID = "dropFrameCount"
private

ValueTree identifier for Drop frame count (not often used) (int64_t)

◆ ffValueID

juce::Identifier Time::Timecode::ffValueID = "ffValue"
private

ValueTree identifier for Frames value (int)

◆ frameOffsetID

juce::Identifier Time::Timecode::frameOffsetID = "frameOffset"
private

ValueTree identifier for Frame offset of this timecode (int64_t)

◆ frData

FrameRate Time::Timecode::frData
private

◆ hhValueID

juce::Identifier Time::Timecode::hhValueID = "hhValue"
private

ValueTree identifier for Hours value (int)

◆ isDropFrameID

juce::Identifier Time::Timecode::isDropFrameID = "isDropFrame"
private

ValueTree identifier for Is this drop frame timecode or simple? (bool)

◆ mmValueID

juce::Identifier Time::Timecode::mmValueID = "mmValue"
private

ValueTree identifier for Minutes value (int)

◆ nominalFrameRateID

juce::Identifier Time::Timecode::nominalFrameRateID = "nominalFrameRate"
private

ValueTree identifier for ceil framerate (int)

◆ offset

int64_t Time::Timecode::offset
private

◆ ssValueID

juce::Identifier Time::Timecode::ssValueID = "ssValue"
private

ValueTree identifier for Seconds value (int)

◆ tcData

SimpleTimecode Time::Timecode::tcData
private

◆ trueFrameCountID

juce::Identifier Time::Timecode::trueFrameCountID = "trueFrameCount"
private

ValueTree identifier for true total frame count (int64_t)

◆ trueFrameRateID

juce::Identifier Time::Timecode::trueFrameRateID = "trueFrameRate"
private

ValueTree identifier for true framerate (double)


The documentation for this class was generated from the following files:
  • /Users/cliftonmarien/Documents/Photosine/Photosine/Source/Time/Timecode.h
  • /Users/cliftonmarien/Documents/Photosine/Photosine/Source/Time/Timecode.cpp