blendersynth.utils.blender_setup.blender_locator
- blendersynth.utils.blender_setup.blender_locator.find_blender_python(blender_path)[source]
Given a blender executable, find the python interpreter it uses
- Parameters:
blender_path (
str
) – path to blender executable- Return type:
str
- blendersynth.utils.blender_setup.blender_locator.get_blender_path()[source]
Return blender path, or None if no config file found
- Return type:
str
- blendersynth.utils.blender_setup.blender_locator.is_blender_in_path()[source]
Check if blender is in the PATH (i.e. can be run from the command line with ‘blender’)
- Return type:
bool
- blendersynth.utils.blender_setup.blender_locator.read_from_config(key, section='BLENDER_SETUP')[source]
Load config, and read value from cfg[section]
- blendersynth.utils.blender_setup.blender_locator.remove_from_config(key, section='BLENDER_SETUP')[source]
Load config, and remove key from cfg[section]
- blendersynth.utils.blender_setup.blender_locator.set_blender_path(_blender_path=None)[source]
First time set-up of Blender Path. Will try to find Blender path in following order of precedence: :rtype:
str
Input argument _blender_path
Environment variable BLENDER_PATH
Blender in PATH
Ask user for path
When it finds a valid path, it will save it to the Config file stored in user’s platformdirs.user_config_dir