C# Класс OpenBveApi.Textures.TextureInterface

Represents the interface for loading textures. Plugins must implement this interface if they wish to expose textures.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
CanLoadTexture ( string path ) : bool

Checks whether the plugin can load the specified texture.

Load ( Hosts host ) : void

Called when the plugin is loaded.

LoadTexture ( string path, Texture &texture ) : bool

Loads the specified texture.

QueryTextureDimensions ( string path, int &width, int &height ) : bool

Queries the dimensions of a texture.

Unload ( ) : void

Called when the plugin is unloaded.

Описание методов

CanLoadTexture() публичный абстрактный Метод

Checks whether the plugin can load the specified texture.
public abstract CanLoadTexture ( string path ) : bool
path string The path to the file or folder that contains the texture.
Результат bool

Load() публичный Метод

Called when the plugin is loaded.
public Load ( Hosts host ) : void
host Hosts The host that loaded the plugin.
Результат void

LoadTexture() публичный абстрактный Метод

Loads the specified texture.
public abstract LoadTexture ( string path, Texture &texture ) : bool
path string The path to the file or folder that contains the texture.
texture Texture Receives the texture.
Результат bool

QueryTextureDimensions() публичный абстрактный Метод

Queries the dimensions of a texture.
public abstract QueryTextureDimensions ( string path, int &width, int &height ) : bool
path string The path to the file or folder that contains the texture.
width int Receives the width of the texture.
height int Receives the height of the texture.
Результат bool

Unload() публичный Метод

Called when the plugin is unloaded.
public Unload ( ) : void
Результат void