Version 2 vs 3
Version 2 vs 3
Edits
Edits
- Edit by 0xseantasker, Version 3
- Dec 24 2016 1:45 AM
- Edit by 0xseantasker, Version 2
- Aug 10 2015 7:41 AM
« Previous Change | Next Change » |
Edit Older Version 2... | Edit Older Version 3... |
Content Changes
Content Changes
The `Application` class takes care of a lot of the common work an application might do for initialisation. For initialisation it can be given the name of a configuration file which will be loaded to get the settings for the application. If you prefer you can initialise using a `Configuration` object directly rather than loading the configuration from a file.
The following is a list of configuration options that you can use and what each does.
Depending on the complexity of your application you may end up with a configuration file for each platform you target. This is because the configuration file might contain platform specific options or need to have different values for each platforms.
|Option|Type|Valid values|Description|
|network|bool|1, 0|Defines whether to initialise the network manager|
|network.update-mode|string|kernel, network.events, none|The network manager update mode|
|network.redirect-cout|string|connection information string. For example direct:127.0.0.1:20154|The server to redirect cout to|
|network.redirect-cout.reconnect-time|float|any|The number of seconds to wait before attempting a reconnect if the connection is dropped.|
|network.redirect-cout.dual-local|bool|1, 0|if true and redirection is set up output will go to the local stream before redirection as well.|
|resolution.x|u32|any|The x resolution of the default render target.|
|resolution.y|u32|any|The y resolution of the default render target.|
|fullscreen|bool|1, 0|Flag to indicate that the default render target should be made full screen. This feature depends on support on the target platform.|
|window.title|string|any|The title of the default render target window. This value may not be used on some platforms.|
|audio|string|Default or platform specific value|The audio system to use. If not specified the default will be used.|
|render.target|string|Platform specific value|When specified the application will attempt to create a render target using a bound factory method. Typically platforms support "Window(x,y,bitdepth,fullscreenflag)" but this isn't guaranteed. This option can be specified multiple times to create multiple render targets.|
|material.list|string|file name|A file containing a list of material resources to load.|
|texture.list|string|file name|A file containing a list of text resources to load. The texture manager doesn't explicitly need a texture list as it accepts file names as resource names and will load it if the resource hasn't been specified before hand.|
|skeleton.list|string|file name|A file containing a list of skeleton resources to load.|
|mesh.list|string|file name|A file containing a list of mesh resources to load.|
|font.list|string|file name|A file containing a list of font resources to load.|
|vertex.shader.list|string|file name|A file containing a list of vertex shader resources to load.|
|fragment.shader.list|string|file name|A file containing a list of fragment shader resources to load.|
The `Application` class takes care of a lot of the common work an application might do for initialisation. For initialisation it can be given the name of a configuration file which will be loaded to get the settings for the application. If you prefer you can initialise using a `Configuration` object directly rather than loading the configuration from a file.
The following is a list of configuration options that you can use and what each does.
Depending on the complexity of your application you may end up with a configuration file for each platform you target. This is because the configuration file might contain platform specific options or need to have different values for each platforms.
|Option|Type|Valid values|Description|
|network|bool|1, 0|Defines whether to initialise the network manager|
|network.update-mode|string|kernel, network.events, none|The network manager update mode|
|network.redirect-cout|string|connection information string. For example direct:127.0.0.1:20154|The server to redirect cout to|
|network.redirect-cout.reconnect-time|float|any|The number of seconds to wait before attempting a reconnect if the connection is dropped.|
|network.redirect-cout.dual-local|bool|1, 0|if true and redirection is set up output will go to the local stream before redirection as well.|
|resolution.x|u32|any|The x resolution of the default render target.|
|resolution.y|u32|any|The y resolution of the default render target.|
|fullscreen|bool|1, 0|Flag to indicate that the default render target should be made full screen. This feature depends on support on the target platform.|
|window.title|string|any|The title of the default render target window. This value may not be used on some platforms.|
|audio|string|Default or platform specific value|The audio system to use. If not specified the default will be used.|
|render.target|string|Platform specific value|When specified the application will attempt to create a render target using a bound factory method. Typically platforms support "Window(x,y,bitdepth,fullscreenflag)" but this isn't guaranteed. This option can be specified multiple times to create multiple render targets.|
|material.list|string|file name|A file containing a list of material resources to load.|
|texture.list|string|file name|A file containing a list of text resources to load. The texture manager doesn't explicitly need a texture list as it accepts file names as resource names and will load it if the resource hasn't been specified before hand.|
|skeleton.list|string|file name|A file containing a list of skeleton resources to load.|
|mesh.list|string|file name|A file containing a list of mesh resources to load.|
|font.list|string|file name|A file containing a list of font resources to load.|
|vertex.shader.list|string|file name|A file containing a list of vertex shader resources to load.|
|fragment.shader.list|string|file name|A file containing a list of fragment shader resources to load.|
|kernel.frame-time.min|Seconds|floating point numbers representing seconds|The minimum time the kernel should take per frame. Setting value can be useful for saving processing and battery power. If your frame time is less than this value the process will sleep for a short period of time so the CPU can perform other work (or save power). The default value is 0.01666667 which approximates to 60 frame per second.|
|kernel.frame-time.max-delta|Seconds|floating point numbers representing seconds|The maximum time the kernel will use as the `lastFrameTime` in Task updates. This value **does not** limit the time a frame can process, only the upper value that Tasks can receive as a parameter in their `Update()` method. The default value for this option is 1 second|
|kernel.frame-rate.fps|integer|any values greater than 0|The number of frames per second that the kernel is expected to run at. This can be used as an alternative way to set `kernel.frame-time.min` since it might be a more natural way for some people to think about frame time limits. If both this option and `kernel.frame-time.min` are present, `kernel.frame-time.min` will take priority.
|audio.player.list|string|file name|A file that lists the resources for the Application's AudioPlayer instance.|
The `Application` class takes care of a lot of the common work an application might do for initialisation. For initialisation it can be given the name of a configuration file which will be loaded to get the settings for the application. If you prefer you can initialise using a `Configuration` object directly rather than loading the configuration from a file.
The following is a list of configuration options that you can use and what each does.
Depending on the complexity of your application you may end up with a configuration file for each platform you target. This is because the configuration file might contain platform specific options or need to have different values for each platforms.
|Option|Type|Valid values|Description|
|network|bool|1, 0|Defines whether to initialise the network manager|
|network.update-mode|string|kernel, network.events, none|The network manager update mode|
|network.redirect-cout|string|connection information string. For example direct:127.0.0.1:20154|The server to redirect cout to|
|network.redirect-cout.reconnect-time|float|any|The number of seconds to wait before attempting a reconnect if the connection is dropped.|
|network.redirect-cout.dual-local|bool|1, 0|if true and redirection is set up output will go to the local stream before redirection as well.|
|resolution.x|u32|any|The x resolution of the default render target.|
|resolution.y|u32|any|The y resolution of the default render target.|
|fullscreen|bool|1, 0|Flag to indicate that the default render target should be made full screen. This feature depends on support on the target platform.|
|window.title|string|any|The title of the default render target window. This value may not be used on some platforms.|
|audio|string|Default or platform specific value|The audio system to use. If not specified the default will be used.|
|render.target|string|Platform specific value|When specified the application will attempt to create a render target using a bound factory method. Typically platforms support "Window(x,y,bitdepth,fullscreenflag)" but this isn't guaranteed. This option can be specified multiple times to create multiple render targets.|
|material.list|string|file name|A file containing a list of material resources to load.|
|texture.list|string|file name|A file containing a list of text resources to load. The texture manager doesn't explicitly need a texture list as it accepts file names as resource names and will load it if the resource hasn't been specified before hand.|
|skeleton.list|string|file name|A file containing a list of skeleton resources to load.|
|mesh.list|string|file name|A file containing a list of mesh resources to load.|
|font.list|string|file name|A file containing a list of font resources to load.|
|vertex.shader.list|string|file name|A file containing a list of vertex shader resources to load.|
|fragment.shader.list|string|file name|A file containing a list of fragment shader resources to load.|
|kernel.frame-time.min|Seconds|floating point numbers representing seconds|The minimum time the kernel should take per frame. Setting value can be useful for saving processing and battery power. If your frame time is less than this value the process will sleep for a short period of time so the CPU can perform other work (or save power). The default value is 0.01666667 which approximates to 60 frame per second.|
|kernel.frame-time.max-delta|Seconds|floating point numbers representing seconds|The maximum time the kernel will use as the `lastFrameTime` in Task updates. This value **does not** limit the time a frame can process, only the upper value that Tasks can receive as a parameter in their `Update()` method. The default value for this option is 1 second|
|kernel.frame-rate.fps|integer|any values greater than 0|The number of frames per second that the kernel is expected to run at. This can be used as an alternative way to set `kernel.frame-time.min` since it might be a more natural way for some people to think about frame time limits. If both this option and `kernel.frame-time.min` are present, `kernel.frame-time.min` will take priority.
|audio.player.list|string|file name|A file that lists the resources for the Application's AudioPlayer instance.|