예제 #1
0
    def _maybe_draw_ui_for_voice_style(context: Context, layout: UILayout):
        seq: Optional[KiritanifyScriptSequence] = get_selected_script_sequence(
            context)
        if seq is None:
            return
        setting: KiritanifyScriptSequenceSetting = _script_setting(seq)

        _row = layout.row()
        _row.prop(setting, 'use_custom_voice_style', text='custom_voice')
        _row.operator(KIRITANIFY_OT_ResetVoiceStyle.bl_idname, text='Reset')
        if setting.use_custom_voice_style:
            _row = layout.row()
            _row.prop(setting.custom_voice_style, 'volume')
            _row.prop(setting.custom_voice_style, 'speed')
            _row.prop(setting.custom_voice_style, 'pitch')
            _row.prop(setting.custom_voice_style, 'intonation')
예제 #2
0
    def _draw_ui_for_seq_settings(context: Context, layout: UILayout):
        seq: Optional[KiritanifyScriptSequence] = get_selected_script_sequence(
            context)
        if seq is None:
            return
        setting: KiritanifyScriptSequenceSetting = _script_setting(seq)

        layout.prop(setting, "text")
        layout.label(
            text=
            f"Chara: {get_character_from_channel(context, seq.channel).chara_name}"
        )

        row = layout.row()
        row.prop(setting, "gen_voice")
        if setting.gen_voice:
            row.prop(setting, "voice_seq_name", text="", emboss=False)