Rework decode sample count getters
[pulseview.git] / pv / data / decodesignal.hpp
index 2f7c273e978bfa2ec09618d89ddb1d273c1be676..03b8d0af45e3f95d73ea4ac06656ec7d6e4eb478 100644 (file)
@@ -28,6 +28,7 @@
 #include <libsigrokdecode/libsigrokdecode.h>
 
 #include <pv/data/signalbase.hpp>
+#include <pv/util.hpp>
 
 using std::list;
 using std::unordered_set;
@@ -76,6 +77,7 @@ public:
        void remove_decoder(int index);
        bool toggle_decoder_visibility(int index);
 
+       void begin_decode();
        QString error_message() const;
 
        const list<data::DecodeChannel> get_channels() const;
@@ -86,8 +88,15 @@ public:
 
        double samplerate() const;
        const pv::util::Timestamp& start_time() const;
-       int64_t sample_count() const;
-       int64_t samples_decoded() const;
+
+       /**
+        * Returns the number of samples that can be worked on,
+        * i.e. the number of samples where samples are available
+        * for all connected channels.
+        */
+       int64_t get_working_sample_count() const;
+
+       int64_t get_decoded_sample_count() const;
 
        vector<decode::Row> visible_rows() const;