OpenShot Library | libopenshot
0.4.0
|
Go to the documentation of this file.
27 info.
description =
"Negates the colors, producing a negative of the image.";
34 std::shared_ptr<openshot::Frame>
Negate::GetFrame(std::shared_ptr<openshot::Frame> frame, int64_t frame_number)
37 frame->GetImage()->invertPixels();
71 catch (
const std::exception& e)
74 throw InvalidJSON(
"JSON is invalid (missing keys or invalid data types)");
93 return root.toStyledString();
const Json::Value stringToJson(const std::string value)
Json::Value JsonValue() const override
Generate Json::Value for this object.
EffectInfoStruct info
Information about the current effect.
Header file for Negate class.
This namespace is the default namespace for all code in the openshot library.
virtual Json::Value JsonValue() const
Generate Json::Value for this object.
std::string Json() const override
Generate JSON string of this object.
Json::Value BasePropertiesJSON(int64_t requested_frame) const
Generate JSON object of base properties (recommended to be used by all effects)
Exception for invalid JSON.
void SetJson(const std::string value) override
Load JSON string into this object.
bool has_audio
Determines if this effect manipulates the audio of a frame.
Negate()
Default constructor.
std::string class_name
The class name of the effect.
std::string description
The description of this effect and what it does.
void SetJsonValue(const Json::Value root) override
Load Json::Value into this object.
bool has_video
Determines if this effect manipulates the image of a frame.
std::string name
The name of the effect.
std::string PropertiesJSON(int64_t requested_frame) const override
Header file for all Exception classes.
virtual void SetJsonValue(const Json::Value root)
Load Json::Value into this object.
std::shared_ptr< openshot::Frame > GetFrame(int64_t frame_number) override
This method is required for all derived classes of ClipBase, and returns a new openshot::Frame object...