48 explicit Plot(QCustomPlot *parent, QCPAxis *keyAxis =
nullptr, QCPAxis *valueAxis =
nullptr);
125 const std::vector<plot_item_t> &
getItems()
const {
return items_; }
153 static void setAxisColor(QCPAxis *axis,
const QPen &pen);
198 static void tap_reset(
void *plot_ptr);
202 static void tap_draw(
void *plot_ptr);
220 double plot_start_time_;
222 bool tap_registered_;
225 QString full_filter_;
228 std::vector<plot_item_t> items_;
Represents an event occurring during a capture or file operation.
Definition capture_event.h:24
PlotStyles
Defines the available visual styles for plotting data.
Definition graph.h:37
bool visible() const
Checks if the graph is currently visible.
Definition graph.h:94
Graph(QCustomPlot *parent, QCPAxis *keyAxis=nullptr, QCPAxis *valueAxis=nullptr)
Constructs a new Graph.
Definition graph.cpp:15
void requestReplot()
Emitted to request a lightweight QCustomPlot replot without recalculation.
void captureEvent(const CaptureEvent &e)
React to a capture lifecycle event.
Definition plot.cpp:51
~Plot()
Destroy the Plot.
Definition plot.cpp:47
Plot(QCustomPlot *parent, QCPAxis *keyAxis=nullptr, QCPAxis *valueAxis=nullptr)
Construct a Plot.
Definition plot.cpp:19
void setYAxisFactor(double y_axis_factor)
Set a multiplier applied to all Y-axis values before plotting.
Definition plot.cpp:220
static void setAxisColor(QCPAxis *axis, const QPen &pen)
Set the pen colour of all visual components of a QCPAxis.
Definition plot.cpp:269
static bool itemRelCapCompare(const plot_item_t &a, const plot_item_t &b)
Compare two plot items by relative capture timestamp.
Definition plot.cpp:240
void makeCsv(QTextStream &stream) const
Write all plot items as CSV rows to stream.
Definition plot.cpp:368
void removeTapListener()
Remove this plot's tap listener, if one is registered.
Definition plot.cpp:60
void requestRecalc()
Emitted to request a medium-weight value recalculation followed by replot.
double startTime() const
Return the capture timestamp of the first packet seen by this plot.
Definition plot.cpp:189
void setVisible(bool visible)
Show or hide this plot on the graph.
Definition plot.cpp:173
void setPlotStartTime(double start_time)
Set the shared plot start time used for relative-time calculations.
Definition plot.cpp:204
int hfIndex() const
Return the resolved header field index for the Y-axis field.
Definition plot.h:118
void setPlotStyle(PlotStyles style)
Set the visual plot style for this series.
Definition plot.cpp:148
QString configError() const
Return any configuration error set by setFilterField().
Definition plot.h:79
bool absoluteTime() const
Return whether this plot uses absolute (wall-clock) time on the X axis.
Definition plot.h:98
uint32_t packetFromTime(double ts) const
Return the frame number of the packet closest to a given timestamp.
Definition plot.cpp:252
void requestRetap()
Emitted to request a full retap of the capture file.
static bool itemCompare(const plot_item_t &a, const plot_item_t &b)
Compare two plot items by absolute capture timestamp.
Definition plot.cpp:228
void setFilterField(const QString &filter, const QString &field)
Set the display filter and Y-axis field for this plot.
Definition plot.cpp:68
const std::vector< plot_item_t > & getItems() const
Return read-only access to the collected plot items.
Definition plot.h:125
void setAbsoluteTime(bool abs_time)
Set the X-axis time display mode.
Definition plot.cpp:212
QCPRange recentDrawnDataRange(int count) const
Return the key (X-axis) range covering the most recent count items.
Definition plot.cpp:387
struct epan_dissect epan_dissect_t
Opaque type representing a single packet dissection context.
Definition epan.h:62
struct _packet_info packet_info
Represents the metadata and indexing information for a single captured frame.
struct _plot_item_t plot_item_t
Represents a single data point sampled from a packet field for plotting.
Represents a single data point sampled from a packet field for plotting.
Definition plot.h:25
unsigned idx
Definition plot.h:29
double rel_cap_ts
Definition plot.h:27
double frame_ts
Definition plot.h:26
double value
Definition plot.h:30
uint32_t frame_num
Definition plot.h:28
tap_packet_status
Definition tap.h:22