OpenShot Library | libopenshot 0.3.2
Loading...
Searching...
No Matches
Negate.h
Go to the documentation of this file.
1
9// Copyright (c) 2008-2019 OpenShot Studios, LLC
10//
11// SPDX-License-Identifier: LGPL-3.0-or-later
12
13#ifndef OPENSHOT_NEGATE_EFFECT_H
14#define OPENSHOT_NEGATE_EFFECT_H
15
16#include "../EffectBase.h"
17
18#include "../Frame.h"
19#include "../KeyFrame.h"
20
21#include <memory>
22#include <string>
23
24#include <QImage>
25
26namespace openshot
27{
28
34 class Negate : public EffectBase
35 {
36 public:
37
39 Negate();
40
47 std::shared_ptr<openshot::Frame> GetFrame(int64_t frame_number) override { return GetFrame(std::make_shared<openshot::Frame>(), frame_number); }
48
58 std::shared_ptr<openshot::Frame> GetFrame(std::shared_ptr<openshot::Frame> frame, int64_t frame_number) override;
59
60 // Get and Set JSON methods
61 std::string Json() const override;
62 void SetJson(const std::string value) override;
63 Json::Value JsonValue() const override;
64 void SetJsonValue(const Json::Value root) override;
65
66 // Get all properties for a specific frame
67 std::string PropertiesJSON(int64_t requested_frame) const override;
68 };
69
70}
71
72#endif
Header file for EffectBase class.
Header file for Frame class.
Header file for the Keyframe class.
This abstract class is the base class, used by all effects in libopenshot.
Definition EffectBase.h:53
This class uses the ImageMagick++ libraries, to negate image (i.e. negative)
Definition Negate.h:35
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...
Definition Negate.h:47
void SetJson(const std::string value) override
Load JSON string into this object.
Definition Negate.cpp:62
Json::Value JsonValue() const override
Generate Json::Value for this object.
Definition Negate.cpp:51
Negate()
Default constructor.
Definition Negate.cpp:19
void SetJsonValue(const Json::Value root) override
Load Json::Value into this object.
Definition Negate.cpp:79
std::string Json() const override
Generate JSON string of this object.
Definition Negate.cpp:44
std::string PropertiesJSON(int64_t requested_frame) const override
Definition Negate.cpp:87
This namespace is the default namespace for all code in the openshot library.
Definition Compressor.h:29