Compare commits

..

No commits in common. "a5957fc3b2c65cd3380b541c519ad11964c0a365" and "5075394318181bf42df099da67ffd2715b1a5b86" have entirely different histories.

3 changed files with 6 additions and 31 deletions

View file

@ -30,21 +30,10 @@ class Command(BaseCommand):
json.dump(scene, fd, indent=2, ensure_ascii=False)
if not options['no_video']:
for timeline in timelines:
ext = '.mp4'
if '-audio.kdenlive' in timeline:
ext = '.wav'
cmd = [
'xvfb-run', '-a',
'melt', timeline,
'-consumer', 'avformat:%s' % timeline.replace('.kdenlive', ext)
'-consumer', 'avformat:%s' % timeline.replace('.kdenlive', '.mp4')
]
subprocess.call(cmd)
if ext == '.wav':
cmd = [
'ffmpeg', '-i',
timeline.replace('.kdenlive', ext),
timeline.replace('.kdenlive', '.mp4')
]
subprocess.call(cmd)
os.unlink(timeline.replace('.kdenlive', ext))

View file

@ -62,14 +62,9 @@ def compose(clips, target=150, base=1024):
break
length += clip['duration']
fg = clip['foreground']
if 'foreground2' in clip:
if chance(seq, 0.5):
fg = clip['foreground2']
scene['front']['V1'].append({
'duration': clip['duration'],
'src': fg,
'src': clip['foreground'],
"filter": {
'transparency': seq() / 10,
}
@ -115,7 +110,7 @@ def compose(clips, target=150, base=1024):
})
scene['audio']['A2'].append({
'duration': clip['duration'],
'src': fg,
'src': clip['foreground'],
})
return scene

View file

@ -19,16 +19,8 @@ class KDEnliveProject:
def to_xml(self):
track = self._main_tractor.xpath(".//track")[0]
duration = max(self._duration.values())
values = {
"in": "0",
"out": str(duration - 1)
}
for key, value in values.items():
track.attrib[key] = value
self._sequence.attrib[key] = value
self._main_tractor.attrib[key] = value
self._audio_tractor.attrib[key] = value
track.attrib["in"] = self._sequence.attrib["in"] = self._main_tractor.attrib["in"] = "0"
track.attrib["out"] = self._sequence.attrib["out"] = self._main_tractor.attrib["out"] = str(duration - 1)
self._tree.remove(self._sequence)
self._tree.append(self._sequence)
self._tree.remove(self._main_bin)
@ -313,7 +305,6 @@ class KDEnliveProject:
self._sequence = sequence
self._main_bin = main_bin
self._main_tractor = t4
self._audio_tractor = t1
self._v1 = v1
self._v2 = v2
self._a1 = a1
@ -343,7 +334,7 @@ class KDEnliveProject:
("kdenlive:clip_type", "0"),
("kdenlive:folderid", "-1"),
("kdenlive:id", kdenlive_id),
("set.test_audio", "0"),
("set.test_audio", "1"),
("set.test_image", "0"),
("xml", "was here"),
]: