Kodi Development 22.0
for Binary and Script based Add-Ons
 
All Classes Functions Variables Typedefs Enumerations Enumerator Modules Pages
Loading...
Searching...
No Matches

Detailed Description

Functions to manage the addon and get basic information about it

Function Documentation

◆ CInstanceGame()

CInstanceGame ( )
inline

Game class constructor.

Used by an add-on that supports only one game instance.

Kodi creates this class in the add-on.


Here's an example of how to use this:

#include <kodi/addon-instance/Game.h>
...
class ATTR_DLL_LOCAL CGameExample
{
public:
CGameExample()
{
}
virtual ~CGameExample();
{
}
...
};
ADDONCREATOR(CGameExample)
Definition AddonBase.h:772
Definition Game.h:118

◆ ~CInstanceGame()

~CInstanceGame ( )
overridedefault

Destructor.

◆ GameClientDllPath()

std::string GameClientDllPath ( ) const
inline

Callback to Kodi Function
The path of the game client being loaded.

Returns
The game client DLL path
Remarks
Only called from the add-on itself

◆ ProxyDllPaths()

bool ProxyDllPaths ( std::vector< std::string > & paths)
inline

Callback to Kodi Function
Paths to proxy DLLs used to load the game client.

Parameters
[out]pathsVector list to store available DLL paths
Returns
True if DLL paths were found, false otherwise
Remarks
Only called from the add-on itself

◆ ResourceDirectories()

bool ResourceDirectories ( std::vector< std::string > & dirs)
inline

Callback to Kodi Function
The "system" directories of the frontend.

These directories can be used to store system-specific ROMs such as BIOSes, configuration data, etc.

Parameters
[out]dirsVector list to store available resource directories
Returns
True if resource directories were found, false otherwise
Remarks
Only called from the add-on itself

◆ ProfileDirectory()

std::string ProfileDirectory ( ) const
inline

Callback to Kodi Function
The writable directory of the frontend.

This directory can be used to store SRAM, memory cards, high scores, etc, if the game client cannot use the regular memory interface, GetMemoryData().

Returns
The profile directory
Remarks
Only called from the add-on itself

◆ SupportsVFS()

bool SupportsVFS ( ) const
inline

Callback to Kodi Function
The value of the <supports_vfs> property from addon.xml.

Returns
True if VFS is supported, false otherwise
Remarks
Only called from the add-on itself

◆ Extensions()

bool Extensions ( std::vector< std::string > & extensions)
inline

Callback to Kodi Function
The extensions in the <extensions> property from addon.xml.

Parameters
[out]extensionsVector list to store available extensions
Returns
True if successful and extensions were found, false otherwise
Remarks
Only called from the add-on itself

◆ CInstanceShaderPreset()

Shader preset class constructor.

Used by an add-on that only supports Shader Presets, and only in one instance.

This class is created in the addon by Kodi.


Here's an example of how to use this class:

#include <kodi/addon-instance/ShaderPreset.h>
...
class ATTR_DLL_LOCAL CShaderPresetExample
{
public:
CShaderPresetExample()
{
}
virtual ~CShaderPresetExample();
{
}
...
};
ADDONCREATOR(CShaderPresetExample)
Definition ShaderPreset.h:33

◆ ~CInstanceShaderPreset()

~CInstanceShaderPreset ( )
overridedefault

Destructor.

◆ UserPath()

std::string UserPath ( ) const
inline

Used to get the full path to the add-on's user profile.

Returns
Path to the user profile
Remarks
Only called from the add-on

◆ AddonPath()

std::string AddonPath ( ) const
inline

Used to get the full path where the add-on is installed.

Returns
The add-on installation path
Remarks
Only called from the add-on itself

◆ PresetFileNew()

virtual preset_file PresetFileNew ( const char * path)
inlinevirtual

Loads a preset file

Parameters
pathThe path to the preset file
Returns
The preset file, or NULL if file doesn't exist

◆ PresetFileFree()

virtual void PresetFileFree ( preset_file file)
inlinevirtual

Free a preset file

◆ ShaderPresetRead()

virtual bool ShaderPresetRead ( preset_file file,
video_shader & shader )
inlinevirtual

Loads preset file and all associated state (passes, textures, imports, etc)

Parameters
filePreset file to read from
shaderShader passes handle
Returns
True if successful, otherwise false

◆ ShaderPresetWrite()

virtual void ShaderPresetWrite ( preset_file file,
const video_shader & shader )
inlinevirtual

Save preset and all associated state (passes, textures, imports, etc) to disk.

Parameters
filePreset file to read from
shaderShader passes handle

◆ ShaderPresetResolveParameters()

virtual bool ShaderPresetResolveParameters ( preset_file file,
video_shader & shader )
inlinevirtual

Resolve all shader parameters belonging to the shader preset.

Parameters
filePreset file to read from
shaderShader passes handle
Returns
True if successful, otherwise false

◆ ShaderPresetFree()

virtual void ShaderPresetFree ( video_shader & shader)
inlinevirtual

Free all state related to shader preset.

Parameters
Theshader object to free