summaryrefslogtreecommitdiff
path: root/src/subtitle.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2022-10-20 23:17:40 +0200
committerCarl Hetherington <cth@carlh.net>2022-11-03 09:31:53 +0100
commit5048e3e1d91858c2a4132e616438e1943f820124 (patch)
tree5ef98efb29690e8320d4e9e36266f41e1214e174 /src/subtitle.h
parent80fc63959caa039401a4d7e33bc72cd3c6ec2fe3 (diff)
Add Z position to subtitles; existing tests pass.
Diffstat (limited to 'src/subtitle.h')
-rw-r--r--src/subtitle.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/subtitle.h b/src/subtitle.h
index 2a8e0322..d42a54b7 100644
--- a/src/subtitle.h
+++ b/src/subtitle.h
@@ -82,6 +82,10 @@ public:
return _v_align;
}
+ float z_position() const {
+ return _z_position;
+ }
+
Time fade_up_time () const {
return _fade_up_time;
}
@@ -109,6 +113,10 @@ public:
_v_position = p;
}
+ void set_z_position(float z) {
+ _z_position = z;
+ }
+
void set_fade_up_time (Time t) {
_fade_up_time = t;
}
@@ -128,6 +136,7 @@ protected:
HAlign h_align,
float v_position,
VAlign v_align,
+ float z_position,
Time fade_up_time,
Time fade_down_time
);
@@ -144,6 +153,7 @@ protected:
*/
float _v_position = 0;
VAlign _v_align = VAlign::CENTER;
+ float _z_position = 0;
Time _fade_up_time;
Time _fade_down_time;
};