Beispiel #1
0
def script_properties():
	props = obs.obs_properties_create()

	obs.obs_properties_add_text(props, "url", "URL", obs.OBS_TEXT_DEFAULT)
	obs.obs_properties_add_int(props, "interval", "Update Interval (seconds)", 5, 3600, 1)

	p = obs.obs_properties_add_list(props, "source", "Text Source", obs.OBS_COMBO_TYPE_EDITABLE, obs.OBS_COMBO_FORMAT_STRING)
	sources = obs.obs_enum_sources()
	if sources is not None:
		for source in sources:
			source_id = obs.obs_source_get_id(source)
			if source_id == "text_gdiplus" or source_id == "text_ft2_source":
				name = obs.obs_source_get_name(source)
				obs.obs_property_list_add_string(p, name, name)

		obs.source_list_release(sources)

	obs.obs_properties_add_button(props, "button", "Refresh", refresh_pressed)
	return props
def script_properties():
    props = obs.obs_properties_create()
    obs.obs_properties_add_button(props, "button1", "add to current scene",
                                  callback)
    return props
def script_properties():
    props = S.obs_properties_create()
    S.obs_properties_add_text(props, "_text1", "_text1:", S.OBS_TEXT_DEFAULT)
    S.obs_properties_add_text(props, "_text2", "_text2:", S.OBS_TEXT_DEFAULT)
    return props
Beispiel #4
0
def script_properties():  # ui
    props = S.obs_properties_create()
    S.obs_properties_add_button(props, "button", "Stop", stop_pressed)
    S.obs_properties_add_button(props, "button2", "Start", start_pressed)
    return props
Beispiel #5
0
def script_properties():
    props = obs.obs_properties_create()
    obs.obs_properties_add_int(props, "interval", "Interval (minutes)", 2,
                               1500, 1)
    obs.obs_properties_add_bool(props, "enabled", "enable")
    return props
Beispiel #6
0
def script_properties():
    # Display YAML file path property
    props = obs.obs_properties_create()
    obs.obs_properties_add_path(props, 'file_path', 'File Path',
                                obs.OBS_PATH_FILE, 'YAML file (*.yml)', None)
    return props
Beispiel #7
0
def render(elements, on_changed):
    p = _obs.obs_properties_create()
    for e in elements:
        e._add(p, on_changed)
    return p
Beispiel #8
0
def script_properties():
    props = obs.obs_properties_create()
    obs.obs_properties_add_text(props, "portti", "Sarjaportti",
                                obs.OBS_TEXT_DEFAULT)
    obs.obs_properties_add_button(props, "yhdistä", "yhdistä", nappi)
    return props
Beispiel #9
0
def script_properties():
    props = obs.obs_properties_create()
    obs.obs_properties_add_button(props, "button1", "Press 1", press_1)
    obs.obs_properties_add_button(props, "button2", "Press shift + 1", press_shift_1)
    return props
def script_properties():
    props = S.obs_properties_create()
    S.obs_properties_add_button(props, "button", "Refresh", refresh_pressed)
    return props
Beispiel #11
0
def script_properties():
    props = obs.obs_properties_create()
    obs.obs_properties_add_path(props, 'configPath', 'Configuration path',
                                obs.OBS_PATH_FILE, '*.ini', None)
    return props
Beispiel #12
0
 def get_properties(self):
     a = libobs.obs_properties_create()
     print (a) 
     return a
Beispiel #13
0
def script_properties():
    props = obs.obs_properties_create()
    obs.obs_properties_add_text(props, "server", "tallyd Server",
                                obs.OBS_TEXT_DEFAULT)
    obs.obs_properties_add_button(props, "apply", "Apply", apply_pressed)
    return props
def script_properties():
    props = obs.obs_properties_create()

    p = obs.obs_properties_add_bool(props, "manage_streaming",
                                    "Manage Streaming")
    obs.obs_property_set_modified_callback(p, on_property_modified)
    p = obs.obs_properties_add_bool(props, "manage_recording",
                                    "Manage Recording")
    obs.obs_property_set_modified_callback(p, on_property_modified)

    auto_start_group = obs.obs_properties_create()
    obs.obs_properties_add_group(props, "auto_start_group", "Auto Start",
                                 obs.OBS_GROUP_NORMAL, auto_start_group)

    p = obs.obs_properties_add_list(auto_start_group, "start_scene",
                                    "Start Scene", obs.OBS_COMBO_TYPE_LIST,
                                    obs.OBS_COMBO_FORMAT_STRING)
    obs.obs_property_set_enabled(p, manage_streaming or manage_recording)
    obs.obs_property_set_modified_callback(p, on_property_modified)
    obs.obs_property_list_add_string(p, "--Disabled--", "")
    scene_names = obs.obs_frontend_get_scene_names()
    if scene_names != None:
        for scene_name in scene_names:
            obs.obs_property_list_add_string(p, scene_name, scene_name)

    schedule_group = obs.obs_properties_create()
    obs.obs_properties_add_group(auto_start_group, "schedule_group",
                                 "Schedule", obs.OBS_GROUP_NORMAL,
                                 schedule_group)

    p = obs.obs_properties_add_list(schedule_group, "weekday", "Day of Week",
                                    obs.OBS_COMBO_TYPE_LIST,
                                    obs.OBS_COMBO_FORMAT_INT)
    obs.obs_property_set_enabled(p, (manage_streaming or manage_recording)
                                 and start_scene != "")
    for i, day_of_week in enumerate(days_of_week):
        obs.obs_property_list_add_int(p, day_of_week, i)

    p = obs.obs_properties_add_list(schedule_group, "preshow_duration",
                                    "Livestream Start",
                                    obs.OBS_COMBO_TYPE_LIST,
                                    obs.OBS_COMBO_FORMAT_INT)
    obs.obs_property_set_enabled(p, (manage_streaming or manage_recording)
                                 and start_scene != "")
    obs.obs_property_list_clear(p)
    for i in range(4):
        seconds = i * 60 * 5
        obs.obs_property_list_add_int(
            p,
            time(hour=math.floor((event_start - seconds) / 60 / 60),
                 minute=int(
                     (event_start - seconds) / 60 % 60)).strftime("%I:%M %p"),
            seconds)

    p = obs.obs_properties_add_list(schedule_group, "event_start",
                                    "Event Start", obs.OBS_COMBO_TYPE_LIST,
                                    obs.OBS_COMBO_FORMAT_INT)
    obs.obs_property_set_enabled(p, (manage_streaming or manage_recording)
                                 and start_scene != "")
    obs.obs_property_set_modified_callback(p, event_start_list_modified)
    for i in range(288):
        obs.obs_property_list_add_int(
            p,
            time(hour=math.floor(i / 12),
                 minute=(i % 12) * 5).strftime("%I:%M %p"),
            int((i / 12) * 60 * 60))

    text_source_list = obs.obs_properties_add_list(auto_start_group,
                                                   "text_source",
                                                   "Text Source",
                                                   obs.OBS_COMBO_TYPE_LIST,
                                                   obs.OBS_COMBO_FORMAT_STRING)
    obs.obs_property_set_enabled(text_source_list,
                                 (manage_streaming or manage_recording)
                                 and start_scene != "")
    obs.obs_property_set_modified_callback(text_source_list,
                                           on_property_modified)
    obs.obs_property_list_add_string(text_source_list, "--Disabled--", "")

    sources = obs.obs_enum_sources()
    if sources != None:
        for source in sources:
            source_id = obs.obs_source_get_unversioned_id(source)
            if source_id == "text_gdiplus" or source_id == "text_ft2_source":
                name = obs.obs_source_get_name(source)
                obs.obs_property_list_add_string(text_source_list, name, name)
    obs.source_list_release(sources)

    p = obs.obs_properties_add_text(auto_start_group, "countdown_final_text",
                                    "Countdown Final Text",
                                    obs.OBS_TEXT_DEFAULT)
    obs.obs_property_set_enabled(p, (manage_streaming or manage_recording)
                                 and text_source != "" and start_scene != "")

    auto_stop_group = obs.obs_properties_create()
    obs.obs_properties_add_group(props, "auto_stop_group", "Auto Stop",
                                 obs.OBS_GROUP_NORMAL, auto_stop_group)

    p = obs.obs_properties_add_list(auto_stop_group, "closing_scene",
                                    "Closing Scene", obs.OBS_COMBO_TYPE_LIST,
                                    obs.OBS_COMBO_FORMAT_STRING)
    obs.obs_property_set_enabled(p, manage_streaming or manage_recording)
    obs.obs_property_set_modified_callback(p, closing_scene_modified)
    obs.obs_property_list_add_string(p, "--Disabled--", "")
    scene_names = obs.obs_frontend_get_scene_names()
    if scene_names != None:
        for scene_name in scene_names:
            obs.obs_property_list_add_string(p, scene_name, scene_name)

    p = obs.obs_properties_add_int(auto_stop_group, "stop_streaming_delay",
                                   "Streaming Delay", 0, 300, 15)
    obs.obs_property_set_enabled(p, manage_streaming and closing_scene != "")
    p = obs.obs_properties_add_int(auto_stop_group, "stop_recording_delay",
                                   "Recording Delay", 0, 120, 5)
    obs.obs_property_set_enabled(p, manage_recording and closing_scene != "")

    return props
def script_properties():
    props = S.obs_properties_create()
    b = S.obs_properties_add_button(props, "button", "refresh pressed 0 times",
                                    refresh_pressed)
    S.obs_property_set_modified_callback(b, callback)
    return props
    def script_properties():
        props = obs.obs_properties_create()

        youtube_props = obs.obs_properties_create()
        obs.obs_properties_add_group(props, 'youtube', 'YouTube',
                                     obs.OBS_GROUP_NORMAL, youtube_props)

        obs.obs_properties_add_text(youtube_props, 'event_name', 'Event Name',
                                    obs.OBS_TEXT_DEFAULT)
        obs.obs_properties_add_text(youtube_props, 'youtube_description',
                                    'YouTube Description',
                                    obs.OBS_TEXT_MULTILINE)
        obs.obs_properties_add_text(youtube_props, 'youtube_category_id',
                                    'YouTube Category ID',
                                    obs.OBS_TEXT_DEFAULT)
        youtube_privacy_status_prop = obs.obs_properties_add_list(
            youtube_props, 'youtube_privacy_status', 'YouTube Privacy Status',
            obs.OBS_COMBO_TYPE_LIST, obs.OBS_COMBO_FORMAT_STRING)
        obs.obs_property_list_add_string(youtube_privacy_status_prop, 'Public',
                                         'public')
        obs.obs_property_list_add_string(youtube_privacy_status_prop,
                                         'Unlisted', 'unlisted')
        obs.obs_property_list_add_string(youtube_privacy_status_prop,
                                         'Private', 'private')
        obs.obs_properties_add_text(youtube_props, 'youtube_playlist',
                                    'YouTube Playlist', obs.OBS_TEXT_DEFAULT)

        scorekeeper_props = obs.obs_properties_create()
        obs.obs_properties_add_group(props, 'scorekeeper', 'Scorekeeper',
                                     obs.OBS_GROUP_NORMAL, scorekeeper_props)

        obs.obs_properties_add_text(scorekeeper_props, 'event_code',
                                    'Event Code', obs.OBS_TEXT_DEFAULT)
        obs.obs_properties_add_text(scorekeeper_props, 'scorekeeper_api',
                                    'Scorekeeper API', obs.OBS_TEXT_DEFAULT)

        obs.obs_properties_add_button(scorekeeper_props,
                                      'test_scorekeeper_connection',
                                      'Test Scorekeeper Connection',
                                      test_scorekeeper_connection)

        toa_props = obs.obs_properties_create()
        obs.obs_properties_add_group(props, 'toa', 'The Orange Alliance',
                                     obs.OBS_GROUP_NORMAL, toa_props)

        obs.obs_properties_add_text(toa_props, 'toa_key', 'TOA Key',
                                    obs.OBS_TEXT_PASSWORD)
        obs.obs_properties_add_text(toa_props, 'toa_event', 'TOA Event Code',
                                    obs.OBS_TEXT_DEFAULT)

        google_props = obs.obs_properties_create()
        obs.obs_properties_add_group(props, 'google', 'Google API',
                                     obs.OBS_GROUP_NORMAL, google_props)

        obs.obs_properties_add_text(google_props, 'google_project_id',
                                    'Google API Project ID',
                                    obs.OBS_TEXT_DEFAULT)
        obs.obs_properties_add_text(google_props, 'google_client_id',
                                    'Google API Client ID',
                                    obs.OBS_TEXT_DEFAULT)
        obs.obs_properties_add_text(google_props, 'google_client_secret',
                                    'Google API Client Secret',
                                    obs.OBS_TEXT_PASSWORD)

        obs.obs_properties_add_button(google_props,
                                      'refresh_google_authentication',
                                      'Refresh Google Authentication',
                                      refresh_google_authentication)
        obs.obs_properties_add_button(google_props,
                                      'delete_google_authentication',
                                      'Delete Google Authentication',
                                      delete_google_authentication)

        recording_props = obs.obs_properties_create()
        obs.obs_properties_add_group(props, 'recording', 'Recording',
                                     obs.OBS_GROUP_NORMAL, recording_props)

        video_encoder_prop = obs.obs_properties_add_list(
            recording_props, 'video_encoder', 'Video Encoder (H.264)',
            obs.OBS_COMBO_TYPE_LIST, obs.OBS_COMBO_FORMAT_STRING)
        obs.obs_property_list_add_string(video_encoder_prop, 'x264',
                                         'obs_x264')
        if obs.obs_encoder_get_display_name('jim_nvenc'):
            obs.obs_property_list_add_string(video_encoder_prop, 'NVENC',
                                             'jim_nvenc')
        elif obs.obs_encoder_get_display_name('ffmpeg_nvenc'):
            obs.obs_property_list_add_string(video_encoder_prop, 'NVENC',
                                             'ffmpeg_nvenc')
        if obs.obs_encoder_get_display_name('amd_amf_h264'):
            obs.obs_property_list_add_string(video_encoder_prop, 'AMF',
                                             'amd_amf_h264')
        if obs.obs_encoder_get_display_name('obs_qsv11'):
            obs.obs_property_list_add_string(video_encoder_prop, 'QuickSync',
                                             'obs_qsv11')
        obs.obs_properties_add_int(recording_props, 'video_bitrate',
                                   'Video Bitrate', 0, 24000, 50)
        audio_encoder_prop = obs.obs_properties_add_list(
            recording_props, 'audio_encoder', 'Audio Encoder (AAC)',
            obs.OBS_COMBO_TYPE_LIST, obs.OBS_COMBO_FORMAT_STRING)
        obs.obs_property_list_add_string(audio_encoder_prop, 'FFmpeg',
                                         'ffmpeg_aac')
        if obs.obs_encoder_get_display_name('mf_aac'):
            obs.obs_property_list_add_string(audio_encoder_prop,
                                             'MediaFoundation', 'mf_aac')
        if obs.obs_encoder_get_display_name('libfdk_aac'):
            obs.obs_property_list_add_string(audio_encoder_prop,
                                             'Fraunhofer FDK', 'libfdk_aac')
        if obs.obs_encoder_get_display_name('CoreAudio_AAC'):
            obs.obs_property_list_add_string(audio_encoder_prop, 'CoreAudio',
                                             'CoreAudio_AAC')
        obs.obs_properties_add_int(recording_props, 'audio_bitrate',
                                   'Audio Bitrate', 0, 2000, 1)

        match_props = obs.obs_properties_create()
        obs.obs_properties_add_group(props, 'match',
                                     'Match (Internal Settings)',
                                     obs.OBS_GROUP_NORMAL, match_props)

        match_type_prop = obs.obs_properties_add_list(
            match_props, 'match_type', 'Match Type', obs.OBS_COMBO_TYPE_LIST,
            obs.OBS_COMBO_FORMAT_STRING)
        obs.obs_property_list_add_string(match_type_prop, 'Qualification',
                                         'qualification')
        obs.obs_property_list_add_string(match_type_prop, 'Semi-Final',
                                         'semi-final')
        obs.obs_property_list_add_string(match_type_prop, 'Final', 'final')
        obs.obs_properties_add_int(match_props, 'match_pair', 'Match Pair', 1,
                                   2, 1)
        obs.obs_properties_add_int(match_props, 'match_number', 'Match Number',
                                   1, 50, 1)
        obs.obs_properties_add_int(match_props, 'match_code', 'Match Code', 1,
                                   50, 1)

        obs.obs_properties_add_button(match_props, 'reset_match_info',
                                      'Reset Match Info', reset_match_info)

        return props