AnimatedTimeScaler

src/animatedseismograph.ts
new AnimatedTimeScaler(timeScale: AlignmentLinkedTimeScale, alignmentTime: DateTime?, minRedrawMillis: number?)
Parameters
timeScale (AlignmentLinkedTimeScale)
alignmentTime (DateTime?)
minRedrawMillis (number?)
Instance Members
alignmentTime
timeScale
minRedrawMillis
_calcRedrawMillis
goAnimation
previousStep
_animationId
animate()
animateOnce()
stepper(timestamp)

RTDisplayContainer

src/animatedseismograph.ts
new RTDisplayContainer(rawSeisData: Array<SeismogramDisplayData>, organizedDisplay: OrganizedDisplay, animationScaler: AnimatedTimeScaler, packetHandler: function (packet: (DataLinkPacket | SEPacket | SequencedDataRecord)): void, config: RTConfig)
Parameters
rawSeisData (Array<SeismogramDisplayData>)
organizedDisplay (OrganizedDisplay)
animationScaler (AnimatedTimeScaler)
packetHandler (function (packet: (DataLinkPacket | SEPacket | SequencedDataRecord)): void)
config (RTConfig)
Instance Members
rawSeisData
organizedDisplay
animationScaler
packetHandler
resizeObserver
recalculateRedrawTime()
RTConfig

Type: {duration: Duration, alignmentTime: DateTime, offset: Duration, minRedrawMillis: number?, networkList: Array<Network>, removeTrend: boolean, seismographConfig: SeismographConfig?}

Properties
duration (Duration)
alignmentTime (DateTime)
offset (Duration)
minRedrawMillis (number?)
networkList (Array<Network>)
removeTrend (boolean)
seismographConfig (SeismographConfig?)

Validates the object for typescript and adds any missing required fields. Passing in an empty object is allowed.

isValidRTConfig(configObj: any): any
Parameters
configObj (any) config object
Returns
any: true if object has correct structure, with defaults populated

createRealtimeDisplay

src/animatedseismograph.ts
createRealtimeDisplay(config: any): RTDisplayContainer
Parameters
config (any)
Returns
RTDisplayContainer

internalCreateRealtimeDisplay

src/animatedseismograph.ts
internalCreateRealtimeDisplay(config: RTConfig): RTDisplayContainer
Parameters
config (RTConfig)
Returns
RTDisplayContainer

Trims all seismograms to the given window in place. This should not cause a redraw.

trim(orgDisplay: OrganizedDisplay, timeRange: Interval)
Parameters
orgDisplay (OrganizedDisplay) OrganizedDisplay to trim
timeRange (Interval) time window to coarse trim the data to

calcOnePixelDuration

src/animatedseismograph.ts

Calculates the duration covered by one pixel on the time axis. This is the optimal time interval for updating the animation of a real time display as updates more frequently than this tend to cause more flikering than actual movement of the seismogram.

calcOnePixelDuration(seismograph: SeisPlotElement): Duration
Parameters
seismograph (SeisPlotElement) the seismograph to get pixel size from
Returns
Duration: the pixel width as a Duration