Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Multimedia
Kdenlive
Commits
aca44719
Commit
aca44719
authored
Apr 01, 2021
by
Jean-Baptiste Mardelle
Browse files
Fix timeline keyframe position for opacity for affine and other non qtblend effects
parent
7570c1e2
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/assets/keyframes/model/keyframemodel.cpp
View file @
aca44719
...
...
@@ -468,6 +468,11 @@ QVariant KeyframeModel::data(const QModelIndex &index, int role) const
if
(
!
ok
)
{
qDebug
()
<<
"QLocale: Could not convert animated rect opacity"
<<
data
;
}
if
(
auto
ptr
=
m_model
.
lock
())
{
if
(
ptr
->
getAssetId
()
!=
QLatin1String
(
"qtblend"
))
{
converted
/=
100.
;
}
}
return
converted
;
}
double
val
=
it
->
second
.
second
.
toDouble
();
...
...
src/assets/keyframes/model/keyframemodellist.cpp
View file @
aca44719
...
...
@@ -221,8 +221,14 @@ bool KeyframeModelList::updateKeyframe(GenTime oldPos, GenTime pos, const QVaria
if
(
m_parameters
.
at
(
m_inTimelineIndex
)
==
param
)
{
if
(
isRectParam
)
{
if
(
normalizedVal
.
isValid
())
{
double
newValue
=
normalizedVal
.
toDouble
();
if
(
auto
ptr
=
m_model
.
lock
())
{
if
(
ptr
->
getAssetId
()
!=
QLatin1String
(
"qtblend"
))
{
newValue
*=
100.
;
}
}
value
=
param
->
getInterpolatedValue
(
oldPos
);
value
=
param
->
updateInterpolated
(
value
,
n
ormalizedVal
.
toDouble
()
);
value
=
param
->
updateInterpolated
(
value
,
n
ewValue
);
}
}
else
{
value
=
normalizedVal
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment