18 lines
424 B
Go
18 lines
424 B
Go
package panako
|
|
|
|
type EventPoint struct {
|
|
|
|
// Time The time expressed using an analysis frame index.
|
|
Time uint32
|
|
|
|
// Frequency The frequency expressed using the bin number Instance.TransformBands in the constant Q transform (Cent).
|
|
Frequency uint32
|
|
|
|
// Magnitude The energy value of the element.
|
|
Magnitude float32
|
|
}
|
|
|
|
func (p *EventPoint) DeltaTime(point *EventPoint) int64 {
|
|
return int64(p.Time) - int64(point.Time)
|
|
}
|