Plugin Interface Reference
From English DMXCWiki
Plugin Interface References
All listed methods belong to class DMXCplugin_Helper. Therefore the following interfaces are known(?) as methods of an object of this class.
The interfaces are defined in two modules, which have to be imported into the interface module of the plugin:
Implements IDMXCplugin Implements IDMXCModule
The required type definitions are available in the library DMXCTypeLib.dll. Therefore this module has to be located in the program directory of DMXControl and declared in VB6 environment. To do this, select the menu point project ->"references" in VB6 and connect the DMXCTypeLib.dll library. You could use a local copy in your working directory.
Public mHelper
Following interfaces must be implemented in a plugin:
| Method | Called by | Description | Parameter/Variable/Return value |
|---|---|---|---|
| Private Function IDMXCplugin_Configure() As Boolean | plugin Configuration (button "Configure") | Calls the GUI for plugin Configuration, if available | IDMXCplugin_Configure (Boolean) informs, whether a Configuration menue exists |
| Private Function IDMXCplugin_Enable() As Boolean | plugin-Configuration/Start from menue "Windows" | May include function calls for activation of plugins (activate = set hook in plugin list) | IDMXCplugin_Enable (Boolean) informs whether the operations at activation were successful |
| Private Function IDMXCplugin_Disable() As Boolean | DMXControl | May include function calls for deactivation of plugin (Deactivate = remove hook in plugin list) | IDMXCplugin_Disable (Boolean) informs whether the operations at deactivation were succesfull |
| Private Function IDMXCplugin_Init(CallingAppTitle As String, MyFilename As String, DMXCpluginHelper As DMXCTypeLib.IpluginHelper) As Boolean | DMXControl (Load at program start) | May include function calls for initialising the plugins (Initialising = Load at program start) | |
| Private Function IDMXCplugin_Term() As Boolean | DMXControl (Closing the plugin) | May include function calls for das (the?) termination of plugin (Termination = Closing the plugin) | |
| Private Property Get IDMXCplugin_pluginName() As String | plugin Configuration | provides plugin name to plugin Configuration | IDMXCplugin_pluginName (String) |
| Private Property Get IDMXCModule_ModuleInfo() As DMXCTypeLib.Type_Module_Info | DMXControl at loading the programm | provides diverse informationen about the plugin (see table below) |
Within method IDMXCModule_ModuleInfo, the following fields must be adapted:
| Attribute | Description | Comment/Example |
|---|---|---|
| GUID | unique ID for plugin | "{b61b4c42-17ed-11da-94c3-00e08161165f}" (GUID generator) |
| Name | Bezeichnung des plugins in Configuration list, menu tree and Channel overview (mixer channels) | "blinking lights Demo plugin" |
| Description | additional description, currently not used | "Simple GUI for Lauflichter" |
| Author | name of implementor, currently not used | "Max Mustermann" |
| Experimental | shows experimental state in menu tree, (to be set, if not finally tested) | True/False |
| ProvidesToolWindow | defines, whether separate GUI window for plugin exists | True/False |
| Category | defines, in which category of menu tree the plugin is included | CAT_Control |
| FormName | provides VB name of plugin form(GUI) | "frmTutorMain" |
| Frm | provides a reference to plugin form | Set .Frm = frmTutorMain |
| ProvidesCommand | defines, whether Command is defined for plugin function, not yet supported | False |
| ProvidesSceneType | defines, whether plugin defines a new Scene type, not yet supported | False |
| UsesProvidedOutput | defines, whether plugin send signals to mixer | True |
| UsesMessaging | defines, whether plugin receives DMXControl-Messages | True/False |
| Messages | Collection, all received messages types to be added | Messages.Add MSG_Channel_Set |
Following functions can be called from plugin application:
| Method | Example | Description |
|---|---|---|
| Public Function SetChannel(Channel As Long, Value As Long, IgnoreChange As Boolean) | Call mHelper.MyStream.SetChannel(mDimmerAddr, dmxv, True) | Output of DMX value at the referenced channel. The third parameter defines, whether this value modification should be ignored within Scene administration. |
| Public Function DMXC_Channel_IsDimmer(Channel As Long) As Boolean . | Query, whether the channel is responsible for brightness of a devices | |
| Public Property Get DMXC_CHANNEL_MAXCHANNELS() As Long | Provides the number of highest channel in use | |
| Public Function DMXC_Channel_GetValue(Channel As Long) As Long | dmxValue = mHelper.ChannelGetValue(currentChannel) | The plugin can ask for current value. Is needed e.g. at plugin initialisation. |
The interfaces will be extended. Please start a discussion (or send an e-mail), about which additional functions are needed for your plugin.
