Plugins
Plugins work in Photogrok version 2.65 or higher. Previous sample scripts still work and can be found here.

A plugin is a JS program that can interact with other plugins and PhotoGrok. More detailed documentation is on the way but you can view the code here and use the examples to create your own plugins. You can auto-load these plugins by pasting the following three lines into the script editor (you must adjust the paths for your installation):

load('path_to_defaults.js');
var ds = new DefaultSetup('path_to_plugins_directory');
ds.init();

NOTE: Fresh installs of PhotoGrok now create this code for you. Comment out or delete the added lines if you do not want to run any plugins. You can also edit default.js to load only the plugins you want.

Many of these example plugins create menu items in PhotoGrok. Either top-level "User" menu items or pop-up menu items from right-clicking on photos or tree nodes. The plugins provide simple help dialogs which can be found in the PhotoGrok "Help" menu. Painters and filters are display only and do not alter your saved images. You can try these individually by pasting the source into the script editor. You may also need util.js for some plugins to work.

A plugin object can typically be accessed by it's name from other scripts. Functions that can be called should be documented in the help dialog for that plugin. For example, to change the default painter used by the Filler plugin to the psychedelic painter from the Psych plugin, enter the following via CTRL+SHIFT+J or CTRL+SHIFT+E (don't forget to activate the Filler plugin from the menu):

Filler.setFillerPainter(Psych.getPainter());
Expect updated plugins to be added over time. Let me know if you develop a plugin you would like to see added to this list.