X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=pv%2Fdata%2Fanalogsegment.hpp;h=846837ce75f47c2df2afedeaae64f9159d3bd53b;hb=4b018bf1eeed0f7b80120d41d7881673a2f29e61;hp=5267e77e604ed27fa6f3d3ad09ea4779e9d1f3e3;hpb=85a702806a15852f3684645dffdc38cb30274481;p=pulseview.git diff --git a/pv/data/analogsegment.hpp b/pv/data/analogsegment.hpp index 5267e77e..846837ce 100644 --- a/pv/data/analogsegment.hpp +++ b/pv/data/analogsegment.hpp @@ -27,6 +27,7 @@ #include +using std::enable_shared_from_this; using std::pair; namespace AnalogSegmentTest { @@ -38,13 +39,7 @@ namespace data { class Analog; -typedef struct { - uint64_t sample_index, chunk_num, chunk_offs; - uint8_t* chunk; - float* value; -} SegmentAnalogDataIterator; - -class AnalogSegment : public QObject, public Segment +class AnalogSegment : public Segment, public enable_shared_from_this { Q_OBJECT @@ -90,9 +85,7 @@ public: const pair get_min_max() const; - SegmentAnalogDataIterator* begin_sample_iteration(uint64_t start); - void continue_sample_iteration(SegmentAnalogDataIterator* it, uint64_t increase); - void end_sample_iteration(SegmentAnalogDataIterator* it); + float* get_iterator_value_ptr(SegmentDataIterator* it); void get_envelope_section(EnvelopeSection &s, uint64_t start, uint64_t end, float min_length) const;