TimedFIFO.readOldestDataAndDropSome

Get some amount of oldest samples in the FIFO Then drop some amount of samples that correspond to time passing of dt

  1. int readOldestDataAndDropSome(T[] output, double dt, int keepAtLeast)
    struct TimedFIFO(T)
    nothrow @nogc
    int
    readOldestDataAndDropSome
    (
    T[] output
    ,
    double dt
    ,
    int keepAtLeast = 0
    )
  2. bool readOldestDataAndDropSome(T* output, double dt)

Return Value

Type: int

the number of sample data returned. Also return no data if tryLock failed to take the lock. Note that there is a disconnect between the data that is dropped, and the data that is returned. The same data may well be returned multiple time given a large buffer, or zero time.

Meta