13#ifndef OPENSHOT_COORDINATE_H
14#define OPENSHOT_COORDINATE_H
53 Coordinate(
const std::pair<double, double>& co);
56 std::string
Json()
const;
58 void SetJson(
const std::string value);
63template<
class charT,
class traits>
64std::basic_ostream<charT, traits>&
66 std::basic_ostringstream<charT, traits> s;
69 s.precision(o.precision());
70 s <<
"(" << co.
X <<
", " << co.
Y <<
")";
Header file for Fraction class.
Header file for JSON class.
A Cartesian coordinate (X, Y) used in the Keyframe animation system.
void SetJsonValue(const Json::Value root)
Load Json::Value into this object.
Json::Value JsonValue() const
Generate Json::Value for this object.
std::string Json() const
Generate JSON string of this object.
void SetJson(const std::string value)
Load JSON string into this object.
double X
The X value of the coordinate (usually representing the frame #)
double Y
The Y value of the coordinate (usually representing the value of the property being animated)
Coordinate()
The default constructor, which defaults to (0,0)
This namespace is the default namespace for all code in the openshot library.
std::basic_ostream< charT, traits > & operator<<(std::basic_ostream< charT, traits > &o, const openshot::Coordinate &co)
Stream output operator for openshot::Coordinate.