vibrante-node 2.5.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- src/core/__init__.py +0 -0
- src/core/engine.py +484 -0
- src/core/events.py +32 -0
- src/core/graph.py +74 -0
- src/core/integrity.py +925 -0
- src/core/loader.py +56 -0
- src/core/manifest.py +910 -0
- src/core/models.py +59 -0
- src/core/persistence.py +27 -0
- src/core/python_to_workflow.py +182 -0
- src/core/registry.py +314 -0
- src/core/workflow_to_python.py +801 -0
- src/main.py +188 -0
- src/models/__init__.py +0 -0
- src/nodes/__init__.py +0 -0
- src/nodes/ai/__init__.py +1 -0
- src/nodes/base.py +174 -0
- src/nodes/builtins/__init__.py +0 -0
- src/nodes/builtins/group_node.py +210 -0
- src/nodes/builtins/nodes.py +452 -0
- src/nodes/print.py +19 -0
- src/nodes/test.py +19 -0
- src/ui/__init__.py +0 -0
- src/ui/canvas/__init__.py +0 -0
- src/ui/canvas/backdrop.py +223 -0
- src/ui/canvas/canvas_search_bar.py +222 -0
- src/ui/canvas/edge.py +98 -0
- src/ui/canvas/mini_map.py +138 -0
- src/ui/canvas/node_search_popup.py +270 -0
- src/ui/canvas/scene.py +1149 -0
- src/ui/canvas/sticky_note.py +123 -0
- src/ui/canvas/view.py +285 -0
- src/ui/code_editor.py +435 -0
- src/ui/export_python_dialog.py +490 -0
- src/ui/gemini_api_dialog.py +41 -0
- src/ui/gemini_chat.py +370 -0
- src/ui/import_python_dialog.py +122 -0
- src/ui/library_panel.py +246 -0
- src/ui/log_panel.py +315 -0
- src/ui/node_builder.py +841 -0
- src/ui/node_widget.py +1009 -0
- src/ui/port_widget.py +116 -0
- src/ui/script_editor.py +53 -0
- src/ui/scripting_console.py +270 -0
- src/ui/settings_window.py +575 -0
- src/ui/window.py +2012 -0
- src/utils/color_manager.py +50 -0
- src/utils/config_manager.py +71 -0
- src/utils/env_manager.py +232 -0
- src/utils/highlighter.py +110 -0
- src/utils/paths.py +30 -0
- src/utils/prism_config.py +300 -0
- src/utils/prism_core.py +80 -0
- src/utils/qt_compat.py +159 -0
- src/utils/runtime.py +80 -0
- vibrante_node/CLA.md +96 -0
- vibrante_node/COMMERCIAL_LICENSE.md +170 -0
- vibrante_node/LICENSE +178 -0
- vibrante_node/LICENSES/AGPL-3.0.txt +661 -0
- vibrante_node/LICENSES/CC-BY-4.0-SCOPE.md +53 -0
- vibrante_node/LICENSES/CC-BY-4.0.txt +396 -0
- vibrante_node/LICENSES/GPL-3.0.txt +674 -0
- vibrante_node/LICENSES/LGPL-3.0.txt +165 -0
- vibrante_node/LICENSES/README.md +65 -0
- vibrante_node/THIRD_PARTY_NOTICES.txt +3277 -0
- vibrante_node/__init__.py +2 -0
- vibrante_node/app.py +60 -0
- vibrante_node/docs/AUTOMATION_API.html +785 -0
- vibrante_node/docs/DEVELOPER.html +891 -0
- vibrante_node/docs/DOCUMENTATION.html +2761 -0
- vibrante_node/docs/LICENSE.txt +35 -0
- vibrante_node/docs/NODE_BUILDER_API.html +1155 -0
- vibrante_node/docs/RELEASE_v1.0.5.html +140 -0
- vibrante_node/docs/RELEASE_v1.1.0.html +163 -0
- vibrante_node/docs/RELEASE_v1.1.5.html +286 -0
- vibrante_node/docs/RELEASE_v1.2.0.html +175 -0
- vibrante_node/docs/RELEASE_v1.3.0.html +168 -0
- vibrante_node/docs/RELEASE_v1.4.0.html +160 -0
- vibrante_node/docs/RELEASE_v1.5.0.html +432 -0
- vibrante_node/docs/RELEASE_v1.6.0.html +293 -0
- vibrante_node/docs/RELEASE_v1.6.1.html +171 -0
- vibrante_node/docs/RELEASE_v1.7.0.html +270 -0
- vibrante_node/docs/RELEASE_v1.8.0.html +201 -0
- vibrante_node/docs/RELEASE_v1.8.1.html +124 -0
- vibrante_node/docs/RELEASE_v1.8.2.html +119 -0
- vibrante_node/docs/RELEASE_v1.8.3.html +125 -0
- vibrante_node/docs/RELEASE_v1.8.4.html +210 -0
- vibrante_node/docs/RELEASE_v1.8.5.html +223 -0
- vibrante_node/docs/RELEASE_v2.0.0.html +284 -0
- vibrante_node/docs/RELEASE_v2.1.0.html +259 -0
- vibrante_node/docs/RELEASE_v2.1.1.html +156 -0
- vibrante_node/docs/RELEASE_v2.2.0.html +369 -0
- vibrante_node/docs/RELEASE_v2.2.1.html +168 -0
- vibrante_node/docs/RELEASE_v2.3.0.html +185 -0
- vibrante_node/docs/RELEASE_v2.4.0.html +446 -0
- vibrante_node/docs/RELEASE_v2.5.0.html +478 -0
- vibrante_node/docs/RELEASE_v2.5.1.html +190 -0
- vibrante_node/docs/USER_GUIDE.html +1407 -0
- vibrante_node/docs/index.html +103 -0
- vibrante_node/docs/portal/01_introduction.html +1177 -0
- vibrante_node/docs/portal/02_getting_started.html +1267 -0
- vibrante_node/docs/portal/03_user_guide.html +1736 -0
- vibrante_node/docs/portal/04_workflow_tutorials.html +1473 -0
- vibrante_node/docs/portal/05_node_development.html +1562 -0
- vibrante_node/docs/portal/06_backend_architecture.html +1373 -0
- vibrante_node/docs/portal/07_frontend_architecture.html +1588 -0
- vibrante_node/docs/portal/08_api_reference.html +2336 -0
- vibrante_node/docs/portal/09_advanced_topics.html +1664 -0
- vibrante_node/docs/portal/10_contribution_guide.html +1263 -0
- vibrante_node/docs/portal/11_troubleshooting.html +1108 -0
- vibrante_node/docs/portal/12_examples_library.html +1498 -0
- vibrante_node/docs/portal/13_general_purpose_automation.html +1472 -0
- vibrante_node/docs/portal/14_custom_nodes_api.html +1960 -0
- vibrante_node/docs/portal/index.html +605 -0
- vibrante_node/docs/portal/integrations_blender.html +605 -0
- vibrante_node/docs/portal/integrations_deadline.html +536 -0
- vibrante_node/docs/portal/integrations_houdini.html +787 -0
- vibrante_node/docs/portal/integrations_maya.html +675 -0
- vibrante_node/docs/portal/integrations_prism.html +628 -0
- vibrante_node/docs/portal/search.json +1 -0
- vibrante_node/docs/validation.json +333 -0
- vibrante_node/examples/arnold_lighting/orchestration_notes.md +45 -0
- vibrante_node/examples/arnold_lighting/prompt.md +47 -0
- vibrante_node/examples/automation/01_linear_chain.py +10 -0
- vibrante_node/examples/automation/02_batch_update_prefix.py +8 -0
- vibrante_node/examples/automation/03_reset_scene.py +5 -0
- vibrante_node/examples/automation/04_batch_execution.py +9 -0
- vibrante_node/examples/automation/05_git_backup.py +6 -0
- vibrante_node/examples/automation/06_reset_math_nodes.py +12 -0
- vibrante_node/examples/automation/07_stress_test_grid.py +8 -0
- vibrante_node/examples/automation/08_scene_summary.py +8 -0
- vibrante_node/examples/automation/09_toggle_bools.py +8 -0
- vibrante_node/examples/automation/10_session_report.py +7 -0
- vibrante_node/examples/automation/11_simple_math_node.py +7 -0
- vibrante_node/examples/cinematic_camera/orchestration_notes.md +56 -0
- vibrante_node/examples/cinematic_camera/prompt.md +50 -0
- vibrante_node/examples/cinematic_explosion/orchestration_notes.md +76 -0
- vibrante_node/examples/cinematic_explosion/prompt.md +47 -0
- vibrante_node/examples/cinematic_explosion/review.md +75 -0
- vibrante_node/examples/dust_wave/orchestration_notes.md +43 -0
- vibrante_node/examples/dust_wave/prompt.md +40 -0
- vibrante_node/examples/nodes/async_delay.py +21 -0
- vibrante_node/examples/nodes/connection_logger.py +25 -0
- vibrante_node/examples/nodes/data_filter.py +19 -0
- vibrante_node/examples/nodes/dict_merge.py +20 -0
- vibrante_node/examples/nodes/dict_summary.py +21 -0
- vibrante_node/examples/nodes/dropdown_selector.py +29 -0
- vibrante_node/examples/nodes/env_reader.py +18 -0
- vibrante_node/examples/nodes/list_item_picker.py +85 -0
- vibrante_node/examples/nodes/list_stats.py +27 -0
- vibrante_node/examples/nodes/logic_threshold.py +23 -0
- vibrante_node/examples/nodes/math_square.py +30 -0
- vibrante_node/examples/nodes/random_list.py +18 -0
- vibrante_node/examples/nodes/reactive_config.py +24 -0
- vibrante_node/examples/nodes/safety_reset.py +31 -0
- vibrante_node/examples/nodes/string_reverse.py +16 -0
- vibrante_node/icons/210429_DeadlineFreeOn10RenderMachines.jpg +0 -0
- vibrante_node/icons/README.md +39 -0
- vibrante_node/icons/blender_icon.png +0 -0
- vibrante_node/icons/braces.png +0 -0
- vibrante_node/icons/braces.svg +1 -0
- vibrante_node/icons/builder.png +0 -0
- vibrante_node/icons/check.png +0 -0
- vibrante_node/icons/check.svg +1 -0
- vibrante_node/icons/chevron-right.svg +3 -0
- vibrante_node/icons/code.png +0 -0
- vibrante_node/icons/code.svg +4 -0
- vibrante_node/icons/computer-window.png +0 -0
- vibrante_node/icons/data.png +0 -0
- vibrante_node/icons/data.svg +5 -0
- vibrante_node/icons/database-search.png +0 -0
- vibrante_node/icons/database-search.svg +5 -0
- vibrante_node/icons/database-zap.png +0 -0
- vibrante_node/icons/database-zap.svg +5 -0
- vibrante_node/icons/database.png +0 -0
- vibrante_node/icons/database.svg +5 -0
- vibrante_node/icons/dice.png +0 -0
- vibrante_node/icons/dice.svg +1 -0
- vibrante_node/icons/divide.svg +5 -0
- vibrante_node/icons/file-input.svg +6 -0
- vibrante_node/icons/file-plus.png +0 -0
- vibrante_node/icons/file-plus.svg +6 -0
- vibrante_node/icons/file-text.png +0 -0
- vibrante_node/icons/file-text.svg +7 -0
- vibrante_node/icons/folder-plus.png +0 -0
- vibrante_node/icons/folder-plus.svg +5 -0
- vibrante_node/icons/folder.png +0 -0
- vibrante_node/icons/folder.svg +3 -0
- vibrante_node/icons/gear.png +0 -0
- vibrante_node/icons/gear.svg +1 -0
- vibrante_node/icons/git-branch.svg +6 -0
- vibrante_node/icons/hash.png +0 -0
- vibrante_node/icons/hash.svg +1 -0
- vibrante_node/icons/houdini.svg +4 -0
- vibrante_node/icons/houdini_icon.png +0 -0
- vibrante_node/icons/http.png +0 -0
- vibrante_node/icons/list-check.png +0 -0
- vibrante_node/icons/list-check.svg +7 -0
- vibrante_node/icons/list-plus.svg +10 -0
- vibrante_node/icons/list.png +0 -0
- vibrante_node/icons/list.svg +8 -0
- vibrante_node/icons/logic.png +0 -0
- vibrante_node/icons/logic.svg +7 -0
- vibrante_node/icons/math.png +0 -0
- vibrante_node/icons/math.svg +4 -0
- vibrante_node/icons/maya_icon.jpg +0 -0
- vibrante_node/icons/message.png +0 -0
- vibrante_node/icons/message.svg +3 -0
- vibrante_node/icons/minus.svg +3 -0
- vibrante_node/icons/multiply.png +0 -0
- vibrante_node/icons/multiply.svg +1 -0
- vibrante_node/icons/online-library.png +0 -0
- vibrante_node/icons/percentage.svg +5 -0
- vibrante_node/icons/plus.png +0 -0
- vibrante_node/icons/plus.svg +1 -0
- vibrante_node/icons/print.png +0 -0
- vibrante_node/icons/print.svg +5 -0
- vibrante_node/icons/prism_icon.png +0 -0
- vibrante_node/icons/refresh.svg +6 -0
- vibrante_node/icons/repeat.svg +6 -0
- vibrante_node/icons/scales.png +0 -0
- vibrante_node/icons/scales.svg +1 -0
- vibrante_node/icons/shuffle.svg +7 -0
- vibrante_node/icons/string.png +0 -0
- vibrante_node/icons/string.svg +5 -0
- vibrante_node/icons/terminal.png +0 -0
- vibrante_node/icons/terminal.svg +1 -0
- vibrante_node/icons/timer.png +0 -0
- vibrante_node/icons/timer.svg +4 -0
- vibrante_node/icons/toggle-switch.svg +5 -0
- vibrante_node/icons/uppercase.png +0 -0
- vibrante_node/icons/uppercase.svg +1 -0
- vibrante_node/icons/variable-get.svg +4 -0
- vibrante_node/icons/variable-set.svg +6 -0
- vibrante_node/icons/variable.png +0 -0
- vibrante_node/icons/variable.svg +5 -0
- vibrante_node/icons/vibrante-node-icon.png +0 -0
- vibrante_node/icons/vibrante-node-logo.png +0 -0
- vibrante_node/icons/vibrante-node-main_logo.png +0 -0
- vibrante_node/icons/vibrante-node-resize_main_logo.png +0 -0
- vibrante_node/logo.png +0 -0
- vibrante_node/mcp_cli.py +36 -0
- vibrante_node/node_examples/Split_String.json +35 -0
- vibrante_node/node_examples/async_delay.json +32 -0
- vibrante_node/node_examples/delay_timer.json +29 -0
- vibrante_node/node_examples/file_reader.json +29 -0
- vibrante_node/node_examples/fruit_selector.json +37 -0
- vibrante_node/node_examples/json_parser.json +29 -0
- vibrante_node/node_examples/line_counter.json +29 -0
- vibrante_node/node_examples/list_append.json +32 -0
- vibrante_node/node_examples/list_images_recursive.json +55 -0
- vibrante_node/node_examples/logic_and.json +34 -0
- vibrante_node/node_examples/logic_compare.json +36 -0
- vibrante_node/node_examples/math_abs.json +29 -0
- vibrante_node/node_examples/math_add.json +32 -0
- vibrante_node/node_examples/reactive_config.json +28 -0
- vibrante_node/node_examples/string_uppercase.json +29 -0
- vibrante_node/nodes/Dropdown_Selector.json +27 -0
- vibrante_node/nodes/add_integers.json +34 -0
- vibrante_node/nodes/blender_action_bake_animation.json +23 -0
- vibrante_node/nodes/blender_action_custom.json +21 -0
- vibrante_node/nodes/blender_action_export_alembic.json +22 -0
- vibrante_node/nodes/blender_action_export_fbx.json +23 -0
- vibrante_node/nodes/blender_action_export_gltf.json +21 -0
- vibrante_node/nodes/blender_action_export_obj.json +19 -0
- vibrante_node/nodes/blender_action_export_usd.json +23 -0
- vibrante_node/nodes/blender_action_import_alembic.json +18 -0
- vibrante_node/nodes/blender_action_import_fbx.json +18 -0
- vibrante_node/nodes/blender_action_import_gltf.json +18 -0
- vibrante_node/nodes/blender_action_import_obj.json +18 -0
- vibrante_node/nodes/blender_action_new_blend.json +18 -0
- vibrante_node/nodes/blender_action_open_blend.json +18 -0
- vibrante_node/nodes/blender_action_render.json +23 -0
- vibrante_node/nodes/blender_action_save_blend.json +18 -0
- vibrante_node/nodes/blender_action_scene_info.json +17 -0
- vibrante_node/nodes/blender_action_set_frame_range.json +20 -0
- vibrante_node/nodes/blender_action_set_render_settings.json +27 -0
- vibrante_node/nodes/blender_get_action_result.json +22 -0
- vibrante_node/nodes/blender_headless.json +86 -0
- vibrante_node/nodes/compare.json +48 -0
- vibrante_node/nodes/console_print.json +29 -0
- vibrante_node/nodes/create_dictionary.json +18 -0
- vibrante_node/nodes/create_folder.json +17 -0
- vibrante_node/nodes/create_list.json +18 -0
- vibrante_node/nodes/deadline_blender_submit.json +38 -0
- vibrante_node/nodes/deadline_houdini_submit.json +38 -0
- vibrante_node/nodes/deadline_job_status.json +28 -0
- vibrante_node/nodes/deadline_maya_submit.json +40 -0
- vibrante_node/nodes/delay_timer.json +26 -0
- vibrante_node/nodes/example_random_float.json +35 -0
- vibrante_node/nodes/file_append.json +18 -0
- vibrante_node/nodes/file_write.json +18 -0
- vibrante_node/nodes/for_loop.json +46 -0
- vibrante_node/nodes/get_dict_value.json +19 -0
- vibrante_node/nodes/get_list_item.json +19 -0
- vibrante_node/nodes/houdini_action_bake_animation.json +20 -0
- vibrante_node/nodes/houdini_action_custom.json +20 -0
- vibrante_node/nodes/houdini_action_export_alembic.json +20 -0
- vibrante_node/nodes/houdini_action_export_camera_alembic.json +20 -0
- vibrante_node/nodes/houdini_action_export_fbx.json +18 -0
- vibrante_node/nodes/houdini_action_import_alembic.json +18 -0
- vibrante_node/nodes/houdini_action_import_camera.json +17 -0
- vibrante_node/nodes/houdini_action_import_fbx.json +18 -0
- vibrante_node/nodes/houdini_action_import_obj.json +18 -0
- vibrante_node/nodes/houdini_action_new_hip.json +16 -0
- vibrante_node/nodes/houdini_action_open_hip.json +17 -0
- vibrante_node/nodes/houdini_action_save_hip.json +17 -0
- vibrante_node/nodes/houdini_action_scene_info.json +16 -0
- vibrante_node/nodes/houdini_action_set_frame_range.json +18 -0
- vibrante_node/nodes/houdini_get_action_result.json +21 -0
- vibrante_node/nodes/houdini_headless.json +85 -0
- vibrante_node/nodes/houdini_scene_snapshot.json +41 -0
- vibrante_node/nodes/http_request.json +76 -0
- vibrante_node/nodes/if_condition.json +45 -0
- vibrante_node/nodes/list_directory.json +17 -0
- vibrante_node/nodes/list_images_recursive.json +41 -0
- vibrante_node/nodes/list_item_picker.json +41 -0
- vibrante_node/nodes/list_length.json +17 -0
- vibrante_node/nodes/logical_gate.json +45 -0
- vibrante_node/nodes/loop_body.json +62 -0
- vibrante_node/nodes/math_add.json +17 -0
- vibrante_node/nodes/math_divide.json +17 -0
- vibrante_node/nodes/math_modulo.json +17 -0
- vibrante_node/nodes/math_multiply.json +36 -0
- vibrante_node/nodes/math_subtract.json +17 -0
- vibrante_node/nodes/maya_action_assign_material.json +18 -0
- vibrante_node/nodes/maya_action_bake_animation.json +21 -0
- vibrante_node/nodes/maya_action_create_render_layer.json +19 -0
- vibrante_node/nodes/maya_action_custom.json +20 -0
- vibrante_node/nodes/maya_action_export_alembic.json +22 -0
- vibrante_node/nodes/maya_action_export_camera_alembic.json +20 -0
- vibrante_node/nodes/maya_action_export_fbx.json +18 -0
- vibrante_node/nodes/maya_action_import_alembic.json +17 -0
- vibrante_node/nodes/maya_action_import_camera.json +17 -0
- vibrante_node/nodes/maya_action_import_fbx.json +17 -0
- vibrante_node/nodes/maya_action_import_obj.json +17 -0
- vibrante_node/nodes/maya_action_list_references.json +16 -0
- vibrante_node/nodes/maya_action_new_scene.json +16 -0
- vibrante_node/nodes/maya_action_open_scene.json +18 -0
- vibrante_node/nodes/maya_action_playblast.json +22 -0
- vibrante_node/nodes/maya_action_reference_alembic.json +18 -0
- vibrante_node/nodes/maya_action_reference_scene.json +18 -0
- vibrante_node/nodes/maya_action_save_scene.json +18 -0
- vibrante_node/nodes/maya_action_scene_info.json +16 -0
- vibrante_node/nodes/maya_action_set_aovs.json +18 -0
- vibrante_node/nodes/maya_action_set_frame_range.json +18 -0
- vibrante_node/nodes/maya_action_set_render_settings.json +23 -0
- vibrante_node/nodes/maya_get_action_result.json +21 -0
- vibrante_node/nodes/maya_headless.json +27 -0
- vibrante_node/nodes/mcp_call_tool.json +19 -0
- vibrante_node/nodes/mcp_list_tools.json +18 -0
- vibrante_node/nodes/mcp_server_init.json +23 -0
- vibrante_node/nodes/message_node.json +32 -0
- vibrante_node/nodes/prism_add_integration.json +49 -0
- vibrante_node/nodes/prism_build_entity.json +45 -0
- vibrante_node/nodes/prism_change_project.json +37 -0
- vibrante_node/nodes/prism_core_info.json +37 -0
- vibrante_node/nodes/prism_core_init.json +46 -0
- vibrante_node/nodes/prism_create_category.json +44 -0
- vibrante_node/nodes/prism_create_entity.json +60 -0
- vibrante_node/nodes/prism_create_playblast.json +56 -0
- vibrante_node/nodes/prism_create_product_version.json +64 -0
- vibrante_node/nodes/prism_create_project.json +50 -0
- vibrante_node/nodes/prism_create_scene_from_preset.json +59 -0
- vibrante_node/nodes/prism_eval.json +42 -0
- vibrante_node/nodes/prism_get_aovs.json +29 -0
- vibrante_node/nodes/prism_get_asset_by_name.json +69 -0
- vibrante_node/nodes/prism_get_asset_type_by_name.json +62 -0
- vibrante_node/nodes/prism_get_asset_types_by_project.json +55 -0
- vibrante_node/nodes/prism_get_assets_by_project.json +41 -0
- vibrante_node/nodes/prism_get_assets_by_type.json +69 -0
- vibrante_node/nodes/prism_get_config.json +48 -0
- vibrante_node/nodes/prism_get_current_scene.json +37 -0
- vibrante_node/nodes/prism_get_departments.json +37 -0
- vibrante_node/nodes/prism_get_entity_info.json +69 -0
- vibrante_node/nodes/prism_get_entity_path.json +69 -0
- vibrante_node/nodes/prism_get_export_path.json +26 -0
- vibrante_node/nodes/prism_get_latest_product_path.json +34 -0
- vibrante_node/nodes/prism_get_media.json +29 -0
- vibrante_node/nodes/prism_get_media_versions.json +33 -0
- vibrante_node/nodes/prism_get_plugin.json +35 -0
- vibrante_node/nodes/prism_get_preset_scenes.json +35 -0
- vibrante_node/nodes/prism_get_product_versions.json +33 -0
- vibrante_node/nodes/prism_get_products.json +29 -0
- vibrante_node/nodes/prism_get_project_by_name.json +55 -0
- vibrante_node/nodes/prism_get_project_config_path.json +26 -0
- vibrante_node/nodes/prism_get_scene_files.json +45 -0
- vibrante_node/nodes/prism_get_scene_path.json +23 -0
- vibrante_node/nodes/prism_get_sequence_by_project.json +48 -0
- vibrante_node/nodes/prism_get_sequences_by_project.json +41 -0
- vibrante_node/nodes/prism_get_shot_by_name.json +62 -0
- vibrante_node/nodes/prism_get_shot_by_sequence.json +55 -0
- vibrante_node/nodes/prism_get_shot_info.json +69 -0
- vibrante_node/nodes/prism_get_shots.json +29 -0
- vibrante_node/nodes/prism_get_shots_by_project_sequence.json +48 -0
- vibrante_node/nodes/prism_get_shots_by_sequence.json +48 -0
- vibrante_node/nodes/prism_get_tasks.json +39 -0
- vibrante_node/nodes/prism_import_product.json +37 -0
- vibrante_node/nodes/prism_list_plugins.json +25 -0
- vibrante_node/nodes/prism_list_projects.json +25 -0
- vibrante_node/nodes/prism_login_token.json +33 -0
- vibrante_node/nodes/prism_monkey_patch.json +46 -0
- vibrante_node/nodes/prism_open_scene.json +33 -0
- vibrante_node/nodes/prism_popup.json +40 -0
- vibrante_node/nodes/prism_register_callback.json +58 -0
- vibrante_node/nodes/prism_save_scene_version.json +90 -0
- vibrante_node/nodes/prism_send_cmd.json +54 -0
- vibrante_node/nodes/prism_set_config.json +55 -0
- vibrante_node/nodes/prism_studio_assign_project.json +43 -0
- vibrante_node/nodes/prism_trigger_callback.json +42 -0
- vibrante_node/nodes/prism_usd_department_layer_path.json +35 -0
- vibrante_node/nodes/prism_usd_entity_path.json +29 -0
- vibrante_node/nodes/prism_usd_sublayer_path.json +41 -0
- vibrante_node/nodes/prism_usd_update_department_layer.json +33 -0
- vibrante_node/nodes/prism_usd_update_sublayer.json +33 -0
- vibrante_node/nodes/python_script.json +17 -0
- vibrante_node/nodes/scene_intent_extractor.json +25 -0
- vibrante_node/nodes/set_dict_value.json +20 -0
- vibrante_node/nodes/string_concat.json +47 -0
- vibrante_node/nodes/string_length.json +16 -0
- vibrante_node/nodes/string_lowercase.json +16 -0
- vibrante_node/nodes/string_replace.json +18 -0
- vibrante_node/nodes/string_split.json +17 -0
- vibrante_node/nodes/string_uppercase.json +16 -0
- vibrante_node/nodes/variable_node.json +42 -0
- vibrante_node/nodes/while_loop.json +18 -0
- vibrante_node/splash.png +0 -0
- vibrante_node/vfx_workflows/01_prism_project_overview.json +492 -0
- vibrante_node/vfx_workflows/02_maya_asset_publish.json +776 -0
- vibrante_node/vfx_workflows/03_multi_shot_alembic_export.json +856 -0
- vibrante_node/vfx_workflows/04_deadline_render_pipeline.json +994 -0
- vibrante_node/vfx_workflows/05_houdini_fx_pipeline.json +1056 -0
- vibrante_node/vfx_workflows/06_blender_multi_format_export.json +1206 -0
- vibrante_node/website_examples/database_query.json +69 -0
- vibrante_node/website_examples/email_notification.json +104 -0
- vibrante_node/website_examples/file_batch_processor.json +62 -0
- vibrante_node/website_examples/folder_monitor.json +55 -0
- vibrante_node/website_examples/hou_sop_chain.json +69 -0
- vibrante_node/website_examples/http_request.json +90 -0
- vibrante_node/website_examples/image_resizer.json +90 -0
- vibrante_node/website_examples/llm_text_generation.json +90 -0
- vibrante_node/website_examples/prism_multi_asset_publisher.json +76 -0
- vibrante_node/website_examples/regex_replace.json +69 -0
- vibrante_node/workflows/If_condition.json +134 -0
- vibrante_node/workflows/Maya_WorkFlow.json +464 -0
- vibrante_node/workflows/asset_intelligence_pipeline.json +259 -0
- vibrante_node/workflows/concat_string_with_loop.json +262 -0
- vibrante_node/workflows/delay_time.json +74 -0
- vibrante_node/workflows/example_workflow_maya_prism_demo.json +503 -0
- vibrante_node/workflows/example_workflow_prism_demo.json +276 -0
- vibrante_node/workflows/example_workflow_prism_demo_02.json +221 -0
- vibrante_node/workflows/extract_FPS_from_maya_scene.json +265 -0
- vibrante_node/workflows/for_each.json +260 -0
- vibrante_node/workflows/get_list_item.json +151 -0
- vibrante_node/workflows/hou_mcp_scene_context_demo.json +67 -0
- vibrante_node/workflows/list_recursive_images.json +103 -0
- vibrante_node/workflows/logic_if_example.json +262 -0
- vibrante_node/workflows/logic_if_with_variables.json +210 -0
- vibrante_node/workflows/loop_break_example.json +197 -0
- vibrante_node/workflows/loop_operation_example.json +382 -0
- vibrante_node/workflows/mcp_list_tools_demo.json +90 -0
- vibrante_node/workflows/prism_assets_workflow.json +131 -0
- vibrante_node/workflows/python_script_node.json +89 -0
- vibrante_node/workflows/run_in_sequence.json +158 -0
- vibrante_node/workflows/scene_intent_pipeline.json +134 -0
- vibrante_node/workflows/scene_planning_pipeline.json +258 -0
- vibrante_node/workflows/semantic_scene_intent.json +96 -0
- vibrante_node/workflows/setup_maya_scene.json +352 -0
- vibrante_node/workflows/tutorial_maya_headless_prism_pipeline.json +593 -0
- vibrante_node/workflows/two_way_switch.json +341 -0
- vibrante_node/workflows/while_loop_class_example.json +192 -0
- vibrante_node/workflows/while_loop_example.json +184 -0
- vibrante_node/workflows/while_loop_retry_example.json +276 -0
- vibrante_node-2.5.1.dist-info/METADATA +715 -0
- vibrante_node-2.5.1.dist-info/RECORD +487 -0
- vibrante_node-2.5.1.dist-info/WHEEL +5 -0
- vibrante_node-2.5.1.dist-info/entry_points.txt +3 -0
- vibrante_node-2.5.1.dist-info/licenses/CLA.md +96 -0
- vibrante_node-2.5.1.dist-info/licenses/COMMERCIAL_LICENSE.md +170 -0
- vibrante_node-2.5.1.dist-info/licenses/LICENSE +178 -0
- vibrante_node-2.5.1.dist-info/licenses/LICENSES/AGPL-3.0.txt +661 -0
- vibrante_node-2.5.1.dist-info/licenses/LICENSES/CC-BY-4.0-SCOPE.md +53 -0
- vibrante_node-2.5.1.dist-info/licenses/LICENSES/CC-BY-4.0.txt +396 -0
- vibrante_node-2.5.1.dist-info/licenses/LICENSES/GPL-3.0.txt +674 -0
- vibrante_node-2.5.1.dist-info/licenses/LICENSES/LGPL-3.0.txt +165 -0
- vibrante_node-2.5.1.dist-info/licenses/LICENSES/README.md +65 -0
- vibrante_node-2.5.1.dist-info/top_level.txt +2 -0
|
@@ -0,0 +1,575 @@
|
|
|
1
|
+
import json
|
|
2
|
+
import os
|
|
3
|
+
import sys
|
|
4
|
+
|
|
5
|
+
from src.utils.qt_compat import QtWidgets, QtCore, QtGui
|
|
6
|
+
from src.utils.env_manager import env_manager
|
|
7
|
+
|
|
8
|
+
QDialog = QtWidgets.QDialog
|
|
9
|
+
QWidget = QtWidgets.QWidget
|
|
10
|
+
QVBoxLayout = QtWidgets.QVBoxLayout
|
|
11
|
+
QHBoxLayout = QtWidgets.QHBoxLayout
|
|
12
|
+
QLabel = QtWidgets.QLabel
|
|
13
|
+
QPushButton = QtWidgets.QPushButton
|
|
14
|
+
QListWidget = QtWidgets.QListWidget
|
|
15
|
+
QStackedWidget = QtWidgets.QStackedWidget
|
|
16
|
+
QPlainTextEdit = QtWidgets.QPlainTextEdit
|
|
17
|
+
QTableWidget = QtWidgets.QTableWidget
|
|
18
|
+
QTableWidgetItem = QtWidgets.QTableWidgetItem
|
|
19
|
+
QHeaderView = QtWidgets.QHeaderView
|
|
20
|
+
QAbstractItemView = QtWidgets.QAbstractItemView
|
|
21
|
+
QFileDialog = QtWidgets.QFileDialog
|
|
22
|
+
QMessageBox = QtWidgets.QMessageBox
|
|
23
|
+
QFrame = QtWidgets.QFrame
|
|
24
|
+
Qt = QtCore.Qt
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
# Known built-in Vibrante-Node environment variables displayed read-only.
|
|
28
|
+
# v_nodes_dir and v_scripts_path are managed on the Application Paths page.
|
|
29
|
+
# Each entry: (variable_name, description).
|
|
30
|
+
_VIBRANTE_BUILTIN_VARS = [
|
|
31
|
+
("VIBRANTE_NODE_APP", "Path to the Vibrante-Node application root directory."),
|
|
32
|
+
("VIBRANTE_PYTHON_EXE", "Path to the system Python executable used for subprocess launches."),
|
|
33
|
+
("VIBRANTE_HOUDINI_MODE", "Runtime mode: 'subprocess' (launched from Houdini) or 'direct'."),
|
|
34
|
+
("VIBRANTE_HOU_PORT", "TCP port for the Houdini JSON-RPC bridge server (default: 18811)."),
|
|
35
|
+
("VIBRANTE_HIP_FILE", "Path to the current Houdini scene (.hip) file."),
|
|
36
|
+
]
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
class SettingsWindow(QDialog):
|
|
40
|
+
"""Application settings and preferences dialog.
|
|
41
|
+
|
|
42
|
+
Sidebar navigation with stacked pages:
|
|
43
|
+
- Python Runtime (VIBRANTE_PYTHONPATH editor)
|
|
44
|
+
- Application Paths (v_nodes_dir and v_scripts_path editors)
|
|
45
|
+
- Environment Vars (custom user variables table)
|
|
46
|
+
- Vibrante Variables (read-only display of built-in runtime variables)
|
|
47
|
+
"""
|
|
48
|
+
|
|
49
|
+
def __init__(self, parent=None):
|
|
50
|
+
super().__init__(parent)
|
|
51
|
+
self.setWindowTitle("Settings — Vibrante-Node")
|
|
52
|
+
self.setMinimumSize(720, 480)
|
|
53
|
+
self.resize(760, 520)
|
|
54
|
+
self._init_ui()
|
|
55
|
+
self._load_settings()
|
|
56
|
+
|
|
57
|
+
# ------------------------------------------------------------------
|
|
58
|
+
# UI construction
|
|
59
|
+
# ------------------------------------------------------------------
|
|
60
|
+
|
|
61
|
+
def _init_ui(self):
|
|
62
|
+
root = QHBoxLayout(self)
|
|
63
|
+
root.setContentsMargins(0, 0, 0, 0)
|
|
64
|
+
root.setSpacing(0)
|
|
65
|
+
|
|
66
|
+
# ---- Sidebar ----
|
|
67
|
+
self._sidebar = QListWidget()
|
|
68
|
+
self._sidebar.setFixedWidth(170)
|
|
69
|
+
self._sidebar.setFrameShape(QFrame.NoFrame)
|
|
70
|
+
self._sidebar.setSpacing(2)
|
|
71
|
+
self._sidebar.addItem("Python Runtime")
|
|
72
|
+
self._sidebar.addItem("Application Paths")
|
|
73
|
+
self._sidebar.addItem("Environment Variables")
|
|
74
|
+
self._sidebar.addItem("Vibrante Variables")
|
|
75
|
+
self._sidebar.setCurrentRow(0)
|
|
76
|
+
root.addWidget(self._sidebar)
|
|
77
|
+
|
|
78
|
+
# Vertical divider
|
|
79
|
+
divider = QFrame()
|
|
80
|
+
divider.setFrameShape(QFrame.VLine)
|
|
81
|
+
divider.setFrameShadow(QFrame.Sunken)
|
|
82
|
+
root.addWidget(divider)
|
|
83
|
+
|
|
84
|
+
# ---- Right panel ----
|
|
85
|
+
right = QVBoxLayout()
|
|
86
|
+
right.setContentsMargins(16, 16, 16, 12)
|
|
87
|
+
right.setSpacing(8)
|
|
88
|
+
|
|
89
|
+
self._pages = QStackedWidget()
|
|
90
|
+
self._pages.addWidget(self._build_python_runtime_page()) # index 0
|
|
91
|
+
self._pages.addWidget(self._build_app_paths_page()) # index 1
|
|
92
|
+
self._pages.addWidget(self._build_env_vars_page()) # index 2
|
|
93
|
+
self._pages.addWidget(self._build_vibrante_vars_page()) # index 3
|
|
94
|
+
right.addWidget(self._pages, 1)
|
|
95
|
+
|
|
96
|
+
# ---- Buttons row ----
|
|
97
|
+
btn_row = QHBoxLayout()
|
|
98
|
+
self._import_btn = QPushButton("Import Settings…")
|
|
99
|
+
self._import_btn.setToolTip("Load settings from a JSON file into this dialog")
|
|
100
|
+
self._export_btn = QPushButton("Export Settings…")
|
|
101
|
+
self._export_btn.setToolTip("Save current settings to a JSON file")
|
|
102
|
+
btn_row.addWidget(self._import_btn)
|
|
103
|
+
btn_row.addWidget(self._export_btn)
|
|
104
|
+
btn_row.addStretch()
|
|
105
|
+
self._ok_btn = QPushButton("OK")
|
|
106
|
+
self._ok_btn.setFixedWidth(88)
|
|
107
|
+
self._ok_btn.setDefault(True)
|
|
108
|
+
self._cancel_btn = QPushButton("Cancel")
|
|
109
|
+
self._cancel_btn.setFixedWidth(88)
|
|
110
|
+
btn_row.addWidget(self._ok_btn)
|
|
111
|
+
btn_row.addWidget(self._cancel_btn)
|
|
112
|
+
right.addLayout(btn_row)
|
|
113
|
+
|
|
114
|
+
right_widget = QWidget()
|
|
115
|
+
right_widget.setLayout(right)
|
|
116
|
+
root.addWidget(right_widget, 1)
|
|
117
|
+
|
|
118
|
+
# ---- Connections ----
|
|
119
|
+
self._sidebar.currentRowChanged.connect(self._pages.setCurrentIndex)
|
|
120
|
+
self._ok_btn.clicked.connect(self._save_and_accept)
|
|
121
|
+
self._cancel_btn.clicked.connect(self.reject)
|
|
122
|
+
self._import_btn.clicked.connect(self._import_settings)
|
|
123
|
+
self._export_btn.clicked.connect(self._export_settings)
|
|
124
|
+
|
|
125
|
+
# ------------------------------------------------------------------
|
|
126
|
+
# Page builders
|
|
127
|
+
# ------------------------------------------------------------------
|
|
128
|
+
|
|
129
|
+
def _build_general_page(self) -> QWidget:
|
|
130
|
+
page = QWidget()
|
|
131
|
+
layout = QVBoxLayout(page)
|
|
132
|
+
layout.setContentsMargins(0, 0, 0, 0)
|
|
133
|
+
|
|
134
|
+
title = QLabel("<b>General</b>")
|
|
135
|
+
title.setStyleSheet("font-size: 14px;")
|
|
136
|
+
layout.addWidget(title)
|
|
137
|
+
|
|
138
|
+
sep = QFrame()
|
|
139
|
+
sep.setFrameShape(QFrame.HLine)
|
|
140
|
+
sep.setFrameShadow(QFrame.Sunken)
|
|
141
|
+
layout.addWidget(sep)
|
|
142
|
+
|
|
143
|
+
note = QLabel(
|
|
144
|
+
"General application preferences will be available here in a future release.\n\n"
|
|
145
|
+
"Current settings such as theme can be changed via the Themes menu."
|
|
146
|
+
)
|
|
147
|
+
note.setWordWrap(True)
|
|
148
|
+
layout.addWidget(note)
|
|
149
|
+
layout.addStretch()
|
|
150
|
+
return page
|
|
151
|
+
|
|
152
|
+
def _build_python_runtime_page(self) -> QWidget:
|
|
153
|
+
page = QWidget()
|
|
154
|
+
layout = QVBoxLayout(page)
|
|
155
|
+
layout.setContentsMargins(0, 0, 0, 0)
|
|
156
|
+
layout.setSpacing(8)
|
|
157
|
+
|
|
158
|
+
title = QLabel("<b>Python Runtime</b>")
|
|
159
|
+
title.setStyleSheet("font-size: 14px;")
|
|
160
|
+
layout.addWidget(title)
|
|
161
|
+
|
|
162
|
+
sep = QFrame()
|
|
163
|
+
sep.setFrameShape(QFrame.HLine)
|
|
164
|
+
sep.setFrameShadow(QFrame.Sunken)
|
|
165
|
+
layout.addWidget(sep)
|
|
166
|
+
|
|
167
|
+
layout.addWidget(QLabel("<b>VIBRANTE_PYTHONPATH</b>"))
|
|
168
|
+
desc = QLabel(
|
|
169
|
+
"Extra Python package/library directories injected into sys.path at startup. "
|
|
170
|
+
"Enter one absolute path per line. Paths that do not exist are ignored."
|
|
171
|
+
)
|
|
172
|
+
desc.setWordWrap(True)
|
|
173
|
+
layout.addWidget(desc)
|
|
174
|
+
|
|
175
|
+
self._pythonpath_edit = QPlainTextEdit()
|
|
176
|
+
self._pythonpath_edit.setPlaceholderText(
|
|
177
|
+
"C:\\MyLibs\\python\nD:\\studio\\tools\\python"
|
|
178
|
+
)
|
|
179
|
+
self._pythonpath_edit.setMinimumHeight(120)
|
|
180
|
+
layout.addWidget(self._pythonpath_edit)
|
|
181
|
+
|
|
182
|
+
browse_btn = QPushButton("Browse && Add Directory…")
|
|
183
|
+
browse_btn.clicked.connect(self._browse_pythonpath)
|
|
184
|
+
layout.addWidget(browse_btn)
|
|
185
|
+
|
|
186
|
+
layout.addSpacing(8)
|
|
187
|
+
layout.addWidget(QLabel("<b>Current sys.path preview</b> (VIBRANTE_PYTHONPATH entries only):"))
|
|
188
|
+
self._syspath_preview = QPlainTextEdit()
|
|
189
|
+
self._syspath_preview.setReadOnly(True)
|
|
190
|
+
self._syspath_preview.setMaximumHeight(80)
|
|
191
|
+
self._syspath_preview.setPlaceholderText("(none yet applied)")
|
|
192
|
+
layout.addWidget(self._syspath_preview)
|
|
193
|
+
|
|
194
|
+
layout.addStretch()
|
|
195
|
+
return page
|
|
196
|
+
|
|
197
|
+
def _build_app_paths_page(self) -> QWidget:
|
|
198
|
+
page = QWidget()
|
|
199
|
+
layout = QVBoxLayout(page)
|
|
200
|
+
layout.setContentsMargins(0, 0, 0, 0)
|
|
201
|
+
layout.setSpacing(8)
|
|
202
|
+
|
|
203
|
+
title = QLabel("<b>Application Paths</b>")
|
|
204
|
+
title.setStyleSheet("font-size: 14px;")
|
|
205
|
+
layout.addWidget(title)
|
|
206
|
+
|
|
207
|
+
sep = QFrame()
|
|
208
|
+
sep.setFrameShape(QFrame.HLine)
|
|
209
|
+
sep.setFrameShadow(QFrame.Sunken)
|
|
210
|
+
layout.addWidget(sep)
|
|
211
|
+
|
|
212
|
+
# v_nodes_dir
|
|
213
|
+
layout.addWidget(QLabel("<b>v_nodes_dir</b> — Extra Node Directories"))
|
|
214
|
+
nodes_desc = QLabel(
|
|
215
|
+
"Additional directories scanned for .json node definitions at startup. "
|
|
216
|
+
"One absolute path per line. Changes take effect after restarting the application."
|
|
217
|
+
)
|
|
218
|
+
nodes_desc.setWordWrap(True)
|
|
219
|
+
layout.addWidget(nodes_desc)
|
|
220
|
+
|
|
221
|
+
self._v_nodes_dir_edit = QPlainTextEdit()
|
|
222
|
+
self._v_nodes_dir_edit.setPlaceholderText(
|
|
223
|
+
"C:\\MyStudio\\nodes\nD:\\pipeline\\vibrante_nodes"
|
|
224
|
+
)
|
|
225
|
+
self._v_nodes_dir_edit.setMinimumHeight(80)
|
|
226
|
+
self._v_nodes_dir_edit.setMaximumHeight(110)
|
|
227
|
+
layout.addWidget(self._v_nodes_dir_edit)
|
|
228
|
+
|
|
229
|
+
nodes_browse_btn = QPushButton("Browse && Add Directory…")
|
|
230
|
+
nodes_browse_btn.clicked.connect(self._browse_v_nodes_dir)
|
|
231
|
+
layout.addWidget(nodes_browse_btn)
|
|
232
|
+
|
|
233
|
+
layout.addSpacing(8)
|
|
234
|
+
|
|
235
|
+
# v_scripts_path
|
|
236
|
+
layout.addWidget(QLabel("<b>v_scripts_path</b> — Extra Script Directories"))
|
|
237
|
+
scripts_desc = QLabel(
|
|
238
|
+
"Additional directories scanned for .py scripts in the Scripts menu. "
|
|
239
|
+
"One absolute path per line. Use Scripts → Refresh Scripts to apply without restarting."
|
|
240
|
+
)
|
|
241
|
+
scripts_desc.setWordWrap(True)
|
|
242
|
+
layout.addWidget(scripts_desc)
|
|
243
|
+
|
|
244
|
+
self._v_scripts_path_edit = QPlainTextEdit()
|
|
245
|
+
self._v_scripts_path_edit.setPlaceholderText(
|
|
246
|
+
"C:\\MyStudio\\scripts\nD:\\pipeline\\vibrante_scripts"
|
|
247
|
+
)
|
|
248
|
+
self._v_scripts_path_edit.setMinimumHeight(80)
|
|
249
|
+
self._v_scripts_path_edit.setMaximumHeight(110)
|
|
250
|
+
layout.addWidget(self._v_scripts_path_edit)
|
|
251
|
+
|
|
252
|
+
scripts_browse_btn = QPushButton("Browse && Add Directory…")
|
|
253
|
+
scripts_browse_btn.clicked.connect(self._browse_v_scripts_path)
|
|
254
|
+
layout.addWidget(scripts_browse_btn)
|
|
255
|
+
|
|
256
|
+
layout.addStretch()
|
|
257
|
+
return page
|
|
258
|
+
|
|
259
|
+
def _build_env_vars_page(self) -> QWidget:
|
|
260
|
+
page = QWidget()
|
|
261
|
+
layout = QVBoxLayout(page)
|
|
262
|
+
layout.setContentsMargins(0, 0, 0, 0)
|
|
263
|
+
layout.setSpacing(8)
|
|
264
|
+
|
|
265
|
+
title = QLabel("<b>Environment Variables</b>")
|
|
266
|
+
title.setStyleSheet("font-size: 14px;")
|
|
267
|
+
layout.addWidget(title)
|
|
268
|
+
|
|
269
|
+
sep = QFrame()
|
|
270
|
+
sep.setFrameShape(QFrame.HLine)
|
|
271
|
+
sep.setFrameShadow(QFrame.Sunken)
|
|
272
|
+
layout.addWidget(sep)
|
|
273
|
+
|
|
274
|
+
desc = QLabel(
|
|
275
|
+
"Custom variables set in the current process environment (os.environ). "
|
|
276
|
+
"These are accessible inside nodes and workflows via os.environ.get()."
|
|
277
|
+
)
|
|
278
|
+
desc.setWordWrap(True)
|
|
279
|
+
layout.addWidget(desc)
|
|
280
|
+
|
|
281
|
+
self._var_table = QTableWidget(0, 2)
|
|
282
|
+
self._var_table.setHorizontalHeaderLabels(["Variable Name", "Value"])
|
|
283
|
+
self._var_table.horizontalHeader().setSectionResizeMode(0, QHeaderView.ResizeToContents)
|
|
284
|
+
self._var_table.horizontalHeader().setSectionResizeMode(1, QHeaderView.Stretch)
|
|
285
|
+
self._var_table.setSelectionBehavior(QAbstractItemView.SelectRows)
|
|
286
|
+
self._var_table.setSelectionMode(QAbstractItemView.SingleSelection)
|
|
287
|
+
self._var_table.verticalHeader().setVisible(False)
|
|
288
|
+
layout.addWidget(self._var_table, 1)
|
|
289
|
+
|
|
290
|
+
btn_row = QHBoxLayout()
|
|
291
|
+
add_btn = QPushButton("Add Variable")
|
|
292
|
+
add_btn.clicked.connect(self._add_variable_row)
|
|
293
|
+
remove_btn = QPushButton("Remove Selected")
|
|
294
|
+
remove_btn.clicked.connect(self._remove_variable_row)
|
|
295
|
+
btn_row.addWidget(add_btn)
|
|
296
|
+
btn_row.addWidget(remove_btn)
|
|
297
|
+
btn_row.addStretch()
|
|
298
|
+
layout.addLayout(btn_row)
|
|
299
|
+
|
|
300
|
+
return page
|
|
301
|
+
|
|
302
|
+
def _build_vibrante_vars_page(self) -> QWidget:
|
|
303
|
+
page = QWidget()
|
|
304
|
+
layout = QVBoxLayout(page)
|
|
305
|
+
layout.setContentsMargins(0, 0, 0, 0)
|
|
306
|
+
layout.setSpacing(8)
|
|
307
|
+
|
|
308
|
+
title = QLabel("<b>Vibrante-Node Variables</b>")
|
|
309
|
+
title.setStyleSheet("font-size: 14px;")
|
|
310
|
+
layout.addWidget(title)
|
|
311
|
+
|
|
312
|
+
sep = QFrame()
|
|
313
|
+
sep.setFrameShape(QFrame.HLine)
|
|
314
|
+
sep.setFrameShadow(QFrame.Sunken)
|
|
315
|
+
layout.addWidget(sep)
|
|
316
|
+
|
|
317
|
+
desc = QLabel(
|
|
318
|
+
"Built-in environment variables used by the Vibrante-Node runtime. "
|
|
319
|
+
"Values are read-only — set them via your Houdini package JSON or system environment."
|
|
320
|
+
)
|
|
321
|
+
desc.setWordWrap(True)
|
|
322
|
+
layout.addWidget(desc)
|
|
323
|
+
|
|
324
|
+
self._vibrante_vars_table = QTableWidget(0, 3)
|
|
325
|
+
self._vibrante_vars_table.setHorizontalHeaderLabels(["Variable", "Current Value", "Description"])
|
|
326
|
+
hh = self._vibrante_vars_table.horizontalHeader()
|
|
327
|
+
hh.setSectionResizeMode(0, QHeaderView.ResizeToContents)
|
|
328
|
+
hh.setSectionResizeMode(1, QHeaderView.ResizeToContents)
|
|
329
|
+
hh.setSectionResizeMode(2, QHeaderView.Stretch)
|
|
330
|
+
self._vibrante_vars_table.setEditTriggers(QAbstractItemView.NoEditTriggers)
|
|
331
|
+
self._vibrante_vars_table.setSelectionBehavior(QAbstractItemView.SelectRows)
|
|
332
|
+
self._vibrante_vars_table.setSelectionMode(QAbstractItemView.SingleSelection)
|
|
333
|
+
self._vibrante_vars_table.verticalHeader().setVisible(False)
|
|
334
|
+
self._vibrante_vars_table.setAlternatingRowColors(True)
|
|
335
|
+
layout.addWidget(self._vibrante_vars_table, 1)
|
|
336
|
+
|
|
337
|
+
refresh_btn = QPushButton("Refresh")
|
|
338
|
+
refresh_btn.setToolTip("Re-read current runtime values from os.environ")
|
|
339
|
+
refresh_btn.clicked.connect(self._load_vibrante_vars)
|
|
340
|
+
btn_row = QHBoxLayout()
|
|
341
|
+
btn_row.addWidget(refresh_btn)
|
|
342
|
+
btn_row.addStretch()
|
|
343
|
+
layout.addLayout(btn_row)
|
|
344
|
+
|
|
345
|
+
return page
|
|
346
|
+
|
|
347
|
+
# ------------------------------------------------------------------
|
|
348
|
+
# Load / Save
|
|
349
|
+
# ------------------------------------------------------------------
|
|
350
|
+
|
|
351
|
+
def _load_settings(self):
|
|
352
|
+
# Python Runtime page
|
|
353
|
+
paths = env_manager.get_vibrante_pythonpath()
|
|
354
|
+
self._pythonpath_edit.setPlainText("\n".join(paths))
|
|
355
|
+
self._refresh_syspath_preview()
|
|
356
|
+
|
|
357
|
+
# Application Paths page
|
|
358
|
+
self._v_nodes_dir_edit.setPlainText("\n".join(env_manager.get_v_nodes_dir()))
|
|
359
|
+
self._v_scripts_path_edit.setPlainText("\n".join(env_manager.get_v_scripts_path()))
|
|
360
|
+
|
|
361
|
+
# Environment Variables page
|
|
362
|
+
custom = env_manager.get_custom_variables()
|
|
363
|
+
self._var_table.setRowCount(0)
|
|
364
|
+
for name, value in custom.items():
|
|
365
|
+
self._append_var_row(name, value)
|
|
366
|
+
|
|
367
|
+
# Vibrante Variables page
|
|
368
|
+
self._load_vibrante_vars()
|
|
369
|
+
|
|
370
|
+
def _load_vibrante_vars(self):
|
|
371
|
+
"""Populate the Vibrante Variables table from current os.environ values."""
|
|
372
|
+
self._vibrante_vars_table.setRowCount(0)
|
|
373
|
+
for var_name, description in _VIBRANTE_BUILTIN_VARS:
|
|
374
|
+
row = self._vibrante_vars_table.rowCount()
|
|
375
|
+
self._vibrante_vars_table.insertRow(row)
|
|
376
|
+
|
|
377
|
+
name_item = QTableWidgetItem(var_name)
|
|
378
|
+
value = os.environ.get(var_name, "")
|
|
379
|
+
value_item = QTableWidgetItem(value if value else "(not set)")
|
|
380
|
+
desc_item = QTableWidgetItem(description)
|
|
381
|
+
|
|
382
|
+
if not value:
|
|
383
|
+
gray = QtGui.QColor(128, 128, 128)
|
|
384
|
+
value_item.setForeground(gray)
|
|
385
|
+
|
|
386
|
+
self._vibrante_vars_table.setItem(row, 0, name_item)
|
|
387
|
+
self._vibrante_vars_table.setItem(row, 1, value_item)
|
|
388
|
+
self._vibrante_vars_table.setItem(row, 2, desc_item)
|
|
389
|
+
self._vibrante_vars_table.resizeColumnsToContents()
|
|
390
|
+
self._vibrante_vars_table.horizontalHeader().setSectionResizeMode(2, QHeaderView.Stretch)
|
|
391
|
+
|
|
392
|
+
def _refresh_syspath_preview(self):
|
|
393
|
+
configured = set(env_manager.get_vibrante_pythonpath())
|
|
394
|
+
applied = [p for p in configured if p in sys.path]
|
|
395
|
+
self._syspath_preview.setPlainText("\n".join(applied) if applied else "")
|
|
396
|
+
|
|
397
|
+
def _save_and_accept(self):
|
|
398
|
+
# Collect VIBRANTE_PYTHONPATH
|
|
399
|
+
raw_paths = self._pythonpath_edit.toPlainText()
|
|
400
|
+
paths = [p.strip() for p in raw_paths.splitlines() if p.strip()]
|
|
401
|
+
|
|
402
|
+
# Validate paths — warn but don't block
|
|
403
|
+
missing = [p for p in paths if not os.path.isdir(p)]
|
|
404
|
+
if missing:
|
|
405
|
+
msg = "The following paths do not exist and will be ignored at runtime:\n\n"
|
|
406
|
+
msg += "\n".join(missing)
|
|
407
|
+
msg += "\n\nSave anyway?"
|
|
408
|
+
reply = QMessageBox.question(
|
|
409
|
+
self, "Path Warning", msg,
|
|
410
|
+
QMessageBox.Yes | QMessageBox.No, QMessageBox.Yes
|
|
411
|
+
)
|
|
412
|
+
if reply == QMessageBox.No:
|
|
413
|
+
return
|
|
414
|
+
|
|
415
|
+
# Collect custom variables
|
|
416
|
+
variables = {}
|
|
417
|
+
for row in range(self._var_table.rowCount()):
|
|
418
|
+
name_item = self._var_table.item(row, 0)
|
|
419
|
+
value_item = self._var_table.item(row, 1)
|
|
420
|
+
name = (name_item.text().strip() if name_item else "")
|
|
421
|
+
value = (value_item.text().strip() if value_item else "")
|
|
422
|
+
if name:
|
|
423
|
+
variables[name] = value
|
|
424
|
+
|
|
425
|
+
# Validate variable names
|
|
426
|
+
invalid = [n for n in variables if not n.replace("_", "").isalnum()]
|
|
427
|
+
if invalid:
|
|
428
|
+
QMessageBox.warning(
|
|
429
|
+
self, "Invalid Variable Names",
|
|
430
|
+
"Variable names must be alphanumeric (underscores allowed):\n" + "\n".join(invalid)
|
|
431
|
+
)
|
|
432
|
+
return
|
|
433
|
+
|
|
434
|
+
# Collect Application Paths
|
|
435
|
+
v_nodes_dir = [
|
|
436
|
+
p.strip()
|
|
437
|
+
for p in self._v_nodes_dir_edit.toPlainText().splitlines()
|
|
438
|
+
if p.strip()
|
|
439
|
+
]
|
|
440
|
+
v_scripts_path = [
|
|
441
|
+
p.strip()
|
|
442
|
+
for p in self._v_scripts_path_edit.toPlainText().splitlines()
|
|
443
|
+
if p.strip()
|
|
444
|
+
]
|
|
445
|
+
|
|
446
|
+
# Persist and apply
|
|
447
|
+
env_manager.set_vibrante_pythonpath(paths)
|
|
448
|
+
env_manager.set_v_nodes_dir(v_nodes_dir)
|
|
449
|
+
env_manager.set_v_scripts_path(v_scripts_path)
|
|
450
|
+
env_manager.set_custom_variables(variables)
|
|
451
|
+
env_manager.reinitialize()
|
|
452
|
+
|
|
453
|
+
self.accept()
|
|
454
|
+
|
|
455
|
+
# ------------------------------------------------------------------
|
|
456
|
+
# Table helpers
|
|
457
|
+
# ------------------------------------------------------------------
|
|
458
|
+
|
|
459
|
+
def _append_var_row(self, name: str = "", value: str = ""):
|
|
460
|
+
row = self._var_table.rowCount()
|
|
461
|
+
self._var_table.insertRow(row)
|
|
462
|
+
self._var_table.setItem(row, 0, QTableWidgetItem(name))
|
|
463
|
+
self._var_table.setItem(row, 1, QTableWidgetItem(value))
|
|
464
|
+
|
|
465
|
+
def _add_variable_row(self):
|
|
466
|
+
self._append_var_row()
|
|
467
|
+
self._var_table.scrollToBottom()
|
|
468
|
+
row = self._var_table.rowCount() - 1
|
|
469
|
+
self._var_table.editItem(self._var_table.item(row, 0))
|
|
470
|
+
|
|
471
|
+
def _remove_variable_row(self):
|
|
472
|
+
rows = self._var_table.selectedItems()
|
|
473
|
+
if rows:
|
|
474
|
+
self._var_table.removeRow(self._var_table.currentRow())
|
|
475
|
+
|
|
476
|
+
def _import_settings(self):
|
|
477
|
+
"""Load settings from a JSON file and populate the UI widgets."""
|
|
478
|
+
path, _ = QFileDialog.getOpenFileName(
|
|
479
|
+
self, "Import Settings", "", "Vibrante Settings (*.json);;All Files (*)"
|
|
480
|
+
)
|
|
481
|
+
if not path:
|
|
482
|
+
return
|
|
483
|
+
try:
|
|
484
|
+
with open(path, "r", encoding="utf-8") as f:
|
|
485
|
+
data = json.load(f)
|
|
486
|
+
except Exception as exc:
|
|
487
|
+
QMessageBox.critical(self, "Import Failed", f"Could not read settings file:\n{exc}")
|
|
488
|
+
return
|
|
489
|
+
if not isinstance(data, dict):
|
|
490
|
+
QMessageBox.critical(self, "Import Failed", "Settings file format is invalid (expected a JSON object).")
|
|
491
|
+
return
|
|
492
|
+
|
|
493
|
+
# Populate UI widgets — user still clicks OK to persist
|
|
494
|
+
if "vibrante_pythonpath" in data and isinstance(data["vibrante_pythonpath"], list):
|
|
495
|
+
self._pythonpath_edit.setPlainText("\n".join(data["vibrante_pythonpath"]))
|
|
496
|
+
if "v_nodes_dir" in data and isinstance(data["v_nodes_dir"], list):
|
|
497
|
+
self._v_nodes_dir_edit.setPlainText("\n".join(data["v_nodes_dir"]))
|
|
498
|
+
if "v_scripts_path" in data and isinstance(data["v_scripts_path"], list):
|
|
499
|
+
self._v_scripts_path_edit.setPlainText("\n".join(data["v_scripts_path"]))
|
|
500
|
+
if "custom_variables" in data and isinstance(data["custom_variables"], dict):
|
|
501
|
+
self._var_table.setRowCount(0)
|
|
502
|
+
for name, value in data["custom_variables"].items():
|
|
503
|
+
self._append_var_row(str(name), str(value))
|
|
504
|
+
|
|
505
|
+
print(f"[Settings] Imported settings from: {path}")
|
|
506
|
+
|
|
507
|
+
def _export_settings(self):
|
|
508
|
+
"""Save the current UI state to a JSON file."""
|
|
509
|
+
path, _ = QFileDialog.getSaveFileName(
|
|
510
|
+
self, "Export Settings", "vibrante_settings.json",
|
|
511
|
+
"Vibrante Settings (*.json);;All Files (*)"
|
|
512
|
+
)
|
|
513
|
+
if not path:
|
|
514
|
+
return
|
|
515
|
+
|
|
516
|
+
# Read current UI state (not necessarily saved to config yet)
|
|
517
|
+
data = {
|
|
518
|
+
"vibrante_pythonpath": [
|
|
519
|
+
p.strip()
|
|
520
|
+
for p in self._pythonpath_edit.toPlainText().splitlines()
|
|
521
|
+
if p.strip()
|
|
522
|
+
],
|
|
523
|
+
"v_nodes_dir": [
|
|
524
|
+
p.strip()
|
|
525
|
+
for p in self._v_nodes_dir_edit.toPlainText().splitlines()
|
|
526
|
+
if p.strip()
|
|
527
|
+
],
|
|
528
|
+
"v_scripts_path": [
|
|
529
|
+
p.strip()
|
|
530
|
+
for p in self._v_scripts_path_edit.toPlainText().splitlines()
|
|
531
|
+
if p.strip()
|
|
532
|
+
],
|
|
533
|
+
"custom_variables": {
|
|
534
|
+
self._var_table.item(r, 0).text().strip(): self._var_table.item(r, 1).text().strip()
|
|
535
|
+
for r in range(self._var_table.rowCount())
|
|
536
|
+
if self._var_table.item(r, 0) and self._var_table.item(r, 0).text().strip()
|
|
537
|
+
},
|
|
538
|
+
}
|
|
539
|
+
try:
|
|
540
|
+
with open(path, "w", encoding="utf-8") as f:
|
|
541
|
+
json.dump(data, f, indent=2)
|
|
542
|
+
except Exception as exc:
|
|
543
|
+
QMessageBox.critical(self, "Export Failed", f"Could not write settings file:\n{exc}")
|
|
544
|
+
return
|
|
545
|
+
|
|
546
|
+
print(f"[Settings] Exported settings to: {path}")
|
|
547
|
+
|
|
548
|
+
def _browse_pythonpath(self):
|
|
549
|
+
directory = QFileDialog.getExistingDirectory(self, "Select Python Library Directory")
|
|
550
|
+
if directory:
|
|
551
|
+
current = self._pythonpath_edit.toPlainText().strip()
|
|
552
|
+
if current:
|
|
553
|
+
self._pythonpath_edit.setPlainText(current + "\n" + directory)
|
|
554
|
+
else:
|
|
555
|
+
self._pythonpath_edit.setPlainText(directory)
|
|
556
|
+
|
|
557
|
+
def _browse_v_nodes_dir(self):
|
|
558
|
+
directory = QFileDialog.getExistingDirectory(self, "Select Node Directory")
|
|
559
|
+
if directory:
|
|
560
|
+
current = self._v_nodes_dir_edit.toPlainText().strip()
|
|
561
|
+
if current:
|
|
562
|
+
self._v_nodes_dir_edit.setPlainText(current + "\n" + directory)
|
|
563
|
+
else:
|
|
564
|
+
self._v_nodes_dir_edit.setPlainText(directory)
|
|
565
|
+
|
|
566
|
+
def _browse_v_scripts_path(self):
|
|
567
|
+
directory = QFileDialog.getExistingDirectory(self, "Select Script Directory")
|
|
568
|
+
if directory:
|
|
569
|
+
current = self._v_scripts_path_edit.toPlainText().strip()
|
|
570
|
+
if current:
|
|
571
|
+
self._v_scripts_path_edit.setPlainText(current + "\n" + directory)
|
|
572
|
+
else:
|
|
573
|
+
self._v_scripts_path_edit.setPlainText(directory)
|
|
574
|
+
|
|
575
|
+
|