Welcome to mirror list, hosted at ThFree Co, Russian Federation.

mixdown.py « bscripts « bpsrender « BPSRender « scripts « power_sequencer - git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: a6b885cc279a5e0dc610368dce14a400caa1d9c0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#
# Copyright (C) 2016-2019 by Razvan Radulescu, Nathan Lovato, and contributors
#
# This file is part of Power Sequencer.
#
# Power Sequencer is free software: you can redistribute it and/or modify it under the terms of the
# GNU General Public License as published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# Power Sequencer is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
# without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along with Power Sequencer. If
# not, see <https://www.gnu.org/licenses/>.
#
import bpy
import os.path as osp
import sys


for strip in bpy.context.scene.sequence_editor.sequences_all:
    if strip.type == "META":
        continue
    if strip.type != "SOUND":
        strip.mute = True

path = sys.argv[-1]
ext = osp.splitext(path)[1][1:].upper()
bpy.ops.sound.mixdown(filepath=path, check_existing=False, container=ext, codec=ext)