32#ifndef RACK_SVG_INTERACTIVE
33#define RACK_SVG_INTERACTIVE
37#include <drain/prog/Command.h>
38#include <drain/image/MouseEventXML.h>
39#include <drain/util/Base64.h>
43#include "graphics-overlay.h"
69 bool cursorCoord =
false;
85 getParameters().link(
"bbox", bbox,
"xLL,yLL,xUR,yUR[px|m|deg] or xLL,yLL,r").setSeparator(
',');
87 getParameters().link(
"resolution", resolution.tuple(),
"pixel").setFill(
true).setSeparator(
',');
88 getParameters().link(
"fixedAEQD", fixedAEQD,
"fix origin to the first radar");
89 getParameters().link(
"cursorCoord", cursorCoord,
"show cursor coordinate");
101 void exec()
const override ;
103 std::string bbox =
"";
105 bool fixedAEQD =
true;
118 getParameters().link(
"resolution", resolution.tuple(),
"pixel").setFill(
true);
130 void exec()
const override ;
144DRAIN_ENUM_DICT(rack::CmdCoords::CoordUnit);
156 getParameters().link(
"filename", filename,
"PNG data file path");
163 void exec()
const override;
167 std::string filename;
182 void exec()
const override ;
186 template <
typename T>
193 bytes.convertFrom(v);
195 drain::Base64::base64_encode(bytes, code);
199 imgData->set(
"data-base64", code);
220 getParameters().link(
"lonlat", coords.tuple(25.0, 60.0),
"Coordinate (lon,lat) in degrees(decimal) or metres.");
221 getParameters().link(
"radius", radiusMetres.range.tuple(0,25000),
"metres or relative").setFill(
true);
223 getParameters().link(
"style", style,
"XML element CSS style");
231 void exec()
const override;
virtual const drain::ReferenceMap & getParameters() const
Returns the command parameters.
Definition Command.h:396
LogSourc e is the means for a function or any program segment to "connect" to a Log.
Definition Log.h:326
void copyStruct(const ReferenceMap &m, const T &src, T &dst, extLinkPolicy policy=RESERVE)
Experimental. Copies references and values of a structure to another.
Definition ReferenceMap.h:412
char separator
Default character used for splitting input and output. See setValues.
Definition SmartMap.h:81
Definition graphics-interactive.h:109
void exec() const override
Run the command with current parameter values.
Definition graphics-interactive.cpp:471
Definition graphics-interactive.h:151
void exec() const override
Run the command with current parameter values.
Definition graphics-interactive.cpp:760
Definition graphics-interactive.h:209
void exec() const override
Definition graphics-interactive.cpp:94
Definition graphics-overlay.h:75
void linkMask()
Definition graphics-overlay.cpp:116
Definition graphics-interactive.h:77
void exec() const override
Run the command with current parameter values.
Definition graphics-interactive.cpp:307
Definition graphics-interactive.h:172
void exec() const override
Run the command with current parameter values.
Definition graphics-interactive.cpp:842
A map of radar data, indexed by quantity code (DBZH, VRAD, etc).
Definition Data.h:1293
Tools for adding user interaction to SVG displays.
Definition graphics-interactive.h:63
Definition AltitudeOp.cpp:42
A container for a static dictionary of enumeration values.
Definition Enum.h:51
static const std::string & str()
Default implementation: name returned by std::type_info::name()
Definition TypeName.h:68