Skip to content
GitLab
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
9a2ad8a3
Commit
9a2ad8a3
authored
Apr 14, 2020
by
Jean-Baptiste Mardelle
Browse files
Small fixes for track rec audio level
Fixes
!38
parent
3f1525e7
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/timeline2/view/qml/AudioLevels.qml
View file @
9a2ad8a3
...
...
@@ -21,7 +21,7 @@ Item {
}
}
RowLayout
{
spacing
:
2
spacing
:
4
Layout.fillWidth
:
true
Rectangle
{
id
:
recbutton
...
...
@@ -52,11 +52,12 @@ Item {
id
:
levelsContainer
width
:
recContainer
.
width
-
recbutton
.
width
-
6
height
:
recbutton
.
height
border.color
:
root
.
frameColor
border.color
:
"
#000000
"
border.width
:
1
color
:
Qt
.
lighter
(
activePalette
.
base
)
Repeater
{
model
:
audiorec
.
levels
.
length
id
:
level
Repeater
model
:
audiorec
.
levels
.
length
==
0
?
2
:
audiorec
.
levels
.
length
id
:
bg
Repeater
Rectangle
{
color
:
'
transparent
'
LinearGradient
{
...
...
@@ -72,17 +73,50 @@ Item {
GradientStop
{
position
:
1.0
;
color
:
"
red
"
}
}
}
width
:
parent
.
width
*
audiorec
.
levels
[
index
]
height
:
parent
.
height
/
level
Repeater
.
count
width
:
parent
.
width
-
1
height
:
parent
.
height
/
bg
Repeater
.
count
y
:
height
*
index
}
}
Repeater
{
model
:
audiorec
.
levels
.
length
==
0
?
2
:
audiorec
.
levels
.
length
id
:
levelRepeater
Item
{
anchors.fill
:
parent
anchors.margins
:
1
property
double
currentLevel
:
audiorec
.
levels
.
length
<=
0
?
0
:
audiorec
.
levels
[
index
]
property
double
peak
:
0
Rectangle
{
color
:
"
#cc000000
"
width
:
parent
.
width
*
(
1.0
-
currentLevel
)
anchors.right
:
parent
.
right
height
:
parent
.
height
/
levelRepeater
.
count
y
:
height
*
index
}
onCurrentLevelChanged
:
{
if
(
currentLevel
>
peak
)
{
peak
=
currentLevel
}
else
if
(
peak
>
0
)
{
peak
-=
0.003
}
}
Rectangle
{
visible
:
peak
>
0
color
:
activePalette
.
text
width
:
2
height
:
parent
.
height
/
levelRepeater
.
count
x
:
parent
.
width
*
peak
y
:
height
*
index
}
}
}
Repeater
{
model
:
8
Rectangle
{
color
:
levelsContainer
.
color
color
:
"
#000000
"
width
:
1
height
:
parent
.
height
y
:
1
height
:
parent
.
height
-
2
x
:
parent
.
width
*
(
index
+
1
)
/
9
}
}
...
...
src/timeline2/view/qml/TrackHead.qml
View file @
9a2ad8a3
...
...
@@ -413,7 +413,6 @@ Rectangle {
Item
{
id
:
recLayout
y
:
root
.
collapsedHeight
+
4
//width: trackHeadRoot.width
anchors.left
:
trackHeadColumn
.
left
anchors.right
:
trackHeadColumn
.
right
anchors.margins
:
2
...
...
Julius Künzel
💬
@jlskuz
mentioned in merge request
!38 (closed)
·
Jul 25, 2021
mentioned in merge request
!38 (closed)
mentioned in merge request !38
Toggle commit list
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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