Skip to content

Plugin Manager Draft

Simon edited this page Jul 3, 2021 · 14 revisions

use cfg file to store paths for later use

// plugins.cfg -> save in MR dir (MESHROOM_INSTALL_DIR) as defined in meshroom/meshroom/init.py -> value=os.environ.get('ALICEVISION_SENSOR_DB', ''), InstantMeshesPath = 'c:\path\to\exe' var2 = 'c:\path\to\exe' //...

// In your script file def getVarFromFile(filename): import imp f = open(filename) global data data = imp.load_source('data', '', f) f.close()

# path to "config" file getVarFromFile('c:/plugins.cfg') print data.var1 print data.var2 print data.var3 ...

https://stackoverflow.com/questions/924700/best-way-to-retrieve-variable-values-from-a-text-file

Plugin Manager [draft]

  • Manager for external plugins (CLI and GUI) (install/remove)

  • list available external plugins with metadata (plugin summary and license/copyright, supported OS)

  • download python node to MR folder and external software or provide path to existing installation

  • New GUI menu entry "Plugins"

  • host production ready plugins in a dedicated location (github)

external plugins

Python 3 draft (or use PySide2)

import urllib.request

url = "https://raw.githubusercontent.com/natowi/meshroom_external_plugins/master/InstantMeshes.py"

print ("downloading")

filename, headers = urllib.request.urlretrieve(url, filename="lib\meshroom\nodes\aliceVision")

print ("download complete!")

Could be similar to Blender Plugin Manager:

plugins

Create external nodes Helper/Configurator

provide a GUI for creating nodes based on simple cli tools with known parameters

  • define tool path
  • define parameters and associate field types from gui
  • generate python node
Clone this wiki locally