OpenShot Library | libopenshot
1.1.1
Toggle main menu visibility
Loading...
Searching...
No Matches
Shadow.h
Go to the documentation of this file.
1
8
9
// Copyright (c) 2008-2026 OpenShot Studios, LLC
10
//
11
// SPDX-License-Identifier: LGPL-3.0-or-later
12
13
#ifndef OPENSHOT_SHADOW_EFFECT_H
14
#define OPENSHOT_SHADOW_EFFECT_H
15
16
#include "
../Color.h
"
17
#include "
../EffectBase.h
"
18
#include "
../Frame.h
"
19
#include "
../Json.h
"
20
#include "
../KeyFrame.h
"
21
22
#include <memory>
23
#include <string>
24
25
namespace
openshot
26
{
27
class
Shadow
:
public
EffectBase
28
{
29
private
:
30
void
init_effect_details();
31
32
public
:
33
Keyframe
opacity
;
34
Keyframe
blur_radius
;
35
Keyframe
spread
;
36
Keyframe
distance
;
37
Keyframe
angle
;
38
Color
color
;
39
40
Shadow
();
41
Shadow
(
Keyframe
new_opacity,
Keyframe
new_blur_radius,
Keyframe
new_spread,
42
Keyframe
new_distance,
Keyframe
new_angle,
Color
new_color);
43
44
std::shared_ptr<openshot::Frame>
GetFrame
(int64_t frame_number)
override
{
45
return
GetFrame
(std::make_shared<openshot::Frame>(), frame_number);
46
}
47
48
std::shared_ptr<openshot::Frame>
GetFrame
(std::shared_ptr<openshot::Frame> frame,
49
int64_t frame_number)
override
;
50
51
std::string
Json
()
const override
;
52
void
SetJson
(
const
std::string value)
override
;
53
Json::Value
JsonValue
()
const override
;
54
void
SetJsonValue
(
const
Json::Value root)
override
;
55
56
std::string
PropertiesJSON
(int64_t requested_frame)
const override
;
57
};
58
}
59
60
#endif
Color.h
Header file for Color class.
EffectBase.h
Header file for EffectBase class.
Frame.h
Header file for Frame class.
Json.h
Header file for JSON class.
KeyFrame.h
Header file for the Keyframe class.
openshot::Color
This class represents a color (used on the timeline and clips).
Definition
Color.h:27
openshot::EffectBase
This abstract class is the base class, used by all effects in libopenshot.
Definition
EffectBase.h:57
openshot::Keyframe
A Keyframe is a collection of Point instances, which is used to vary a number or property over time.
Definition
KeyFrame.h:53
openshot::Shadow::JsonValue
Json::Value JsonValue() const override
Generate Json::Value for this object.
Definition
Shadow.cpp:293
openshot::Shadow::distance
Keyframe distance
Shadow offset distance in pixels.
Definition
Shadow.h:36
openshot::Shadow::angle
Keyframe angle
Shadow angle in degrees.
Definition
Shadow.h:37
openshot::Shadow::color
Color color
Shadow tint color.
Definition
Shadow.h:38
openshot::Shadow::opacity
Keyframe opacity
Overall shadow opacity.
Definition
Shadow.h:33
openshot::Shadow::PropertiesJSON
std::string PropertiesJSON(int64_t requested_frame) const override
Definition
Shadow.cpp:331
openshot::Shadow::blur_radius
Keyframe blur_radius
Blur radius in pixels.
Definition
Shadow.h:34
openshot::Shadow::spread
Keyframe spread
Boosts the source alpha before blur.
Definition
Shadow.h:35
openshot::Shadow::Shadow
Shadow()
Definition
Shadow.cpp:212
openshot::Shadow::GetFrame
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
Shadow.h:44
openshot::Shadow::Json
std::string Json() const override
Generate JSON string of this object.
Definition
Shadow.cpp:289
openshot::Shadow::SetJson
void SetJson(const std::string value) override
Load JSON string into this object.
Definition
Shadow.cpp:305
openshot::Shadow::SetJsonValue
void SetJsonValue(const Json::Value root) override
Load Json::Value into this object.
Definition
Shadow.cpp:315
openshot
This namespace is the default namespace for all code in the openshot library.
Definition
AnimatedCurve.h:24
effects
Shadow.h
Generated by
1.17.0