Class Track
Assembly: AudioAnalysisTools.dll
public class Track : ITrack, IPointData, IDrawableEvent
Constructors
|
Improve this Doc
View Source
Initializes a new instance of the Track class.
Constructor.
Declaration
public Track(UnitConverters converter, TrackType trackType)
Parameters
Type |
Name |
Description |
UnitConverters |
converter |
A reference to unit conversions this track class should use to
convert spectrogram data to real units.
|
TrackType |
trackType |
The type of track.
|
|
Improve this Doc
View Source
Declaration
public Track(UnitConverters converter, TrackType trackType, params (int Frame, int Bin, double Amplitude)[] initialPoints)
Parameters
Properties
|
Improve this Doc
View Source
Declaration
public double DurationSeconds { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public double EndTimeSeconds { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public double HighFreqHertz { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public double LowFreqHertz { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public int PointCount { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public ICollection<ISpectralPoint> Points { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public TimeSpan SegmentStartOffset { get; }
Property Value
|
Improve this Doc
View Source
Gets the frequency of the first point in the track.
Where there is more than one frequency in this first frame, returns the lowest frequency.
Declaration
public double StartFrequency { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public double StartTimeSeconds { get; }
Property Value
|
Improve this Doc
View Source
Declaration
public double TrackBandWidthHertz { get; }
Property Value
Methods
|
Improve this Doc
View Source
Does a sanity check on the conversion of frame/bins to real values and back again.
Declaration
public string CheckPoint(int frame, int bin)
Parameters
Type |
Name |
Description |
Int32 |
frame |
The frame number.
|
Int32 |
bin |
The freq bin number.
|
Returns
|
Improve this Doc
View Source
Draw(IImageProcessingContext, EventRenderingOptions)
Draws the track on an image given by its processing context.
Declaration
public void Draw(IImageProcessingContext graphics, EventRenderingOptions options)
Parameters
Type |
Name |
Description |
SixLabors.ImageSharp.Processing.IImageProcessingContext |
graphics |
|
EventRenderingOptions |
options |
|
|
Improve this Doc
View Source
Declaration
public static Image<Rgb24> DrawTracksOnSpectrogram(SpectrogramStandard sonogram, List<Track> tracks, TimeSpan segmentStartOffset)
Parameters
Returns
Type |
Description |
SixLabors.ImageSharp.Image<SixLabors.ImageSharp.PixelFormats.Rgb24> |
|
|
Improve this Doc
View Source
Returns the maximum amplitude in each time frame.
Declaration
public double[] GetAmplitudeOverTimeFrames()
Returns
|
Improve this Doc
View Source
Returns the maximum amplitude in each time frame.
Declaration
public double GetAverageTrackAmplitude()
Returns
|
Improve this Doc
View Source
Returns an array that has the same number of time frames as the track.
Each element contains the highest frequency (Hertz) for that time frame.
NOTE: For tracks that include extreme frequency modulation (e.g. clicks and vertical tracks),
this method returns the highest frequency value in each time frame.
Declaration
public double[] GetTrackAsSequenceOfHertzValues()
Returns
Type |
Description |
Double[] |
An array of Hertz values.
|
|
Improve this Doc
View Source
Returns an array of Hertz difference values.
The array has length one less than the number of dicrete time frames in the track.
THis array can be used to compare simularity bewteen the shapes of tracks even if absolute frequency values are not similar.
Declaration
public double[] GetTrackFrequencyProfile()
Returns
Type |
Description |
Double[] |
An array of Hertz difference values.
|
|
Improve this Doc
View Source
Adds a new point to track given the fram, freq bin and amplitude.
Declaration
public void SetPoint(int frame, int bin, double amplitude)
Parameters
Type |
Name |
Description |
Int32 |
frame |
The frame number.
|
Int32 |
bin |
The freq bin number.
|
Double |
amplitude |
The amplitude at given point.
|
Implements
Extension Methods