WIP
DirectOutput framework for virtual pinball cabinets WIP
|
Go to: Overview |
Global configuration for the DirectOutput framework.
More...
Public Member Functions | |
Dictionary< int, FileInfo > | GetIniFilesDictionary (string TableFilename="") |
Gets the a dictionary containing all ini files (file) and their number (key). More... | |
FileInfo | GetTableMappingFile (string TableFilename="") |
Gets a FileInfo object pointing to the table mapping file or null if no table mapping file exists. More... | |
FileInfo | GetShapeDefinitionFile (string TableFilename="", string RomName="") |
Gets the FileInfo object for the xml file defining the shapes to be used by DOF. More... | |
FileInfo | GetCabinetConfigFile () |
FileInfo object for the file containing the configuration of the cabinet (outputs, toys and so on). More... | |
DirectoryInfo | GetCabinetConfigDirectory () |
Gets the cabinet config directory. More... | |
FileInfo | GetTableConfigFile (string FullTableFilename) |
Gets a FileInfo object for the table config file. The file is lookued up using the list of the property TableConfigFilePatterns. If more than one file matches the search patterns, only the first file is returned. More... | |
string | GetLogFilename (string TableFilename="", string RomName="") |
Gets the log filename based on the LogFilePattern with replaced placeholders. More... | |
string | GlobalConfigDirectoryName () |
Path to the directory where the global config is stored (readonly). More... | |
DirectoryInfo | GetGlobalConfigDirectory () |
Gets a DirectoryInfo object for the global config directory. More... | |
FileInfo | GetGlobalConfigFile () |
Gets a FileInfo object for the global config file. More... | |
string | GetGlobalConfigXml () |
Returns a serialized XML representation of the global configuration. More... | |
void | SaveGlobalConfig (string GlobalConfigFilename="") |
Saves the GlobalConfig to the file specified in GlobalConfigFilename. Before saving the current global config file is backed up. More... | |
GlobalConfig () | |
Initializes a new instance of the GlobalConfig class. More... | |
Static Public Member Functions | |
static GlobalConfig | GetGlobalConfigFromConfigXmlFile (string GlobalConfigFileName) |
Instanciates a GlobalConfig object from a global configuration in a XML file. If the global config file does not exist or can not be loaded, null will be returned. More... | |
static GlobalConfig | GetGlobalConfigFromGlobalConfigXml (string ConfigXml) |
Instanciates a GlobalConfig object from a global configuration in a XML string. More... | |
Properties | |
int | LedWizDefaultMinCommandIntervalMs [get, set] |
Gets or sets the mininimal interval between command for LedWiz units in miliseconds (Default: 1ms). Depending on the mainboard, usb hardware on the board, usb drivers, OS and other factors the LedWiz does sometime tend to loose or misunderstand commands received if the are sent in to short intervals. The settings allows to increase the default minmal interval between commands from 1ms to a higher value. Higher values will make problems less likely, but decreases the number of possible updates of the ledwiz outputs in a given time frame. It is recommended to use the default interval of 1 ms and only to increase this interval if problems occur (Toys which are sometimes not reacting, random knocks of replay knocker or solenoids). This is only a default value. The min command interval can also be set on a per LedWiz base in the cabinet config. More... | |
int | LedControlMinimumEffectDurationMs [get, set] |
Gets or sets the minimum duration in milliseconds for LedControl effects occupying one output (e.g. contactors). This settings has no effect if a duration or blinking is defined for the LedControlEffect. If this value is not specified in the globalconfig file, 60 miliseconds will be used by default. More... | |
int | LedControlMinimumRGBEffectDurationMs [get, set] |
Gets or sets the minimum duration in milliseconds for LedControl effects controlling RGB leds. This settings has no effect if a duration or blinking is defined for the LedControlEffect. If this value is not specified in the globalconfig file, 120 miliseconds will be used by default. More... | |
string | IniFilesPath [get, set] |
Gets or sets the path to the ini files used for table configurations More... | |
FilePattern | ShapeDefintionFilePattern [get, set] |
Gets or sets the path and name for the file containing shape definitions. More... | |
FilePattern | CabinetConfigFilePattern [get, set] |
Gets or sets the path and name of the cabinet config file. More... | |
FilePatternList | TableConfigFilePatterns [get, set] |
Gets or sets the config file patterns used to looup the table configuration. More... | |
bool | EnableLogging [get, set] |
Gets or sets a value indicating whether impotant events in the framework are logged to a file. More... | |
bool | ClearLogOnSessionStart [get, set] |
Gets or sets a value indicating whether DOF clears the log file on session start. More... | |
FilePattern | LogFilePattern [get, set] |
Gets or sets the log file pattern. The log file pattern supports the following placeholders: More... | |
string | GlobalConfigFilename [get, set] |
Gets or sets the global config filename. More... | |
Global configuration for the DirectOutput framework.
Definition at line 18 of file GlobalConfig.cs.
DirectOutput.GlobalConfiguration.GlobalConfig.GlobalConfig | ( | ) |
Initializes a new instance of the GlobalConfig class.
Definition at line 682 of file GlobalConfig.cs.
DirectoryInfo DirectOutput.GlobalConfiguration.GlobalConfig.GetCabinetConfigDirectory | ( | ) |
Gets the cabinet config directory.
Definition at line 325 of file GlobalConfig.cs.
FileInfo DirectOutput.GlobalConfiguration.GlobalConfig.GetCabinetConfigFile | ( | ) |
FileInfo object for the file containing the configuration of the cabinet (outputs, toys and so on).
Definition at line 310 of file GlobalConfig.cs.
DirectoryInfo DirectOutput.GlobalConfiguration.GlobalConfig.GetGlobalConfigDirectory | ( | ) |
Gets a DirectoryInfo object for the global config directory.
Definition at line 519 of file GlobalConfig.cs.
FileInfo DirectOutput.GlobalConfiguration.GlobalConfig.GetGlobalConfigFile | ( | ) |
Gets a FileInfo object for the global config file.
Definition at line 548 of file GlobalConfig.cs.
|
static |
Instanciates a GlobalConfig object from a global configuration in a XML file.
If the global config file does not exist or can not be loaded, null will be returned.
GlobalConfigFileName | Name of the global config XML file. |
Definition at line 599 of file GlobalConfig.cs.
|
static |
Instanciates a GlobalConfig object from a global configuration in a XML string.
ConfigXml | XML string |
Definition at line 637 of file GlobalConfig.cs.
string DirectOutput.GlobalConfiguration.GlobalConfig.GetGlobalConfigXml | ( | ) |
Returns a serialized XML representation of the global configuration.
Definition at line 561 of file GlobalConfig.cs.
Dictionary<int, FileInfo> DirectOutput.GlobalConfiguration.GlobalConfig.GetIniFilesDictionary | ( | string | TableFilename = "" | ) |
Gets the a dictionary containing all ini files (file) and their number (key).
TableFilename | The table filename. |
Definition at line 100 of file GlobalConfig.cs.
string DirectOutput.GlobalConfiguration.GlobalConfig.GetLogFilename | ( | string | TableFilename = "" , |
string | RomName = "" |
||
) |
Gets the log filename based on the LogFilePattern with replaced placeholders.
TableFilename | The table filename. |
RomName | Name of the rom. |
Definition at line 446 of file GlobalConfig.cs.
FileInfo DirectOutput.GlobalConfiguration.GlobalConfig.GetShapeDefinitionFile | ( | string | TableFilename = "" , |
string | RomName = "" |
||
) |
Gets the FileInfo object for the xml file defining the shapes to be used by DOF.
Definition at line 256 of file GlobalConfig.cs.
FileInfo DirectOutput.GlobalConfiguration.GlobalConfig.GetTableConfigFile | ( | string | FullTableFilename | ) |
Gets a FileInfo object for the table config file.
The file is lookued up using the list of the property TableConfigFilePatterns. If more than one file matches the search patterns, only the first file is returned.
FullTableFilename | The table filename (The *.vpt file for the table, not the config file). |
Definition at line 369 of file GlobalConfig.cs.
FileInfo DirectOutput.GlobalConfiguration.GlobalConfig.GetTableMappingFile | ( | string | TableFilename = "" | ) |
Gets a FileInfo object pointing to the table mapping file or null if no table mapping file exists.
TableFilename | The table filename (optional). |
Definition at line 213 of file GlobalConfig.cs.
string DirectOutput.GlobalConfiguration.GlobalConfig.GlobalConfigDirectoryName | ( | ) |
Path to the directory where the global config is stored (readonly).
Definition at line 506 of file GlobalConfig.cs.
void DirectOutput.GlobalConfiguration.GlobalConfig.SaveGlobalConfig | ( | string | GlobalConfigFilename = "" | ) |
Saves the GlobalConfig to the file specified in GlobalConfigFilename.
Before saving the current global config file is backed up.
GlobalConfigFilename | (Optional)Global config filename. If no value is supplied the value of the property GlobalConfigFilename will be used. |
Definition at line 657 of file GlobalConfig.cs.
|
getset |
Gets or sets the path and name of the cabinet config file.
The path and name of the cabinet config file.
Definition at line 298 of file GlobalConfig.cs.
|
getset |
Gets or sets a value indicating whether DOF clears the log file on session start.
true
if DOF should clear the log file on session start; otherwise, false
.
Definition at line 406 of file GlobalConfig.cs.
|
getset |
Gets or sets a value indicating whether impotant events in the framework are logged to a file.
true
if logging is enabled, false
if logging is disabled.
Definition at line 392 of file GlobalConfig.cs.
|
getset |
Gets or sets the global config filename.
The global config filename.
Definition at line 538 of file GlobalConfig.cs.
|
getset |
Gets or sets the path to the ini files used for table configurations
The path to the directory containing the ini files used for table configurations.
Definition at line 89 of file GlobalConfig.cs.
|
getset |
Gets or sets the minimum duration in milliseconds for LedControl effects occupying one output (e.g. contactors).
This settings has no effect if a duration or blinking is defined for the LedControlEffect.
If this value is not specified in the globalconfig file, 60 miliseconds will be used by default.
The minimum effect duration in milliseconds.
Definition at line 57 of file GlobalConfig.cs.
|
getset |
Gets or sets the minimum duration in milliseconds for LedControl effects controlling RGB leds.
This settings has no effect if a duration or blinking is defined for the LedControlEffect. If this value is not specified in the globalconfig file, 120 miliseconds will be used by default.
The minimum effect duration in milliseconds.
Definition at line 73 of file GlobalConfig.cs.
|
getset |
Gets or sets the mininimal interval between command for LedWiz units in miliseconds (Default: 1ms). Depending on the mainboard, usb hardware on the board, usb drivers, OS and other factors the LedWiz does sometime tend to loose or misunderstand commands received if the are sent in to short intervals. The settings allows to increase the default minmal interval between commands from 1ms to a higher value. Higher values will make problems less likely, but decreases the number of possible updates of the ledwiz outputs in a given time frame. It is recommended to use the default interval of 1 ms and only to increase this interval if problems occur (Toys which are sometimes not reacting, random knocks of replay knocker or solenoids). This is only a default value. The min command interval can also be set on a per LedWiz base in the cabinet config.
The min interval between commands sent to LedWiz units in milliseconds.
Definition at line 40 of file GlobalConfig.cs.
|
getset |
Gets or sets the log file pattern.
The log file pattern supports the following placeholders:
The log file pattern.
Definition at line 435 of file GlobalConfig.cs.
|
getset |
Gets or sets the path and name for the file containing shape definitions.
The path and name of the file containing shape defintions.
Definition at line 247 of file GlobalConfig.cs.
|
getset |
Gets or sets the config file patterns used to looup the table configuration.
The table config file patterns.
Definition at line 357 of file GlobalConfig.cs.