C# Класс TextureBogusExtension, mapa-de-calor

Add a feature to the Texture class which allows you to detect the case when you have attempted to download a bogus WWW Texture. by Matt "Trip" Maker, Monstrous Company :: http://monstro.us TODO could also use the filesystem cache to keep the example error image between runs. from http://unifycommunity.com/wiki/index.php?title=TextureBogusExtensions
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
ready bool

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

Метод Описание
Equivalent ( Array, bytes1, Array, bytes2 ) : bool

Compare two byte arrays.

Init ( MonoBehaviour, bhv ) : void

Get an example of whatever the current "error" texture is. (At the time of this writing, an "upside down red question mark on a white background".)

asPNGDeclaration ( Texture, tex ) : string

Express the texture in the form of the C# code that would be necessary to represent a PNG of it.

isBogus ( Array, png ) : bool
isBogus ( Texture, tex ) : bool

The easy way: compare to a saved version of the question mark image, expressed here as an array of bytes.

obtainExampleBogusTexture ( ) : IEnumerator,

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

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

Compare two byte arrays.
public static Equivalent ( Array, bytes1, Array, bytes2 ) : bool
bytes1 Array, /// A ///
bytes2 Array, /// A ///
Результат bool

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

Get an example of whatever the current "error" texture is. (At the time of this writing, an "upside down red question mark on a white background".)
public static Init ( MonoBehaviour, bhv ) : void
bhv MonoBehaviour,
Результат void

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

Express the texture in the form of the C# code that would be necessary to represent a PNG of it.
public static asPNGDeclaration ( Texture, tex ) : string
tex Texture, /// A ///
Результат string

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

public static isBogus ( Array, png ) : bool
png Array,
Результат bool

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

The easy way: compare to a saved version of the question mark image, expressed here as an array of bytes.
public static isBogus ( Texture, tex ) : bool
tex Texture, /// A ///
Результат bool

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

public static obtainExampleBogusTexture ( ) : IEnumerator,
Результат IEnumerator,

Описание свойств

ready публичное статическое свойство

public static bool ready
Результат bool