- // Create a snapshot, keep it in the maps of channels
- snapshot = shared_ptr<data::AnalogSnapshot>(
- new data::AnalogSnapshot(sample_limit));
- cur_analog_snapshots_[channel] = snapshot;
+ // Create a segment, keep it in the maps of channels
+ segment = shared_ptr<data::AnalogSegment>(
+ new data::AnalogSegment(
+ cur_samplerate_, sample_limit));
+ cur_analog_segments_[channel] = segment;